[quote quote=143745]If I’ve got you right you’re looking for something like this:
<textarea class="ace_text-input" style="opacity: 0; height: 18px; width: 6.59781px; left: 83.9891px; top: 108px;" spellcheck="false" wrap="off"></textarea>
$prog = @(
WD = 'C:\windows\system32';
TargetPathPath = 'C:\cms\Support';
File = 'cmd.exe';
App = '/c `$`_.TargetPathPath + Desktopinfo.exe'
$pop = $_.TargetPathPath
Start-Process -WorkingDirectory $_.WD -FilePath $_.File -ArgumentList $_.App
You create a variabel $pop without using it. You might read about_Splatting
To format your code as code here in this forum you should use the code tag buttons “pre” right above the edit window when you create a post. Thanks … it’s even easier to see what’s wrong when you format your code nicely.
Yea, I was messing around with different variables and rearranging values when I created the pop variable. i just forgot to remove it when I posted. I was in a rush to get home when I posted earlier and didn’t review all of the code.
I still can’t get that app to open with the code you posted. I know the reason why it’s not working, but don’t know how to get TargetPath to be resolved correctly when put in as a value like that.