5 replies
by smacdonald Accepted solution
by faradhi Accepted solution
We use a program called colligo to network when my users are in the field. The problem with colligo is that it conflicts with our wireless configuration utility. It uses the builtin wireless configuration utility. I had to disable our utility and the associated services before launching colligo. Well, that just was not going to happen with our users.
My solution was to create a script that disables everything and then launches colligo for them. Then I replaced the shortcut that has the same icon as the original program with one that launches the script. The users were none the wiser.
To do this, here are the steps I suggest to follow.
- Copy the shortcut for Program A and Program B to a folder on the root of C: that the students have only read and execute rights.
- Create a VBScript with the contents below.
Option Explicit
Dim objWShell, strCmd1, strCmd2
strCmd1 = {enter path to program B's shortcut copied in the step above}
strCmd2 = {enter path to program A's shortcut copied in the step above}
Set objWShell = CreateObject("Wscript.Shell")
objWShell.Run strCmd1,1,0 'this launches program1
wscript.sleep 1000 'pauses execution to allow the program B time to run
objWShell.Run strCmd2,1,0 'this launches program2
- Create shortcut to the VBScript you created above. Change the Icon on the shortcut to the icon for Program B.
Your done. The reason I launch the Shortcut rather than the exe directly is that many programs require the run in option to be correct. I could find no way to pass that run in portion of the shortcut using VBScripts.
I hope this helps.
Bryan
edited to change desktop to root of C:
by smacdonald Accepted solution
by faradhi Accepted solution
instead of the program B.
The code would go something like this:
Dim objNet
Set objNet = CreateObject("WScript.Network")
objNet.MapNetworkDrive "H:", "\\" & servername & "\" & sharename, , _
DomainName\UserName, Password
This of course will require the password to be placed in the script as plain text. The risk can be minimized if you have a program like primal script that will create an EXE from a vbscript.
I hope it helps.
Bryan
by gopal saini Accepted solution
As I have seen that the prob. is that if You want to access the network drive. then before that You are logging to that particular computer again and again. Am i right?
if i am the u can make a batch file with command " net use z:(means drive letter) \\server name\drive letter /user:administrator passowrd"
u have to mention the user name and password after the string "/user:" and separate the user name and password with a single space and save this batch file and put it in start up folder. when ur system would be opened, it will automatically connect ur network drive and You will be able to access this drive directly.
And that would be visible. If you want to make it invisible then Put "@echo off" before the command.
This discussion is closed to new replies.
Trending Networks posts
Sort by Trending