How can I know the name of the file that the user has currently open ?

Hello
I'm developing a module for x3dv.
http://hiperia3d.blogspot.com/search/label/X3DV%20Module%20For%20Netbeans
I am going to add a button to open the files when I click it.
I just need to know how can I know the name of the file that the user has currently open in the editor. What variable holds it in Netbeans?
Thank you
Jordi

If you are using the JFileChooser to open the document, I would create another class with this included:
//initiate class variables
private File f;
//create JFileChooser
JFileChooser fc = new JFileChooser();
fc.setMultiSelectionEnabled(false);
fc.setFileSelectionMode(JFileChooser.FILES_ONLY)
//set the chooser to initialise File f with the file selected
int status = fc.showOpenDialog(null);
if (status == JFileChooser.APPROVE_OPTION)
     f = fc.getSelectedFile();
public File getFile()
     return f;
}

Similar Messages

  • A phantom folder with the name of a folder that held photos has appeared in my finders places list.  I can't choose it to delete it.  it won't move.  It can't be found in a search.  How can I choose it and delete it?

    a phantom folder with the name of a folder that held photos has appeared in my finders>places list.  I can't choose it to delete it.  it won't move.  It can't be found in a search.  How can I choose it and delete it?

    Can you drag it off holding down the CMD key?
    Do a search for it with EasyFind  (try different settings in "Operator")
    http://www.devontechnologies.com/products/freeware/

  • HT4623 How can I upload a word or PDF file to the photo album folder on my iphone 5 ?

    How can I upload a word or PDF file to the photo album folder on my iphone 5 ?

    What is the web site?

  • How to create a record based on the name of a file in the file-system?

    Hi,
    With a lot of pictures I want to have a database to gather some information about these pictures.
    First question is how to generate a record based on a file in the file system?
    e.g. the pictures are "c:\fotos\2009\01\disc_001.jpg" to "c:\foto\2009\01\dis_98.jpg" .
    now i want to create records with as one of the attributes the name of the picture (not the picture itself). how to create these records (based on the information of the file-ssytem). i.e. the number of records should be the same as the number of pictures.
    any suggestions?
    any reaction will be appreciated.
    Leo

    Link to Create directory
    http://www.adp-gmbh.ch/ora/sql/create_directory.html
    You can create a list of files in the directory and read the list files from that directory.
    [UTL_FILE Documentation |http://download.oracle.com/docs/cd/B14117_01/appdev.101/b10802/u_file.htm#996728]
    [Solution using Java|http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:439619916584]
    SS

  • I need some files that were in my idisk; how can i get them, i need some files that were in my idisk; how can i get them

    Whoops!
    Didn't download / upload all my files from my idisk account; now i need some for some study work; what can i do to access them?

    As Apple announced over 14 months ago, iDisk was shut down at the end of June 2012. They gave a one month extension for any laggards to download their data, and finally turned off the servers, deleting all files at the end of July.
    Did you not keep offline backups of these important files, as recommended by Apple? You should never only have one copy of any important file, especially if that one copy if stored on someone elses server you don't have control over, and more importantly when they say it is being shut down forever.

  • How can I remove my name from being associated with the GB file I export?

    I am using Garage Band '11, 6.0.5.
    I am editing an audio recording for a friend.
    When I exported the edited recording, it had my name associated with the file as the artist, album, etc.
    I searched and found "My info" (in "Preferences") and deleted my information from ALL name, album, artist fields, but it still exported the file with my name as the artist (but it did not list it as from my album this time)?
    Does anyone know how/where/what I need to do to remove all references of my name associated with this file I'm editing?
    And also, can I change who is associated with a GB file, from file to file (i.e. if editing my audio, use my name & info, if editing for a friend or colleague, theirs?  or is the name associated with my GB account universally embedded into every file, no matter if I want it to be mine or not)?
    Thank you for your support!
    Joe

    When I exported the edited recording, it had my name associated with the file as the artist, album, etc.
    The problem is, that this information is stored with the GarageBand project, when you first create the project.  You have to edit the Preferences, before you create the project.
    If the project already exists, you can change this option by turning the project into a podcast. Add a Podcast track (Track menu, Show Podcast Track), select the podcast track, and open the Info panel. Then edit the artist field in the Info panel, before you save the song to disk.
    (added: I saw the workaround with the Podcast track first in a post by Edgar).

  • How can I copy the name of a file, that I selected by a click?

    Hi,
    I have a device controled by a Excell (VBA) interface. Truogh this interface I control the motors and Diadem (for the report) and the data are save in a database. When I  use the load button from the excell, the VBA application call the script from Diadem  Load_DATA_BOF.VBS, (after I complete the new data for the report), and make the report.  Now to make it work, I copy the name of the filename that I want to load in a TextBox, and all the data are store in a txt file( protocol_for_load.txt) and Diadem takes from there the data for the report.
    What I want to do is to fill automatic the field of the filename in the  protocol_for_load.txt, when I select the file in  Diadem.
    Can this be done?
    Thank you for your time
    Solved!
    Go to Solution.
    Attachments:
    BOF script.zip ‏177 KB

    Hi Brad,
    I find out how to copy the name of a selected file ( with filedlgfile) and now I want to open the text file ( with the name the same like the file loaded)  so I can read the data from inside, but the command textfileopen from the script can't support a variable in the description, I thing.
    Fno = textfileopen ( filenametxt, tfread)
    Please look in to my script to understand better.
    I need to open the txt file with the name the same like the file loaded, to take the data and fill the report. This I need to do in Diadem Script, because I will call the script trough a VBA interface.
    Sorry for not being more clearly  first  time, but I am a beginner in working with VBS.
    Attachments:
    Diadem script.zip ‏69 KB

  • How can I know if a process is running in the system???

    Hello all,
    I generate a pdf file with Reports Builder called from Forms Builder.
    This pdf is printed in the default printer with the command line "start AcroRd32.exe /p /h path_file", inside host command, which open the Acrobat Reader and prints the document in the default printer.
    After the document is printed the document is closed but not the Acrobat Reader program.
    I need an instruction to know if the acrord32.exe is running in the system.
    Could anyone help me?
    Thank you very much for advance,
    Jordi

    do you use the commandline, because you want to print directly to your default-printer?
    then have a look at the orarrp - toolset on otn.
    It's a technique, which directly prints via MIME-extensions of your browser. Internally Adobe is used for this direct print, but you only have to install a little program on your client.
    try it
    Gerd

  • How can I generate my own InDesign ePub file without the encryption.xml file?

    My bookstore (B&N) will not accept my ePub file because it doesn't want the file encryption.xml included. How can I generate an InDesign ePub file, for my own books, without it? Is there a check box somewhere? I've searched through the ePub export box and the file info boxes—no luck.
    Error message from B&N's PubIt.com:
    We have found a file name called encryption.xml within your ePub file container, which means that part of, or all of, your file is encrypted. We do not accept any encryptions within ePub source files. Upon closing this message, please remove the encryption.xml file from your ePub, and you may attempt to upload your ePub file again.
    If you wish to apply DRM to your title, go to Section 4, question H and select Yes. PubIt! will apply DRM to your title after you have uploaded your ePub file without encryption.
    Thanks for your help…

    Unfortunately you will find the option to uncheck "Embeddable Fonts" within ID CC 2014 only if you are creating an ePub with reflowable layout, but not if you are creating a "fixed layout" ePub.
    I went with the suggestion of the eCanCrusher and was pleasantly surprised how easy to use this free tool is. You basically just drag your ePub over the icon of the App and it creates a folder in which you find the encryption.xml within the META-INF folder. Once you erased it you drag the folder over the icon of the App and through this you will get a new encryption-free ePub which now passes iTunes Connect Book Proofer test.
    But then - opening the ePub without it's encryption within iBooks (on ipad) the text has moved, spaces between words are gone for no reason, words are even sticking into each other - it looks unacceptable! It does look OK on the iBook desktop app, however.
    My solution was to change the font from Myriad to Verdana. I had changed the fonts before, because - whatever font I had used - it's reproduction on the ipad was messed up, and Myriad was the first one that I tried that looked alright, though, not so much after removing the encryption.xml. Unfortunately everything changes when you change fonts within a fixed layout ePub and all line breaks have to be revised now...
    I also tried to remove the embedded fonts from inside the ePub, like someone else suggested, but that didn't help with the Book Proofer. It's really the encryption.xml that needs to be removed.
    I wish that I now finally can submit successfully to Apple and wish that Adobe would have a better relationship with Apple to solve issues like that.

  • How can I plott data from a text file in the same way as a media player using the pointer slide to go back and fort in my file?

    I would like to plott data from a text file in the same way as a media player does from a video file. I’m not sure how to create the pointer slide function. The vi could look something like the attached jpg.
    Please, can some one help me?
    Martin
    Attachments:
    Plotting from a text file like a media player example.jpg ‏61 KB

    HI Martin,
    i am not realy sure what you want!?!?
    i think you want to display only a part of the values you read from XYZ
    so what you can do:
    write all the values in an array.
    the size of the array is the max. value of the slide bar
    now you can select a part of the array (e.g. values from 100 to 200) and display this with a graph
    the other option is to use the history function of the graphes
    regards
    timo

  • I need to know the names of this files that are inside Users/-username-/AppData/Local/Adobe - Please help

    I just had the absolute worst experience ever with some idiot at Adobe's chat support. He took control of my computer and started renaming files to old, without keeping the original name (original.old) like he should have.  What he was trying to do did not work. Then he just cut the connection and ran.  I am furious.  I need help to rename these back to their original name so that Adobe Creative Cloud will open.  I have Acrobat, AcroCef, AIR, CameraRaw, Color, InDesign, OOBE, the one he renamed to old and PII.  Please help. It should be a file related to Illustrator.

    Hi Daniel,
    We have some user specific preferences files under this folder.
    Kindly provide some more information so that we can try to assist you with it.
    OS version:
    Error message if any:
    Thanks,
    Atul Saini

  • How can I incluce a hyperlink to TDMS file in the report?

    Hi,
    I am storing the measured data in TDMS file in each step. File name is written to the ResultText property so it is visible in the report.
    I would like to have hyperlink in the report that opens this TDMS file automatically either with DIADEM or with the TDMS VIEWER (LabVIEW application)
    Any help in creating hyperlink in the report (XML, HTML) would help.
    Thanks,
    Andras

    Hi Andras,
    you can also write the links within a new step to the report.
    As shown in the attached file.
    Regards
    DianaS
    Attachments:
    Sequence File 2.seq ‏5 KB
    hallo3.vi ‏12 KB

  • How can I write this string to a file as the ASCII representation in Hex format?

    I need to convert a number ( say 16000 ) to Hex string ( say 803E = 16,000) and send it using Visa Serial with the string control in Hex Mode. I have no problem with the conversion (see attached). My full command in the hex display must read AA00 2380 3E...
    I can easily get the string together when in Normal mode to read AA0023803E... but how can I get this to hex mode without converting? (i.e. 4141 3030 3233 3830 3345 3030 3030 3031 )
    Attachments:
    volt to HEX.vi ‏32 KB

    Sorry, The little endian option was probably introduced in 8.0 (?).
    In this special case it's simple, just reverse the string before concatenating with the rest.
    It should be in the string palette, probably under "additional string functions".
    (note that this only works in this special case flattening a single number as we do here. If the stat structure is more complex (array, cluster, etc.) you would need to do a bit more work.
    Actually, you might just use typecast as follows. Same difference.
    I only used the flatten operation because of the little endian option in my version.
    Message Edited by altenbach on 11-16-2007 11:53 AM
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    littleendian71.png ‏4 KB
    littleEndiancast71.png ‏4 KB

  • How can I get Firefox to respond to files with the .nxg extension?

    I have been trying to open other pages than the home page of this site http://www.marinemachining.com/ and the only way that I can get them to open is to right click the URL button and choose open in a different tab or new window. Just clicking on the button should go to the page (for example "Propeller Shafting" and this will not work. Any help you can give is appreciated. Seems this Netopia file extension .nxg is not dealt with right now unless I have set something up wrong. Otherwise, I love Firefox.

    Are that files that you have saved on your computer or web pages that you try to open?
    Are you opening the files with a double-click in Windows Explorer?
    See also http://kb.mozillazine.org/Windows_error_opening_Internet_shortcut_or_local_HTML_file_-_Firefox
    There are other things that need attention:
    Your above posted system details show outdated plugin(s) with known security and stability risks that you should update.
    # Shockwave Flash 10.1 r82
    # Next Generation Java Plug-in 1.6.0_21 for Mozilla browsers
    Update the [[Managing the Flash plugin|Flash]] plugin to the latest version.
    *http://www.adobe.com/software/flash/about/
    Update the [[Java]] plugin to the latest version.
    *http://www.oracle.com/technetwork/java/javase/downloads/index.html (Java Platform: Download JRE)
    Update the [[Adobe Reader]] plugin to the latest version.
    *http://get.adobe.com/reader/otherversions/

  • How can I get bookmarks from my laptop now that the motherboard is dead?

    Laptop motherboard died - a friend transferred my files onto an external hard drive including my backed-up Firefox bookmarks, but (sadly) the last time I backed those up was 6 months ago. At least I have those on my new laptop now, but I'd *love* to get my most current bookmarks back - the ones I had on my laptop when the motherboard died. Is this possible, or are they gone forever? Thanks!

    You will need to be able to access the files on the old hard drive, so hopefully your friend put that drive in a USB enclosure so you can still access the files on that old drive.
    https://support.mozilla.com/en-US/kb/Recovering+important+data+from+an+old+profile

Maybe you are looking for

  • Is there a way to change my user agent from Safari to Internet Explorer?

    Hello All, I need to fill out a application on line and it appears that it does not recognize Safari.  Sounds like it needs to see IE.  Anyway to temporarily enable IE for this application?  Otherwise I have to go use a PC at the local library.... Th

  • HT5622 Do I need a true email to verify my apple I'd account

    Do I need a true email to verify my apple I'd account ?where can I make one

  • Sony Home Theater STR-DH800

    I have a Sony HD TV and a Sony STR-DH800 home theater AV receiver.  I have a Charter Cable box.  I am running an HDMI cable from cable box straight to TV.  I am also running a Digital Audio cable from cable box to AV receiver.  I am getting sound on

  • Problem with 'Advance' entry

    Griends, I am getting this strange problem. Does it happens with you also? Any solution.. The problem is as follows; 1. Transaction PR05 2. Enter only advance and save it with status Request Recorded/To Be Settled. 3. OPen the trip again, Simulate, t

  • "instance of" a class

    I'm writing a test program for our lab using LVOOP. All instruments are child classes of a general device.lvclass. I want to be able to save and load the specific system configuration (what instrument are used). In order to know which specific child