Windows 10

Ask questions about creating Graphical User Interfaces (GUI) in PowerShell and using WinForms controls.
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
This topic is 6 years and 9 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked
User avatar
v35678
Posts: 23
Last visit: Fri Jan 05, 2024 8:25 am

Re: Windows 10

Post by v35678 »

jvierra wrote:YOU must run you script as an elevated administrator.
Hi, how can I accomplish that? Could you give me an example please?
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: Windows 10

Post by jvierra »

Right click on PowerShell Icon and select "Run as Administrator".
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: Windows 10

Post by jvierra »

v35678 wrote:
jvierra wrote:YOU must run you script as an elevated administrator.
Hi, how can I accomplish that? Could you give me an example please?
To run a script under PSS elevated just click the icon on the tool strip that looks like a shield. Hover over the icons to see the tooltip names.
User avatar
v35678
Posts: 23
Last visit: Fri Jan 05, 2024 8:25 am

Re: Windows 10

Post by v35678 »

Hi, I've actually tried that multiple times and it still doesn't work. Is there something Windows 10 I have to change? This is very frustrating. Like I said everything works great windows 7. Thanks for your help.
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: Windows 10

Post by jvierra »

Sorry but I cannot reproduce you issue. I recommend creating a very simple script with only that line of code. Run it at a PS/CLI prompt first. Be sure the exe works as expected then run it in a simple form on a button event.

You cannot use elevated alternate credentials to the local system. That does not work in Win 7 or any version of Windows. You can elevate the current user but not an alternate user.
User avatar
v35678
Posts: 23
Last visit: Fri Jan 05, 2024 8:25 am

Re: Windows 10

Post by v35678 »

If you turn of UAC it works fine.
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: Windows 10

Post by jvierra »

That is never a good idea. Why do you think we have UAC set the way it is by default.
User avatar
v35678
Posts: 23
Last visit: Fri Jan 05, 2024 8:25 am

Re: Windows 10

Post by v35678 »

Getting a cert and signing the script would work correct?
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: Windows 10

Post by jvierra »

v35678 wrote:Getting a cert and signing the script would work correct?
Work for what?
User avatar
v35678
Posts: 23
Last visit: Fri Jan 05, 2024 8:25 am

Re: Windows 10

Post by v35678 »

Just a quick update. I was able to get everything working on Windows 10 Enterprise using the default manifest. If I used any of the other manifests it wouldn't work. Not sure if that makes sense but the PowerShell apps are now working on multiple computers. Thanks for everyone's help.
This topic is 6 years and 9 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked