Executing a String Variable

I would like to Know how to Execute a String Variable. In Clipper you could populate a String Variable with code and then later include in your source code with an @ or an &.

example :

cString as String
cString = "If bolFlag = true then bolFlag = False"
'Later then you can use the Variable to test something

Public Sub Test()
...
@cString
...
End Sub

Is this Posible in VB and if so , How ???
Urgent Responses Please.

EMAIL : [email protected]

Comments

  • Sorry dude, I don't think you can do that, although I may be wrong :/ I know you can make single words like that though, just not whole lines of code...I think

    ex.
    m = MsgBox
    m ("Hey!")

    that would work, don't know if it helps any though...


    ..:: Zantos ::..
  • : I would like to Know how to Execute a String Variable. In Clipper you could populate a String Variable with code and then later include in your source code with an @ or an &.
    :
    : example :
    :
    : cString as String
    : cString = "If bolFlag = true then bolFlag = False"
    : 'Later then you can use the Variable to test something
    :
    : Public Sub Test()
    : ...
    : @cString
    : ...
    : End Sub
    :
    : Is this Posible in VB and if so , How ???
    : Urgent Responses Please.
    :
    : EMAIL : [email protected]
    :

    This might work but I haven't tested it yet. Press Ctrl-T while in VB6
    & select "Microsoft Script Control" (somethin like that) & insert 1 of
    the scripts in a form. It should run functions somehow but you'll have
    2 experiment wt it.

    [b][red]Dragon[/red][purple]storM[/purple][/b]
  • : : I would like to Know how to Execute a String Variable. In Clipper you could populate a String Variable with code and then later include in your source code with an @ or an &.
    : :
    : : example :
    : :
    : : cString as String
    : : cString = "If bolFlag = true then bolFlag = False"
    : : 'Later then you can use the Variable to test something
    : :
    : : Public Sub Test()
    : : ...
    : : @cString
    : : ...
    : : End Sub
    : :
    : : Is this Posible in VB and if so , How ???
    : : Urgent Responses Please.
    : :
    : : EMAIL : [email protected]
    : :
    :
    : This might work but I haven't tested it yet. Press Ctrl-T while in VB6
    : & select "Microsoft Script Control" (somethin like that) & insert 1 of
    : the scripts in a form. It should run functions somehow but you'll have
    : 2 experiment wt it.
    :
    : [b][red]Dragon[/red][purple]storM[/purple][/b]
    :


    Thanx it sure works.
    And very good too
    Thanx
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories