Create a desktop shortcut in all users profile to point to www.appdeploy.com. [/align]if machine already has the www.appdeploy.com shortcut on desktop. exit saying shortcut is already there.[/align]
[/align]


If anyone help on this , thanks in advance.
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
Please can anyone help on this.
Answered 07/22/2009 by: sourav
Orange Senior Belt

Please log in to comment
0
How are you deploying this and why are you using Wscript?

Why don't you just use the login script and a pre-created lnk file on some server share?

I don't know Wscript.. I only use vbs as it's vendor-neutral. I'm sure someone will help if you're set on it but don't expect an answer in 30 mins!
Answered 07/22/2009 by: turbokitty
Sixth Degree Black Belt

Please log in to comment
0
I would simply just create the .url itself on the desktop.

A .url is simply an .ini file.

Simply create a file called %filename%.url with the following ini lines

[InternetShortcut]
URL=http://www.appdeploy.com

Alternatively, if you're using Windows Installer Editor (within Wise) you can just add this to the ini file table
Answered 07/22/2009 by: michaelnowell
Second Degree Blue Belt

Please log in to comment
0
If you want to check if the url already exists using wise script editor, u may use the "check if file\dir exists" option and exit the installation.
here is a vb script which will create the desktop url:

On Error Resume Next
Set objShell = WScript.CreateObject("WScript.Shell")
strDesktopFolder = objShell.SpecialFolders("AllUsersDesktop")
Set objShortCut = objShell.CreateShortcut(strDesktopFolder & _
"\Appdeploy.lnk")
objShortCut.TargetPath = chr(34) & "http://www.appdeploy.com" & chr(34)
ObjShortCut.IconLocation = ", 0"
objShortCut.WorkingDirectory = "http://www.appdeploy.com"
objShortCut.Save

hope this works!
Answered 07/23/2009 by: shalinispillai
Senior Yellow Belt

Please log in to comment
0
Hi,

In addition to Shalinispillai... you can use the "Create Shortcut" action in wisescript so that you don´t need the vbscript.
Answered 07/23/2009 by: dj_xest
Fifth Degree Black Belt

Please log in to comment
0
If you want a wise script, I can help you out in some way. Please check if this helps in solving your issue.

1. Use "Set variable" option and give variable as URLVERSION
2. Use "Set variable" option and give variable as SHORTCUTPATH and value "C:\Documents and Settings\All Users\Desktop"
3. Use "If File Exists" and give pathname is "%SHORTCUTPATH%\xxx.url" and give some text in title and some message in message text.
4. Use "Else" option
5. Use "Create shortcut" option. (not sure whether this option works for you because you have to give the source path) or Use "Install file" option to copy the shortcut from this compiled exe to distination.

Hope this helps your issue or requirement.

Regards
Ramesh
Answered 07/23/2009 by: ramesh111k
Purple Belt

Please log in to comment
0
How hard can it be? 'Search for File', 'If' (test variable content), 'Create Shortcut'.

To be perfectly frank - and please take this in the spirit in which it's intended - if you can't work out how to do this from the options in front of you in the Wise editor and the dialogs that result from their selection, then you should really be looking for an alternative career.

BTW, in spite of the practices of vendors who should know better, the Desktop is no place for such shortcuts. Use the Start menu.
Answered 07/24/2009 by: VBScab
Red Belt

Please log in to comment
0
shalinispillai : Thanks for your reply..yes it's working.. but i need to do it only in WiseScript.

Ramesh111k : yes ramesh your comment make sence,

but i tried creating shortcut by shortcut page in WiseScript Editor(ver 9. ) as follows :

create shortcut page:

Source Path : www.appdeploy.com
Destination Path : %ALLUSERSPROFILE%\DESKTOP\appdeploy.url
command Options : null
Default Directory : %allusersprofiles%
Description : null
Icon pathname : path\xx\

by this am not able to create shortcut.
Am i doing right?
Members please correct me.
Thanks,
Answered 07/24/2009 by: sourav
Orange Senior Belt

Please log in to comment
0
Am i doing right?A cursory read of the WiseScript help file will tell you that, in order to use an environment variable in script, you need to create a WiseScript variable, populate that from the environment variable and then use the WiseScript variable in your script.
Answered 07/27/2009 by: VBScab
Red Belt

Please log in to comment
0
Hi,

As mentioned above, u need to declare the environment variable. Follow the steps below:

1. Select "Get Environment Variable" option in WSE, and enter "ALLUSERSPROFILE" and store it in any variable name . eg:"ALLUSERSPROFILE"

2. Select "Create Shortcut" option and give the following options:

