How can I make Applet call up a JFrame??

hello ..
I'm making a game, and I have a flash screen done in Applet (the very first logo that appears ) so I can just load it in the browser ... someone told me that I can't make another applet that would hold the menu choices and such come up in the same browser window, so I made it into a JFrame .. so I have an Applet calling up a JFrame, and I don't know how to do that ..
any suggestions???

Hmm...but that doesn't put it on the screen thgou, does it?
IIRC applets embedded in the web page cannot contain menus - you have to 'break out' your applet so that it becomes a separate window.
To do this you would have a small standard applet embedded in your web page which then invokes your main JFrame-based application (not applet!).
When the user loads the web page, the embedded applet starts and then launches the JFrame-based application.
eg:
import java.awt.*;
import java.awt.applet.*;
public class RunApplet extends Applet {
    public void init() {
        MyApplet myA = new MyApplet();
import java.awt.*;
import java.awt.event.*;
import java.applet.*;
import javax.swing.*;
public class MyApplet extends JFrame {
    private JPanel pnlCenter;
    private JLabel lblSomeText;
    public MyApplet() {
        try {
            myInit();
        catch(Exception e) {
            e.printStackTrace();
    private void myInit() throws Exception {
        //Create components to display...
        pnlCenter = new JPanel();  //Main container inside the frame.
        lblSomeText = new JLabel("GUI stuff displays here!");
        pnlCenter.add(lblSomeText);
        //Put them on the screen...
        getContentPane().add(pnlCenter);
        //Show it...
        setTitle("My First Windowed App");
        setVisible(true);
}Hope this helps.
Paul.

Similar Messages

  • How can I make a call from iPad

    How can I make a call from IPad

    Oh, you have to get the iPhone app.
    Seriously, though .... you are aware that it's not a telephone, right? Any calls you make will be using VOIP and any of the apps and/or services (Skype, Google Talk, etc., etc.) which support that. Some of those are US-only, all have various restrictions and cost structures.

  • How can we make function calls to sap in odi ?

    how can we make function calls to sap in odi ?
    to populate a column i need to make a function call which returns the value.

    There are two ODI SAP adapters available that allows extraction from SAP ERP and SAP BW. For SAP ERP we allow extraction from ERP tables, but not from RFCs/BAPIs.
    You can find details on them at
    http://www.oracle.com/technetwork/middleware/data-integrator/overview/odigs-sapabap-168070.pdf
    http://www.oracle.com/technetwork/middleware/data-integrator/overview/odigs-sapabapbw-168071.pdf

  • How Can I make redirect caller from agent to any branch IVR?

    I have IPCC Enterprise Edition (ICM 5.0, IVR 3.1)
    How can I make redirect caller from agent to chosen branch IVR, and send with call any variable to IVR (e.g. account number).
    Regards
    Krzysztof

    I would suggest that post-routing should not be used. The way to go is to use translation routing applications. Although post-routing is easy to set up, almost all deployments require translation routing. I can't think of anything good to say about post routing, other than it's trivial to configure.
    You want the main route point to be on the CM_PIM.RC for a number of reasons. You can check to see which of your IVRs are on line, and/or to do load balancing. If calls don't need to go to the IVR if agents are ready, you can have an LAA Select node immediately, and then translation route. Even if you just have one IVR, translation routing will enable you to do RONA more easily.
    You need to bite the bullet and learn translation routing. If you do it that way, peripheral variables attached to the call remain unaffected whether the call is under the control of the CM_PIM.RC or the IVR_PIM.RC. This is exactly what you want.
    There is no need, in my opinion, to go to an external database. In your IVR, decisions made by the caller (e.g. which "skill" they want) set peripheral variables. When the call comes out of this script you check the peripheral variable, and depending on the value do a queue to the appropriate skill group and run external script (BasicQ.aef).
    Separate the intelligence gathering IVR script from the Queuing script. Allow ICM to make the routing decisions.

  • HT5176 How can I make a call from my new iPad(3rd generation) with wifi+4G

    How can we make a call from iPad 3rd generation with wifi+4G?

    You cant "Call" anyone. Its not a phone. You can facetime other IOS users. Setup facetime with your apple id in ipad settings/facetime. You can also download apps like skype in the app store.

  • How can I make a call with my iPad in Nigeria

    How can I make calls with my iPad in Nigeria? Also, why is Nigeria not listed among the Region on iPad?

    You can try downloading them as explained here:http://support.apple.com/kb/ht2519.  (This is not available in all countries, and must be permitted by the movie studio.)
    Otherwise, sync them to your iPad by selecting them on the Movies tab of your iTunes sync settings and syncing.

  • How can I make a call to *190*phone number# in c#?

    Hi,
    I am trying to create an app as shortcut for some requests.
    I want to make a call to this number: *190*phone number# using c# but it never works.
    On the phone, I can call this number and I get a reply from my provider.
    If I try to call it using:
    Windows.ApplicationModel.Calls.PhoneCallManager.ShowPhoneCallUI("*190*phone number#", "TEST CALL");
    I get a message saying that I have to use the dialer keypad to send the request.
    Is there a workaround for this (bug)? I mean, if I put the phone number in the phoneCall-request, it is because I don't want insert it manually in the dialer keypad...
    Thanks,
    Adriano

    Yes security LOL...
    If Microsoft want security, they should create a smartphone without the possibility to install apps ;)
    If an app can't make a call (user has to press CALL), the same thing is also possible for a FREE request to the provider, or not?
    Thanks for the link! This show once again that write a utility for WP is a hard work...
    If I create a new contact, I have to call phoneCallTask.Show();
    ... And so I am on the same situation.
    .My phone provider created an app for iPhone and one for Android. I was thinking I would be able to create something for Windows Phone too. Now I know why nobody want to create tools for Windows Phone. The API never allow you to write a utility (for security
    reason, I know ;) )... But it would also be nice to have a utility some times in a store full of inutility apps :(
    About this BUG:
    I can create a textbox where the user can copy the phone number (maybe the app could copy it automatically in the clipboard if there is no security problem about the OS :P). But the user has to exit the app, open the dialer and insert this text.
    Is there a way to open the phone dialer?
    Thank you for the support Cristian!

  • How can we make a call to the Data base in the SAP Scripts?

    Hi All,
            How we make a call to the data base in scripts?
    I think we can use the PERFORM statement to achieve the above functionality.
    Pls correct me if i am wrong?
    Regards
    Abhilash.

    Hello.
    If you want to access database in the script itself (not in print program) yes, you can use PERFORM statement.
    In your script, use:
    /: PERFORM F_FORM IN PROGRAM ZRFIRFS05
    /: USING &VAR1&
    /: CHANGING &VAR2&
    /: ENDPERFORM
    Then, create a program ZPROG (ZRFIRFS05 in my case) with a structure like this one:
    REPORT ZRFIRFS05 .
    FORM f_form TABLES in_par STRUCTURE itcsy out_par STRUCTURE itcsy.
      DATA: l_data1(10).
      READ TABLE in_par WITH KEY name = 'VAR1'.
      CHECK sy-subrc = 0.
      l_data1 = in_par-value.
    *  SELECT .... "YOUR SELECT TO DATABASE
      READ TABLE out_par WITH KEY name = 'VAR2'.
      CHECK sy-subrc = 0.
      out_par-value = l_data3.
      MODIFY out_par INDEX sy-tabix.
    ENDFORM.
    Regards.
    Valter Oliveira.

  • How can I make a call to a swing component which will be blocking?

    Hi,
    I have a small GUI, and an underlying application class which interacts with it. At one point in time, the underlying class needs to wait for the user to type a string into a textbox, and press a submit button (both of which are on a GUI that is already visible to the user). I cant seem to figure out how to make the call to the gui, so that i blocks, until that submit button is pressed.
    Do I have to spawn a seperate thread which constantly is checking if that button is pressed (i.e. associate a flag with that button).
    I pretty much wanna do something similar to JOptionDialog, but with my own gui implementation.
    thanks!

    No...let me rephrase...
    1) I only want 1 dialog...with multiple swing components on there. 2 of which are a textbox, and a jbutton....the jbutton has a listener associated with it....and that obviously grabs the text from the textbox...
    2) I have a model class (no swing components, only a reference to my dialog)...I want to make a call to the dialog, which blocks, until the button is pressed...
    did this clear things up at all?

  • How can I make internet calls from OS X 10.5.8?

    I want to make internet to landline calls with Mac OS X 10.5.8. Which applications will work with this operating system?
    I was previously using Skype until their recent compulsory upgrade, which is not compatible with my computer . A friend suggested Viber, but that also seems to require a more advanced version of OS X than my MacBook will support.
    Thank you,
    REM

    Buy a Snow Leopard DVD
    Any copies you find that can be downloaded besides being illegal are probably loaded with malware. so save yourselt the troubles and purchase a DVD.
    Allan

  • How can I make local calls without using a country code when it's in my Contacts?

    The phone numbers in my Contacts all contain country codes because I do a lot of travelling.
    An example of this might be:
    +1 (229) 123-4567
    +44 (0)12 345 6789
    +31 (0)10 2345 6789
    I have an unlocked phone so when I travel, I usually pick up a local SIM and use that to make calls.
    The problem I have is that when I am abroad and select a phone number from my contact list it doesn' work. For example, if I select a contact with the number:
    +31 (0)10 2345 6789
    A voice-recording comes on saying that the number I had dialed was incorrect.
    But when I dial the number manually:
    010 2345 6789
    It works.
    In the US I do not have this problem because for some reason, the phone knows whether the +1 is needed or not. I'm sure if it uses it at all when you're in the US. When I dial internationally from within the US, the number dialing works fine.
    So this problem only occurs when I'm dialing locally in the country I'm in while travelling outside the US.
    Anyone have any idea of why this is happening and more importantly, what I need to do to fix this? I would hate to have go and change all my contact numbers and get rid of the country codes. If I ever have to call those numbers internationally, I'll need to manually add the country code back in.
    Very annoying!
    Advice anyone?

    If you include a country number, you have to drop the initial 0 from the area code. eg +31 10 2345 6789 instead of +31 (0)10 2345 6789

  • I can't make a call but i can recieve calls

    why can't i make a call but i can recieve a call. im using TM/Globe sim and i followed sum instructions on the net. i tried updating my carrier. at first i was ignoring these pop up to make an update but now i'm searching for that pop up to make updates.
    i don't know how to fix it. i tried to call even with a strong signal connection. same things happening to me. i dial a number (e.g. - 09352908272) and at first it will make a call dialog. but after 5 secs. the call ended. at first i thought that the person im calling is declining my call, but when i tried to make another call to someone else. call ended still appears with my call
    Still i can't figure out how can i make a call. please help, thanks

    What did your carrier say when you contacted them to report the problem?

  • How can i make a free facetime video call? There's always appearing that my provider might charge for the call?

    How can i make a free facetime video call? There's always appearing that my provider might charge for the call?

    If you make a call then tap the Facetime button to connect Facetime, the duration of call up to Facetime connection will be charged under your regular airtime.  However, duration during facetime conversation will not consume airtime.
    But if you tap the Facetime button on the Contact Page, then the whole duration will not consume airtime.
    For Facetime to work, both parties must be connected to wifi.

  • HT204380 How can I make a face time call from one country to another( supporsing both parties using iphone 4s). What will be the caller charges. If there is no charges as we use wifi, will there be a charge till connecting the call?

    How can I make a Face Time call from one country to another( supporsing both parties using iphone 4s). What will be the caller charges. If there is no charges as we use wifi, will there be a charge till connecting the call?

    FaceTime is free to use. You will not be charged for using FaceTime.

  • I can only make emergency calls from my iphone 4. How do I fix this? Not tech savvy in the slightest !!

    I've just recently bought a white iphone formy daughter and am trying to put my sim into her old one but can only make emergency calls.  How do I get round this?  Not tech savvy at all as you can probably gather.  Thanks

    Did you connect your iPhone to the computer and sync it with iTunes? You will need the internet as well as Apple will unlock your iPhone over the internet via iTunes. Let us know if this helps.

Maybe you are looking for

  • HTTP Headers - enabling caching and compression with the portal?

    Has anyone configured their web server (IIS or Apache) or use a commercial product to flawlessly cache and compress all content generated by the portal? Compression and caching is critical for making our portal based applictions work for overseas use

  • Concatenate a field in internal table without loopat.

    In an internal table, I need to update one field (all rows) concatenate that field with a value say '999'. Is it possible to do this in a single MODIFY statement without using loopat condition or any other best possible way to do it?

  • Core dump on OCI call

    We are getting the following core dump on an OCI call .... fde12fe0 kpucHTDelete (f872ac, f68380, 0, 31, 203d203a, f7c684) + 9c fddae464 kpursetstmttext (f872ac, f871c8, 8, fdd9fa84, d49c40, fe449a64) + 9c fddae61c kpurclientparse (f872ac, f7cc7c, f6

  • Handling ActionScript errors on Assert

    Hello, I have a question that I can't seem to find an answer to anywhere online. In the old Google discussion group, someone asked the question regarding the problem I'm having. But no solution was ever posted. I'm testing a method to make sure that

  • Scripting IP Management

    I am a scripting novice/intermediate, familiar with shell/bash (eg: sed, awk,) and learning Python, also have some readability of Perl. Does anyone know of/use any good scripts that do any or all of below?  - Discover/report subnetting structure (eg,