Define Variable - Forum

Forum Navigation
You need to log in to create posts and topics.

Define Variable

This is perhaps a stupid question, but I honestly don't know the answer to this.

VisualNeo Win determines the type of data in a variable automatically in most cases, and I have never had a problem with variables in this case.

My question is, what are the advantages of defining a variable TYPE if VN handles this automatically?

Thanks for any insight with this.

 

Hello,

The define type of a variable is used with subroutines. There you can use it to feed the right format into your subroutine.

Basicly the is no real type of a variable. Technically they are all Strings. (PChar's in memory)

Only when you feed the variable into a command, its content is converted dynamicly into a usable type for that command.

So the neoscript engine does this for its commands when needed.

A plugin developer does it code for his own commands.

Regards

Hans-Peter

 

 

 

 

luishp and rcohen have reacted to this post.
luishprcohen

Thanks for the info Hans.    I guess then the short answer is that there isn't really a need for this with VNW script...

rcohen