Code only for Dotnet 2.0

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 7 years and 11 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
GHIsolierung
Posts: 62
Last visit: Tue Nov 02, 2021 12:46 am

Code only for Dotnet 2.0

Post by GHIsolierung »

Product, version and build: 5.2.119
32 or 64 bit version of product: 64
Operating system: Windows 10
32 or 64 bit OS: 64
PowerShell Version: 5

Hello,

short question.

Im working with Windows 10 and Powershell Studion 2016 and Ihe Code is automatically working with .NetFramework 4

If I want to Code for DotnetFramework Version 2, how would I do this?


thanks in advance.
User avatar
davidc
Posts: 5913
Last visit: Mon Jul 08, 2019 8:55 am
Been upvoted: 2 times

Re: Code only for Dotnet 2.0

Post by davidc »

To help me better understand the request, what are you trying to accomplish? Are you asking in regards to GUI scripts or general PowerShell scripts?

David
David
SAPIEN Technologies, Inc.
User avatar
GHIsolierung
Posts: 62
Last visit: Tue Nov 02, 2021 12:46 am

Re: Code only for Dotnet 2.0

Post by GHIsolierung »

Hello and thanks for reply,

in this case it is a special Power Shell Studio question.

I want to make GUI Applications for our Server, but theres another dotnet and powershell Version installed.

When I transform my powershell scripts to executables, theres always a popup failure coming up, that dotnet 4.xxx has to be installed.

I dont want this on our Server, i want to use dotnet 2.xx and the corresponding powershell Version.



Hope you understand what I´m trying to say
greets
User avatar
davidc
Posts: 5913
Last visit: Mon Jul 08, 2019 8:55 am
Been upvoted: 2 times

Re: Code only for Dotnet 2.0

Post by davidc »

The dot net version is determined by the packager engine / PowerShell version:

https://www.sapien.com/blog/2015/11/16/ ... equisites/

If you are using GUI scripts, make sure you have the PowerShell V2 (.NET 2.0) compatibility option checked (Options->Designer):
PowerShell V2 compatibility.png
PowerShell V2 compatibility.png (25.53 KiB) Viewed 2348 times
When dealing with multiple PowerShell versions, you will need to create a separate executable that corresponds to each PowerShell version.

David
David
SAPIEN Technologies, Inc.
User avatar
GHIsolierung
Posts: 62
Last visit: Tue Nov 02, 2021 12:46 am

Re: Code only for Dotnet 2.0

Post by GHIsolierung »

Hey David,

thanks a lot. That solved my Problem.
This topic is 7 years and 11 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.