01-30-2010 03:18 AM
Hi all,
I am trying to make a connection(GET) to
using WAP2 Connection. The logic for appending connection suffix is :
ServiceBook sb = ServiceBook.getSB();
net.rim.device.api.servicebook.ServiceRecord[] records = sb.findRecordsByCid("WPTCP");
String uid = null;
for(int i=0; i < records.length; i++) {
if (records[i].isValid() && !records[i].isDisabled()) {
if (records[i].getUid() != null && records[i].getUid().length() != 0) {
if ((records[i].getCid().toLowerCase().indexOf("wptcp ") != -1) && records[i].getUid().toLowerCase().indexOf("wap2") !=- 1 &&
(records[i].getUid().toLowerCase().indexOf("wifi") == -1) &&
(records[i].getUid().toLowerCase().indexOf("mms") == -1)) {
uid = records[i].getUid();
break;
}
}
}
}
if (uid != null) {
url = url +";ConnectionUID=" + uid;
}And after this my resulting url becomes :
I am not able to figure out what is going wrong here.
The same url works when i append ";interface=wifi" but not when i append ";ConnectionUID=WAP2Trans"
01-30-2010 03:27 AM - edited 01-30-2010 03:32 AM
I am Sorry..My question is not clear above!!
Actually I am trying to establish connection to following url :
The problem is that when i am trying to make an connection to above url using WAP2 i am getting connection as null , on the other hand, i am able to establish connection and getting correct response when i am making connection on WIFI.
appending :
";ConnectionUID=WAP2Trans" to above url doesn't work.(getting connection as null)
while
appending
";interface=wifi" to above url works.
01-30-2010 07:32 AM - edited 01-30-2010 07:47 AM
1. Are you sure there's no space between "WAP2" and "Trans" inside the UID "WAP2Trans"? On most carriers I've seen, there's a space in the UID: "WAP2 Trans". Have a quick look at the Service Book record...
2. Try appending ";deviceside=true" in addition to what you already have. I don't remember whether deviceside=true is needed for WAP 2.0 requests...
3. Try connecting to a URL with any search strings, e.g.: "http://www.yahoo.com;ConnectionUID=WAP2Trans" to see whether the search string of the URL somehow interferes with the parsing of the Connector.open URL.
01-30-2010 08:37 AM
HI Klyubin, thank you ver much for the reply..
I have Cross Checked in ServiceBooks...And i see
Record Type:
Name : VodaFone live!
UID : WAP2trans
CID : WPTCP
I also noticed that all my other applications that used WAP2.0 for estabilishing connection used to work earlier, now none of them work.
Can it might be the case that Vodafone has suddenly refused WAP2.0 connection??
01-30-2010 08:43 AM
I can't help you here. It's best if you ask Vodafone.
01-30-2010 09:05 AM
Ya i will get ir confirmed by VodaFone..neways Thank you very much for the reply..
01-30-2010 09:57 AM
Just start Vodafone Live (the WAP Browser). If it works, your app should work.
What country are you in?
01-30-2010 10:16 AM
It's possible that the browser is using WAP 1.x. However, if the Vodafone Live! browser doesn't work, then it's definitely something Vodafone should look at and fix.
01-31-2010 10:36 AM
I've had issues with connections on vodafone.
This has always been resolved by doing the following on my handset,
Navigate to Vodafone Live! On blackberry, goto pay my bill section, account settings, disable ” allow vodafone to make this website faster”
See if that makes a difference.
02-01-2010 11:34 PM
Hi Peter thanx for the reply,
No, My WAP browser isn,t working. I am in INDIA