Consulting

Results 1 to 8 of 8

Thread: Sleeper: Com addin

  1. #1
    VBAX Expert
    Joined
    Jan 2005
    Posts
    574
    Location

    Sleeper: Com addin

    im just starting to learn how to make these using office 2000 developer, can anyone tell me is it possible to save a whole excel project as an addin (i.e the worksheets as well) or just the vba code?

  2. #2
    Site Admin
    Jedi Master
    VBAX Guru Jacob Hilderbrand's Avatar
    Joined
    Jun 2004
    Location
    Roseville, CA
    Posts
    3,712
    Location
    When you save the workbook as an add-in, all the sheets will remain. But the sheets will be hidden and the user cannot use them. VBA code can use these sheets to store data.

  3. #3
    VBAX Expert
    Joined
    Jan 2005
    Posts
    574
    Location
    sorry jake can you explain a little more for me or tell me where to look for more info,

    basically im wondering if i can make a template database saved as a com addin where the userforms will store data onto the worksheets named customer, products etc or do i have to make the com add in name the spreadsheets progamatically and add new ones etc. i would also like to add code to the workbook_open event when the addin is run, is that possible from a com addin?

    Thanks for taking an interest Jake

    Gibbo

  4. #4
    You can write data to an addin, but how would you allow the user to access it? you can add code programatically (see Chip pearson), but the VB Project must not be protected.
    Hope that helps.
    Get the free Excel based Toolbar or click here for free examples & Excel Consultancy

    RoyUK

  5. #5
    VBAX Expert
    Joined
    Jan 2005
    Posts
    574
    Location
    what im planning on making is an addin that is in effect a template, if thats possible.

    so when called it creates a new spreadsheet containing code and the worksheets i have already designed and saves it with a name i specify.

    If the addin is run again does exactly the same again i. e a new spreadsheet.

    I can write the code I require using the standard vba with no problem but wanted to know if i have to programatically name and create the worksheets or if i can just retain the ones I have already as a template when creating a com addin.

    I also want to be able to write code to the workbook_open event if thats possible.

    Hope that makes sense

    Gibbo

  6. #6
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    Why not just create a template?
    ____________________________________________
    Nihil simul inventum est et perfectum

    Abusus non tollit usum

    Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
    James Thurber

  7. #7
    VBAX Expert
    Joined
    Jan 2005
    Posts
    574
    Location
    i want to be able to protect the code as much as possible and understand a com addin to be much more secure

  8. #8
    VBAX Contributor Aaron Blood's Avatar
    Joined
    Sep 2004
    Location
    Palm Beach, Florida, USA
    Posts
    130
    Location
    Quote Originally Posted by gibbo1715
    i want to be able to protect the code as much as possible and understand a com addin to be much more secure
    Well you're right about that... A compiled addin would indeed be more secure.

    But typically those kinda things are developed in like VB6 (or is it 7 or 8 now?) or visual C+ or something along those lines.

    ...and they're usually just userform based apps that are designed to run on top of Excel. Actually compiling the sheets of a workbook? Haven't investigated that too deeply myself. Seems unlikely. Heard some rumors of some sorta developer version of Office or somethin or other (probably what you've got there) but haven't looked much further into it. Don't know what all it can compile.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •