Deploying VB CAB in VisualStudio 2005/8


New member
Oct 27, 2008
Programming Experience
I'm trying to write a mail merge tool that will be activated and downloaded from a web page through an activeX control. It should consume data from a webservice (passed through javascript into the control) and create a Word mail merge file.

I think I have a handle on the code, as I've found good examples on this forum and others about how to perform this type of action, but most of the examples have been in VB6, and I only have VS 200x (both versions), which is I've been fighting with the IDE for the past week trying to get it to build a working CAB.

Here are the steps I'm taking:
1. Create new VB class library project.
2. Create a public method in the default Class1.vb called doIt() with no content
3. Create a new project of type CAB package
4. Add the output of the VB class lib project to the cab project.
5. Build the VB project
6. Build the CAB project
7. Create a test HTML page with:
- an OBJECT tag, referencing the GUID found in the Assembly Information section of the VB project
- the cab name for codebase
- a button that calls a javascript method that calls the objectId.doIt()
8. drop the html file and the cab file in the same directory in the docroot of apache
9. Load the webpage and click 'install' on the security warning popup
10. Click the button

I always get an error that the object does not support this property or method. I've also tried Object.Class1.doIt(), to no avail.

I know there's got to be something simple that I'm missing here. The docs seem to suggest that it should be just this simple to deploy an app. For some reason the ClickOnce tool is not available for class libraries. I don't want to create a windows app because I want this to be completely behind the scenes for the user (they should just see the Word doc).

Any help would be most appreciated!

 <OBJECT ID="AutoWord" 
 <SCRIPT language="Javascript">
   function handleClick(){
 <a href="#" onclick="handleClick();">click here</a>
Top Bottom