Consulting

Page 2 of 2 FirstFirst 1 2
Results 21 to 23 of 23

Thread: Solved: Import Excel with own code.

  1. #21
    VBAX Mentor
    Joined
    Feb 2009
    Posts
    447
    Location
    In VBA we need only the = sign to assign a value to a simple variable.
    [vba]strFoo = "bar"[/vba] But assigning to an object variable also requires the Set keyword:
    [vba]Set myDataBase = CurrentDb.OpenRecordset(sqlQuery2)[/vba]

  2. #22
    But assigning to an object variable also requires the Set keyword:

    VBA:
    Set myDataBase = CurrentDb.OpenRecordset(sqlQuery2)
    VBA tags courtesy of www.thecodenet.com
    Ah, right, that's fair enough then.
    Does VBA also have object variables for the simple variables, for complex operations ?
    (for example, like the java Integer object which you have to use for methods like ParseInt() )

  3. #23
    VBAX Mentor
    Joined
    Feb 2009
    Posts
    447
    Location
    Quote Originally Posted by Frenchy646
    Does VBA also have object variables for the simple variables, for complex operations ?
    (for example, like the java Integer object which you have to use for methods like ParseInt() )
    I will guess the answer is no. But I should defer to some who knows Java.

Posting Permissions

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