Problem with command line argument files and quoted strings

I'm trying to use the following custom tag:
-tag com.me.Test.testTag:f:"My Test Tag"
This works fine when sent straight to the command line, but if I put it in an argument file (@argfile) along with the rest of my command, I get the following error:
javadoc: Illegal package name: "My Test Tag"
Any idea why this is happening? If I use a one-word tag header and omit the quotes, javadoc runs with no problems. I'm using Sun's SDK 1.4.1.
Thanks for your help!
Linda Howard

White space is treated a bit differently in an @argfile,
to enable users to put packages or options on separate lines.
You might try escaping the spaces:
"My\ Test\ Tag"
or using a non-breaking space:
"My Test Tag"
What operating system are you on?
-Doug Kramer
javadoc team

Similar Messages

  • Problem with command line arguments and multiple targets in ant

    Based on the argument value,I have to create properties file .I am using the key value pairs present in the properties file in my build.xml file.
    Here the problem is , I am able to create the properties file,using the argument vaue.i.e.,
    ant -Denv=build-dev copy.
    ant build-all.
    it works fine,but if i want to call another target which uses the propeties file ,at the time of passing argument is failing
    ant -Denv=build-dev copy build-all
    why it is happening ?
    My build.xml file
    <project name="AntParam" default="copy">
    <target name="copy">
    <fail unless="env">You must specify the env property when you run ant.</fail>
    available property="env.prop.file.exists" file="${env}.properties"/>
    <fail unless="env.prop.file.exists">Cannot find ${env}.properties file.</fail>
    copy file="${env}.properties" tofile="build.properties" overwrite="true"/>
    </target>
    <target name="build-all">
    <property name="one.dir" value="${project.home}/two" />
    </target>
    </project>
    "${project.home}"--------this value I am getting from properties file.

    i find solution.

  • How To Run An External .exe File With Command Line Arguments

    Hiya, could anyone tell me how I can run an external .exe file with command line arguments in Java, and if possible catch any printouts the external .exe file prints to the command line.
    Thanks.

    Using the Runtime.exec() command. And read this:
    http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html

  • Problem associated with Command Line arguments

    hi ,
    I am not able to pass a file path as command line argument in java.
    Actually i want to run a java program from the command prompt passing a file path . Something like this i tried to do , but its not working.
    D:\VISHAL\src> java CopyFile C:\Documents and Settings\Administrator\Desktop\link.txt
    where ,
    CopyFile is the name of my class which i am going to run
    C:\Documents and Settings\Administrator\Desktop\link.txt is the argument.
    Can anyone tell me whether a java program accepts an argument like this, if yes please tell me the exact syntax..
    Thanks
    Vishal J
    Message was edited by:
    vishal_vj

    is there any other way of solving this?Y don't U try it out with the logic as mentioned
    below it wud be the case if U r not going with
    java CopyFile "C:\Documents and
    Settings\Administrator\Desktop\link.txt" 1
    String filepath = new String();
    for(int i = 0; i < Arg.length; i++)
    filepath.append(Arg);
    File f = new File(filepath);
    What????  This is a non-solution to a non-problem.  First of all, you would be constructing a filename without spaces, when the real path contains spaces.  Secondly, even if you did insert spaces it would not matter.  What if the String (and it does not have to be a filename) contained tabs rather than spaces.  The real (and really only) solution to the problem is to put quotes around the argument, for the exact reason stated in my last post.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Need Help with command line arguments for a class method

    Hey guys,
    I'm fairly new to programming in java.
    I want to a write a class method that adds up its command line arguments which are numbers. For example, if the input was .... 5 2 3....then the output would be 10.
    I have been told to use the Convert to convert a string to a double. I'm ok for writing the class method but I have no idea how to use Convert and why I need it in the method.
    Can anybody help please?

    Hey guys,
    I'm fairly new to programming in java.
    I want to a write a class method that adds up its
    command line arguments which are numbers. For
    example, if the input was .... 5 2 3....then the
    output would be 10.Okay. So you would receive the numbers to add as the String[] argument to a main method. The steps are simple:
    1) declare a variable for the count
    2) for each String in the array:
    2.1) extract the value as a double
    2.2) add this to the count
    3) output the resulting count
    I have been told to use the Convert to convert a
    string to a double.
    I'm ok for writing the class
    method but I have no idea how to use ConvertThere is no class Convert in the Java API.
    and why
    I need it in the method. Do you understand you need to somehow convert each String to a double (step 2.1)? Since Convert is unknown to me, maybe you should just take a look at class Double. It can help you do step 2.1, the rest should be trivial enough.
    http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Double.html
    Give it a go and feel free to post back with a specific problem you are having, accurately described if you please :-)

  • Executing another program with command line arguments

    I am very new to Java, so bare with me.
    I have written an encryption/decryption program in C (that accepts command line arguments of the key, mode (encrypt/decrypt), and file), and I have written a GUI for it in Java. It accepts the filename (and has a button which opens the "File/Open" dialog), key, and mode, and has a button to Start the process of the encryption. I'd like for that "Start" button to call my encryption program in C (eep.exe) with the command line arguments of the file, key, and mode. This is what I have written so far :
    Start = new JButton("Start");
    Start.setBounds(150, 180, 90, 25);
    Start.addActionListener(new ActionListener() {     
    public void actionPerformed(ActionEvent ae) {
    Desktop.open(new File("C:\\eep.exe" + " " + filename + " " + mode + " " + key));
    However, I get the error "Cannot make a static reference to the non-static method open(File) from the type Desktop" on the Desktop.open command.
    What should I do? Is Desktop.Open the right way to go about this? If not, what is the right way to go about it?
    Thanks in advance.

    That has helped greatly, but I cannot pass command line arguments to it.
    Using :
    try {
        Desktop.getDesktop().open(new File("C:\\eep.exe"));
    catch (Exception e) {
       System.out.println("Error executing.");
    }I can execute eep.exe, but when I try to pass command line arguments to it, such as
    Desktop.getDesktop().open(new File("C:\\eep.exe" + " " + filename));it fails, get caught and prints "Error Executing."
    I have also tried loading the program, as well as some command line arguments into an array of strings :
    String[] cmdArray = {"C:\\eep.exe", filename};
    Desktop.getDesktop().open(new File(cmdArray));But it gives me the error "The constructor File(String[]) is undefined" on the
    new File (cmdArray)part of the command.

  • Launch executable with command line arguments

    I have a programmer that I need to launch in my cvi code.  I tried the system command and lauchexecutable command but cannot get the programmer to lauch correctly.  If I run it from the command prompt or create a windows shortcut it works fine.  Here is the shortcut I created:
    C:\TPD\SAVS20P3\asix\up\up.exe /e c:\tpd\savs20p3\q33.hex/erase /q /p
    I'm trying to run the up.exe software with /e c:\tpd\v20_hex\v20.hex /erase /q /p as the command line paramters.
    I tried the following code which created the above path with command line
     strcpy(filename,"C:\\tpd\\savs20p3\\asix\\up\\up.exe /e c:\\tpd\\savs20p3\\hex_ee\\");   ///e c:\\tpd\\savs20p3\\hex_ee\\"");
      strcat(filename, hfile);//hex file name will change dynamically
      strcat(filename, "/q /p");
    I then tried LaunchExecutable(filename) and system(filename).  The system functions gives an error.  Its trying to lauch the /e c:\tpd\v20_hex\v20.hex file
    any suggestions.  I beieve its a simple syntax error.

    Well, apart evident typos in the code you posted, which is not creating the command line you stated, I can only think that before "/q" you should add a space to separate the option from the filename.
    This code should create the correct command line:
    strcpy (hfile, "c:\\tpd\\v20_hex\\v20.hex");
    strcpy (filename, "C:\\tpd\\savs20p3\\asix\\up\\up.exe /e ");
    strcat (filename, hfile);
    strcat (filename, " /erase /q /p");
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • Pass the command line argument (argc and argv) to a LabVIEW built shared library.

    Hello,
    I have successully use this trick to build a LabVIEW application that runs on Linux without X Display.
    http://digital.ni.com/public.nsf/allkb/5D6EC36DCF43343786257449006919E6
    I'd like to know if it's possible to pass the command line arguments ( ./TEST A B C D) directly into the shared library without having to pass the arguments using a array of strings which would require to write code using DSNewHandle, DSSetHandleSize, extract the arguments and ..... (I'm not proficient in C, but if I don't have a choice I will do it and improve my C skills).
    int main(int argc, char *argv[])
            Test(argc, argv);
            return 0;
    Thanks,
    Michel
    Solved!
    Go to Solution.

    Well, you can always flatten it back into a space separated single string and pass it like that. Basically reverse what the OS does when it calls your main function with the command line parameters. And while the first element in the array is always the program name itself you can just skip that here, but then format all the rest into a single string.
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Permission problems with command line CVS and Java CVS App

    Greetings,
    I'm part of a moderately sized website development team which recently upgraded to MacBook Pros (dual core) running OS 10.4.9. One of the primary tools we use in our day to day work is the open source concurrent versioning system (CVS). We've noticed a distressing issue running CVS on our macbook pros: there seems to be a problem with the way these new machines handle permissions on the directories/files that CVS uses to manage files.
    The error occurs when the CVS application, in this case both command line CVS and GUI CVS application named SmartCVS, tries to rename a temporary file named Entries~ to its new name Entries (no ~). It looks like this:
    java.io.IOException: Could not rename file
    /Users/[USER]/Sites/[MODULE]/lib/CVS/Entries~ to
    /Users/[USER]/Sites/[MODULE]/lib/CVS/Entries
    at smartcvs.JP.a(SourceFile:125)
    at smartcvs.JP.a(SourceFile:113)
    We've noticed that if we open up a get info window on the directory we're downloading, and choose "Apply to enclosed items" right when we start the download process, the issue will be resolved, presumably because the permissions are being set on the subdirectories as the download is taking place.
    We've checked the permissions on the overall ~/Sites/ directory numerous times, and they always seem to be set correctly as drwxr-xr-x. It's within this folder that CVS creates a directory with the CVS module name and downloads all the contained files, so we don't see why it would be having issues completing this successfully. We also checked to ensure the GUI CVS application is running under the current user on the machine: it does.
    Has anyone run into issues like this in the past? Is there more information I could provide to further clarify the problem we're having?
    Thanks for any input you have!

    Thanks for asking Jeff, yes one place we are seeing this error is Java application SmartCVS, though the results posted here are from a normal command line CVS checkout.
    ===
    Checkout command:
    cvs co [MODULE]
    ===
    Error:
    cvs [checkout aborted]: cannot rename file CVS/Entries.Backup to CVS/Entries: No such file or directory
    ===
    ID:
    uid=502([USER]) gid=502([USER]) groups=502([USER]), 81(appserveradm), 79(appserverusr), 80(admin)
    ===
    LS -ALN
    Computer:~/Sites [USER]$ ls -aln
    drwxr-xr-x 28 502 502 952 Jun 4 13:11 Sites
    Computer:~/Sites/[MODULE] [USER]$ ls -aln
    drwxr-xr-x 38 502 502 1292 Jun 4 13:33 www_root
    Computer:~/Sites/[MODULE]/www_root [USER]$ ls -aln
    drwxr-xr-x 32 502 502 1088 Jun 4 13:33 [SUBDIR1]
    Computer:~/Sites/[MODULE]/www_root/[SUBDIR1] [USER]$ ls -aln
    drwxr-xr-x 5 502 502 170 Jun 4 13:33 [SUBDIR2]
    Computer:~/Sites/[MODULE]/www_root/[SUBDIR1]/[SUBDIR2] [USER]$ ls -aln
    drwxr-xr-x 4 502 502 136 Jun 4 13:33 [SUBDIR3]
    Computer:~/Sites/[MODULE]/www_root/[SUBDIR1]/[SUBDIR2]/[SUBDIR3] [USER]$ ls -aln
    drwxr-xr-x 6 502 502 204 Jun 4 13:33 CVS
    Computer:~/Sites/[MODULE]/www_root/[SUBDIR1]/[SUBDIR2]/[SUBDIR3]/CVS [USER]$ ls -aln
    total 32
    drwxr-xr-x 6 502 502 204 Jun 4 13:33 .
    drwxr-xr-x 4 502 502 136 Jun 4 13:33 ..
    -rw-r--r-- 1 502 502 45 Jun 4 13:33 Entries
    -rw-r--r-- 1 502 502 45 Jun 4 13:33 Entries.Log
    -rw-r--r-- 1 502 502 48 Jun 4 13:33 Repository
    -rw-r--r-- 1 502 502 63 Jun 4 13:33 Root
    MacBook Pro / MacPro Mac OS X (10.4.9)

  • ITunes / iPod having problems with lyrics in MP3 files and not with M4A ?

    Over the last two month (without this forum) I believed sometimes to be the only one having a weird problems with iTunes lyric format structure.
    Now after more than 50h of investigations interesting results appear.
    The field of trouble:
    a) People are not able to delete lyrics in iTunes
    b) People discover that iTunes and their iPod/iPhone do not show the same lyrics
    c) it seems that the lyrics of certain songs can't synchronised with the iPod
    d) it seems that the problem in iTunes can appear more than one times that itunes corrupts the contents of lyrics in a way that:
    e) the text structure is damaged, no more line breaks, no empty lines between text sections.
    After all my suspicion is: All of this trouble can be caused by one problem:
    iTunes (at least latest version 9.0.3 (15) has a -unkonwn- problem with the lyric-text structure in MP3-files. It seems that iTunes does not have the same problems if the file is in M4A-file format, created by apple-store files being downloaded, or CDs being converten in iTunes using the build in AAC-converter!
    Converting "infected" files (via AAC) to M4A are clean again (on iTunes and iPod) showing no more one of the trouble ahead. The ghost is eliminated. Everything synchronizes as it should be.
    And I for myself have to convert more than 3000 songs now... to ged rid of this nightmare.
    Now I'm very curious of You experiences. Can You confirm my suspicion? Or have You had similar problems with Your M4A-files too?
    - Best Regards ThomasK_DJ, south Germany

    Try this -> http://mp3val.sourceforge.net/ to verify and fix MP3 files.
    Also, it could be the version of the ID3 tags.
    Select a song in iTunes then go to iTunes menu Advanced -> Convert ID3 tags and select a different version and see what happens.

  • Memory problem with loading a csv file and displaying 2 xy graphs

    Hi there, i'm having some memory issues with this little program.
    What i'm trying to do is reading a .csv file of 215 mb (6 million lines more or less), extracting the x-y values as 1d array and displaying them in 2 xy graphs (vi attacked).
    I've noticed that this process eats from 1.6 to 2 gb of ram and the 2 x-y graphs, as soon as they are loaded (2 minutes more or less) are really realy slow to move with the scrollbar.
    My question is: Is there a way for use less memory resources and make the graphs move smoother ?
    Thanks in advance,
    Ierman Gert
    Attachments:
    read from file test.vi ‏106 KB

    Hi lerman,
    how many datapoints do you need to handle? How many do you display on the graphs?
    Some notes:
    - Each graph has its own data buffer. So all data wired to the graph will be buffered again in memory. When wiring a (big) 1d array to the graph a copy will be made in memory. And you mentioned 2 graphs...
    - load the array in parts: read a number of lines, parse them to arrays as before (maybe using "spreadsheet string to array"?), finally append the parts to build the big array (may lead to memory problems too).
    - avoid datacopies when handling big arrays. You can show buffer creation using menu->tools->advanced->show buffer allocation
    - use SGL instead of DBL when possible...
    Message Edited by GerdW on 05-12-2009 10:02 PM
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • Problem with diagonal lines printing jagged and unclean

    I am new to computer illustration and vector graphics. i am using Illustrator CS2. lines drawn using the pen tool that are slightly diagonal are printing "pixelated" or jagged. Especially bad when placed into an Indesign doc.
    They appear clean onscreen in Illustrator, but don't print perfectly clean. They both display and print badly when placed in Indesign.
    The graphic i am experiencing this with was drawn quite small for letterhead logo(about 50mm)with .15 pt stroke - doesn't seem like that should make any difference...?
    Thanks!
    K

    Hi Scott,
    "Which is it?"
    Not sure what you're asking
    My printer is an HP Color LaserJet3800 Post Script
    I did export to from AI to PDF and that printed a little better... still not perfect.
    When i opened the AI file in Acrobat there were several problems including letters of text (outlines) all different sizes.

  • Problem with CS3 InCopy text files and InDesign CS5

    I have a large annual magazine that I am developing. There is one section that doesn't change much from year to year and I was hoping to grandfather in the InCopy text files from last year's edition. I've successfully used this strategy the past few years without issue. However, now when I try to check out those text files from last year, I receive the following message "This story needs to be coverted to "InCopy Document" format in order to edit it."
    I am running both InDesign CS5 and InCopy CS5 in SL 10.6.4. The previous year's magazine document was in CS3 InDesign format and the text files were in InCopy CS3. Is there some sort of compatibility issue? Is there a specific method for converting them so I can check them out in InDesign? I haven't attempted to check them out in InCopy CS5 yet but I will try that next. But I really need the ability to check out the content via InDesign too.
    Thanks in advance.
    Robert

    AFAIK, you're going to actually need to open the INCX files in InCopy and then resave them as ICML file. You can then relink them all in InDesign.
    Other choice is killing the InCopy links and then relinking everything.
    Best practice would be to finish any job started in CS3 with CS3 and then move to CS5 with new projects.
    Bob

  • Having problems with launchd a plist file and launch on demand.

    First, my plist file:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
    <plist version="1.0">
    <dict>
    <key>Debug</key>
    <true/>
    <key>KeepAlive</key>
    <false/>
    <key>Label</key>
    <string>TestApp</string>
    <key>OnDemand</key>
    <true/>
    <key>Program</key>
    <string>/Applications/Test/TestApp</string>
    <key>ProgramArguments</key>
    <array>
    <string>daemon</string>
    </array>
    <key>Sockets</key>
    <dict>
    <key>SockFamily</key>
    <string>IPv4</string>
    <key>SockPassive</key>
    <true/>
    <key>SockServiceName</key>
    <string>8585</string>
    <key>SockType</key>
    <string>stream</string>
    </dict>
    <key>WorkingDirectory</key>
    <string>/Applications/Test/</string>
    </dict>
    </plist>
    The idea is, if another app which I have tries to connect to 127.0.0.1:8585 that my test app will launch and do its stuff. The test app is the server and the guy making the call is the client.
    The plist file is located in "/Library/LaunchDaemons" and is owned by root and only readable by anyone but root. Similarly TestApp is only readable/executable by root and no one else can do anything. Finally TestApp is a C++ program not an actual application ie:TestApp.app/Contents/etc...
    If it were windows, it would be TestApp.exe.
    Anyway, when I invoke my other program, TestApp isn't launched. (I rebooted after I put the plist file in so it would be read). I know TestApp and TestClient can talk, if I run them both myself everything is fine. I just want to get launchd to do it on demand. There isn't a clear way for me to debug this because if there is an error, I do not know where to look to see it, if any such errors are reported. Syslog doesn't show anything of interest in this reguard.
    Any help is greatly appricated.

    Hello Mark:
    You are seeing a "normal" behavior, if this is the case on the load of a first report. Subsequent reports should be significantly faster. Only way to make the first load appear faster is to load the CR assemblies and dlls on app start. E.g.; load a fake report on app start. Unfortunately, those 20+ seconds will now move to the initialization / load of the app...
    Ludek
    BTW., downloading the latest Service packs is never a bad idea and may help a bit, but not 10+ seconds for sure.

  • Compiling Problem With Command Line

    I am facing problem to compile the following class:
    the error code is Like the following :
    Sorry, I was trying to understand the members of a class declaration
    but I got confused when I saw 'var' which is a keyword.var city: String;
    {color:#ff0000}class Address {
    var city: String;
    }{color}
    But when i compile the following class there was no error.
    {color:#339966}class Address {
    attribute city: String;
    }{color}
    Ok I consider that it takes attribute key word.
    But in NetBeans 6.5 The following code is OK
    {color:#339966}class Address {
    var city: String;
    }{color}
    Could Any One tell me where is the problem.
    With Best Regards
    A S M Russel.
    Edited by: Russel8930 on Dec 9, 2008 2:25 PM
    Edited by: Russel8930 on Dec 9, 2008 2:28 PM

    You have two different versions of the compiler on your machine. The right syntax is the one with the var-keyword.

Maybe you are looking for

  • Font in Adobe Reader 11

    Hi! On the PC from my customer is installed Version 11.0.0.5.3 of adobe reader. I have the problem that the font in some documents only cryptic symbols. I have this screenshot: I have this problem on any computer with Adobe Reader XI. Befor we update

  • Outlook 2010 won't update new messages unless you update folder

    Hi, Outlook 2010 sp1 with Exchange 2010 latest sp. Scenario: Some users are not receiving emails unless they click on update Folder. Once they do emails come in. Troubleshooting: No virus scanning outlook folder. Delete the profile with OST and re-cr

  • Do I have to sync my dishnetwork dvr inorder to watch my network via slingbox?

    Do I have to sync my dishnetwork dvr inorder to beable to watch my dishnetwork tv via slingbox plugged in to dvr with a slingbox andriod app on my mobile device on my andriod mobile phone ?

  • Any idea how to get past a forgotten password??

    My dad recently bought an Iphone 4s second hand and it wasn't restored back to factory settings so therefore, not synced to his Itunes. He set a password on it and somehow forgot the password. Can anyone help as I have no idea how to get into the pho

  • Eprint total waste of time

    Come on HP either fix it or tell us it is just junk!