Removing a hidden file on msi uninstall
Hi Guys,
Part 2 of my mission of creating a mst from a vendor provided msi from hell.
Upon uninstall testing of the app I've noticed that a hidden file gets left behind, obviously this is due to the app generating the file after installation. Easy I say lets just add a remove file entry on unistall except that it didnt get removed after re-testing.
Would I be correct in thinking that if a file had the hidden attribute set it would not be removed as instructed? If so, how would I go about removing the hidden file using WPS 7 as part of the uninstall process?
Thanks again
Part 2 of my mission of creating a mst from a vendor provided msi from hell.
Upon uninstall testing of the app I've noticed that a hidden file gets left behind, obviously this is due to the app generating the file after installation. Easy I say lets just add a remove file entry on unistall except that it didnt get removed after re-testing.
Would I be correct in thinking that if a file had the hidden attribute set it would not be removed as instructed? If so, how would I go about removing the hidden file using WPS 7 as part of the uninstall process?
Thanks again
0 Comments
[ + ] Show comments
Answers (7)
Please log in to answer
Posted by:
anonymous_9363
15 years ago
Posted by:
suchi.jigar
15 years ago
This scenario, i have faced when, we launch help files. After launching help files, gid files get created, which are hidden and which does not get removed after uninstallation.
I used to create, REMOVEFILE entry for it. It gets removed, in your case if it is not getting removed, then
1) may be any application related process is running. so kill that process 1st.
2) may be your removefile entry is wrong, validate your msi/mst with orca, then you will get to know the problem, with related ice error.
if you want scripts you can take help from following scripts.
'this script will check the file exists, and then it will delete it.
Option Explicit
'On Error Resume NExt
Dim Objshell
Dim Objfso
Dim strprogramfiles
Dim strpath
Dim strpath1
Dim strpath2
Dim objfolder
Set objshell = Createobject("Wscript.shell")
Set Objfso = Createobject("scripting.filesystemobject")
strprogramfiles = objshell.expandenvironmentstrings("%Programfiles%")
'Wscript.echo strprogramfiles
strpath = strprogramfiles & "\Suchikant.txt"
'Wscript.echo strpath
If objfso.fileexists (strpath) Then
'wscript.echo ("test")
objfso.deletefile (strpath)
End If
I used to create, REMOVEFILE entry for it. It gets removed, in your case if it is not getting removed, then
1) may be any application related process is running. so kill that process 1st.
2) may be your removefile entry is wrong, validate your msi/mst with orca, then you will get to know the problem, with related ice error.
if you want scripts you can take help from following scripts.
'this script will check the file exists, and then it will delete it.
Option Explicit
'On Error Resume NExt
Dim Objshell
Dim Objfso
Dim strprogramfiles
Dim strpath
Dim strpath1
Dim strpath2
Dim objfolder
Set objshell = Createobject("Wscript.shell")
Set Objfso = Createobject("scripting.filesystemobject")
strprogramfiles = objshell.expandenvironmentstrings("%Programfiles%")
'Wscript.echo strprogramfiles
strpath = strprogramfiles & "\Suchikant.txt"
'Wscript.echo strpath
If objfso.fileexists (strpath) Then
'wscript.echo ("test")
objfso.deletefile (strpath)
End If
Posted by:
anonymous_9363
15 years ago
Posted by:
anonymous_9363
15 years ago
Posted by:
suchi.jigar
15 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.