uipath2017里invoke code函数

invoke code这个控件,感觉像一个方法体。我们可以在里面写函数,方法。定义类的语句好像就不行了。

亲测,亲测,replace方法不可用。

documentdate=Mid(tmp,20,15) 从tmp里第20个字符开始,截取15个字符

companycode=Split(tmp,"TO:"+vbNewLine)(1) 从tmp里"TO:+\n"截取,取第二块值

For  i=0 To ii-1                      for嵌套if的语句
		If checkdt.Rows(i)(0).ToString = companycode Then
			companycode=checkdt.Rows(i)(1).ToString
                        EXIT FOR 退出for循环的key
		End If
	Next
If month = " JAN" Then 土办法,还可以用case
 month="01" 
 Else If month =" FEB" Then 
  month="02" 
  Else If month=" MAR" Then 
   month="03"
   Else If month=" APL" Then 
    month="04"
    Else If month=" MAY" Then 
     month="05"
     Else If month=" JAN" Then 
      month="06"
      Else If month=" JUL" Then 
       month="07"
       Else If month=" AUG" Then 
        month="08"
        Else If month=" SEP" Then 
         month="09"
         Else If month=" OCT" Then 
          month="10"
          Else If month=" NOV" Then 
           month="11"
           Else If month=" DEC" Then 
            month="12"
            End If
//case方法 也是可用的
Select Case month
Case "1"
	month="Jan"
Case "2"
	month="Feb"
Case "7"
	month="Jul"
Case Else
	month="error"
End Select
While i<>0        while语句
documentnumber=datasource.Substring(i,10)'查找documentnumber
datasource=Split(datasource,documentnumber)(1)
'console.WriteLine(documentnumber)'''''''''''''''''
id=id+","+documentnumber
i=InStr(datasource," 1930")
End While

 

 

 

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值