+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    j_r_auden
    Guest

    Default dynamic allocation/global variables

    Registered forum members do not see this ad.

    2 quick questions

    1. How do I dynamically allocate space for an array. I do not know the size of the array until after runtime so I do not know how much space to allocate for the array.

    2. I have an application that consists of several modules and I need one global variable to be a counter. Where do I need to declare this variable?? I am aware that in languages such as Java and C++, you have a main program and you can call other functions defined in header files. Can you do this in VBA. If so, how ???

    Thanks,
    James

  2. #2
    Super Member
    Using
    AutoCAD 2007
    Join Date
    Aug 2003
    Location
    Livingston, Scotland
    Posts
    995

    Default

    Registered forum members do not see this ad.

    to dynamically allocate space for an array, you have to use the REDIM statement
    to have a global variable, declare it at module level and make it Public
    ResourceCAD.... the Resource for your CAD Solutions

Bookmarks

Posting Permissions

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