Running macro at startup

Discussion in 'SolidWorks' started by JeremyL, May 1, 2007.

  1. JeremyL

    JeremyL Guest

    I've looked through the following posts for help but I haven't gotten
    anything to work.
    http://groups.google.com/group/comp...2da1b73e8d1/81c43f8857b597e8#81c43f8857b597e8
    http://groups.google.com/group/comp...d773a7a8c6b/bf0d4caaa53e72e0#bf0d4caaa53e72e0
    Thanks still to those who contributed.

    I'm running SW 2006 & 2007. 2007 is installed at C:\Program Files
    \SolidWorks 2007\SLDWORKS.exe.
    I've tried changing the "Start in:" textbox on the desktop shortcut
    properties to be:
    "C:\Program Files\SolidWorks 2007\SLDWORKS.exe" /m N:\CAD\SOLIDWORKS
    2007\MACRO\Workshop\AutoLoad.swp"
    The "Target:" field is not enabled.

    The macro is simply:
    Sub main()
    MsgBox "You Started Solidworks"
    End Sub

    What am I doing, or not doing, that is not allowing this startup macro
    to run when I start SolidWorks?
    Thanks!
    Jeremy
     
    JeremyL, May 1, 2007
    #1
  2. JeremyL

    Dale Dunn Guest

    You need to figure out why the target field is disabled. Perhaps try
    creating a new shortcut to work with. The start in field should have no
    bearing on launching a macro.

    Here's what I've been using for my 05 shortcut (the quotation marks are
    critical):

    "C:\Program Files\SolidWorks 05\SLDWORKS.exe" /M "C:\0Home\FUE\doc type
    watcher\applauncher.swp"

    I've been using that basic format from 03 through 07.
     
    Dale Dunn, May 1, 2007
    #2
  3. JeremyL

    JeremyL Guest

    That worked, manually creating a shortcut. The shortcuts I've been
    trying this on were ones automatically created with the SolidWorks
    installation. Maybe the fact that we have dual versions installed
    (2006 & 2007) threw something off. The new shortcut did allow me to
    customize the "Target:" field.

    With service pack installations (we're on SP2.2), shortcuts are
    usually automatically updated as well. I'll have to keep an eye on
    what takes place during the next service pack installation.

    Thanks Dale!
     
    JeremyL, May 1, 2007
    #3
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.