Oct 11, 2018 01:39 PM
(This post was last modified: Oct 11, 2018 01:55 PM by animalchub.)
I've been working on this off and on while I work. It converts PS to a vb form and used simply to launch programs on a users pc without the need to push.
The second script launches a form that will edit AD and allow you to edit members specific users at the user's desk.
Reasons I made this:
First make two js files with:
In the body.
So how to use and properly configure.
Using the file paths to the two js files. Change any line with (\\Path\to\my.js) to whichever path you want. Then do the same for the other js file (\\Path\to\myCITRIX.exe) to the other script that was converted to exe. *How to convert PS to exe listed at bottom of the page.
Enter in your credentials to:
* I don't advise using this method as you should never post your username and password in plain text.
Main Script
https://pastebin.com/w4NeEPDj
Change the Paths to the network js (\\Path\to\myCitrix.js) to whichever path you want.
Secondary Script
https://pastebin.com/gANDQVmL
*Convert to EXE
I would suggest converting the following Powershell code to an EXE using ps2exe
Use this for converting to EXE:
The second script launches a form that will edit AD and allow you to edit members specific users at the user's desk.
Reasons I made this:
- I created it because I'm a lazy admin.
- I like all my programs to be listed under one area and only want to run-as admin once.
First make two js files with:
Code
[
{"ProgramName":"Chrome", "FP":"\\\\andent.andersonsinc.com\\home\\Users$\\SG140984\\Work Notes\\Programs\\Google\\ChromeSetup.exe"},
{"ProgramName":"", "FP":"Placeholder"}
]So how to use and properly configure.
Using the file paths to the two js files. Change any line with (\\Path\to\my.js) to whichever path you want. Then do the same for the other js file (\\Path\to\myCITRIX.exe) to the other script that was converted to exe. *How to convert PS to exe listed at bottom of the page.
Enter in your credentials to:
* I don't advise using this method as you should never post your username and password in plain text.
Code
$username = "Plaintext Username"
$password = "Plaintext Password"https://pastebin.com/w4NeEPDj
Change the Paths to the network js (\\Path\to\myCitrix.js) to whichever path you want.
Secondary Script
https://pastebin.com/gANDQVmL
*Convert to EXE
I would suggest converting the following Powershell code to an EXE using ps2exe
Use this for converting to EXE:
Code
powershell.exe -command "&'\\Path\To\ps2exe.ps1' -inputfile '\\Path\To\MainScript.ps1' -outputfile '\\Path\To\MainScriptOutput.exe'" -noConsole - requireAdmin
