Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Custom Command
Jan999
Hi,
I'm having some problems creating a custom menu option in FileSite.
I've followed the instructions in the "Creating Custom Commands in Worksite" document but I cannot get the new menu item to appear, although I can rename the existing commands ok so I know I'm amending the correct registry setting.
Please help!
Thanks
Jan
Find more posts tagged with
Comments
Rooose
The class has to exist and its dll registered in order for the command to be visible in the menus
Russ
jny
Would you let me know where you intend to add this custom command in FileSite? Perhaps a screencapture of where you would like to see it added?
Jan999
Yes I've created the class and registered it. I can see it in the registry, but it won't appear on the menu. I'm trying to add it to the document menu on FileSite.
If I complie the project in VS 2003 on the same machine that is running FileSite then it works.
What do I need to do to get the dll and the interop assemblies registered correctly on a remote PC?
jny
Does the remote PC have the correct .NET Platform? If you have deployed and packaged successfully, it should get loaded properly as well.
Jan999
Yes it does.
Here's what I'm doing.
1. Copy custom dll to client PC in the program files/interwoven/worksite directory
2. Use Regasm to create the tlb file for the dll and then register it
3. Edit the registry to add the command to the relevent bit of the FileSite menu (e.g. dllname.classname)
4. Restart Outlook
But nothing appears in the menu.
The code works on my development PC but I can't seem to get it to work when I deploy it.
jny
I'd like to back up to where you have added the progid (to your custom command) in the FileSite registry key. If you would like to see your custom command in the FileSite Document Menu, there are two ways to add it so that the document menu will inlcude your custom command:
1)
[HKEY_LOCAL_MACHINE\SOFTWARE\Interwoven\WorkSite\8.0\FileSite\Commands\Document\]
Commands="iManExt.OpenCmd,iManExt.PrintCmd,iManExt.ViewCmd,-,IManExt.SendDocCopyCmd,SendNrl/Url,iManExt.CheckoutCmd,iManExt.CheckinCmd,iManExt.ExportCmd,-,IManExt2.IManMoveContentsCmd,Copy,IManExt2.IManCreateShortcutsCmd@Add to Folder...,-,IManExt2.IManRefileCmd,-,iManExt.PurgeCmd,iManExt.UnLockCmd,IManExt.DeleteCmd,-,Utilities,-,IManExt2.AddToFavoritesCmd,-,iManExt3.FreezeDocumentCmd,DocumentInfo,IManExt2.IManPropertiesCmd"
2) The Defining a New Add-In approach documented in the "Creating Custom Commands in WorkSite.pdf manual", which distributed with your WorkSite iToolkit 8.x.
Is your progid placed in the registry using either one of these above approaches?
Jan999
Finally got a reply from Interwoven support on this. Apparently the dll has to go in the GAC!
wolfgang
According to my experience, it doesn't necessarily have to be in the GAC. But to name it in the "Commands" Registry Name you would have to use namespace.classname, not dllname.classname.
Once you have registered your dll, you can search and find it in the registry under HKCR\CLSID\
your-gid-here
\ and see what full name your class has been registered with.
jny
In my experience, .NET, unlike COM, should be in the GAC, for distribution use in client machines -- and those client machines should have the same version of the .NET Framework as the compiled code -- but the command would work without being in the GAC when its code is running on the development machine.
The FileSite key needs to have the progid to the custom command in order for the custom command to show up in the FileSite menu (specified by the key).
The way I understand .NET is that the Interop DLL cannot be registered as a COM Object as this is not a COM DLL. But, I think that you can also register the DLL, so that the CLSID is in the registry, using Regasm.