l3ioHazardX Posted October 1, 2006 Share Posted October 1, 2006 I'm having problems with creating shortcuts(they don't wan't to create at all), I'm using a .cmd file that runs from RunOnceEx as the 2nd to last command and it is just not creating the shortcuts. The cmd file works fine when just double clicked.Here is the .cmd file:cmdow @ /HID:Installing mIRC Shortcuts for All Usersshortcut /f:"%ALLUSERSPROFILE%\Desktop\mIRC.lnk" /a:c /t:"%ProgramFiles%\mIRC\mirc.exe"shortcut /f:"%ALLUSERSPROFILE%\Start Menu\Programs\mIRC\mIRC.lnk" /a:c /t"%ProgramFiles%\mIRC\mirc.exe"shortcut /f:"%ALLUSERSPROFILE%\Start Menu\Programs\mIRC\IRC Intro.lnk" /a:c /t"%ProgramFiles%\mIRC\ircintro.hlp"shortcut /f:"%ALLUSERSPROFILE%\Start Menu\Programs\mIRC\mIRC Help.lnk" /a:c /t"%ProgramFiles%\mIRC\mirc.hlp"shortcut /f:"%ALLUSERSPROFILE%\Start Menu\Programs\mIRC\ReadMe.lnk" /a:c /t"%ProgramFiles%\mIRC\readme.txt"shortcut /f:"%ALLUSERSPROFILE%\Start Menu\Programs\mIRC\Versions.lnk" /a:c /t"%ProgramFiles%\mIRC\versions.txt"Here is my RunOnceEX:cmdow @ /HID@echo offSET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceExREG ADD %KEY% /V TITLE /D "Installing Applications" /fREG ADD %KEY%\001 /VE /D "Microsoft Office 2003" /fREG ADD %KEY%\001 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\Office2003\setup.exe TRANSFORMS="Unattended.MST" /qb-" /fREG ADD %KEY%\002 /VE /D "Mozilla Firefox" /fREG ADD %KEY%\002 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Browsers\firefox_1.506.exe -ms -ira" /fREG ADD %KEY%\003 /VE /D "Mozilla Thunderbird" /fREG ADD %KEY%\003 /V 1 /D "%SYSTEMDRIVE%\Install\Software\E-mail\thunderbird_1.07.exe -ms -ira" /fREG ADD %KEY%\004 /VE /D "WinRAR" /fREG ADD %KEY%\004 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\WinRAR\wrar330.exe /s" /fREG ADD %KEY%\006 /VE /D "Visual Basic 6 Runtimes" /fREG ADD %KEY%\006 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\VB\vbrun6.msi /Q" /fREG ADD %KEY%\007 /VE /D "Daemon Tools" /fRED ADD %KEY%\007 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\Daemon\Daemon.exe /qn /Reboot-Suppress" /fREG ADD %KEY%\008 /VE /D "Shockwave" /fREG ADD %KEY%\008 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Plugins\swInstaller.exe" /fREG ADD %KEY%\011 /VE /D "WinISO 5.3" /fREG ADD %KEY%\011 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\WinISO\WINISO53.EXE /VERYSILENT /SP-" /fREG ADD %KEY%\012 /VE /D "SpyBot S&D" /fREG ADD %KEY%\012 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\Spybot\spybotsd14.exe /verysilent" /fREG ADD %KEY%\013 /VE /D "VLC Video Lan" /fREG ADD %KEY%\013 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\VideoLan\vlc-0.8.5-win32.exe /S" /fREG ADD %KEY%\014 /VE /D "WinDVD 7" /fREG ADD %KEY%\014 /V 1 /D "%SYSTEMDRIVE%\Install\Software\Applications\WinDVD7\Setup.exe /s /sms /f2"C:\WinDVD.log"" /fREG ADD %KEY%\050 /VE /D "Importing Registry Tweaks" /fREG ADD %KEY%\050 /V 1 /D "REGEDIT /S %SYSTEMDRIVE%\Install\Software\AgentTweaks.reg" /fREG ADD %KEY%\051 /VE /D "Importing Program Keys" /fREG ADD %KEY%\051 /V 1 /D "REGEDIT /s %SYSTEMDRIVE%\Install\Software\WinDVD.reg" /fREG ADD %KEY%\051 /V 2 /D "REGEDIT /s %SYSTEMDRIVE%\Install\Software\mIRC.reg" /fREG ADD %KEY%\052 /VE /D "Creating Shortcuts" /fREG ADD %KEY%\052 /V 1 /D "%systemdrive%\install\shortcuts.cmd" /fREG ADD %KEY%\055 /VE /D "Cleaning Up" /fREG ADD %KEY%\055 /V 1 /D "%systemdrive%\install\cleanup.cmd" /fREG ADD %KEY%\056 /VE /D "Rebooting" /fREG ADD %KEY%\056 /V 1 /D "%systemdrive%\reboot.cmd" /fEXIT Link to comment Share on other sites More sharing options...
urie Posted October 1, 2006 Share Posted October 1, 2006 This is what i have for one of my apps i know its %USERPROFILE% rather than %ALLUSERSPROFILE%"cmd /C Shortcut.exe /f:\"%USERPROFILE%\Desktop\Homecall Broadband.lnk\" /a:c /t:\"%ProgramFiles%\thomson\SpeedTouch USB\stdialup.exe\" /W:\"%ProgramFiles%\thomson\SpeedTouch USB\"" /f Link to comment Share on other sites More sharing options...
mazin Posted October 1, 2006 Share Posted October 1, 2006 I've, recently, decided to use $OEM$ folders for this purpose.In your situation, I'd suggest creating these directories in your UACD:$OEM$\$Docs\All Users\Start Menu\Programs\mIRC$OEM$\$Docs\All Users\DesktopYou put whatever shortcuts there.Actually, you copy shortcuts from your current system to those dirs of $OEM$.One thing to take care of is to right-click each shortcut for Properties.Then, you change C: to %SystemDrive% in the following fields:Target: "%SystemDrive%\Program Files\mIRC\mirc.exe"Start in: "%SystemDrive%\Program Files\mIRC"This guarantees a shortcut functionality whatever your %SystemDrive% is.You can, also, fill in the "Comment:" field if it's empty.HTH Link to comment Share on other sites More sharing options...
Ctrl-X Posted October 2, 2006 Share Posted October 2, 2006 I'm having problems with creating shortcuts(they don't wan't to create at all), I'm using a .cmd file that runs from RunOnceEx as the 2nd to last command and it is just not creating the shortcuts. The cmd file works fine when just double clicked.Are you sure that Shortcut.exe is in the search path? Try specifying the complete path to the executable in your .CMD file. Link to comment Share on other sites More sharing options...
l3ioHazardX Posted October 2, 2006 Author Share Posted October 2, 2006 Thanks mazin, that worked great. Not sure why I could never get shortcut.exe working since it works with other shortcuts. l3ioHazardX Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now