Results 1 to 3 of 3

Thread: Macro Command

  1. #1

    Thread Starter
    Lively Member
    Join Date
    May 2004
    Location
    Cleveland,Oh
    Posts
    95

    Macro Command

    Hi All:
    Is there a such command that would allow me to run the following line of code:

    oLstSpkr = IIF(oRecData!Option_Name = "Speaker","Set oLstSpkr=LstPSpeak,Set oLstSpkr=LstSndSpkr)

    &oLstSprk --(run whateve is in the oLostSprk)

    Thanks
    Zus

  2. #2
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974
    It is possible, but I would recommend using a normal If rather than IIF, as the IIF always evaluates code for both the True and False results (which could well be a problem as there are objects invloved).
    VB Code:
    1. IF oRecData!Option_Name = "Speaker" Then
    2.   Set oLstSpkr = LstPSpeak
    3. Else
    4.   Set oLstSpkr = LstSndSpkr
    5. End If

  3. #3

    Thread Starter
    Lively Member
    Join Date
    May 2004
    Location
    Cleveland,Oh
    Posts
    95

    Resolved:Macro

    Thanks si_the_geek
    Zus

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