I have having an odd issue with evaluation of Action Script with a file path that contains the { } characters. Normally with registry values you can just do the double {{ to escape but it doesnt seem to work the same way with file paths.
Basically I have multiple possible locations for the same file but they are all buried in a similar fashion. The script that I am working with is below. The statement in the if statement works in QnA but does not seem to work in actionscript. Running the second statement in QnA does work properly. In theory the code below should check the existance in the if/elseif statement and than run the statement afterwards to uninstall.
if (exists file “C:\ProgramData\Package Cache\{96a8b90c-0a91-4e76-ab34-730c23923d11}\vs_community.exe”)
waithidden “C:\ProgramData\Package Cache\{{96a8b90c-0a91-4e76-ab34-730c23923d11}\vs_community.exe” /uninstall /quiet
elseif (exists file “C:\ProgramData\Package Cache\{79b486b9-c5f0-4096-a00c-8351f59587c2}\vs_community.exe”)
waithidden “C:\ProgramData\Package Cache\{{79b486b9-c5f0-4096-a00c-8351f59587c2}\vs_community.exe” /uninstall /quiet
q: (exists file “C:\ProgramData\Package Cache\{96a8b90c-0a91-4e76-ab34-730c23923d11}\vs_community.exe”)
A: False
T: 0.202 ms
q: (exists file “C:\ProgramData\Package Cache\{79b486b9-c5f0-4096-a00c-8351f59587c2}\vs_community.exe”)
A: True
T: 0.209 ms
q: (exists file “C:\ProgramData\Package Cache\{{96a8b90c-0a91-4e76-ab34-730c23923d11}\vs_community.exe”)
A: False
T: 0.153 ms
q: (exists file “C:\ProgramData\Package Cache\{{79b486b9-c5f0-4096-a00c-8351f59587c2}\vs_community.exe”)
A: False
T: 0.178 ms