Hi, Thanks for replay,I got one solution to delete Folders WiX RemoveFolder was unable to delete folders as it was containing user data. So i was trying to delete that folder with cmd which was failing to delete folders
so i created property with VBScript and folders are deleted successfully This is code for property ____________________________________________________________________________________________ <Property Id="vbscript"> <![CDATA[ Function main() strFolderPath = Session.Property("VERSIONPATH") Set fso=CreateObject("Scripting.FileSystemObject") if fso.FolderExists(strFolderPath) Then fields = Split(strFolderPath,"\") For i = 0 To UBound(fields)-1 if i < UBound(fields)-1 then FolderPath=FolderPath & fields(i) & "\\" else FolderPath=FolderPath & fields(i) End if Next fso.DeleteFolder FolderPath else msgbox "Folder not deleted " End if End Function ]]> </Property> ____________________________________________________________________________________________ And called this *property in custom action* <CustomAction Id ="DeleteFolder" VBScriptCall="main" Property="vbscript"></CustomAction> ____________________________________________________________________________________________ *This was my earlier custom action by which i was trying to delete folders* <CustomAction Id="DeleteUBFolder" BinaryKey="cmdexe" ExeCommand='/c RD /S /Q "[VERSIONPATH]"' Execute="immediate" Return="check" /> this custom action is working fine with 32 bit Os but it is faling in 64 bit Os This is Error i am getting There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: DeleteFolder, location: C:\Windows\Installer\MSIE2A4.tmp, command: /c RD /S /Q "C:\Program Files\ultac" DeleteFolder. Return value 3. INSTALL. Return value 3. Error code 3 :- is for invalid path If i am doing any thing wrong in this custom action plese sugget me the correct way to do it ____________________________________________________________________________________________ Thank you. On Tue, Nov 2, 2010 at 11:08 PM, Wilson, Phil <phil.wil...@invensys.com>wrote: > You're getting an error, you say. What is the error? > > The folder you're trying to remove, exactly what is this folder. There's an > obvious explanation in a couple of areas. First, it's a 64-bit path in a > folder that's not the same as a 32-bit system. Or your 64-bit system is a > UAC system and your immediate custom just doesn't have the rights to remove > the folder. > > The right way to do this has been pointed out, WiX RemoveFolder. If that > didn't work, that was the time to ask questions about it. Why go off in the > wrong direction and then ask how to make that work? > > Phil Wilson > > -----Original Message----- > From: sagar shinde [mailto:sagar.i...@gmail.com] > Sent: Monday, November 01, 2010 11:49 PM > To: General discussion for Windows Installer XML toolset. > Subject: Re: [WiX-users] Custom Action > > Hi, > thanks for reply. > I tried to use remove folder in my wix code but it doesn't seems working, > and i am calling this custom action at the end of all task in uninstall > time, > so all the folders are empty and need to be deleted. > i tried to call custom action with cmd which is working properly in my > 32bit > code, > but i am getting error when me using same cmd in 64 bit code is there any > other way > to call that cmd in 64bit installer. > > Thank you. > > On Mon, Nov 1, 2010 at 8:39 PM, Rob Mensching <r...@robmensching.com> > wrote: > > > If cmd.exe returns anything but zero that will be treated as an error. > This > > is a really bad way to remove a directory, by the way. There is no > > rollback, > > for one. > > > > The RemoveFoldersEx in http://wixcontrib.codeplex.com would be better. > > > > > > On Thu, Oct 28, 2010 at 7:50 AM, sagar shinde <sagar.i...@gmail.com> > > wrote: > > > > > Thank you for reply, > > > But still its not working. > > > > > > i have same custome action in my another MSI which is made for 32bit > > > machine,and it works fine. > > > > > > is it issue of Solution configuration is Debug and Solution platform is > > x64 > > > > > > as MSI is made for 64bit machine > > > > > > > > > > > > On Thu, Oct 28, 2010 at 7:43 PM, Nick Ramirez <nickra...@hotmail.com> > > > wrote: > > > > > > > > > > > In the log, does it give a specific error code after the part where > it > > > says > > > > it's returning a status of 3? Oftentimes it will and you can use that > > to > > > > look up its meaning. > > > > > > > > I noticed that you're running this custom action as "immediate". If > > > you're > > > > deleting files, should it come during the deferred stage? That way it > > can > > > > be > > > > rolled back if there's a failure. > > > > > > > > If the folder is empty at the time you're trying to delete it, could > > you > > > > use > > > > the WiX element RemoveFolder? > > > > > > > > ----- > > > > Nick Ramirez > > > > > > > > Learn WiX with the book: > > > > > > > > > > > > > > https://www.packtpub.com/wix-a-developers-guide-to-windows-installer-xml/book > > > > WiX: A Developer's Guide to Windows Installer XML > > > > -- > > > > View this message in context: > > > > > > > > > > http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/Custom-Action-tp5677972p5682719.html > > > > Sent from the wix-users mailing list archive at Nabble.com. > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------------ > > > > Nokia and AT&T present the 2010 Calling All Innovators-North America > > > > contest > > > > Create new apps & games for the Nokia N8 for consumers in U.S. and > > > Canada > > > > $10 million total in prizes - $4M cash, 500 devices, nearly $6M in > > > > marketing > > > > Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi > > Store > > > > http://p.sf.net/sfu/nokia-dev2dev > > > > _______________________________________________ > > > > WiX-users mailing list > > > > WiX-users@lists.sourceforge.net > > > > https://lists.sourceforge.net/lists/listinfo/wix-users > > > > > > > > > > > > > ------------------------------------------------------------------------------ > > > Nokia and AT&T present the 2010 Calling All Innovators-North America > > > contest > > > Create new apps & games for the Nokia N8 for consumers in U.S. and > > Canada > > > $10 million total in prizes - $4M cash, 500 devices, nearly $6M in > > > marketing > > > Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi > Store > > > http://p.sf.net/sfu/nokia-dev2dev > > > _______________________________________________ > > > WiX-users mailing list > > > WiX-users@lists.sourceforge.net > > > https://lists.sourceforge.net/lists/listinfo/wix-users > > > > > > > > > > > > -- > > virtually, Rob Mensching - http://RobMensching.com LLC > > > > > ------------------------------------------------------------------------------ > > Nokia and AT&T present the 2010 Calling All Innovators-North America > > contest > > Create new apps & games for the Nokia N8 for consumers in U.S. and > Canada > > $10 million total in prizes - $4M cash, 500 devices, nearly $6M in > > marketing > > Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store > > http://p.sf.net/sfu/nokia-dev2dev > > _______________________________________________ > > WiX-users mailing list > > WiX-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wix-users > > > > ------------------------------------------------------------------------------ > Nokia and AT&T present the 2010 Calling All Innovators-North America > contest > Create new apps & games for the Nokia N8 for consumers in U.S. and Canada > $10 million total in prizes - $4M cash, 500 devices, nearly $6M in > marketing > Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store > http://p.sf.net/sfu/nokia-dev2dev > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > > > *** Confidentiality Notice: This e-mail, including any associated or > attached files, is intended solely for the individual or entity to which it > is addressed. This e-mail is confidential and may well also be legally > privileged. If you have received it in error, you are on notice of its > status. Please notify the sender immediately by reply e-mail and then delete > this message from your system. Please do not copy it or use it for any > purposes, or disclose its contents to any other person. This email comes > from a division of the Invensys Group, owned by Invensys plc, which is a > company registered in England and Wales with its registered office at 3rd > Floor, 40 Grosvenor Place, London, SW1X 7AW (Registered number 166023). For > a list of European legal entities within the Invensys Group, please go to > http://www.invensys.com/legal/default.asp?top_nav_id=77&nav_id=80&prev_id=77 > . > > You may contact Invensys plc on +44 (0)20 3155 1200 or e-mail > recept...@invensys.com. This e-mail and any attachments thereto may be > subject to the terms of any agreements between Invensys (and/or its > subsidiaries and affiliates) and the recipient (and/or its subsidiaries and > affiliates). > > > > > ------------------------------------------------------------------------------ > Nokia and AT&T present the 2010 Calling All Innovators-North America > contest > Create new apps & games for the Nokia N8 for consumers in U.S. and Canada > $10 million total in prizes - $4M cash, 500 devices, nearly $6M in > marketing > Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store > http://p.sf.net/sfu/nokia-dev2dev > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > ------------------------------------------------------------------------------ Achieve Improved Network Security with IP and DNS Reputation. Defend against bad network traffic, including botnets, malware, phishing sites, and compromised hosts - saving your company time, money, and embarrassment. Learn More! http://p.sf.net/sfu/hpdev2dev-nov _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users