'####################view script##################################
rndName = GetRandomName()
Tel = RandomNumbers(1, 99999999)
Email = GetRandomEmail()
Browser(1).Page("32303133A578A55FB0EABBDAC2A7AB7EBA5BA4E5A8E3AE695F31").Edit("txtName").Value=rndName
Browser(1).Page("32303133A578A55FB0EABBDAC2A7AB7EBA5BA4E5A8E3AE695F31").Edit("txtPhone").Value=Tel
Browser(1).Page("32303133A578A55FB0EABBDAC2A7AB7EBA5BA4E5A8E3AE695F31").Edit("txtEmail").Value=Email
Browser(1).Page("32303133A578A55FB0EABBDAC2A7AB7EBA5BA4E5A8E3AE695F31").Image("送出").Click
Browser(1).Page("32303133A578A55FB0EABBDAC2A7AB7EBA5BA4E5A8E3AE695F31").Edit("txtCkeckCode").Value="9BSRU"
Browser(1).Page("32303133A578A55FB0EABBDAC2A7AB7EBA5BA4E5A8E3AE695F31").Image("送出").Click
Browser(1).Dialog("網頁訊息").Button("確定").Click
Browser(1).Tools.NavigateBack
'以上code 由web replay自行產生,page的欄位編碼我轉過,基本上不會產生這種東西。
'####################include script##################################
Function RandomNumbers(Lowest, Highest) Randomize RandomNumbers = Int((Highest + 1 - Lowest) * Rnd + Lowest) End Function Function GetRandomEmail() Randomize length = 8 tmpEmail = "" ext = "@yahoo.com.tw" For i = 1 To length tmpAsc = Int(26 * Rnd + 97) tmpNum = tmpNum & Int((9 + 1 - 1) * Rnd + 1) tmpEmail = tmpEmail & Chr(tmpAsc) Next GetRandomEmail = tmpEmail & tmpNum & ext End Function Function GetRandomName() o = "偉勇毅俊峰強平保東文輝力明永健世廣志義興良海山仁波寧貴福生龍元勝學祥才發武新利清飛彬富順信子傑昌成星光天達安岩中茂進林有堅和博誠先敬震振壯會思群心邦承樂紹功松善厚慶磊民友裕河江超浩亮政謙亨奇翰朗宏言若朋斌啟倫翔旭鵬澤晨建家致樹炎德行時泰盛雄鈞冠策騰楠榕風弘" '男名第一字www.12264.com o2 = "偉剛勇毅俊峰強軍平保東文輝力明永健世廣志義興良海山仁波寧貴福生龍元全國勝學祥才發武新利清飛彬富順信子傑濤昌成康星光天達安岩中茂進林有堅和彪博誠先敬震振壯會思群豪心邦承樂功松善厚慶磊民友裕河江超浩亮政謙亨奇固之翰宏言若鳴朋斌維克倫翔旭鵬建家致樹炎德行時泰盛雄鈞冠策騰楠榕風航弘" '男名第二字 o3 = "秀英華慧巧美娜靜淑惠珠翠雅芝玉萍紅玲芬芳燕彩春菊蘭鳳潔梅琳素雲蓮真環雪妹霞香月鶯媛艷佳嘉瓊珍莉桂葉璐琦晶妍茜秋珊錦黛倩婷婉嫻瑾露瑤怡嬋雁蓓儀荷丹蓉眉君琴蕊薇菁夢嵐苑婕馨瑗韻聰純毓悅昭冰爽琬羽希欣飄馥柔曉歡芸菲宜可姬舒麗陽妮嬌靈琪晴容雯萱彥宇雨藍翠煙" '女名第一字 o4 = "秀娟英華慧巧美娜靜淑惠珠翠雅玉萍紅娥玲芬芳燕彩春菊蘭鳳潔梅琳素雲蓮真環雪妹霞香月鶯媛艷佳嘉瓊珍莉桂葉璐琦晶妍茜秋珊錦黛倩婷婉嫻瑾露瑤怡嬋雁蓓儀荷丹蓉眉君琴蕊薇菁夢嵐苑婕馨瑗韻聰純毓悅昭冰爽琬羽希欣飄馥柔曉歡芸菲宜可姬舒麗陽妮嬌靈琪晴容雯萱彥宇雨曼藍兒翠煙" '女名第一字 Randomize x1 = "趙錢孫李周吳鄭王馮陳衛蔣沈韓楊朱許何呂施張孔曹嚴陶戚謝鄒蘇潘範彭馬花方任袁柳唐費薛雷賀湯羅畢傅顧孟黃穆姚邵毛狄戴宋龐熊紀舒屈項祝董梁杜阮賈江童顏郭梅林鍾徐駱高蔡田胡霍盧莫柯房丁鄧單洪包崔龔程裴翁仇劉詹葉邰賴卓喬譚溫莊習易廖耿聶關" '百家姓中常見單姓 x2 = Len(x1) x3 = o x4 = Len(x3) x5 = o2 x6 = Len(x5) x7 = Mid(x3, Int(Rnd * x4) + 1, 1) x8 = Mid(x5, Int(Rnd * x6) + 1, 1) x9 = Mid(x1, Int(Rnd * x2) + 1, 1) z = x9 & x7 & x8 '最終的名字,換成z = x9 & Space(2) & x7 為單字名字www.12264.com GetRandomName = z '顯示名字 End Function
沒有留言:
張貼留言