上一篇主題 :: 下一篇主題 |
發表人 |
內容 |
TPECI
註冊時間: 2004-07-22 文章: 17
第 1 樓
|
發表於: 星期五 三月 11, 2005 10:44 am 文章主題: VFP送簡訊到手機 ? |
|
|
可以從PC VFP送簡訊到手機嗎 ? VFP用什麼指令?
經由普通電話線就可以嗎? 謝謝! |
|
回頂端 |
|
|
syntech
註冊時間: 2003-05-16 文章: 4212 來自: Taipei,Taiwan
第 2 樓
|
|
回頂端 |
|
|
rixw83
註冊時間: 2004-07-12 文章: 12
第 3 樓
|
發表於: 星期六 六月 18, 2005 11:07 am 文章主題: |
|
|
用ㄧ個 WinSock , ㄧ個 Timer , 數個輸入文字方塊
***************************************
&& Code Begin Here
&& PhoneMsg ==> WinSock 元件的名稱
If Thisform.PhoneMsg.Object.State = 7
If Used('MBTMP')
Thisform.Txt_RCNO.Value = Alltrim(MBTMP.行動電話)
Endif
XX_ACCU = Left(Alltrim(Thisform.Txt_USER.Value) + Space(,
XX_PASS = Left(Alltrim(Thisform.Txt_PASS.Value) + Space(,
XX_SNDN = Left(Alltrim(Thisform.Txt_SNNO.Value) + Space(12),12)
XX_RCNO = Left(Alltrim(Thisform.Txt_RCNO.Value) + Space(12),12)
XX_ENCD = Left(Alltrim(Thisform.Txt_CODE.Value) + Space(5),5)
XX_TIME = Left(Alltrim(Thisform.Txt_TIME.Value) + Space(6),6)
XX_LENT = Right('000' + Alltrim(Str(Thisform.Txt_LENG.Value)),3)
XX_NOTE = Alltrim(Thisform.EDIT_TEXTBODY.Value)
If Empty(Alltrim(XX_RCNO))
Thisform.Timer1.Enabled = .F.
Wait Clear
= Messagebox("無法傳送服務訊息 !!",48,"提示訊息 !!")
Else
Wait '正在傳送訊息給 ' + Alltrim(XX_RCNO) + ' 門號中...' Window Nowait
XX_MSG = XX_ACCU + XX_PASS + XX_SNDN + XX_RCNO + XX_ENCD + XX_TIME + XX_LENT + XX_NOTE
Thisform.PhoneMsg.Object.SendData(XX_MSG)
Endif
Else
Wait Clear
XX_RCNO = Alltrim(Thisform.Txt_RCNO.Value)
= Messagebox("傳送訊息給 " + XX_RCNO + "時遭到不明的中斷,無法繼續傳送 !!",16,"錯誤訊息 !!")
*Thisform.PhoneMsg.Object.Close()
Endif
&& Code End Here
**********************************************************************************
已經發過數萬通囉!! _________________ It's Me And My Super Rich Kw. |
|
回頂端 |
|
|
rixw83
註冊時間: 2004-07-12 文章: 12
第 4 樓
|
發表於: 星期六 六月 18, 2005 11:10 am 文章主題: |
|
|
奇怪
XX_ACCU = Left(Alltrim(Thisform.Txt_USER.Value) + Space(8 ),8 )
XX_PASS = Left(Alltrim(Thisform.Txt_PASS.Value) + Space(8 ),8 )
這兩行怎麼這樣 ~~ 哇哩勒 ~~ _________________ It's Me And My Super Rich Kw. |
|
回頂端 |
|
|
bigear
註冊時間: 2004-12-19 文章: 162 來自: 網路的另一端
第 5 樓
|
發表於: 星期六 六月 18, 2005 1:41 pm 文章主題: |
|
|
這是哪一家廠商的語法 ?
米瑟其嗎 ? _________________ 以上淺見,歡迎批評指教
________________________________________________
山不轉路轉,路不轉人轉,人不轉頭轉,頭不轉眼睛轉,眼睛不轉眼珠轉
眼珠再不轉就去睡覺,睡起來繼續轉 |
|
回頂端 |
|
|
rixw83
註冊時間: 2004-07-12 文章: 12
第 6 樓
|
發表於: 星期一 六月 20, 2005 4:02 pm 文章主題: |
|
|
"米瑟其" ==> 是啥咪?? _________________ It's Me And My Super Rich Kw. |
|
回頂端 |
|
|
an1060
註冊時間: 2004-02-29 文章: 48 來自: 高雄
第 7 樓
|
發表於: 星期三 五月 17, 2006 3:50 pm 文章主題: |
|
|
請問一下 "rixw83"
以下各物件是須放入什麼資料內容
XX_ACCU = Left(Alltrim(Thisform.Txt_USER.Value) + Space(8 ),8 )
XX_PASS = Left(Alltrim(Thisform.Txt_PASS.Value) + Space(8 ), 8 )
XX_SNDN = Left(Alltrim(Thisform.Txt_SNNO.Value) + Space(12),12)
XX_RCNO = Left(Alltrim(Thisform.Txt_RCNO.Value) + Space(12),12)
XX_ENCD = Left(Alltrim(Thisform.Txt_CODE.Value) + Space(5),5)
XX_TIME = Left(Alltrim(Thisform.Txt_TIME.Value) + Space(6),6)
XX_LENT = Right('000' + Alltrim(Str(Thisform.Txt_LENG.Value)),3)
XX_NOTE = Alltrim(Thisform.EDIT_TEXTBODY.Value) |
|
回頂端 |
|
|
215001
註冊時間: 2003-06-11 文章: 389
第 8 樓
|
發表於: 星期五 五月 19, 2006 8:56 am 文章主題: |
|
|
可試中華電信企業簡訊: http://sockettoair.hinet.net/
或台灣簡訊: http://www.twsms.com
以下為台灣簡訊用法:
xhttp = createObject("Msxml2.XMLHTTP")
xhttp.open("GET", "http://api.twsms.com/send_sms.php?username=帳號&password=密碼&type=now&encoding=big5&mobile=電話號碼&message=簡訊文字內容&vldtime=有效秒數", .F. )
xhttp.send()
MESSAGEBOX(xhttp.responseText ) && 傳回值字串(執行結果)
RELEASE xhttp |
|
回頂端 |
|
|
jason0730
註冊時間: 2006-08-28 文章: 11
第 9 樓
|
發表於: 星期五 六月 01, 2007 4:20 pm 文章主題: |
|
|
215001 寫到: | 可試中華電信企業簡訊: http://sockettoair.hinet.net/
或台灣簡訊: http://www.twsms.com
以下為台灣簡訊用法:
xhttp = createObject("Msxml2.XMLHTTP")
xhttp.open("GET", "http://api.twsms.com/send_sms.php?username=帳號&password=密碼&type=now&encoding=big5&mobile=電話號碼&message=簡訊文字內容&vldtime=有效秒數", .F. )
xhttp.send()
MESSAGEBOX(xhttp.responseText ) && 傳回值字串(執行結果)
RELEASE xhttp |
請問一下 Msxml2.XMLHTTP 是個什麼元件,為何我在使用大大的程式是會 出現 OLE IDispatch execption code 0 from msxml3.dll: 系統找不到指定的資源,還是我用法錯誤
謝謝 |
|
回頂端 |
|
|
ufochen
註冊時間: 2003-09-17 文章: 165
第 10 樓
|
發表於: 星期二 七月 10, 2007 1:47 am 文章主題: |
|
|
以下為台灣簡訊用法:
xhttp = createObject("Msxml2.XMLHTTP")
xhttp.open("GET", "http://api.twsms.com/send_sms.php?username=帳號&password=密碼&type=now&encoding=big5&mobile=電話號碼&message=簡訊文字內容&vldtime=有效秒數", .F. )
xhttp.send()
MESSAGEBOX(xhttp.responseText ) && 傳回值字串(執行結果)
RELEASE xhttp[/quote]
我在vfp9.0+xp sp2環境下使用,已經發上千封簡訊了,並沒有任何問題,只是仍不明白MESSAGEBOX(xhttp.responseText )傳回的字串代表什麼意義... |
|
回頂端 |
|
|
215001
註冊時間: 2003-06-11 文章: 389
第 11 樓
|
|
回頂端 |
|
|
angeljack
註冊時間: 2006-09-04 文章: 5
第 12 樓
|
發表於: 星期三 五月 26, 2010 2:33 pm 文章主題: |
|
|
ufochen 寫到: | 以下為台灣簡訊用法:
xhttp = createObject("Msxml2.XMLHTTP")
xhttp.open("GET", "http://api.twsms.com/send_sms.php?username=帳號&password=密碼&type=now&encoding=big5&mobile=電話號碼&message=簡訊文字內容&vldtime=有效秒數", .F. )
xhttp.send()
MESSAGEBOX(xhttp.responseText ) && 傳回值字串(執行結果)
RELEASE xhttp |
我在vfp9.0+xp sp2環境下使用,已經發上千封簡訊了,並沒有任何問題,只是仍不明白MESSAGEBOX(xhttp.responseText )傳回的字串代表什麼意義...[/quote]
各位大大,我用台灣簡訊的用法,第一次發是OK的,但是第二次再發的時候,都只會得到第一次的response的字串,也下了release xhttp 還是沒用,要整個VFP離開再進來,才可以再發下一通,請教各位先進,感謝! |
|
回頂端 |
|
|
215001
註冊時間: 2003-06-11 文章: 389
第 13 樓
|
發表於: 星期三 五月 26, 2010 2:55 pm 文章主題: |
|
|
不要設定Proxy
解決方式有下列3種方法:
1.於IE6 -->工具-->網際網路選項-->一般-->設定-->
--> (檢查儲存的畫面是否有更新版時) 勾選:每次查閱畫面時
2.不要設定proxy
3.於程式內設計每次簡訊內容都不一樣 (如:加入第幾通,或時間等變動訊息) |
|
回頂端 |
|
|
angeljack
註冊時間: 2006-09-04 文章: 5
第 14 樓
|
發表於: 星期四 五月 27, 2010 10:24 am 文章主題: |
|
|
感謝回復
我測試結果會再回覆上來!!! |
|
回頂端 |
|
|
goto-dream
註冊時間: 2004-05-11 文章: 909
第 15 樓
|
發表於: 星期三 六月 02, 2010 5:30 pm 文章主題: |
|
|
http://www.smsgo.com.tw/
到這邊去購買點數
然後將底下程式修改一下就可以了
傳送簡訊
代碼: |
x_username=Alltrim(Thisform.userName.Value)
x_password=Alltrim(Thisform.Password.Value )
x_tel=Alltrim(Thisform.tel1.Value)
x_http = Createobject("Msxml2.XMLHTTP")
XMLDocument = Createobject("Microsoft.XMLDOM")
smsURL = "http://www.smsgo.com.tw/sms_gw/sendsms.asp?"
TEXT TO smsArgs NOSHOW &&帳號/密碼
username=<<x_username>>&
password=<< x_password>>&
dstaddr=<< x_tel>>&
encoding=BIG5&
smbody=<<urlEncode(Thisform.edit2.Value)>>&
response=<<urlEncode("http://59.126.95.134")>>
ENDTEXT
x_http.Open("GET", smsURL + smsArgs , .F. )
x_HTTP.setRequestHeader('Content-Type', 'text/html; charset=big5')
x_HTTP.setRequestHeader("charset", "big5")
x_HTTP.setRequestHeader("Content-Length",Len(smsArgs))
x_http.Send()
If x_http.Status == 200
Thisform.edit1.Value= x_http.responseText
Endif
Release x_http
|
查詢發送
代碼: |
x_username=Alltrim(Thisform.userName.Value)
x_password=Alltrim(Thisform.Password.Value )
x_msgid=Alltrim(Thisform.msgid.Value)
x_http = Createobject("Msxml2.XMLHTTP")
XMLDocument = Createobject("Microsoft.XMLDOM")
smsURL = "http://www.smsgo.com.tw/sms_gw/query_point point.asp?"
smsArgs = ""
smsArgs = smsArgs +"username=" +x_username &&使用者帳號
smsArgs = smsArgs + "&password=" + x_password &&使用者密碼
smsArgs = smsArgs + "&msgid=" + x_msgid &&使用者密碼
x_http.Open("GET", smsURL + smsArgs , .F. )
x_http.Send()
If x_http.Status == 200
*lcText = Strextract(xHttp.responseText,This.apiStartTags,This.apiEndTags)
Thisform.edit1.Value= x_http.responseText
Endif
Release x_http
|
查詢點數
代碼: |
x_username=Alltrim(Thisform.userName.Value)
x_password=Alltrim(Thisform.Password.Value )
x_tel=Alltrim(Thisform.tel1.Value)
x_http = Createobject("Msxml2.XMLHTTP")
smsURL = "http://www.smsgo.com.tw/sms_gw/query_point.asp?"
TEXT TO smsArgs NOSHOW &&帳號/密碼
username=<<x_username>>&
password=<< x_password>>
ENDTEXT
*smsArgs=urlEncode(smsArgs)
x_http.Open("GET", smsURL + smsArgs , .F. )
x_HTTP.setRequestHeader('Content-Type', 'text/html; charset=big5')
x_HTTP.setRequestHeader("charset", "big5")
x_HTTP.setRequestHeader("Content-Length",Len(smsArgs))
x_http.Send( )
If x_http.Status == 200
Thisform.edit1.Value= x_http.responseText
STRTOFILE(Thisform.edit1.Value, "a.html")
Endif
Release x_http
|
_________________ 福隆昌淨水有限公司--淨水器的專家,淨水器,飲水機,濾心!!
想了解更多,您可上幸福雞湯組.找尋!!丁澐瑄.老師.
愛作夢 |
|
回頂端 |
|
|
|