Source Path : http://www.appdeploy.com
Destination Path : %ALLUSERSPROFILE%\Desktop\appdeploy.lnk
command Options : null
Default Directory : %ALLUSERSPROFILE%
Description : Appdeploy
Answered 07/27/2009 by: shalinispillai
Senior Yellow Belt

Please log in to comment
0
shalinispillai : Thanks

i did as you mentioned , but it is not creating shortcut on desktop.



Thanks for your further help.

Thanks
Answered 07/27/2009 by: sourav
Orange Senior Belt

Please log in to comment
0
Hi Sourav,

It should ideally create shortcut on desktop if u have followed the steps. Kindly ensure that you have used the variable declared in "get env var", in the create shortcut tabs also.
Answered 07/27/2009 by: shalinispillai
Senior Yellow Belt

Please log in to comment
0
I don't use Wise unless I'm forced to, but there must be a canned Wise variable for the user's desktop??
Answered 07/27/2009 by: turbokitty
Sixth Degree Black Belt

Please log in to comment
0
Yes shalinispillai, i did same..

item: Get Environment Variable
Variable=ALLUSERSPROFILE
Environment=ALLUSERSPROFILE
end
item: Create Shortcut
Source=http:\\www.appdeploy.com
Destination=%ALLUSERSPROFILE%\Desktop\appdeploy.url
Working Directory=%ALLUSERSPROFILE%
Description=appdeploy
Key Type=1536
Flags=00000001
end

but it is not creating shortcut.
Answered 07/27/2009 by: sourav
Orange Senior Belt

Please log in to comment
0
Use .lnk instead of .url. It will work.
Answered 07/27/2009 by: shalinispillai
Senior Yellow Belt

Please log in to comment
0
Not sure why you'd use WiseScript for something this simple. Here's a VBScript that does exactly what you want.

If the file doesn't exist, it makes it. Take out the IF and END if you want it to overwrite.

Set sho = Wscript.CreateObject("Wscript.Shell")
Set fso = wscript.CreateObject("Scripting.FileSystemObject")
strAllUsersProfile = sho.expandenvironmentstrings("%AllUsersProfile%")
If NOT fso.fileexists (strAllUsersProfile & "\Desktop\Appdeploy.URL") then
Set oLink = fso.CreateTextFile(strAllUsersProfile & "\Desktop\Appdeploy.URL", True)
oLink.WriteLine("[InternetShortcut]")
oLink.WriteLine("URL=http://www.appdeploy.com")
oLink.Close
End If
Answered 07/27/2009 by: elgwhoppo
Senior Purple Belt

Please log in to comment
0
.lnk

shalini i tried .lnk but no luck. :-(


elgwhoppo thanks.
Answered 07/27/2009 by: sourav
Orange Senior Belt

Please log in to comment
0
No problem, glad it helped.

I usually prefer VB script to Wise because it's native to the OS, a easier to incorporate WMI queries and opens with notepad.

Plus you can't decompile a wisescript. It can be really annoying to come across a wisescript with no corresponding .WSE file. I started out with Wise and mvoed up to VB.
Answered 07/27/2009 by: elgwhoppo
Senior Purple Belt

Please log in to comment
-1
I know nothing much abt VB and trying to learn so please consider me as trainee and help with the below problems :)

I do know how to open a URL using a VB script but the problem is cant enter the username, password and login automatically can you help with me that. Below is the pasted example script let me know if its my bad

set IE=CreateObject("InternetExplorer.application")
IE.Visible=TRUE
IcUrl="http:\\www.gmail.com"
SetUsr = InputBox("Please Enter Your Username")
SetPas = InputBox("Please Enter Your Password")


IE.Navigate(IcUrl)
'IE.quit
'Set IE=Nothing
Answered 07/29/2009 by: XpressMusic
Yellow Belt

Please log in to comment
0
- Please don't hijack threads. As this is a scripting question, please start a new thread in the 'Scripting' forum. http://www.appdeploy.com/messageboards/tt.asp?forumid=6&p=&tmode=1&smode=1

- Please use the CODE tags when posting code (or lengthy text). You can access the tag by clicking the button marked '<%' in the 'Post New Thread' or 'Reply to Message' windows.
Answered 07/29/2009 by: VBScab
Red Belt

Please log in to comment
0
I do know how to open a URL using a VB script but the problem is cant enter the username, password and login automatically can you help with me that.

I can help you with that: use Firefox.
Answered 07/29/2009 by: MSIPackager
Third Degree Black Belt

Please log in to comment
Answer this question or Comment on this question for clarity