I have the following Action XML in my package installer, and the attribute values are exactly the same values as I have in the database on my working version.
But when you install the package, the tree is not added into the database? What am I doing wrong?
To use a custom packageaction, you need to include the class using IPackageAction within your package... it can be compiled within the package assembly or a seperate assembly.. as long as it's available to umbraco.
PackageActions are run after the assemblies are copied to the bin.
I was under the impression if I used the <Action> tag in the package installer Umbraco would just pick it up??
I have been looking at the Robots.txt editor package on Google code (Link below) which adds a tree exactly as I need and that has no reference to IPackageAction? Yet it installs into the database?
Add New Tree Action Not Working?
I have the following Action XML in my package installer, and the attribute values are exactly the same values as I have in the database on my working version.
But when you install the package, the tree is not added into the database? What am I doing wrong?
Do you have a class in your package that uses the IPackageAction interface?
No, I didn't realise I needed to for this?
To use a custom packageaction, you need to include the class using IPackageAction within your package... it can be compiled within the package assembly or a seperate assembly.. as long as it's available to umbraco.
PackageActions are run after the assemblies are copied to the bin.
I was under the impression if I used the <Action> tag in the package installer Umbraco would just pick it up??
I have been looking at the Robots.txt editor package on Google code (Link below) which adds a tree exactly as I need and that has no reference to IPackageAction? Yet it installs into the database?
http://code.google.com/p/robotstxt-editor-for-umbraco/source/browse/#svn%2Ftrunk%2Fumbraco%2Frobots-txt
I have almost identical code to Lee's above, including the package XML?
I re-read your post... you are trying to add a new tree... change the alias to "addApplicationTree"
http://our.umbraco.org/wiki/reference/packaging/package-actions/add-application-tree
Thought it was custom becuause of the alias you posted.
Hmmm ok this officially doing my nut... Do you have an example of some code using IPackageAction?
Look at my previous post... I realized you don't need that... you're just adding a tree. Change alias to "addApplicationTree"
Damn... Can't beleive I missed that :) Cheers all working now!!
Awesome... :)... I've been there before..
is working on a reply...