Hmm I am only going on what the source code comment suggested Ismail. However keep me posted on this as I would be interested to hear how it turns out.
Can you check whether the uninstall action made it to the xml that gets created when installing the package. Generated xml should contain your action, otherwise it will never be fired. If it's not there... it's a bug, if it's there and didn't fire... well, it's a bug.
Remove the undo=true attribute. If the dll is still in memory during uninstall it will be executed.If the dll is already deleted than the action can't be found and the package action will fail to uninstall also.
Package action uninstall
Guys,
I am using http://our.umbraco.org/wiki/reference/packaging/package-actions/community-made-package-actions/execute-an-sql-statementscript which works fine it inserts 2 rows into cmsMacroPropertyType table. Do I also need to create an uninstall action for the package that removes the inserted rows on uninstall?
regards
Ismail
I don't know, but would like to know the answer myself.
Good question
Matt
It is good practise to do so. However I am not entirely sure that that particular package action supports the Undo/uninstall.
OK just took a quick look at the source code - http://packageactioncontrib.codeplex.com/SourceControl/changeset/view/47778#597529
It seems like you need to create a sperapte action that has the uninstall SQL statement in.
<Action runat="uninstall" undo="false" alias="ExecuteSql"></Action>
Warren
Warren,
Tried that however the uninstall script didnt run my action looks like
regards
Ismail
Hmm I am only going on what the source code comment suggested Ismail.
However keep me posted on this as I would be interested to hear how it turns out.
Warren
Ismail,
Can you check whether the uninstall action made it to the xml that gets created when installing the package. Generated xml should contain your action, otherwise it will never be fired. If it's not there... it's a bug, if it's there and didn't fire... well, it's a bug.
Did you find some errors in the umbracoLog table?
Cheers,
/Dirk
Hi all
i also have the same problem on package action Uninstall
here is my package action uninstall
<Action runat="uninstall" undo="false" alias="ExecuteSql"><![CDATA[
delete from umbracoUser2app where app = 'custom' ]]></Action>
is there any way to execute that sql script
Thanks
Asim
Hi Asim,
Remove the undo=true attribute. If the dll is still in memory during uninstall it will be executed.If the dll is already deleted than the action can't be found and the package action will fail to uninstall also.
Cheers,
Richard
Thanx Richard
but how i know that dll for user control is deleted first before execute Package action Uninstall.
actually when uninstall if first confirms the files to be delete, including dll from bin + user control files
cheers,
Asim
is working on a reply...