473,385 Members | 1,888 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

URLEncode in MS Access

I want to send sms from my ms access 2007 application. I want to make use of a web site to send the sms. The code provided by the web site requires me to use server.URLEncode. But it seems the same is not available with MS Access. Is there any work around ?

I have been given following code :

--------------------------------------------Cut--------------------------------------------------
''''wirte code for loop while (you can open record set here)
sResponse = ""
sResponse = SMSSend(pno, message )
If right(sResponse,15) = "Send Successful" Then
'write your code here
End If
'''End Wend
Function SMSSend (strPh,strMsg)

Dim msgResponse
Dim strRequest
Dim strUrl
msgResponse = ""

strPh=right(strPh,10)
If not IsNumeric(strPh) Or len(strPh) <> 10 Then
msgResponse = "Enter valid Mobile Number."
End If
If strMsg = "" Then
msgResponse = "Enter text message."
End If

strUrl = "http://bulksmsindia.mobi/sendurl.asp?"
strRequest = strRequest+"&user=profileid"
strRequest = strRequest+"&pwd=pass"
strRequest = strRequest+"&mobileno="+strPh
strRequest = strRequest+"&msgtext="+Server.URLEncode(strMsg)

strUrl = strUrl+strRequest

If msgResponse = "" Then
Dim oXML
Dim sPage
Err.Clear
On Error Resume Next
Set oXML = Server.CreateObject("Msxml2.XMLHTTP")
oXML.Open "get", strUrl , false
oXML.Send
msgResponse = oXML.ResponseText
Set oXML = Nothing
End If

SMSSend = msgResponse

If Err.Number <> 0 Then
SMSSend = "Problem on sending sms : "& Err.Description
End If

End Function
----------------------------------------Paste---------------------------------------------------
Nov 20 '08 #1
0 2397

Sign in to post your reply or Sign up for a free account.

Similar topics

22
by: Fawke101 | last post by:
Hi there, I am having trouble with some data that is ripped from a SQL database and displayed as a hyperlink. The hyperlink inserts the data into a querystring so the next page can read it. ...
3
by: George Hester | last post by:
http://support.microsoft.com/default.aspx?scid=kb;en-us;301464 Look down at the MyPage.asp example. You will see that Microsoft does this: 'Costruct the URL for the current page s = "http://"...
1
by: yawnmoth | last post by:
Any ideas as to why urlencode(addslashes(chr(0))) returns '%5C0'? It seems like it should return '%00' since that's what urlencode(chr(0)) returns. If not that, I could also see it returning...
1
by: Jim | last post by:
Hello, I'm trying to do urllib.urlencode() with unicode correctly, and I wonder if some kind person could set me straight? My understanding is that I am supposed to be able to urlencode...
2
by: Imran Aziz | last post by:
Hello All, from my C# dialog based application I am creating a URL that has some query string parameters that I want to URL encode, the URLEncode function is suppose to be in the HttpUtility class...
5
by: vtreddy | last post by:
Hi All: In my application I am sending the input values through query string from a datagrid template column,I used URLEncode to encode the URL String, please find the input below, I am facing a...
4
by: Andreas Klemt | last post by:
Hello, is there a difference between System.Web.HttpUtility.UrlEncode and Server.UrlEncode ?
1
by: Dario Sala | last post by:
Hi, what's the difference about Asp Server.UrlEncode and the Asp.Net Server.UrlEncode ? In asp: Server.UrlEncode("*") = %2A In Asp.Net: Server.UrlEncode("*") = *
12
by: sleytr | last post by:
Hi, I'm trying to make a gui for a web service. Site using ± character in value of some fields. But I can't encode this character properly. >>> data = {'key':'±'} >>> urllib.urlencode(data)...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.