Application.Events and My.Settings

This forum can be browsed by the general public. Posting is limited to current SAPIEN license holders with active maintenance and does not offer a response time guarantee.
Forum rules
DO NOT POST LICENSE NUMBERS, ACTIVATION KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.

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 8 years and 3 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.
User avatar
ginolard
Posts: 34
Last visit: Tue Jun 21, 2022 12:06 am

Application.Events and My.Settings

Post by ginolard »

Product, version and build: 2015 4.2.95.0
32 or 64 bit version of product: 64
Operating system: Windows 2008 R2
32 or 64 bit OS: 64

Hello again,

I was just wondering if Powershell Studio supports the My.Settings and Application.Events functionality that you have in Winforms via Visual Studio?

The Application Events are things like Startup, Shutdown so that you can do things before the main form is even loaded (e.g. display a splash screen, check for updates etc)

My.Settings allows for application to support persistent settings that can be loaded each time the application starts (e.g. alternate credentials, paths to files etc).

I couldn't find any implementation of these so I'm guessing not but the My.Settings functionality would be particularly useful!
User avatar
davidc
Posts: 5913
Last visit: Mon Jul 08, 2019 8:55 am
Been upvoted: 2 times

Re: Application.Events and My.Settings

Post by davidc »

My.Setting is part of Visual Basic .NET language. Although C# has methods for this, scripts aren't applications. If you can alter the settings via a script, you may end up tampering with the host's settings.

As for Application.Events that is part of the WPF not WinForms, but you should be able to access it via your script as long as the correct assemblies are loaded.

David
David
SAPIEN Technologies, Inc.
This topic is 8 years and 3 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.