Need help with saving text

i,ve created frame with a JTable, and add new button.
every time i run project table gets empty, of course, that is normal, but i would like that when i tipe something in my table and press button, things i wrote in table get saved. lets say that the variable name of JTable is "table" and name of button "save". i'm not expert in java programing but i really need this code. could someone please be so generous and wrote that code for me? i need it till tomorrow :S

What you need is Serialization.
I did a quick google search and found this:
http://java.sun.com/developer/technicalArticles/Programming/serialization/
It basically allows you to save your object and load it later.
You could also save your stuff in plain text. Follow this tutorial to learn how, This is maybe a bit easier if you don't know what objects are.
http://java.sun.com/docs/books/tutorial/essential/io/index.html

Similar Messages

  • I need help with my text tone and I have ring tone. no text tone for the 4s.

    I need help with my text tone. I have ring tone no text tone. I have a 4s.

        Hi Sarar2333!  Let's get your text tones working again!
    Here's a link with instructions how to enable and change your alert sounds for your text/notification settings on your iPhone 4S: http://vz.to/1stiF8a.  You can ensure text tones are enabled by selecting a tone in the "Text Tone" setting.  Let me know how that works out for you.  Thanks!
    AnthonyTa_VZW
    Follow us on Twitter @VZWSupport

  • Need help with saving data and keeping table history for one BP

    Hi all
    I need help with this one ,
    Scenario:
    When adding a new vendor on the system the vendor is suppose to have a tax clearance certificate and it has an expiry date, so after the certificate has expired a new one is submitted by the vendor.
    So i need to know how to have SBO fullfil this requirement ?
    Hope it's clear .
    Thanks
    Bongani

    Hi
    I don't have a problem with the query that I know I've got to write , the problem is saving the tax clearance certificate and along side it , its the expiry date.
    I'm using South African localization.
    Thanks

  • Need help with automating text import/pasting/macro between Photoshop and Excel

    Hey everyone,
    I'm working on a large project now that seems extremely daunting, but I was hoping there would be some way to automate it using either Actions or some sort of macro program.  Here's the gist:
    I've created a template with 24 differently sized text boxes in the photoshop image file.  Each text feild has unique text that needs to be be pasted into it, which has been compiled in excel.  This wouldn't be too dificult to do, except I have to recreate this image and all 24 text fields aproximately 350 times.  None of the text boxes will remain static through all 350 images as text is the title, description, and demographic ratings/percentages/data for the topic of each image.  I did something similar manually last year and it took me about 3, non-stop 18 hour days to complete it.
    (the test template)
    Can anyone think of any way I could automate this process?  I'm thinking some sort of macro that copies cell 1 in excel, switches to photoshop, opens layer 1, pastes, switches back to excel, goes to cell 2, copies, back to photoshop, layer 2, pastes, etc, etc, then does a 'save as' in photoshop and revets to PS layer 1, EX cell 1 (on tab 2) to start the process all over again.  I have no idea if this would work or if there is another way to do this but I would really appreciate any help or advice you guys could give.  I don't have really any expreience using PS Actions or macro programs/scripts, so I may be over my head or overlooking a really simple way to do this.  If there's a way to do it, I'm persistent enough to figure it out and get it working. Doesn't really matter how it gets done, I just need to fill those text boxes as best as I can and as quickly as I can.
    Any help you all could give is really appreciated.

    Have you read up on the Variables support in Photoshop?

  • Need help with cleening text during ExportAllStories (JS-CS4)

    I have altered the ExportAllStories.jsx script for CS4 to export the selected TextFrame(s).
    The main function are the same as in the original.
    It works fine, but I need advice on how to clean the text before it gets exported to a text file.
    I have tried to pass the TextFrame object myStory, as in the original script, to a function like this:
    myStory = cleantext(myStory)
    The function cleantext works with a text string passed to it,like this:
    function cleantext(s) {
    s.replace(/\u2011/g,'-');
    I guess I have to extract the myStory object to a text string but haven’t succeeded yet.
    Maybe the solution is to do some search and replace with GREP or other techniques?
    All tips on how to proceed would be appreciated.

    This is how i solved my problem.
    With the help from Peter Kahrels function
    function replace (f, r)
       app.findGrepPreferences.findWhat = f;
       app.changeGrepPreferences.changeTo =r;
       app.documents[0].changeGrep ()
    And in my script I could easily do this:
    app.findGrepPreferences = app.changeGrepPreferences = null;
    story = app.selection[0].parentStory;
    // Sample: Replace non-breaking hyphen (8209 -> \u2011) with a regular hyphen.
    replace("/\u2011/g",'-');
    app.findGrepPreferences = app.changeGrepPreferences = null;
    And thereafter proceeding with the exporting stuff.
    Thank you all contributors in this forum!

  • Need help with optimizing text appearance when exporting video

    Here's what I'm trying to do:
    1. Convert a Powerpoint presentation to an MP4 (AVC) file, frame rate 30 (actually defaults to 29.97) and video bit rate of 1200kbps,using Wondershare PPT2VideoPro.  (There are no actual video clips contained in the original PPT file).
    2. Import the newly created MP4 video into a new project in Premeire Elements.
    3. Add audio files (WAV) created by Audacity.
    4. Export the final product as a video.
    Here's the problem:
    The text quality in the final exported film is very poor, and the screen occasionally seems to sublty flicker once and a while.  I've tried multiple different settings, but all with the same result.
    Can anyone offer suggestions on optimal settings for exporting the final product such that the text is as clear as possible?  (The text in the MP4 file created by Wondershare looks great.)
    Thanks!
    - Ernest

    One option would be to create the Text Images in Photoshop, and Save_As a PSD.
    For large sets of Titles, I do the text portion in Word/WordPerfect, so I can use Spell-Check. Then in PS, I just Copy/Paste the text into an Image, where I apply all of the PS Styles that I need. Because I use PrPro for most of my NLE work, I will often do the Titles with Layered Text, and Import those as a Sequence, so that the Layers are not Flattened. This allows me to independently animate each Layer, as I need. Unfortunately, PrE does not allow one to Import the Layered PSD's, Unflattened, as it does not have Sequences.
    Also note that PrE's Titler's Styles are just a starting point. Once applied, one can alter most aspects, and when they are satisfied with the changes, they can then Save the new Style and re-use it over and over. Do not forget the ability to modify those Styles.
    From PowerPoint, and this depends on the version, the best that one can usually do is to Export each "slide" as a TIFF, and Import those into the NLE program.
    Good luck,
    Hunt

  • Need help with saving item from combobox to textfile

    Hi all. right now my codes can only save one stock information in the textfile but when I tried to save another stock in the textfile , it overrides the pervious one.
    So I was wondering which part of my codes should be changed??
    DO the following
    Create a fypgui class and put this bunch of codes inside
    import java.awt.GridLayout;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.awt.event.KeyEvent;
    import java.awt.event.KeyListener;
    import java.io.BufferedInputStream;
    import java.io.BufferedReader;
    import java.io.DataInputStream;
    import java.io.File;
    import java.io.FileReader;
    import java.io.FileWriter;
    import java.io.IOException;
    import java.io.InputStream;
    import java.net.URL;
    import java.util.ArrayList;
    import java.util.Scanner;
    import javax.swing.JButton;
    import javax.swing.JComboBox;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    import javax.swing.JPanel;
    import javax.swing.JTabbedPane;
    import javax.swing.JTable;
    public class fypgui {
         private ArrayList<Stock> stockList = new ArrayList<Stock>();
         private String[] stockArray;
         private JComboBox choice1;
         private JTabbedPane tabbedPane = new JTabbedPane();
         private JPanel displayPanel = new JPanel(new GridLayout(5, 1));
         private JButton saveBtn = new JButton("Save");
         private JPanel choicePanel = new JPanel();
         String yahootext;
         String     symbol;
         int index;
         public fypgui() {
              try {
                   //read from text file for stockname
                   File myFile = new File("D:/fyp/savedtext2.txt");
                   FileReader reader = new FileReader(myFile);
                   BufferedReader bufferedReader = new BufferedReader(reader);
                   String line = bufferedReader.readLine();
                   while (line != null) {
                        Stock stock = new Stock();
                        // use delimiter to get name and symbol
                        Scanner scan = new Scanner(line);
                        scan.useDelimiter(",");
                        String name = "";
                        String symbol = "";
                        while (scan.hasNext()) {
                             name += scan.next();
                             symbol += scan.next();
                        stock.setStockName(name);
                        stock.setSymbol(symbol);
                        stockList.add(stock);
                        line = bufferedReader.readLine();
                   //size of the array(stockarray) will be the same as the arraylist(stocklist)
                   stockArray = new String[stockList.size()];
                   for (int i = 0; i < stockList.size(); i++) {
                        stockArray[i] = stockList.get(i).getStockName();
                   //create new combobox
                   choice1 = new JComboBox(stockArray);
                   //For typing stock symbol manually
                   choice1.setEditable(true);
                   //set the combobox as blank
                   choice1.setSelectedIndex(-1);
              } catch (IOException ex) {
                   ex.printStackTrace();
              JFrame frame1 = new JFrame("Stock Ticker");
              frame1.setBounds(200, 200, 300, 300);
              JPanel panel1 = new JPanel();
              panel1.add(choice1);
              choice1.setBounds(20, 35, 260, 20);
              JPanel panel2 = new JPanel();
              JPanel panel5 = new JPanel();
              panel5.add(saveBtn);
              displayPanel.add(panel1);
              displayPanel.add(panel5);
              tabbedPane.addTab("Choice", displayPanel);
              tabbedPane.addTab("Display", choicePanel);
              JLabel label2 = new JLabel("Still in Progress!");
              choicePanel.add(label2);
              frame1.add(tabbedPane);
              frame1.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              frame1.setVisible(true);
              saveBtn.addActionListener(new ActionListener() {
                   public void actionPerformed(ActionEvent e) {
                        // initalize index as the postion of the stock in the combo box
                        index = choice1.getSelectedIndex();
                        /*if the postion of the combobox is not blank,
                             it will get the StockName and symbol according to the
                             position and download the stock*/
                        if(index != -1){
                             symbol = stockList.get(index).getSymbol();
                             save(symbol);
         @SuppressWarnings("deprecation")
         public void save(String symbol){
              try {
                   String part1 = "http://download.finance.yahoo.com/d/quotes.csv?s=";
                   String part2 = symbol;
                   String part3 = "&f=sl1d1t1c1ohgv&e=.csv";
                   String urlToDownload = part1+part2+part3;
                   URL url = new URL(urlToDownload);
                   //read contents of a website
                   InputStream fromthewebsite = url.openStream(); // throws an IOException
                   //input the data from the website and read the data from the website
                   DataInputStream yahoodata = new DataInputStream(new BufferedInputStream(fromthewebsite));
                   // while there is some contents from the website to read then it will print out the data.
                   while ((yahootext = yahoodata.readLine()) != null) {
                        File newsavefile = new File("D:/fyp/savedtext.txt");
                        try {
                             FileWriter writetosavefile = new FileWriter(newsavefile);
                             writetosavefile.write(yahootext);
                             System.out.println(yahootext);
                             writetosavefile.close();
                        } catch (IOException e) {
                             e.printStackTrace();
              } catch (IOException e) {
                   e.printStackTrace();
         public static void main(String[] args) {
              // TODO code application logic here
              new fypgui();
    Create a Stock class a put this bunch of codes inside
    public class Stock {
         String stockName ="";
         String symbol="";
         double lastDone=0.0;
         double change =0.0;
         int volume=0;
         public String getStockName() {
              return stockName;
         public void setStockName(String stockName) {
              this.stockName = stockName;
         public String getSymbol() {
              return symbol;
         public void setSymbol(String symbol) {
              this.symbol = symbol;
         public double getLastDone() {
              return lastDone;
         public void setLastDone(double lastDone) {
              this.lastDone = lastDone;
         public double getChange() {
              return change;
         public void setChange(double change) {
              this.change = change;
         public int getVolume() {
              return volume;
         public void setVolume(int volume) {
              this.volume = volume;
    Create a folder called fyp in D drive and create two txt file in it.
    -savedtext.txt
    -savedtext2.txt
    in the saved savedtext2.txt add
    A ,AXP
    B ,B58.SI
    C ,CLQ10.NYM
    this is my whole application. if you guys can tell me what can I do to make sure that the stock info doesn't overrides . I will more than thankful.
    Edited by: javarookie123 on Jul 9, 2010 9:49 PM

    javarookie123 wrote:
    Hi all. right now my codes can only save one stock information in the textfile but when I tried to save another stock in the textfile , it overrides.. 'over writes'
    ..the pervious one.
    So I was wondering which part of my codes should be changed??Did not look at the code closely, but I am guessing the problem lies in the instantiation of the FileWriter. Try [this constructor|http://download.oracle.com/docs/cd/E17409_01/javase/6/docs/api/java/io/FileWriter.html#FileWriter(java.io.File,%20boolean)] (<- link). The documentation is a wonderful thing. ;-)
    And generally on the subject of getting help:
    - There is no need for two question marks. One '?' means a question, while 2 or more typically means a dweeb.
    - Do your best to [write well|http://catb.org/esr/faqs/smart-questions.html#writewell] (<- link). Each sentence should start with an upper case letter. Not just the first one.
    Also, when posting code, code snippets, XML/HTML or input/output, please use the code tags. The code tags protect the indentation and formatting of the sample. To use the code tags, select the sample and click the CODE button.

  • Need help with creating text anchors with tagged text.

    Can anyone tell me how to determine the correct value for a "Hyperlink Dest Index" value?
    I have a script which creates a tagged text file that specifies about about 280 pages of tables (thank heavens for autoflow) , and would like to add live links between different parts. I can create a text anchor and a hyperlink to it in InDesign. The tagged text definition for the link source is simple and in-line and exports and imports nicely as tagged text. However, I see that all the link destinations, aka  text anchors, are all exported at the very end of the tagged text files as global definitions, and thier location iin the document is specified by the property HyperlinkDestIndex. However, I can't figure out how to set this value progammatically. I've spent over an hour exporting links, and it sure isn't anything as obvious as character index in the story.
    Any advice appreciated,
      Read Roberts

    Read, I'm not sure the following is going to help you. It works for external hyperlinks, but you want internal links, right? Anyway, it might give you some clues.
    A funny thing: I was reviewing some script where I got links to work, and I spotted a tiny coding error. Links seemed to be defined by two separate identifiers: a "link name", which is what appears in Edit Hyperlink dialog, and a "Dest Key", which seems to be a simple increasing number. However, due to aformentioned coding error, the dest keys between the actual link and its definition were off by '1', so there was no way that ought to have matched. But it still worked! So "Dest Key" is a red herring ...
    As far as I understand, it works like this (for hyperlinks): in your text, you have
    HplName -- this is actually the 'title' that appears in the Hyperlink palette
    HplDest -- this is the 'internal name'
    DestKey. Hm. Perhaps you could omit this, per above obsvn.
    CharStyleRef, the name of the auto-applied style
    Hid -- seems to be always '0'
    HplOff: the "offset" from this entire command to the start of the hyperlink, in InDesign characters.
    HplLen: the "length" from the hyperlinked text, in InDesign characters.
    and in the list of 'proper' definitions, those that appear at the very end of your file:
    HplDestDfn -- the internal name again
    DestKey -- see above
    HplDestUrl -- finally! A real URL! (But you must escape lots of characters, such as the forward slash and colon.)
    Hid -- again, always seems to be '0'.
    Some of these items are perhaps optional, but experimenting with what may be left out only lead to frustration The Tagged Text guide is far from complete, as I'm sure you already knew.
    As noted, some (or all) of the named items need a backslash escape for a few characters, but I can't find a definitive way to determine in advance what is 'good' and what is 'not good'.
    The following script creates a Tagged Text file with a couple of working hyperlinks in it -- I don't know if this is of any help for your internal links.
    var hyperlinkDest = [];
    var text = "This is some text with a link [http://www.jongware.com/idjshelp.html] and another one [http://forums.adobe.com/thread/1014617?tstart=0] in it.";
    var tagtext = text.replace (/\[(.+?)\]/g, function (full, match)
                        return makelink (match, 'title:'+match, match, match);
    // When done processing plain text, add the destinations at the end:
    tagtext += hyperlinkDest.join('');
    tagFile = File(Folder.myDocuments+'/__tmp.txt');
    if (tagFile.open('w') == false)
              alert ("Unable to create temporary file!");
              exit();
    if (File.fs == "Windows")
              tagFile.write ("<ASCII-WIN>\n");
    else
              tagFile.write ("<ASCII-MAC>\n");
    tagFile.write ("<dcs:HYPERLINK=<cu:1>>\n");
              tagFile.write (tagtext);
    tagFile.close();
    // 'text' is the actual text that will be clickable
    // 'title' is what will appear in the Hyperlinks palette
    // 'name' is the internal name in the Edit Hyperlink dialog
    // 'url' is the actual URL that will be linked to
    function makelink (text, title, name, url)
              var destkey = hyperlinkDest.length;
              // In URL you must escape forward slashes and colons
              // .. and some other characters as well, by the way. There seems to be no list
              url = url.replace(/\//g, '\\/').replace(/:/g, '\\:');
              hyperlinkDest.push ('<HplDestDfn:=<HplDestName:'+name+'><DestKey:'+String(destkey)+'><HplDestUrl:'+url+'><Hid:0>>');
              return '<Hpl:=<HplName:'+title+'><HplDest:'+name+'><DestKey:'+String(destkey)+'><CharStyleRef:HYPERLINK><Hid:0><Brdrv:0><HplOff:0><HplLen:'+String(text.length)+'>>'+text;

  • Need Help with Arrays/Text

    I'm trying to create a flash program that uses it's own code to send and create images. Each square has a colour and that colour gets added into the array. A black, then grey, then white is:
    filecode = ["Bl", "Gr", "Wh"];
    That works fine, but when I try to paste it into an Input text box it will only fill in the first part of the array.
    filecode = ["Bl,Gr,Wh"];
    So the program has NO idea what I want.
    The only ways I can think of fixing this is by putting in 402 text boxes to suit every box...But every one of them needs a Variable Name.
    Or by sending the information straight into the array. But this way you are just looking at what you just drew, and that is not at ALL practical.
    Helping me with this headache will be greatly apprectiated.
    FlashDrive100.

    If you can explain the first part of your posting it might become a little clearer what you are trying to do and what isn't working... particularly this...
    " when I try to paste it into an Input text box it will only fill in the first part of the array."
    I can't speak for anyone else, but at this point, I share your file's problem... not knowing what you want.

  • Need Help with parsing text

    Hello all, I hope this is an easy question....
    I have a string similar to
    <li><span class="RandomInformation">the latest news on my site</span></li>
    I am currently geting a string where each new line is a new <li> from a pure http call. what I need to do is split this down into an array of strings (Yes this is my website, and no im not trying to rebrand other's work...:) ) delimeted on :
    - each line needs to be a separate element within a multidimensional array
    - Can't split on CrLf because further up and further down I have other entries I dont care about, so I need to use the <li></li> as indicators that they contain the information I want.
    - out of each line, I need to separate them into multiple 'columns' within the array
    - one for the contents of the span clas (in this case "RandomInformation"
    - one element for the contents of the link (in this case my url, http://www.w2gas.com, but will be sub pages later like http://www.w2gas.com/page2.html)
    - most importantly one element for the text between anchor tags (this case it is "the latest news on my site")
    I tried a Regex for stripping the HTML tags out, however all I was left with was the text between anchors. I know I could do it based on character by character looping (have done that) but its terrible slow. I know there must be a way to accomplish this, however Im just too new to figure it out. (maybe?)
    Thanks in advance
    Lee

    Would something like [this |http://htmlparser.sourceforge.net/] help?

  • Newb needs help with dynamic text

    Hi Everyone,
    I don't like being a newb - but that's how it is...
    I'm trying to create a multipage registration form that
    allows uses to register products.
    The first page asks for name etc, and on the second page I
    want it to say "Welcome "+username "!" - that sort of thing...
    The problem is I can't get it to keep the dynamic text values
    accross the pages.
    I can get it to repeat the input on the first page with this
    code:
    _root.firstname_txt.onChanged = function() {
    _root.firstname_repeat.text="Hello
    "+_root.firstname_txt.text;
    However when I call it on the second page it is undefined:
    second_repeat.text="hello "+_root.firstnamt_txt.text;
    trace (_root.second_repeat.text);
    I'm sure this is something simple and I'm just a programming
    dunce...
    Any help is appreciated.
    ta

    if your textfield (_root.firstname_repeat) doesn't exist on
    the 2nd frame, its text property will be undefined.
    to remedy, either extend your textfield's existance into the
    frames needed or use a variable to store its text property (in your
    onChanged handler) and use that variable to retrieve the value you
    need.

  • New to swing :( need help with simple text areas

    i'm trying to make a username and pasword GUI thingy (techinical word) but what i have now is this:-
    import javax.swing.*;
    import javax.swing.text.*;
    import javax.swing.*;
    import javax.swing.text.*;
    import java.awt.*;
    import java.awt.event.*;
    import java.net.URL;
    import java.io.IOException;
    public class swing1 extends JFrame implements ActionListener
         private String newline = "\n";
         protected static final String textFieldString = "JTextField";
         protected static final String passwordFieldString = "JPasswordField";
         protected JLabel actionLabel;
         private JTextField textField;
         private JPasswordField passwordField;
         private Container p; // make a panel to witch the components can be added
         public swing1()
              super("swing1");
              //Create a regular text field.
              textField = new JTextField(10);
              textField.setActionCommand(textFieldString);
              textField.addActionListener(this);
              //Create a password field.
              passwordField = new JPasswordField(10);
              passwordField.setActionCommand(passwordFieldString);
              passwordField.addActionListener(this);
              //Create some labels for the fields.
              JLabel textFieldLabel = new JLabel(textFieldString + ": ");
              textFieldLabel.setLabelFor(textField);
              JLabel passwordFieldLabel = new JLabel(passwordFieldString + ": ");
              passwordFieldLabel.setLabelFor(passwordField);
              //Create a label to put messages during an action event.
              actionLabel = new JLabel("Type text and then Return in a field.");
              actionLabel.setBorder(BorderFactory.createEmptyBorder(10,0,0,0));
              //Lay out the text controls and the labels.
              p=getContentPane(); //get te contant pane of this Swing1 to add the componets to
              p.add("West",textField); //add your fist component, add it west on the dafault borderLayout
              p.add("East",textFieldLabel);// add another component, add it east on the dafault borderLayout
              p.add("South",passwordField);// add it south on the dafault borderLayout
              p.add("North",actionLabel); // add it north on the dafault borderLayout
              setSize(400,100); //make it a bit bigger
              setVisible(true);
              public void actionPerformed(ActionEvent e)
                   Object o = e.getSource();// the component that fired this event
                   if (o == textField)
                        //action from the textField
                   else if (o == passwordField)
                        //action from passwordfield
              public static void main(String[] args)
                                  JFrame frame = new TextSamplerDemo();
                                  frame.addWindowListener(new WindowAdapter()
                                       public void windowClosing(WindowEvent e)
                                                 System.exit(0);
                                                                new swing1(); //make a new instance of your class
    [\code]
    why won't the label on my password field dislay?
    and can you take a look at the end of my code i got it off another program, i want to get rid of the HTML page its trying to access and i want it just to close when i click X
    any help would be briliant
    Ant                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Since you are new to Swing the first thing I would recommend is to read the tutorial "Creating a Gui with JFC/Swing". I think the Text Component section has a demo on creating a username/password GUI. It can be downloaded at:
    http://java.sun.com/docs/books/tutorial/
    Why doesn't the password field label display? You are not adding it to the container. You add textField, textFieldLabel, passwordField, actionLabel but no passwordFieldLabel.
    Instead of adding a WindowListener and implementing the windowClosing() method, there is an easier way to close the JFrame in JDK1.3. Simply use:
    frame.setDefaultCloseOperation( EXIT_ON_CLOSE );
    The class "TextSamplerDemo" doesn't belong in this class (it must be a demo class you downloaded from somewhere). All the code you need in the main method is:
    JFrame frame = new swing1();
    frame.setDefaultCloseOperation( EXIT_ON_CLOSE );
    Also, by convention classes should be named with the first character of each word capitalized. So you class should be renamed to "Swing1" from "swing1". Also remember to rename the file as the filename and class name must be the same and case does matter.

  • Need help with Vietnamese Text in Adobe Premiere CS4

    I just switch from PC to Mac and using Adobe CS4 to edit. Most of my client required Vietnamese Text for their wedding movies. On PC is very easy to type vietnamese text right on Adobe Premiere titles but in Mac is not. Anyone knows how to type vietnamese text in Premiere on Mac Please help. Thanks very much

    Try resetting your preferences.
    Easiest way I know is just delete the entire Preferences folder. Make sure PP and AME are both closed.
    If you have workspaces you want to save - not have to rebuild - then drag the entire Prefs folder out of Program Files.
    When you restart PP it will build a new prefs folder. You can then - one by one - import the saved workspaces from your old Prefs folder (and whatever else you want).

  • Need Help with Postioning Text Boxes

    Hello,
    I am fairly new to APEX, but I think I getting the hang of it. I am very much impressed with the functionality. I have a question and I hope someone can help me with it.
    I have a Diagram that looks like:
    X
    X X X X
    X X X X X
    The X's represent values that will go in the them, source being an SQL Query so I though I could use TextBox Item and make the sqlquery which will be a count of some sort. This will be dynamically changed depending on user input.
    I also have lines connecting to the X's and labels. So I created a table with the diagram as a background. So my dilema is that how do I reference ITEM Text boxes to be in the table. I tried
    <table background="my_image.bmp"><tr><td>#ITEMS#:P1_X</td></tr><table>
    but it only shows up as ":P1_X" not that actual ITEM, i know my syntax maybe wrong to reference the item, so that would be my first question.
    Is there a way I can just position the actual textbox to in the table?
    My second question, for positioning so the textboxes woudl line up where the X's are, should I use CSS, and if so, do I have to upload a Style Sheet?(which I don't mind, just wondering if there is a way to just use CSS in the Page HTML SOURCE?)
    SO... basically I would like to know the best way to get these textboxes in the place where the X's are. The diagram is a image that is the background of a table. Any thoughts?

    After posting the message my representation of the diagram is a bit off, it looks like a Tree diagram with spaces and teh first X being in the middle and equally spaced then on.

  • Need help with flash text

    I created a banner for my groups web site with some simple
    text effects. It came out fine but I was assigned other work and
    was not able to finish the site for almost a yr. When I got back to
    it and tried to change a few words of the text it wouldn't work it
    seems all the effects I had used no longer would work. I would get
    error saying that I couldn't do it but the file I was modifying
    already "was" doing it, weird. I have no clue what changed. I
    managed to get it looking right in flash, I'm using FLASH MX 2004
    ver 7.2, but when I preview it in a browser it comes out all jerky
    and none of the effects work. Since this is an internat site I
    can't give anyone the address bcs you wouldn't be able to view it
    but I would be willing to send anyone the file I am talking about
    so you could see it for yourself. I would appreciate any help as I
    am at a dead end..
    Mike
    United Space Alliance

    anyone ??

Maybe you are looking for

  • Any Link with SAP BI and ECC6

    Hi.. Is there any Direct Link between SAP BI and ECC6. Regards Lakshman

  • Abap HR .Call funaction for RT tables

    Hi All   i  have one problem in abap-Hr reporting.. I call   function   CD_READ_RGDIR and then for  payroll results.                              PYXX_READ_PAYROLL_RESULT it works  in the dev. Server. but in the other, same client these  functional a

  • Invoice Help

    I am using LiveCycle Designer to create invoices for my small business. I used one of templates available and edited it to my needs. My problem is that I can not get it to compute sales tax. The invoice was already set up to compute everything else s

  • IPhoto Book Slideshow Music Settings Not Working

    When I try to view a Photo book as a slideshow, a default guitar music track plays. When I uncheck "Play music" the music still plays. When I try to change the music, the default guitar track still plays. It seems the music settings are not holding o

  • Certification for WEB COMPONENT DEVELOPER FOR J2EE[tm]

    Hi all, I'm thinking of getting certified as a WEB COMPONENT DEVELOPER FOR J2EE[tm] PLATFORM. What is your experience? How do I prepare best for the exam? Any book / tutorial particulary useful? Thanks for your input! Anja