×

Discussion Board

Page 1 of 2 12 LastLast
Results 1 to 15 of 19
  1. #1
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Unhappy Mobile application is not running in 5130C and 3600

    Hello,

    I have just developed a new .jar application which is similar to http://www.dcrdirect.com/. We have developed this application with the help of netbeans.

    When we are browsing through the mobile, it is getting downloaded and installed in all the version of nokia mobile phones.(we have tested using N73, N70, Nokia 5800). At the time login screen appears, when we are putting up the login credentials, it is not loging in in Nokia 5130C and Nokia 3600. where in case of N73, N70 and in Nokia 5800 it is getting connected and the application is running well. In case of 5130c and 3600 it is showing the 'wait' icon for a long time and is not getting connected.

    We have used MIDP 2.1 and CLDC 1.1 to develop the same.

    As we are very new in this mobile development technology, would appreciate your help.

    We are planning to develop our own web based application in to mobile based application so that people can report online even from their own cell phone.

    Please help us in this regards,

    Thanks,
    Kaushik

  2. #2
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Mobile application is not running in 5130C and 3600

    Install htp://mini.opera.com onto the same devices. If it doesn't connect either, then you have a problem with the network settings on the device.

    Graham.

  3. #3
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    We have tried using the opera mini browser from the phone 5130C. But it is still giving the same problem. Where in case we are accessing the other websites like gmail.com, it works well......

    Do you still blv its a network problem???

    Please confirm.

    Thanks

  4. #4
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Mobile application is not running in 5130C and 3600

    Quote Originally Posted by kaushikdg View Post
    We have tried using the opera mini browser from the phone 5130C. But it is still giving the same problem. Where in case we are accessing the other websites like gmail.com, it works well......
    What do you mean? In what way does Opera Mini not work?

    Do you mean you can access gmail.com from Opera Mini, or the device's browser?

    Graham.

  5. #5
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    Hi,

    I can access gmail through opera mini from my cell phone nokia 5130C. But when i am trying to run the .jar application developed by us only, it is not getting connected.

    i.e we have a login screen in our own .jar application, and when we are trying to login through it, it is taking a long time showing us the waiti icon. finally it is not getting connected.

  6. #6
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Mobile application is not running in 5130C and 3600

    So, Opera Mini works perfectly? I understood from your earlier post that you encountered some problem with Opera Mini.

    I suspect that some exception is being thrown, and that your code is catching it and doing nothing useful with it.

    Do you see a security prompt? Does a network connection start? ("G" icon appear, for example.)

    Graham.

  7. #7
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    yeah......'G' appears ..............network is connecting fine i blv...

  8. #8
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Mobile application is not running in 5130C and 3600

    Then it sounds like a problem in your code. You will need to do some debugging.

  9. #9
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    But when i am running the same using the SDK (have downloaded the installer from nokia- I am using S40- 5th Edition), it is running fine from our pc.......even we have tested the same using S40- 3th Edition. It is running fine from the pc.

    Please help me to figure out this issue.

    thanks,
    Thanks and Regards,
    Kaushik DG

  10. #10
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    If there were ne problem in our code.......i think SDK would not run it perfectly from the PC itself..... but its fine when we are trying to run it from the pc.......

    m being confused. please help
    Thanks and Regards,
    Kaushik DG

  11. #11
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Mobile application is not running in 5130C and 3600

    Your assumption is not correct. Different Java runtime environments can behave differently. It is quite common for an error in code to show up on one device and not another, because of implementation differences.

    As you say, there does not appear to be a problem with the network configuration on the device.

    You will need to find out exactly what is happening on the device. For example, is an exception being thrown?

    Graham.

  12. #12
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    Hi,

    we have figure it out i think.......... the problem is with the database connectivity.

    here is the code we have used to connect the db:-


    private String processServerResponseForDcrFinish(HttpConnection http, InputStream iStrm) throws IOException {
    errorMsg = null;
    System.err.println(iStrm);

    if (http.getResponseCode() == HttpConnection.HTTP_OK) {
    int length = (int) http.getLength();
    String str;

    if (length != -1) {
    byte servletData[] = new byte[length];
    iStrm.read(servletData);
    str = new String(servletData);
    System.err.println(str);
    }
    else {
    ByteArrayOutputStream bStrm = new ByteArrayOutputStream();
    int ch;
    while ((ch = iStrm.read()) != -1)
    bStrm.write(ch);
    str = new String(bStrm.toByteArray());
    bStrm.close();
    }

    String rtnStr;
    rtnStr=str.toString().trim();
    return rtnStr;
    }
    else
    errorMsg = new String( http.getResponseMessage());
    return "false";
    }
    Thanks and Regards,
    Kaushik DG

  13. #13
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    Can you please tell me if there is ne problem in this code where i am trying to connect the database?
    Thanks and Regards,
    Kaushik DG

  14. #14
    Super Contributor
    Join Date
    Jun 2003
    Location
    Cheshire, UK
    Posts
    7,395

    Re: Mobile application is not running in 5130C and 3600

    You're assuming that the HttpConnection has opened correctly in the first place. I wouldn't bet on it, unless you have evidence.

    Quote Originally Posted by kaushikdg View Post
    private String processServerResponseForDcrFinish(HttpConnection http, InputStream iStrm) throws IOException {
    Why pass both the Connection and InputStream objects? Surely the stream is acquired from the connection anyway?

    Quote Originally Posted by kaushikdg View Post
    System.err.println(iStrm);
    What do you expect this to do?

    Quote Originally Posted by kaushikdg View Post
    byte servletData[] = new byte[length];
    iStrm.read(servletData);
    This is a bad plan. Use a DataInputStream and readFully(). InputStream.read(byte[]) does not guarantee to read all the bytes from the stream. It will read "some number of bytes" and return the number actually read.

    Quote Originally Posted by kaushikdg View Post
    str = new String(servletData);
    This is also a bad plan, and will behave differently on different devices. Do you know what encoding scheme will be used to translate bytes into characters? What scheme do you need it to use?

    Finally, are you sure you are closing connections correctly?

    Graham.

  15. #15
    Registered User
    Join Date
    Feb 2010
    Posts
    10

    Re: Mobile application is not running in 5130C and 3600

    Okie......but can you tell me how to read the istream Correctly?

    Yeah we are colsing the connection correctly. and We are using UTF 8 encoding scheme to translate the same.

    Please reply with an example atleast so that i can understand
    Thanks and Regards,
    Kaushik DG

Posting Permissions

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