Hello,
Product, version and build: SAPIEN PowerShell Studio 2024 v5.8.251 (latest)
Operating system: Windows 10 22H2 Enterprise
PowerShell version(s): 7.4.6 (also 5.1 built-in to OS but not used)
Hello,
This issue is extremely simple to reproduce for me and hopefully for you too.
ERROR: Error executing script
(OK button)
Steps to reproduce:
1. installed PowerShell-7.4.6-win-x64.msi on my device (win10 22H2 enterprise, can't run win11 yet)
2. in PowerShell Studio:
a. File > New > Form > Empty Form
b. Save the file to a folder
c. Toolbox > add a Label to the form
d. select the label > Properties > Font > change Bold to true (simplest way to trigger the error but in reality i also want to change the size)
e. Deploy > Settings > Script Engine >
- Target Platform is Microsoft Windows 64 Bit
- Script Engine: Use STA Mode (checked)
- PowerShell 7.4.x: PowerShell 7.4.6 Host (Windows Forms)
f. Deploy > Build
g. on the same device, run the EXE (built above)
h. it gives me the error "Error executing script"
I can make the form display correctly by selecting the label > Properties > Font > Reset.
Resetting the font to the default allows the EXE form to load and display correctly but changing the font triggers the error and the form does not display. Click OK on the error dialog and the form EXE terminates.
I tried setting the font via code instead of setting it on the label's properties and it generates the same error.
Interestingly, if i Run the form inside PowerShell Studio (not compiled), it displays correctly. The error is only triggered when running the compiled/build EXE. PowerShell Studio's Platform is set to "V7 - 64 Bit".
Also, this same form with the bold font on the label works correctly when using SAPIEN PowerShell V5 Host (Windows Forms).
Any ideas how to solve this?
Thank you
Product, version and build: SAPIEN PowerShell Studio 2024 v5.8.251 (latest)
Operating system: Windows 10 22H2 Enterprise
PowerShell version(s): 7.4.6 (also 5.1 built-in to OS but not used)
Hello,
This issue is extremely simple to reproduce for me and hopefully for you too.
ERROR: Error executing script
(OK button)
Steps to reproduce:
1. installed PowerShell-7.4.6-win-x64.msi on my device (win10 22H2 enterprise, can't run win11 yet)
2. in PowerShell Studio:
a. File > New > Form > Empty Form
b. Save the file to a folder
c. Toolbox > add a Label to the form
d. select the label > Properties > Font > change Bold to true (simplest way to trigger the error but in reality i also want to change the size)
e. Deploy > Settings > Script Engine >
- Target Platform is Microsoft Windows 64 Bit
- Script Engine: Use STA Mode (checked)
- PowerShell 7.4.x: PowerShell 7.4.6 Host (Windows Forms)
f. Deploy > Build
g. on the same device, run the EXE (built above)
h. it gives me the error "Error executing script"
I can make the form display correctly by selecting the label > Properties > Font > Reset.
Resetting the font to the default allows the EXE form to load and display correctly but changing the font triggers the error and the form does not display. Click OK on the error dialog and the form EXE terminates.
I tried setting the font via code instead of setting it on the label's properties and it generates the same error.
Interestingly, if i Run the form inside PowerShell Studio (not compiled), it displays correctly. The error is only triggered when running the compiled/build EXE. PowerShell Studio's Platform is set to "V7 - 64 Bit".
Also, this same form with the bold font on the label works correctly when using SAPIEN PowerShell V5 Host (Windows Forms).
Any ideas how to solve this?
Thank you
Statistics: Posted by fernsantos — Thu Dec 05, 2024 10:13 am