Indigo Rose Software

Professional Software Development Tools

 
+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2007
    Posts
    2

    ShortCut slash problem

    Hi
    I have a problem about shortcut.
    I wolud like to make a shourtcut target:
    "C:\CAD\MEP 2009\acad.exe" /ld "C:\CAD\MEP 2009\AecBase.dbx" /p "AutoCAD Architecture (US Metric)"

    But When I make a string, it is OK, but when Shortcut done, the target line will be:
    "C:\CAD\MEP 2009\acad.exe" \ld "C:\CAD\MEP 2009\AecBase.dbx" \p "AutoCAD Architecture (US Metric)"

    My question is:
    How can I make "\p" or other command switch, if I use Shell.CreateShortcut built in function?


    This is my code:

    -- Make a target comman line
    ShorCutString = "\""..DLLdir;
    ShorCutString = ShorCutString.."\\acad.exe\"";
    ShorCutString = ShorCutString.." /ld ";
    ShorCutString = ShorCutString.."\""..DLLdir.."\\AecBase.dbx\"";
    ShorCutString = ShorCutString.." /p ";
    ShorCutString = ShorCutString.."\"AutoCAD MEP (HUN)\"";

    Dialog.Message("This Is a String",ShorCutString); [COLOR="YellowGreen"]-- it is ready, and if i see the dialog, the "ShorCutString" message correct[/COLOR]-- Make a ShortCut with "ShorCutString" parameter, and the result will be incorrect
    Shell.CreateShortcut(_DesktopFolder, "AutoCAD MEP ", ShorCutString, "", "", DLLdir.."\\MEP2009.ico", 0, SW_MAXIMIZE, nil, "MEP 2009 magyar felülettel");

    Have any solution?

    Regards Keki

  2. #2
    Join Date
    Jun 2000
    Location
    Indigo Rose Software
    Posts
    1,943
    Hi keki,

    When creating a shortcut using Shell.CreateShortcut() the target parameter should only be the target file. All command line options should be passed using the CmdLine parameter.

    In your example you are attempting to pass command line options via the target parameter.

    Try something closer to this:

    Code:
    -- Make a target comman line
    ShorCutString = "\""..DLLdir;
    ShorCutString = ShorCutString.."\\acad.exe\"";
    strCommandLine = "/ld ";
    strCommandLine = strCommandLine.."\""..DLLdir.."\\AecBase.dbx\"";
    strCommandLine = strCommandLine.." /p ";
    strCommandLine = strCommandLine.."\"AutoCAD MEP (HUN)\"";
    
    Dialog.Message("This Is a String",ShorCutString);
    Shell.CreateShortcut(_DesktopFolder
    	, "AutoCAD MEP "
    	, ShorCutString
    	, strCommandLine
    	, ""
    	, DLLdir.."\\MEP2009.ico"
    	, 0
    	, SW_MAXIMIZE
    	, nil
    	, "MEP 2009 magyar felülettel");
    MSI Factory The Next Generation Intelligent Setup Builder

Similar Threads

  1. Shortcut Problem
    By Antagony in forum Setup Factory 7.0
    Replies: 2
    Last Post: 11-26-2007, 05:16 AM
  2. Problem with Uninstall Shortcut
    By SteveinVegas in forum Setup Factory 7.0
    Replies: 2
    Last Post: 12-02-2006, 08:49 AM
  3. Little but annoying shortcut problem.
    By jalari in forum Setup Factory 6.0
    Replies: 2
    Last Post: 02-18-2003, 01:25 AM
  4. HOWTO: Uninstall a Shortcut Created with Actions
    By Support in forum Setup Factory 6.0 Knowledge Base
    Replies: 0
    Last Post: 09-25-2002, 09:50 AM
  5. HOWTO: Create a Shortcut on the Desktop
    By Support in forum Setup Factory 6.0 Knowledge Base
    Replies: 0
    Last Post: 09-19-2002, 02:56 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts