Results 1 to 5 of 5

Thread: VB in Excel

  1. #1

    Thread Starter
    Frenzied Member Mark Sreeves's Avatar
    Join Date
    Nov 1999
    Location
    UK
    Posts
    1,845
    This is my first attempt at using VB in Excel

    I've written a function to be included in a spread-sheet but some variables need initalising when it first runs.

    If it was a normal vb form I would call it from Form_Load so it only runs once.

    Is it possible to run initialisation code when a spread-sheet is first opened?

    Mark
    -------------------

  2. #2
    Hyperactive Member
    Join Date
    Feb 2000
    Location
    Sedgefield
    Posts
    337

    Lightbulb Use this...

    Code:
    Private Sub Workbook_Open()
    
    End Sub
    Should do the trick

    Dan

    Outside of a dog, a book is a man's best friend.
    Inside of a dog, it's too dark to read.

  3. #3

    Thread Starter
    Frenzied Member Mark Sreeves's Avatar
    Join Date
    Nov 1999
    Location
    UK
    Posts
    1,845
    Thanks Judd!
    Mark
    -------------------

  4. #4
    Hyperactive Member
    Join Date
    Feb 2000
    Location
    Sedgefield
    Posts
    337

    No problemo.

    That was quick, so I figure you're in the UK someplace? And at work already, like me

    Dan

    Outside of a dog, a book is a man's best friend.
    Inside of a dog, it's too dark to read.

  5. #5
    Hyperactive Member Libero's Avatar
    Join Date
    Jun 2000
    Location
    Swedish viking
    Posts
    460
    U can also use:


    Sub Auto_open()

    End Sub


    (I dont want any viruses from u then ;-))

Posting Permissions

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



Click Here to Expand Forum to Full Width