To help you better we need some information from you.
*** Please fill in the fields below. If you leave fields empty or specify 'latest' rather than the actual version your answer will be delayed as we will be forced to ask you for this information. ***
Product, version and build: PowerShell Studio 5.4.145
32 or 64 bit version of product: 64 bit
Operating system: Win 10
32 or 64 bit OS: 64 bit
*** Please add details and screenshots as needed below. ***
DO NOT POST SUBSCRIPTIONS, KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM
hi support,
sorry for the long post, but I need to describe the process.
I have a template to install packages from SCCM. In this template, there are a few lines that need to be edited to add the stuff that need to run.
here's an example:
If the installation is a setup file that accepts parameters to run silently, usually I need to run "setup.exe /install /silent /norestart". Since we do this a lot, I created a function called runExeFile that I need to pass the EXE name and the params string. The line is;
runExeFile -exeFile "file_name_here" -params "params_here"
now, here's the annoying part: when I edit this line, whenever I change "file_name_here" for "$somevar....
as soon as I type the backslash in the string, PowerShell studio will replace double-quotes for single-quotes. I do not wish for that behavior, it is very annoying to have to go back and put the double-quotes back there. I looked into the options but saw no where to remove that darn feature.
thank you!
very annoying behavior (at least for me)
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.
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.
Re: very annoying behavior (at least for me)
I wasn't able to reproduce your bug, so that I can better replicate your circumstances, could you provide a screen shot of your PowerShell Studio settings?
- mxtrinidad
- Posts: 399
- Last visit: Tue May 16, 2023 6:52 am
Re: very annoying behavior (at least for me)
I neither was able to reproduce the behavior. The only thing you may want to try is, under "Options", to unchecked the "Auto-insert closing string quote".
So, while trying to find the behavior, create a little code snippet that may help using DOS cmd "netstat" as an example:
So, while trying to find the behavior, create a little code snippet that may help using DOS cmd "netstat" as an example:
Code: Select all
function runExecFile
{
param (
$execfile,
$params
)
## - Construct command string:
$runCmd = "$execfile $params";
Write-Host "Executing Command: $runCmd";
Invoke-Expression $runCmd
};
$execfile = "netstat.exe"
$params = "/a /b";
runExecFile -execfile $execfile -params $params
Re: very annoying behavior (at least for me)
the issue is when you edit a string with quotes already existing.
take this line: $string = ""
add to it c:\ and i bet that you'll see the quotes are changed.
take this line: $string = ""
add to it c:\ and i bet that you'll see the quotes are changed.
Re: very annoying behavior (at least for me)
mxtrinidad,
I copied / pasted your code in my PS Studio, and added c:\ to netstat.exe and the quotes changed.
I copied / pasted your code in my PS Studio, and added c:\ to netstat.exe and the quotes changed.
- mxtrinidad
- Posts: 399
- Last visit: Tue May 16, 2023 6:52 am
Re: very annoying behavior (at least for me)
We starting to spot the behavior. But, it would help if you can provide a screen shot before and after.
This way we can narrow down what's going on.
Thanks!
This way we can narrow down what's going on.
Thanks!
Re: very annoying behavior (at least for me)
as requested!
- Attachments
-
- quotes.png (21.47 KiB) Viewed 5016 times
- mxtrinidad
- Posts: 399
- Last visit: Tue May 16, 2023 6:52 am
Re: very annoying behavior (at least for me)
Hum! I still can't reproduce the behavior. Please send me the print screen of the Options setting of 3 areas:
1. Editor
2. Editor -> Formatting
3. And,Editor -> PrimalSense
Make sure to capture all options shown. I think we could trap the issue in the Options settings.
1. Editor
2. Editor -> Formatting
3. And,Editor -> PrimalSense
Make sure to capture all options shown. I think we could trap the issue in the Options settings.
Re: very annoying behavior (at least for me)
thanks mate!
- Attachments
-
- primalsense.png (27.74 KiB) Viewed 5002 times
-
- formatting.png (32.98 KiB) Viewed 5002 times
-
- editor.png (32.02 KiB) Viewed 5002 times
- mxtrinidad
- Posts: 399
- Last visit: Tue May 16, 2023 6:52 am
Re: very annoying behavior (at least for me)
Ok! So I still puzzle about this issue. But, from two different Windows 10 build seems to works fine.
Sorry to ask for more here! But can you send me the print screen showing only the version #. I need visual confirmation as I need to make sure I got the right version to support you.
Thanks again!
Sorry to ask for more here! But can you send me the print screen showing only the version #. I need visual confirmation as I need to make sure I got the right version to support you.
Thanks again!