Problem with calling a midlet within another midlet

hello friends,
can a create an instance of a midlet within another midlet.i tried to call , but i have got a Security exception. plz comment on this ..
regards..

"For security reasons, it is assumed that MIDlets within a MIDletSuite are packaged
together for a reason and should be able to interoperate. What's implied here is that the
MIDlets share a name space; in other words, each MIDlet in the MidletSuite can "see" one
another. Because they can see one another, they can launch one another (Class.forName
metaphor).
In contrast, one MIDletSuite cannot launch another MIDletSuite. That's because they do not
share name spaces. Since the CLDC+MIDP does not have a security manager (too big and
complex for small devices), the MIDP expert group felt it more prudent to limit the interaction
of downloaded applications to those that are packaged together by the provider."extract from Sun
see http://developers.sun.com/mobility/midp/articles/pushreg/ for infos to launch MIDlets...

Similar Messages

  • Problem with calling a function within a function

    My problem is with the getWidth and getLength functions. The problem I am having is with the fact that when I get an incorrect input I pass it through the function again, which give me a weird return. The return I get is the correct input plus all the previous incorrect inputs after that. The one that gets returned is first incorrect input? I don't know if you understand, but I would appreciate help for this beginner.
    **Sorry about posting in this forum... I just realized this is not for beginners. Help would still be appreciated.**
    import java.util.Scanner;
    //Calculates the area of a rectangle
    public class AreaRectangle {
        private static Scanner c = new Scanner(System.in);
        private static boolean isNumber(String in) {
            boolean isNum = false;
            int count = 0;
            for (int i=0;i<in.length();i++) {
                if (in.charAt(i) >= '0' && in.charAt(i) <= '9' || in.charAt(i) == '.') {
                    if (in.charAt(i) == '.') {count++;}
                    else if (count > 1){isNum=false;break;}
                    else {isNum = true;}
                else {
                    isNum=false;
                    break;
            return isNum;
        public static double getLength() {
            String input;
            boolean isNum;
            double length = 0;
            System.out.print("Please enter the rectangle's length: ");
            input = c.nextLine();
            isNum = isNumber(input);
            if (isNum) {
                length = Double.parseDouble(input);
            else {
                System.out.println("Incorrect input!");
                getLength();
            System.out.println(input);
            return length;
        public static double getWidth() {
            String input;
            boolean isNum;
            double width = 0;
            System.out.print("Please enter the rectangle's width: ");
            input = c.nextLine();
            isNum = isNumber(input);
            if (isNum) {
                width = Double.parseDouble(input);
            else {
                System.out.println("Incorrect input!");
                getWidth();
            System.out.println(input);
            return width;
        public static double getArea(double length, double width) {
            return width*length;
        public static void displayData(double length, double width, double area) {
            System.out.println("Width = "+width+" "+"Length = "+length+" "+"Area = "+area);
        public static void main(String[] args) {
            double l, w, a;
            l = getLength();
            w = getWidth();
            a = getArea(l, w);
            displayData(l, w, a);
    }Edited by: x713 on Apr 12, 2008 7:12 PM
    Edited by: x713 on Apr 12, 2008 7:19 PM

    You're calling things recursively and that's not good (at least not here).
    To clarify, please look:
        public static double getLength() {
            if (something) {
                do something else
            else {
                System.out.println("Incorrect input!");
                getLength();  // you call the entire method again here! This is the recursive call
        }Better is to have a while loop inside the method and repeat this loop until the input that the user enters is correct (or until they quits).

  • Problem with running the midlet class (Error with Installation suite )

    hi everyone...
    i have problem with running the midlet class(BluetoothChatMIDlet.java)
    it keep showing me the same kind of error in the output pane of netbeans...
    which is:
    Installing suite from: http://127.0.0.1:49296/Chat.jad
    [WARN] [rms     ] javacall_file_open: wopen failed for: C:\Users\user\javame-sdk\3.0\work\0\appdb\delete_notify.dat
    i also did some research on this but due to lack of forum that discussing about this,im end up no where..
    from my research i also find out that some of the developer make a changes in class properties..
    where they check the SIGN DISTRIBUTION...and also change the ALIAS to UNTRUSTED..after that,click the EXPORT KEY INTO JAVA ME SDK,PLATFORM,EMULATOR...
    i did that but also didnt work out..
    could any1 teach me how to fix it...
    thanx in advance... :)

    actually, i do my FYP on bluetooth chatting...
    and there will be more than two emulators running at the same time..
    one of my frens said that if u want to run more than one emulator u just simply click on run button..
    and it will appear on the screen..

  • Problem with Call Transaction opt-RACOMMIT = 'X'.

    Hello Experts
    I am having a problem with call transction. I am calling a Z transaction in function module. Within the Z transaction I am furhter calling some function modules and doing commit work and then some more processing  after the comit work inside  So to make sure the code after comit work is fired I am using opt-RACOMMIT = 'X' in call transaction. Whenever I set this parameter opt-RACOMMIT = 'X' call transaction fails and gives error saying No batch Input data for screen XXXX. However the Z tcode processed succesfully.
    By changing the Mode to E i found that it remians at the last screen of call transction after executing the Z transaction and never comes back 
    But if I donot use RACOMMIT = 'X'  everything is fine. Please let me know if anyone came across such problem. Any help will be apreciated.
    Thanks,
    kamal

    Hello,
    as you said, if there is more than commit statement in your ztransaction, then you should put RACOMMIT to 'X'.
    I think the problem is in your bdcdata: change it to be sure to get back to the 1st screen of your ztransaction. Then, at this point (1st screen) hit "back" button.
    Cordialement,
    Chaouki

  • Problem with calling onApplicationStart() method

    Hi all,
         I have a problem with calling application.cfc's methods from coldfusion template. The problem is like when i am calling "onapplicationstart" method inside a cfml template i getting the error shown below
    The onApplicationStart method was not found.
    Either there are no methods with the specified method name and argument types or the onApplicationStart method is overloaded with argument types that ColdFusion cannot decipher reliably. ColdFusion found 0 methods that match the provided arguments. If this is a Java object and you verified that the method exists, use the javacast function to reduce ambiguity.
    My code is like below.
    Application.cfc
    <cfcomponent hint="control application" output="false">
    <cfscript>
    this.name="startest";
    this.applicationtimeout = createtimespan(0,2,0,0);
    this.sessionmanagement = True;
    this.sessionTimeout = createtimespan(0,0,5,0);
    </cfscript>
    <cffunction name="onApplicationStart" returnType="boolean">
        <cfset application.myvar = "saurav">
    <cfset application.newvar ="saurav2">
        <cfreturn true>
    </cffunction>
    </cfcomponent>
    testpage.cfm
    <cfset variables.onApplicationStart()>
    I have tried to call the above method in different way also like
    1--- <cfset onApplicationStart()>
    i got error like this
    Variable ONAPPLICATIONSTART is undefined.
    2---<cfset Application.onApplicationStart()>
    The onApplicationStart method was not found.
    Either there are no methods with the specified method name and argument types or the onApplicationStart method is overloaded with argument types that ColdFusion cannot decipher reliably. ColdFusion found 0 methods that match the provided arguments. If this is a Java object and you verified that the method exists, use the javacast function to reduce ambiguity
    Please help me out.
    Thanks
    Saurav

    You can't just call methods in a CFC without a reference to that CFC. This includes methods in Application.cfc.
    What are you trying to do, exactly, anyway? You'd probably be better served by placing a call to onApplicationStart within onRequestStart in Application.cfc, if your goal is to refresh the application based on some condition:
    <cffunction name="onRequestStart">
         <cfif someCondition>
              <cfset onApplicationStart()>
         </cfif>
    </cffunction>
    Dave Watts, CTO, Fig Leaf Software
    http://www.figleaf.com/
    http://training.figleaf.com/

  • TS3367 FaceTime has a problem with calling (audio, video) between two devices when they are in the different networks.

    Hi,
    I have a problem with calling by FaceTime when me and my friend are in the different networks.
    When i call to another device I see this call on that device and tap to the answer button after that i see a message "connecting" but the first device is trying to call in during about 1 minute and finish the call.
    But if both of the devices have connected to the one network (wifi) it works correct.

    Actually, it started working fine when I told it to capture
    sound at 11kHz.. I should have tried that first, before making a
    fuss here, sorry. Looks like some weird glitch, a driver problem
    maybe, but anyway, switching to 11kHz seems to have solved
    it.

  • Problem with calling on some numbers

    Hi my mum has problem with calling on my number. She is in the USA and has a lof of money on her Skype account. When she was in Poland (country when I am now) she could without any troubles calling on my number. What is wird now in the USA she can call on some other polish numbers (I think that Skype doesn't support connection with my mobile operator).
    I fell deceived because I created Skype account and transfered some money on it for my mum to give her possibility to call to me. Is possible to fix it? Is somewhere table with can help me check which one numbers (mobile operators) Skype supports in the USA?
    My mom used Skype from Android smartphone.

    Hi my mum has problem with calling on my number. She is in the USA and has a lof of money on her Skype account. When she was in Poland (country when I am now) she could without any troubles calling on my number. What is wird now in the USA she can call on some other polish numbers (I think that Skype doesn't support connection with my mobile operator).
    I fell deceived because I created Skype account and transfered some money on it for my mum to give her possibility to call to me. Is possible to fix it? Is somewhere table with can help me check which one numbers (mobile operators) Skype supports in the USA?
    My mom used Skype from Android smartphone.

  • Problem with call forwarding. Calls can not be forwarded for incoming external calls

    Hi Everybody, how are you?
    I have a problem with call forwarding. Everything was fine but now is not working.
    In the reception of an office, the receptionist activate the call forward option to an internal extension. If somebody, internal in the office, call to the reception, the call is forwarding to the extension configured. But if I call from the outside (in example, from my cellphone) the call is not forwarded to the extension configured and continue ringing in the reception phone. Why this behavior? Any idea?
    If you know something please tell me.
    Thanks. Best regards.
    Andres Collazos.

    I encounter a similar problem with 9.1.1.
    My problem is link to this bug ID : CSCtq10477.
    Mathieu

  • My sister had a problem with call volume being too low on the iPhone 5S.  Is the iPhone 6 louder?  Is anyone else feeling that call volume on iPhone 5S isn't loud enough?

    My sister had a problem with call volume being too low on the iPhone 5S.  Is the iPhone 6 louder?  Is anyone else feeling that call volume on iPhone 5S isn't loud enough?

    I personally haven't experienced much of the "reverberation/feedback" when using a headset on the i4S...
    Yes, I have near-perfect hearing too (for scope, squeaky brakes hurt my ears) I come from many conversations on many phones and types and first off, CDMA technology is great for coverage, terrible for voice quality. HD Voice in Europe made for some of the best phone conversations I've ever had.
    Back on track, feedback is most noticable (similar to the landline phone) when using the iPhone without a headset, but for me it's not an absolute criticality mainly because I use VoIP apps alot, so maybe it has desensitized me some over the past year.
    But whenever I'm on a call, and the other person has me on speakerphone, I have alot of trouble talking because of the feedback loop caused. So the less of my voice I hear the better I can talk.
    Have you tried a bluetooth headset yet?

  • Lync 2013 I have a strange problem concerning group call pickup in lync 2013.the pickup calls on snom 710 having only a second delay, but in lync client it having about 5-7 second Anybody out there having similar problems with call pickup Groups?

    HI
    I have a strange problem concerning  group call pickup  in lync 2013.the pickup calls on snom 710 having only a second delay, but in lync client it having  about 5-7 second
    Anybody out there having similar problems with call pickup Groups?

    Hi,
    Did you meet any other call delay when you using Lync?
    As the issue happen for Lync desktop client, it can be performance issue. Please check if there is any error message from FE Server when the issue happen.
    Also please check if you have updated Lync Server to the latest version, if not, update it and then test again.
    Best Regards,
    Eason Huang  
    Eason Huang
    TechNet Community Support

  • I am getting weary of my iPhone 4s. the battery life is non-existent, second, i had problems with calls, the caller couldn't hear me and now it cannot detect internet networks. Be they wi-fi or cellular. what could be the problem.

    I am getting weary of my iPhone 4s. The battery life is non-existent, secondly, I had problems with calls, the caller couldn't hear me and now it cannot detect internet networks. Be they Wi-Fi or cellular. what could be the problem?

    Mullaly75 wrote:
    I assume u guys don't understand what open source software is
    Yes, I think most of us do understand what open source software is. It sounds as if you don't. Here's some information:
    Open-source software (OSS) is computer software that is available in source code form: the source code and certain other rights normally reserved forcopyright holders are provided under an open-source license that permits users to study, change, improve and at times also to distribute the software.
    Open source software is very often developed in a public, collaborative manner. Open-source software is the most prominent example of open-sourcedevelopment and often compared to (technically defined) user-generated content or (legally defined) open content movements.
    from http://en.wikipedia.org/wiki/Open_source_software
    Yes, Tom Wu of Stanford wrote a paper on something called Secure Remote Access Protocol. It's a form of Asymetric Key Exchange and has nothing to do with hacking anything. It's actually intended to protect data.

  • Problems with calls and Answering Machine

    I have a problem with calls on my Z3 dual and the Answering Machine after the update to L.I don't have Smart Answer enabled -gesture to answer calls- but when I answer a call too close to the time set to the Answering Machine to kick in, when the call reaches this time (say 25 seconds) the call will be interrupted for about 2 to 5  seconds where I can't hear the other party and they can't hear me, and then the call will resume.If I disasble the answering machine, this bug is gone.I have cleared data of the phone app but still this issue persists.

    I suggest that you try to repair the phone software using PC Companion..
    Before repairing your device you may want to backup your information first. Check out this topic for more information on how to.
    How to backup?
    Let us know if the problem persist after you've repaired the software.

  • New 4s connects with bluetooth in my Lexus, but I have intermittent problems with calls.  I can hear them, but they can't hear me.  Never did this with 3gs.  Anyone else have this problem?

    New 4s connected to my Lexus bluetooth.  Having intermittent problem with calls.  I can hear them, but they can't hear me.  Never a problem with 3gs phone.  Anyone else having this problem? 

    I ended up getting a new phone, straight through Apple.  I called their technical support and went through all he basics again and they decided to replace it.  Was a pretty quick process - after defaulting and resetting the whole phone (about 2 hours),  I called them back to inform that there was no change, so they set up the order.
    I had to give my CC# so they could hold a charge on it (in case I didn't send my old phone bach, which they sent me a pre-posted package to send it in anyway).  Had a brand new iPhone 4S in my hands in 4 days, which was pretty decent.  I had uploaded everything previously to iCloud, so setting up the new phone was a snap.
    Only thing I really didn't like was they charged me almost 30 bucks for shipping or processing, or something.  Not so sure that should have been my responsibility after spending so much on a brand new product, only to have to have it warrantied after, like, a month.

  • Problems with calling a Bat file in java...

    i'm having some issues when i try to call my bat file within java...
    here is the code
    Runtime.getRuntime().exec("cmd.exe C:\\dev\\CMIC\\components\\client\\bin\\startup.bat");
    it starts up the bat file but it seems to only execute the first line in the bat, then it shuts it down... i dont get it. cuz if i call that bat from another bat it works fine.. if i click on it, it works fine why would java have a problem with it?

    After doing some searching around... this is what i came up with.. but i still get the same results.. the dos screen pops up and then poof.. its gone..
    import java.io.BufferedReader;
    import java.io.ByteArrayOutputStream;
    import java.io.IOException;
    import java.io.InputStream;
    import java.io.InputStreamReader;
    import java.io.OutputStream;
    import java.io.PrintWriter;
    public class test {
         public static void main(String Args[]){
         System.out.println("About to try and EXecute the Bat");
                   //String retVal = ExecWindows( "cmd.exe C:\\dev\\CMIC\\components\\client\\bin\\startup.bat" );
                   String retVal = ExecWindows( "cmd.exe /C C:\\dev\\CMIC\\components\\client\\bin\\startup.bat" );
                   System.out.println(retVal);     
         private static String ExecWindows(String cmd) {
              try {
                   ByteArrayOutputStream bos = new ByteArrayOutputStream(100 * 1024);
                   Runtime rt = Runtime.getRuntime();
                   Process proc = rt.exec(cmd);
                   StreamGobbler errorGobbler =
                        new StreamGobbler(proc.getErrorStream(), "ERROR");
                   StreamGobbler outputGobbler =
                        new StreamGobbler(proc.getInputStream(), "OUTPUT", bos);
                   errorGobbler.start();
                   outputGobbler.start();
                   int exitVal = proc.waitFor();
                   //if ( DEBUG ) System.out.println( "cmd: '" + cmd + "' -> " + exitVal );
                   errorGobbler.join();
                   outputGobbler.join();
                   //if (DEBUG && exitVal != 0)
                   //     System.out.println(" ExitValue: " + exitVal);
                   if (exitVal != 0)
                        return "";
                   bos.flush();
                   String output = bos.toString();
                   bos.close();
                   return output;
              } catch (Throwable t) {
                   return "";
         } /* * Handle standard I/O streams */
    } // end of class
         class StreamGobbler extends Thread {
              InputStream is;
              String type;
              OutputStream os;
              StreamGobbler(InputStream is, String type) {
                   this(is, type, null);
              StreamGobbler(InputStream is, String type, OutputStream redirect) {
                   this.is = is;
                   this.type = type;
                   this.os = redirect;
              public void run() {
                   try {
                        PrintWriter pw = null;
                        if (os != null)
                             pw = new PrintWriter(os);
                        InputStreamReader isr = new InputStreamReader(is);
                        BufferedReader br = new BufferedReader(isr);
                        String line = null;
                        while ((line = br.readLine()) != null) {
                             //System.out.println( "{" + line + "}" );
                             if (pw != null) {
                                  pw.println(line);
                             } else {
                                  System.out.println(type + ">" + line);
                        if (pw != null)
                             pw.flush();
                   } catch (IOException ioe) {
                        ioe.printStackTrace();
         }

  • Problem with "Call Transaction" which calls a view cluster

    Hi Colleagues ,
    I have a rare issue with the call transaction , here is the use case for it :
    1> I call a transaction(calls a screen X) in a report ,
    2> I have a button in the screen , which calls another transaction(calls a screen X2) .
    3> On the screen X2 i have another button which calls transaction (calls the view cluster ).
    problem :
    i'm not able to see the navigation pane in the view cluster on the left. its missing .
    but when the view cluster is called direclty , i'm able to see the navigation pane in the view cluster ..
    My initial doubt was , is this the problem with nesting of 'Call Transaction' calls ????
    please answer the thread , i have to fix this ASAP.
    regards,
    Dilip

    problem solved.

Maybe you are looking for