structure

  • Thread starter Thread starter Carlos
  • Start date Start date
C

Carlos

Hi,

I am trying to create a structure.
I want to know if have a way to create a feature like "UNION" in C using
VB.NET


Thanks


Carlos
 
I am trying to create a structure.
I want to know if have a way to create a feature like "UNION" in C using
VB.NET

VB.NET has no direct equivalent. For what it's worth, neither does C#.
 
Hi,

I am trying to create a structure.
I want to know if have a way to create a feature like "UNION" in C using
VB.NET


Thanks


Carlos


It depends on what you want to use it for... If it is for P/Invoke, then
yes, you can define something like a Union using marshalling attributes. But,
if it is just for your own use in managed code - then not really. You
could probably write a class to fake it... Using a byte array
internally to store the data.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top