Results 1 to 4 of 4

Thread: VBA userform in excel

  1. #1
    Member
    Join Date
    2009-01
    Posts
    8
    Login to Give a bone
    0

    Default VBA userform in excel

    Have completed a code within AutoCAD VBA to export all required info to an excel spreadsheet.

    My next problem is updating the code within excel, I am wanting to do this with simple userforms.

    As all my code is in CAD VBA, is there a way I can show the userforms in excel - not in CAD.

    Alternatively can I produce a new excel code and load that at the end of the CAD code

    Hope i've explained it ok

  2. #2
    Active Member
    Join Date
    2008-06
    Posts
    52
    Login to Give a bone
    0

    Default Re: VBA userform in excel

    I don't know anyway to get your CAD VBA forms to show up in Excel. However you can call Excel Macro's from an AutoCAD Macro.

    Example:

    Dim XLApp As Excel.Application
    Set XLApp = GetObject(, "Excel.Application")
    XLApp.Application.Run "Book1!Macro1"

  3. #3
    Administrator Ed Jobe's Avatar
    Join Date
    2000-11
    Location
    Turlock, CA
    Posts
    6,420
    Login to Give a bone
    0

    Default Re: VBA userform in excel

    It depends on what you want to do with the form in xl. However, you can design a form in xl and call it from acad. A form designed in acad can define and reference xl objects as well.
    C:> ED WORKING....


    LinkedIn

  4. #4
    AUGI Addict MikeJarosz's Avatar
    Join Date
    2015-10
    Location
    New York NY
    Posts
    1,497
    Login to Give a bone
    0

    Default Re: VBA userform in excel

    Just a thought.... I haven't tried this myself but.........

    Tile the Acad and Excel windows on your screen so that popup windows in both will be visible.

Similar Threads

  1. Parameters from Userform
    By CADfunk MC in forum VBA/COM Interop
    Replies: 2
    Last Post: 2010-04-26, 06:25 PM
  2. Unload a userform
    By mikeosborne in forum VBA/COM Interop
    Replies: 2
    Last Post: 2009-09-28, 08:35 PM
  3. All I want is a Userform to show..
    By Coolmo in forum Dot Net API
    Replies: 5
    Last Post: 2009-07-23, 02:03 PM
  4. Reference Excel Spread sheet in a userform combobox
    By mikeosborne in forum VBA/COM Interop
    Replies: 3
    Last Post: 2009-04-30, 06:22 PM
  5. Userform limit
    By Coolmo in forum VBA/COM Interop
    Replies: 8
    Last Post: 2007-06-22, 06:29 PM

Posting Permissions

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