<meter id="pryje"><nav id="pryje"><delect id="pryje"></delect></nav></meter>
          <label id="pryje"></label>

          新聞中心

          EEPW首頁(yè) > 嵌入式系統(tǒng) > 設(shè)計(jì)應(yīng)用 > wincc中使用vbs常用函數(shù)

          wincc中使用vbs常用函數(shù)

          作者: 時(shí)間:2011-06-23 來(lái)源:網(wǎng)絡(luò) 收藏
          28.second()

          本文引用地址:http://www.ex-cimer.com/article/150569.htm

            功能:返回一個(gè)整數(shù)值.

            格式:second(time)

            參數(shù):time是一個(gè)有效的時(shí)間表達(dá)式;

            例子lt;% =second(# 12:28:30#) %>

            結(jié)果:30

            29.strReverse()

            功能:返回與原字符串排列逆向的字符串.

            格式:strreverse(string)

            參數(shù):string是字符串

            例子% =strreverse(“this is a test!”)

            結(jié)果:!tset a si siht

            30.time()

            功能:返回當(dāng)前系統(tǒng)的時(shí)間值.

            格式:time()

            參數(shù):無(wú)

            結(jié)果:9:58:28 Am

            31.函數(shù)trim()

            功能:刪去字符串前,后的空格.

            格式:trim(string)

            參數(shù):string 字符串.

            例子:

            %

            strtest=“ this is a test! ”

            response.write trim(strtest)

            %>

            結(jié)果:this is a test!

            32.函數(shù)UBound()

            功能:返回一個(gè)數(shù)組的上界.

            格式:Ubound(expression_r [,dimension])

            參數(shù):expression_r 是數(shù)組表達(dá)式/數(shù)組變量,dimension 是任意項(xiàng)

            例子:

            %

            i = array(“1”,”2”,”3”)

            response.write ubound(i)

            %>

            結(jié)果: 2

            33.函數(shù):UCase()

            功能:將一字符類(lèi)型變量的字符全部變換成大寫(xiě)字符.

            格式:Ucase(string)

            參數(shù):string是字符串變量

            例子:

            %

            str=“THIS is Lcase!”

            response.write Lcase(str)

            %>

            結(jié)果:THIS IS LCASE!

            34.函數(shù)Vartype()

            功能:返回變量的常量代碼(整數(shù))

            格式:Vartype(varname)

            參數(shù):varname是任何類(lèi)型的變量名稱(chēng).

            例子:

            %

            i=5

            response.write vartype(i)

            %>

            結(jié)果:2 (2表示整數(shù),須要參考ASP常量代碼.)

            35.函數(shù)Weekday()

            功能:返回一個(gè)整數(shù),對(duì)應(yīng)一周中的第幾天.

            格式:Weekday(date [,firstofweek])

            參數(shù): date為日期變量,firstofweek為任選項(xiàng).

            例子:

            %

            d= # 5/9/00 #

            response.write weekday(d) %>

            結(jié)果:3(3 表示是星期二)

            36.函數(shù)weekdayname()

            功能:返回字符串,對(duì)應(yīng)星期幾.

            格式:weekdayname(weekday[,abb[,firstdayofweek]])

            參數(shù):weekday為日期變量,abb,firstdayofweek為任選項(xiàng).

            例子:

            %

            d = #8/4/99#

            response.write weekdayname(d)

            %>

            結(jié)果: Wednesday

            37.函數(shù)year()

            功能:返回日期表達(dá)式所在的年份.

            格式:year(date)

            參數(shù): date是有效的日期表達(dá)式

            例子:

            % =year(#8/9/99#) %>

            結(jié)果:1999

            38.函數(shù)Mod()功能:取余數(shù).

            例子:3 Mod 2

            結(jié)果:1


          上一頁(yè) 1 2 3 4 下一頁(yè)

          關(guān)鍵詞: 函數(shù) 常用 vbs 使用 wincc

          評(píng)論


          相關(guān)推薦

          技術(shù)專(zhuān)區(qū)

          關(guān)閉
          看屁屁www成人影院,亚洲人妻成人图片,亚洲精品成人午夜在线,日韩在线 欧美成人 (function(){ var bp = document.createElement('script'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') { bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; } else { bp.src = 'http://push.zhanzhang.baidu.com/push.js'; } var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(bp, s); })();