Jun 8, 2005 #1 Axoliien Programmer Joined Aug 19, 2003 Messages 166 Location US I was wondering if there is any way to typedef like in C++ in VB.NET. I have a lot of qualified references and would like to shorten their names. Thanks!
I was wondering if there is any way to typedef like in C++ in VB.NET. I have a lot of qualified references and would like to shorten their names. Thanks!
Jun 8, 2005 #2 ThatRickGuy Programmer Joined Oct 12, 2001 Messages 3,841 Location US I'm having a brain fart. I remember the term typedef, but I can place it's functionality. Also my C++ memory has lost it's pointers. -Rick VB.Net Forum forum796 forum855 ASP.NET Forum I believe in killer coding ninja monkeys. Upvote 0 Downvote
I'm having a brain fart. I remember the term typedef, but I can place it's functionality. Also my C++ memory has lost it's pointers. -Rick VB.Net Forum forum796 forum855 ASP.NET Forum I believe in killer coding ninja monkeys.
Jun 8, 2005 1 #3 Dimandja Programmer Joined Apr 29, 2002 Messages 2,720 Location US Not in .NET. The closest you'll get to TYPEDEF is in judicious uses of Imports and Classes. Upvote 0 Downvote
Jun 8, 2005 Thread starter #4 Axoliien Programmer Joined Aug 19, 2003 Messages 166 Location US Ah well, thanks! Upvote 0 Downvote
Jun 8, 2005 #5 ThatRickGuy Programmer Joined Oct 12, 2001 Messages 3,841 Location US Well, I'm still having a brain fart. Off to google I go. -Rick VB.Net Forum forum796 forum855 ASP.NET Forum I believe in killer coding ninja monkeys. Upvote 0 Downvote
Well, I'm still having a brain fart. Off to google I go. -Rick VB.Net Forum forum796 forum855 ASP.NET Forum I believe in killer coding ninja monkeys.
Jun 8, 2005 #6 ThatRickGuy Programmer Joined Oct 12, 2001 Messages 3,841 Location US Okay, back from a memory refreshing trip to google. Couldn't you do something like: Code: Public Class ActualClass Private Class MyClass Inherits Integer End Class Public Sub DoThing dim MyVar as MyClass = 1 '... end sub End Class That's untested, and it takes a few lines as opposed to the inline nature of TypeDef. -Rick VB.Net Forum forum796 forum855 ASP.NET Forum I believe in killer coding ninja monkeys. Upvote 0 Downvote
Okay, back from a memory refreshing trip to google. Couldn't you do something like: Code: Public Class ActualClass Private Class MyClass Inherits Integer End Class Public Sub DoThing dim MyVar as MyClass = 1 '... end sub End Class That's untested, and it takes a few lines as opposed to the inline nature of TypeDef. -Rick VB.Net Forum forum796 forum855 ASP.NET Forum I believe in killer coding ninja monkeys.