r/visualbasic • • Jun 07 '18

Remembered an old trick, thought I'd share

Post image
5 Upvotes

3 comments sorted by

6

u/davesoft Jun 07 '18 edited Jun 07 '18

You can 'alias' another type, even built in ones.

It can help if you later intend to make a real class, but for now, another type will do.

Could be good for 'imports Length = System.Double, Position = System.Double' to differentiate all the various numerical functions flying around.

The mouse-over help can see right through it, and shows you the real type beneath the name.

Sadly it can't be abused to name your function return values :P

https://www.dropbox.com/s/r7hi0thvdauwh1p/nojeff.png?dl=0

5

u/leuldereje Jun 07 '18

Can you add explanation?