Not quite. Here's an example from VMS Basic:
RECORD FOO
VARIANT
CASE
STRING BUF = 10
CASE
STRING FIRST_5 = 5
STRING LAST_5 = 5
END VARIANT
END RECORD
In the sample above, FIRST_5 will return and/or set the first 5 characters
of BUF and LAST_5 will return and/or set the last 5 characters of BUF.
Since I'm porting from VMS to VB 6, which doesn't support this construct
easily, and now to VB.Net, I was hoping for a cleaner solution than I had to
implement in VB 6.
Mike Ober.
"Ken Tucker [MVP]" <vb***@bellsouth.net> wrote in message
news:uk**************@TK2MSFTNGP09.phx.gbl...
Hi,
Use Structure instead of Type.
http://msdn.microsoft.com/library/de...mStructure.asp
Ken
----------------
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:Oi**************@TK2MSFTNGP10.phx.gbl: Hi Michael,
You mean this?
HYPERLINK
"http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon98/ht
ml/vbconcreatingyourowndatatypes.asp"http://msdn.microsoft.com/library/defau lt.asp?url=/library/en-us/vbcon98/html/vbconcreatingyourowndatatypes.asp
I hope this helps?
Cor
--
Outgoing mail is certified Virus Free.
Checked by AVG Anti-Virus (http://www.grisoft.com).
Version: 7.0.230 / Virus Database: 263.3.0 - Release Date: 6/12/2004