BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 10-08-2009, 08:24 AM   #1 (permalink)
New Member
 
Join Date: Oct 2009
Model: 8700g
PIN: N/A
Carrier: cmcc
Posts: 7
Post Thanks: 0
Thanked 0 Times in 0 Posts
Exclamation How to retrieve or set APN through programming?

Please Login to Remove!

Dear all,
I need some help on how to retrieve or set APN on real device through programming which could be setted manual through “Option”-“Advanced Option”-“TCP”. Thanks in advance
Offline  
Old 10-08-2009, 08:51 AM   #2 (permalink)
BlackBerry Extraordinaire
 
Join Date: Mar 2008
Location: Austin, TX
Model: 9700
PIN: N/A
Carrier: T-Mobile
Posts: 1,644
Post Thanks: 0
Thanked 34 Times in 33 Posts
Default

See this article from the knowledgebase:

Livelink - Redirection
Offline  
Old 10-08-2009, 09:14 AM   #3 (permalink)
New Member
 
Join Date: Oct 2009
Model: 8700g
PIN: N/A
Carrier: cmcc
Posts: 7
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks a lot for your kindly help, it's really helpful.
In details due to our carrier have two types of apn that one called cmnet can directly access the internet another one called cmwap which through the carrier's proxy access the internet. For this shake I have to set the connector's parameters against the APN settings in the TCP option. That's why I have to retrieve the APN. Could you pls help me to find the methods to get the APN, thanks in advance.
Quote:
Originally Posted by Dougsg38p View Post
See this article from the knowledgebase:

Last edited by czspace : 10-08-2009 at 09:17 AM.
Offline  
Old 10-08-2009, 09:27 AM   #4 (permalink)
BlackBerry Extraordinaire
 
Join Date: Mar 2008
Location: Austin, TX
Model: 9700
PIN: N/A
Carrier: T-Mobile
Posts: 1,644
Post Thanks: 0
Thanked 34 Times in 33 Posts
Default

There is another thread on this subject about two threads down from this one.

Also, why do you need it? If it is set in Options, the you don't need to know what it is - you just make your connection ";deviceside=true".
Offline  
Old 10-08-2009, 11:02 AM   #5 (permalink)
New Member
 
Join Date: Oct 2009
Model: 8700g
PIN: N/A
Carrier: cmcc
Posts: 7
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

If the user hasn't set APN in TCP options then how do we handle this statution?
I know there exists another thread about how to get the apn. Because till now I haven't get the signning cert from blackberry I haven't try this getApn() function. If we can get the APN, which setted by user in the TCP options, against this getApn() function?
Quote:
Originally Posted by Dougsg38p View Post
There is another thread on this subject about two threads down from this one.

Also, why do you need it? If it is set in Options, the you don't need to know what it is - you just make your connection ";deviceside=true".
Offline  
Old 10-08-2009, 12:02 PM   #6 (permalink)
BlackBerry Extraordinaire
 
Join Date: Mar 2008
Location: Austin, TX
Model: 9700
PIN: N/A
Carrier: T-Mobile
Posts: 1,644
Post Thanks: 0
Thanked 34 Times in 33 Posts
Default

Regardless if the APN is set in Options, you can override this by providing the APN in the URL connecton parameters. This is discussed in the article I posted earlier.
Offline  
Old 10-09-2009, 02:59 AM   #7 (permalink)
New Member
 
Join Date: Oct 2009
Model: 8700g
PIN: N/A
Carrier: cmcc
Posts: 7
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks a lot for your kindly help, I know we can provide the APN in the URL connection parameters. Our question is we need according to this APN setting to specific the correctly URL connection parameters.
In details:
Our carrier provides two types of APN(cmnet--"directly access internet" or cmwap--"access internet through proxy"). Every user will select one of APN from these types as their data plan. Due to this conditon I have to try to retrieve the APN from TCP options, then set the correctly URL connection parameters according the APN type.

I have tried ServiceRecord's getAPN() which always return rim.net.gprs. So I can't according to this value to specific the APN typs.

Thanks again for your kindly help, wish you have a nice day

Quote:
Originally Posted by Dougsg38p View Post
Regardless if the APN is set in Options, you can override this by providing the APN in the URL connecton parameters. This is discussed in the article I posted earlier.
Offline  
Old 10-09-2009, 08:00 PM   #8 (permalink)
New Member
 
Join Date: Oct 2009
Model: 8700g
PIN: N/A
Carrier: cmcc
Posts: 7
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

SOS, who can help to solve this question or rim doesn't provide methords to retrieve or set the apn settings?
Thanks in advance.
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright © 2004-2014 BlackBerryForums.com.
The names RIM © and BlackBerry © are registered Trademarks of BlackBerry Inc.