×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Feb 2006
    Posts
    22

    how to detect if user has disallowed the gprs access ?

    I have a midlet that will use GPRS connection to retrieve data from the Internet. Mobile phone will prompt the user either to allow or disallow the
    GPRS access by displaying Yes and No command. How do I capture or what
    exception will be raised if user select No command ?

  2. #2
    Super Contributor
    Join Date
    Dec 2005
    Location
    Europe/Poland/Warsaw
    Posts
    1,699

    Re: how to detect if user has disallowed the gprs access ?

    hi,
    add try/catch to block where Connector.open(..) is used and catch SecurityException ("java.lang.SecurityException: Application not authorized to access the restricted API"):
    http://java.sun.com/javame/reference...Exception.html

    hth,
    regards,
    Peter

  3. #3
    Registered User
    Join Date
    Feb 2006
    Posts
    22

    Re: how to detect if user has disallowed the gprs access ?

    On midp 2.0, I will got java.lang.SecurityException. For midp 1.0, I got java.io.IOException.

    Thus, on midp1.0, I really don't have a clue if user press No or timeout problem.

  4. #4
    Super Contributor
    Join Date
    Dec 2005
    Location
    Europe/Poland/Warsaw
    Posts
    1,699

    Re: how to detect if user has disallowed the gprs access ?

    hi,

    so just provide "Network error" screen with optional FAQ list, From usability point your user is not interested in knowing of what the reason of exception was becuase she was actor of that error. If she was not actor (she allowed to use network for application) faq items could lists possible reasons of most-common errors (apn configuration error, no data plan at all, off-line mode, cell-outside of range, etc) (such faq list is also optional for midp 2.0 implementations)
    regards,
    Peter

Similar Threads

  1. Nokia 6101 Locked 2 TMobile Midlet can't access internet...
    By Jason Glass in forum Mobile Java Networking & Messaging & Security
    Replies: 45
    Last Post: 2007-11-14, 02:19
  2. Regarding access to user data in 6102
    By _Ace in forum Symbian Tools & SDKs
    Replies: 0
    Last Post: 2006-04-10, 18:07
  3. Detect connection Bluetooth or GPRS
    By curcio1 in forum Symbian Networking & Messaging (Closed)
    Replies: 3
    Last Post: 2004-05-04, 15:29
  4. Access to GPRS access points of 7650
    By lepo in forum Symbian Networking & Messaging (Closed)
    Replies: 7
    Last Post: 2003-10-29, 12:49
  5. Internet Access Config via Smart Message
    By ajbrindley in forum Smart Messaging
    Replies: 1
    Last Post: 2002-08-14, 07:56

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •