Creating flv skins in cs3 and using them in Flash 8

We created a custom skin in flash cs3 but we want to
implement the custom skin into some flash 8 projects. We have been
having problems and when we exported with actionscript 2.0 all hell
broke loose.
Any ideas on how to get this to work??
thank

this code works
var tf:TextField = new TextField();
var tfor:TextFormat = new TextFormat();
tfor.font = new _TrebushetMS().fontName;
tfor.italic = true;
tf.width = 300;
tf.height = 200;
tf.embedFonts = true;
tf.border = true;
tf.defaultTextFormat = tfor ;
tf.text = "this is a test";
this.addChild(tf);
This code does not work
var tf:TextField = new TextField();
var tfor:TextFormat = new TextFormat();
tfor.font = new _TrebushetMS().fontName;
tfor.italic = true;
tf.width = 300;
tf.height = 200;
tf.embedFonts = true;
tf.border = true;
tf.setTextFormat(tfor) ;
tf.text = "this is a test";
this.addChild(tf);
i don't know why

Similar Messages

  • Creating user accounts with OIDDAS and use them from the OS

    Hi,
    I have a customer that is experiencing an error creating user accounts from OIDDAS, and use that user accounts from the operating system.
    My customer is using OID/OAS4OS 10.1.4.2.0, and that version is not longer available to download, then, I will try in my own environment
    with OID/OAS4OS 10.1.4.3.0.
    And the question is the following: is supported to create user accounts with OIDDAS and expect that users can work with OAS4OS and be
    able to authenticate in the operating system?
    For the reference, SR# 7222351.993:
    Thanks,
    Luis Vivero.
    Edited by: LV in ORCL on Dec 11, 2008 6:47 AM

    Hi Jacco,
    I didn't see your post before.
    Nop, unfortulately I don't have a document with that. I just received that answer
    from development (related to the plugin for AD that is not certified, and DAS is
    not intended to work with OAS4OS).
    Anyway, about the plugin to work with AD, this is working for me; at least I tested
    it by configuring the plugin, I configured synchronization, the mapping file, I did
    the bootstrap, and the accounts that were bootstraped now shows the OS attributes
    on DAS.
    Regards,
    Luis Vivero.

  • How to create RFQ s and use them to complete the program

    hi,
    how to create RFQ s and use them to complete the program
    thanks in advance

    Hi Santosh,
    RFQ is created through transaction ME41.
    You need to write down BDC for mass update of RFQ, because BAPI is not available.
    Regards,
    Tutun

  • How to retrieve comments from one OfficeTask activity and use them in another OfficeTask activity for Multi level Approval sequential Workflow

    I'm designing a sequential site workflow using Visual Studio 2010 for Project Server 2010. In my case, I have following 6 stages in the workflow:
    1. InitialProposal Stage
    2. Approval Stage1 -- Needs approval from Approver Project Security Group Members1
    3. Rejection Stage
    4. Approval Stage2 -- Needs approval from Approver Project Security Group Members 2
    5. Execution Stage
    6. Completed Stage
    Requirement is workflow should move to Approval stage2 from Approval stage1  if approved by all members of Approver Project Security Group1and it should move to Rejection Stage even if a single member rejects it.
    Workflow should move from Approval Stage2 to Execution Stage if approved by all members of Approver Project Security Group2 and it should move back to Approval Stage1 on rejection by a single member of the group.
    I'm using inbuilt PSWApproval content type and OfficeTask activity for creating approval task for the group members at both stages.
    On task rejected in Approval stage2, task will be assigned again to Approval Stage1 and I want to show comments given by members of Approver Project Security Group2 to the members of Approver Project Security Group1 with this assigned task
    but I'm not able to retrieve comments from officeTask activity.
    My question is where exactly these comments are saved? how can we retrieve them and use them in another officetask activity? If this is not possible then what is the possible solution for meeting above mentioned business requirement?

    Hi Paul,
    Thanks for your suggestion.
    By comments field I'm assuming OfficeTask.Comments field. Problem is, this field is always null. I tried accessing this field in CheckExitCondition activity as well as in OnTaskCompleted but in both the cases, it was null only(I wrote comments while approving
    the task).
    I used a code activity within OnTaskCompleted activity and following code for accessing Comments and Description fields:
    public string officeComments;
            public string officeDescription;
            private void TaskCOmplete(object sender, EventArgs e)
                CodeActivity Sender = (CodeActivity)sender;
                Microsoft.Office.Workflow.Actions.OfficeTask ofctask1 = ((CompositeActivity)Sender.Parent).Parent as Microsoft.Office.Workflow.Actions.OfficeTask;
                officeComments = ofctask1.Comments;
                officeDescription = ofctask1.Description;          
    Please tell me if I'm doing anything wrong here, I'm very new to Workflows. Also, do I need to set any specific property of officeTask for retriving comments?
    Thank you

  • Is there a way to create multiple New Tabs pages and name them?

    This feature is great but I would like to be able to create multiple new tabs pages and label them. This would be more useful than tabs groups that all load at once.

    No that is (currently) not possible.
    It will be possible in future Firefox version to specify the number of rows and columns.
    *[https://bugzilla.mozilla.org/show_bug.cgi?id=752841 bug 752841] - [New Tab Page] make the number of tabs adjustable
    <i>([https://bugzilla.mozilla.org/page.cgi?id=etiquette.html please do not comment in bug reports])</i>

  • Can I create a "stage" in Animate and use it in Muse to create a responsive site?

    I want to use Muse to build my site and Animate for some elements. I need a responsive site. Muse does not do that but Animate does. That is crazy! How can I combine them? There has got to be a way. Someone smarter than I has figured it out I am sure, I am hoping they chime in.
    Can I create the "stage" in Animate and use it in Muse?

    You are probably right but I was looking for the ease in creating only one and letting it do the work.
    Now that I think about it....my site will have video embedded and a link for Ustream. That won't work on a mobile device if it is part of a responsive design will it?
    Oh, there is soooo much to all of this!
    Newbie anxiety!
    This is why I chose Muse and Animate, I am too new to code it on my own.

  • Can I still create new sites in iweb and publish them to mobile me?

    Can I still create new sites in iweb and publish them to mobile me? Also Can the sites not contain movies or photos, or just not a full gallery?

    You can have as many sites and domain names on a single MMe account. However, only one site can use the CNAME domain name forwarding while the others must use URL forwarding.
    Multiple Sites with Domain Name(s) in a Single MobileMe Account
    Here's how to have multiple sites in a single MMe account with one or more sites having a domain name.
    A. All sites are in the same Domain.sites2 files
    1 - only one site can use the CNAME method of domain name forwarding and it must the top site in the left hand pane of iWeb.
    Click to view full size
    2 - the other sites must use URL domain name forwarding which directs the domain name to the site's full MMe URL, http://web.me.com/MMeUsername/SiteName, or, if there is no domain name, just MobileMe's full URL.
    B. Each site is in its own Domain.sites2 file.
    Again, only one site can use CNAME forwarding. This presents a problem since CNAME forwarding directs the domain name to the basic MMe account URL: http://web.me.com/MMe_Username/ which uses an index.html file in the root folder of the account, iDisk/Web/Sites. Each time a new site is published or an existing site uses the File->Publish Entire Site a new index.html file is created in that root directory, iDisk/Web/Sites folder, directing the browser to that particular site. This file is what the CNAME method uses to find the site it represents.
    Therefore some steps must be taken to assure that the index.html file in the MMe Accounts root directory always points to the correct site. This can be accomplished is three ways.
    1 - don't use the CNAME method. Just use URL forwarding . This, IMO, is the simplest method as it doesn't requre any additional effort on the user once the domain name has been set up.
    2 - use the following method suggested by Wyodor in this topic: Is it possible to have multiple sites when using ur Domain name?
    In iWeb domainfile 1:
    Create a dummy site : _dummy
    with a blank page.
    Create your working site : Whatever
    Add pages
    Publish both Sites to the same same location on the same server.
    Your _dummy site is now the default Site.
    Check.
    In iWeb domainfile 2:
    Create/Use your CurrentSite.
    Move a page to the top of the Site and back. Publish the Site.
    iWeb will create a new index.html file in the root of the server and from now on CurrentSite is the default site.
    Check.
    From now on, never move your Whatever Site to the top of the list in the iWeb sidebar and never change the page in the _dummy site.
    Simply do not touch your _dummy ever again. And never forget that.
    3 - use Ethmoid's suggested method in Using two sites - setting one up with separate domain? or republishing the entire site that uses CNAME forwarding. Just making a minor change and publishing the site changes does not create a new index.html file.
    The entire site must be republsihing in order to get that new site.
    Or keep a copy of the CNAME site's index.html file on your Mac and replace it manually in the iDisk/Web/Sites fodler when necessary.
    NOTE: the CNAME method provides a shorter URL: http://www.DomainName.com/Site_Name/PageName. CNAME does not have masking.
    The URL forwarding displays the full MMe URL:
    http://web.me.com/MMeUsername/Domain_Name/PageName.
    With domain name masking that will be shortened to:
    http://www.Domain_Name.com for every page of your site.
    However, visitors will only be able to bookmark and enter at the first page of the site. If a page is refreshed the visitor is taken back to the first page. Also search engines will only be able to index the first page of the site.

  • How to Create PDF from Illustrator CS3 by using applescript?

    Hi Guys,
    Do some one knows how to create PDF from Illustrator CS3 by using apple script. If know, please give me the scripting.
    HARI

    Have you tried File>Scripts>SaveDocsAsPDF? There should be a folder of sample scripts installed in your AICS3 folder and a folder of documentation which contains an Illustrator AppleScript Reference which has examples.

  • Creating variables in Process Flows and using thse variables in the filter

    Hi,
    I am new to OWB and in learing stage. Need to information.
    *1. as to how pass/create/use variables to OWB mapping ?*
    *2. Creating variables in Process Flows and using thse variables in the filter operator of the OWB mapping?*
    *3. Other mechanisms of how to create/use variables within OWB mapping itself ?*
    can you please provide the above details and guide me / help me in this regard.
    Thanks,
    skms.

    1. Add parameters to your mapping using the MAPPING INPUT PARAMETER from the pallette.
    2. Add parameters to the START operator in the process flow. Bind the process flow parameter to the Mapping parameter.
    3. May be appropriate to use CONSTANTS instead of parameters.
    Regards
    Si

  • External definition and used them as Data Type Templates

    hi all
    how to Develop external definition and used them as Data Type Templates .
    Thank u
    Swari

    HI
    External Definitions: If a definition of the message structure exists in wsdl, xsd, dtd formats, we can use it in the integration repository by importing it as an external definition.
    External Definations:
    An external definition enables you to import a local WSDL, XSD, or DTD file to the Integration Repository and specify which parts of the schema to extract as the description for a message. You can use these extracted message schema as:
    Output or input messages in message interfaces
    Source or target structures for message mappings
    There is a series of standard schema for describing the message structure at runtime. WSDL (Web Service Description Language), XSD (XML Schema Definition Language), or DTDs (Document Type Definitions) are often used to describe message schema. If a description of the message structure already exists in one of the above formats, you can use it in the Integration Repository by importing it as an external definition rather than re-entering it manually using the data type editor.
    Have a look at
    http://help.sap.com/saphelp_nw04/helpdata/en/43/ce49ef1019087ae10000000a1553f6/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/ba/d4c23b95c8466ce10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/26/9e97b0f525d743882936c2d6f375c7/content.htm
    cheers

  • This may sound like a stupid question,,,but can i downlaod other programmes to my ipad, and use them like i would on a pc/net book ?

    this may sound like a stupid question,,,but can i downlaod other programmes to my ipad, and use them like i would on a pc/net book ?

    No.
    It is not a replacement for a computer.
    It mirrors the selected content of your computer.
    The only programs that can be loaded on an ipad are those found in the app store.

  • Creating page items from pl/sql procedure and using them on a page

    I have a page containing 2 select lists (P21_DEPARTMENTS and P21_DATE). Originally I added them as items that were "select list with submits". The problem is that based on the clearance level of the currently logged on user I only wanted the P21_DEPARTMENTS to be a select list if the user was an administrator. If however the user is not an admin then I want the page to have a hidden form field called P21_DEPARTMENTS that stores the user's department and has a label item that has the department name.
    There is also a report region that generates a table based on the department selected from the select list (if the user is an admin) or the value stored in the hidden form field if the user is not.
    My problem is that I cannot have both those items on the same page and use the HTML built-in authentication to determine which item should be rendered because I need to use the same ID for both items so that the stored procedure in my report region doesn't break. HTML does not permit items to share the same ID.
    I tried to circumvent the problem by creating a stored procedure that performs all of the item rendering in the procedure and uses "htp.p()" to output all of my HTML code. This solution would allow me to pass a parameter into the procedure informing me as to whether or not the user is an administrator. If the user is an administrator the procedure would use a conditional statement and render a select list. If not, the hidden form field and label option would be used instead.
    I finally got the stored procedure working perfectly. Now I am encountering the most bizarre thing. Since the "select list with submit" was not working (I used the same code that gets generated when I created other items using htmlDB's GUI) I decided to use a JavaScript function instead that gets triggered by the onChange event. I send along the value that is currently selected in the select list and in the function I set:
    location.href='http://www.myoraclesite.com/pls/htmldb/f?p=111:21:729740000000000000::NO::P21_DEPARTMENTS:1';
    In theory this should work. The problem is that it doesn't. The page reloads and the P21_DEPARTMENTS select list is not pre-selected.
    The only thing I can think of is that when htmlDB generates page items that you've created with it's own admin tool it assigns some internal guid or something as opposed to when someone tries to generate dynamic page items of their own from a pl/sql procedure it's like the application doesn't even know they exist.
    Any help would be GREATLY appreciated.
    My only other solution would be to create a totally separate page (one for admin and another for non-admin). I would really like to avoid this.
    Thanks in advance.

    I would love to be able to generate my menus and
    various other items in my htmlDB applications in much
    the same way I can using ASP, PHP and Cold Fusion.
    Users should have the ability to write server-side
    code wherever they feel like it. The way htmlDB works
    right now I spend more time trying to figure out how
    to create simple effects and generate simple
    interfaces when I need to be building a portal. Ami - it's important to understand that HTML DB is not like other languages. Thus, trying to force concepts which are common in other languages into HTML DB will often result in more work.
    It's definitely worth the time to go over the HTML DB 2-day Developer, which can be found here: http://www.oracle.com/technology/products/database/htmldb/pdf/B14377_01.pdf
    I can build a portal using Classic ASP, C#, PHP or Cold
    Fusion in like 1/10 of the time that it takes me to
    build one using htmlDB. I understand that this is not
    meant for the hard-core programmer but no web
    programming application in today's day and age should
    prevent experts from getting under the hood.And I can build a Portal in HTML DB in 1/10 the time it will take me to do it in any other language. It's like anything else - proficiency comes with practice and work.
    As for getting under the hood, there is plenty of places you can do that with HTML DB. Keep in mind that HTML DB itself is an HTML DB application, so the limits on what you can build with HTML DB are virtually limitless.
    Sorry for the vent there. After spending the last 2
    days trying to figure out how to implement such a
    straightforward thing and now being informed that it
    can't be done kind of bugged me.I understand your frustration, as I've been there before. My rule for beginners is that if you are writing more than a line or two of code in the first week, you're doing something wrong. Stop, take a break, and then use the ample resources (including searching this forum) to help solve your problem. There are plenty of resources available for you to learn about HTML DB on the HTML DB home page: http://otn.oracle.com/htmldb
    Good luck,
    - Scott -

  • Can photoshop actions created in CS2  be imported and used in Photoshop CS6?

    I have a slew of actions that I created in Cs2, my previous version of Photoshop. I've upgraded to CS6  and would like to use my previous actions in the new version. Is this possible? If so, how?
    Thanks!

    If you saved the in CS2 in theroy you should be able to load them in newer versions of Photoshop. As far as I know all Action created in CS2 will play in CS3 correctly. 
    Adode introduced options in CS4 that are not compatible with how Photoshop was designed to run.  When these options are set to have Photoshop work the way it worked before the CS4 options.  Actions will Play correctly.  However if you set these options to change the way Photoshop works some actions will now work correctlr in CS4, CS5 and CS6. It make no difference what version you record those actions in. Recording an action in CS6 doese not mean it will play correctly in CS6.  The Action will record the same way in CS2, CS3, CS4, CS5 and CS6.  Thet will play correctle in CS2, CS3 and they may play correctle in CS4, CS5 and CS6 depending on what options are set. 

  • Get Javascript values and use them in a servlet?

    Hey
    I have a HTML which has Javascript scripts which I have to get values from (a array to be exact) and pass them to a servlet so I can process the information in a certain way. I cant seem to find a way to do this properly as the servlet is server side and Javascript is client side. How can I implement this?
    Using a quick example example I have
    C:/index.html
    C:/js/script.js
    Index.html contains:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <script type="text/javascript" src="js/script.js">
    </script>
    </head>
    <body>
    a href="javascript:void(0);" id="add"><img src="images/menunew.png" alt="plus" border="0" />
    /a>
    </body>
    </html>
    Script.js contains:
    var Script = Class.create({
    a:4,
    b:5,
    add: function(){       
    return (this.a + this.b);
    (Ignore syntaxis errors as this is a quick example I wrote up just to see if you can give me a practical example on how to read it.)
    How can from a Java servlet access a and b from the script.js file (which contains a class named Script) and also access the function add which returns that value?
    Thank you for the help
    Edited by: 902756 on 16-dic-2011 0:18

    DrClap wrote:
    902756 wrote:
    1: Yes, it seems like the logically answer but Im not too up on AJAX and even less on mixing it up with servlets. Do you mind giving me a simple add (function) sample or something similar?You are looking at it the wrong way. What you actually want to do is to have the browser send a request (which somehow contains that Javascript data) to a URL which causes the servlet to receive the data. There's no "mixing it up" going on there. The client and the server are entirely separate.
    And since that request would be an HTTP request, it's just text. There's no concept in HTTP of transmitting objects, whether they be Javascript objects or Java objects. Anything you want to transmit has to be converted into text by the sender and converted back into objects by the receiver.
    So there's no such thing as "a simple add function". You're going to have to stop thinking in that way and start thinking of client-server systems in the way they actually are.The thing is I want to start simple to grab a simple concept....
    Im trying a AJAX route and I have the following:
    /index.html
    /js/Adding.js
    Index contains:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
         <title></title>
         <script type="text/javascript" src="js/Adding.js"></script>
    </head>
    <body>
    <select name="num1">
    <option value="1">1</option>
    <option value="2">2</option>
    <option value="3">3</option>
    <option value="4">4</option>
    </select>
    <select name="num2">
    <option value="5">5</option>
    <option value="6">6</option>
    <option value="7">7</option>
    <option value="8">8</option>
    </select>
    <form method="get" name="adding">
    Do
    <span id="res"></span>
    </form>
    </body>
    </html>
    Adding.js contains
    var Adding = Class.create({
    x: null,
    y: null,
    add: function()
         var xmlHttp = new XMLHttpRequest();
         var value1 = document.getElementById("num1").value;
    var value2 = document.getElementById("num2").value;
         xmlHttp.open("GET", "index.html", false);
         xmlHttp.send(value1 + value2);
         var result = document.getElementById("res");
         result.innerHTML = xmlHttp.responseText;
    This shows 2 comboboxes full of numbers and link saying "Do" which calls the javascript function and adds the two numbers in the comboboxs and shows them on the screen without refreshing the page. This does not work and I would like this to work before I continue onto the bigger picture.

  • Reading values from JTextField and using them?

    Hello,
    I am trying to make a login screen to connect to an oracle database. Im pretty new to creaing GUI. I need help with reading the values from the JTextField and to be able to use them for my connection. So do I need to apply a listener? How do I go about doing that in this project. Thanks for any code or advice.
    import java.util.*;
    import java.awt.*;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.table.*;
    import java.sql.*;
    public class UserDialog
        String databaseURL;
        String driver;
        String database;
        String username;
        String password;
        String hostname;
        String port;
        UserDialog() {
            getInfo();
        static String[] ConnectOptionNames = { "Login", "Cancel" };
        static String   ConnectTitle = "Login screen";
        public void getInfo() {
            JPanel      connectionPanel;
            JLabel     databaseURLLabel = new JLabel("Database URL:   ", JLabel.LEFT);
         JTextField databaseURLField = new JTextField("");
         JLabel     driverLabel = new JLabel("Driver:   ", JLabel.LEFT);
         JTextField driverField = new JTextField("");
            JLabel     databaseLabel = new JLabel("Database:   ", JLabel.LEFT);
         JTextField databaseField = new JTextField("");
            JLabel     usernameLabel = new JLabel("User Name:   ", JLabel.LEFT);
         JTextField usernameField = new JTextField("");
            JLabel     passwordLabel = new JLabel("Password:   ", JLabel.LEFT);
         JTextField passwordField = new JPasswordField("");
            JLabel     hostnameLabel = new JLabel("Host Name:   ", JLabel.LEFT);
         JTextField hostnameField = new JTextField("");
            JLabel     portLabel = new JLabel("Port:   ", JLabel.LEFT);
         JTextField portField = new JTextField("");
         connectionPanel = new JPanel(false);
         connectionPanel.setLayout(new BoxLayout(connectionPanel,
                                  BoxLayout.X_AXIS));
         JPanel namePanel = new JPanel(false);
         namePanel.setLayout(new GridLayout(0, 1));
         namePanel.add(databaseURLLabel);
         namePanel.add(driverLabel);
            namePanel.add(databaseLabel);
            namePanel.add(usernameLabel);
            namePanel.add(passwordLabel);
            namePanel.add(hostnameLabel);
            namePanel.add(portLabel);
         JPanel fieldPanel = new JPanel(false);
         fieldPanel.setLayout(new GridLayout(0, 1));
         fieldPanel.add(databaseURLField);
            fieldPanel.add(driverField);
            fieldPanel.add(databaseField);
            fieldPanel.add(usernameField);
         fieldPanel.add(passwordField);
            fieldPanel.add(hostnameField);
            fieldPanel.add(portField);
         connectionPanel.add(namePanel);
         connectionPanel.add(fieldPanel);
            // Connect or quit
            databaseURL = databaseURLField.getText();
            driver = driverField.getText();
            database = databaseField.getText();
            username = usernameField.getText();
            password = passwordField.getText();
            hostname = hostnameField.getText();
            port = portField.getText();
            int n = JOptionPane.showOptionDialog(null, connectionPanel,
                                            ConnectTitle,
                                            JOptionPane.OK_CANCEL_OPTION,
                                            JOptionPane.PLAIN_MESSAGE,
                                            null, ConnectOptionNames,
                                            ConnectOptionNames[0]);
            if (n == 0) {
                System.out.println("Attempting login: " + username);
                String url = databaseURL+hostname+":"+port+":"+database;
             // load the JDBC driver for Oracle
             try{
                   DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
                   Connection con =  DriverManager.getConnection (url, username, password);
                System.out.println("Congratulations! You are connected successfully.");
                con.close();
                System.out.println("Connection is closed successfully.");
             catch(SQLException e){
                System.out.println("Error: "+e);
            else if (n == 1)
                    System.exit(0);
        public static void main (String args []) {
             UserDialog ud = new UserDialog();
    }thanks again,
    James

    the reason why you can't get the text is because you are reading the value before some actually inserts anything in any fields.
    Here is what you need to do:
    Create a JDialog/JFrame. Create a JPanel and set that panel as contentPane (dialog.setContentPane(panel)). Insert all the components, ie JLabels and JTextFields. Add two buttons, Login and Cancel to the panel as well. Now get the username and password field values using getText() inside the ActionListener of the Login.
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class LoginDialog extends JDialog
    String username, password;
      public LoginDialog( ){
        setTitle( "Login" );
        JPanel content = new JPanel(new GridLayout(0, 2) ); // as many rows, but only 2 columns.
        content.add( new JLabel( "User Name" ) );
        final JTextField nameField = new JTextField( "" );
        content.add( nameField );
        content.add( new JLabel( "Password" ) );
        final JTextField passField = new JTextField( "" );
        content.add( passField );
        JButton login = new JButton( "Login" );
        login.addActionListener( new ActionListener(){
          public void actionPerformed( ActionEvent ae ){
            username = nameField.getText();
            password = passField.getText();
            // call a method or write the code to verify the username and login here...
        content.add( login );
        JButton cancel = new JButton( "Cancel" );
        cancel.addActionListener( new ActionListener( ){
          public void actionPerformed( ActionEvent ae ){
            dispose(); // close the window or write any code that you want here.
        content.add( cancel );
        pack( ); // pack everything in the dialog for display.
        show(); // show the dialog.

Maybe you are looking for