From: John on
Hello everybody,

I am new here.

I wonder if anybody could help me with a problem, since
I am new to the .NET environment, coming from VB6.


In Visual Basic 6 there was a very handy possibility with the TYPE
command, which allowed to group variables, for instance like this :

TYPE dummy
dim A as Integer
dim B as String
dim C as Double
END TYPE

This allowed to write the whole group onto a binary file referencing it
just by the type name. Like this :

write(dummy)

Since I have learned that in .NET environment there is no such thing as
'TYPE' and everything happens through classes, I wrote then :

CLASS dummy
A as Integer
B as String
C as Double
END Class

However, by trying to write them with write(dummy) I got an error
saying that 'dummy cannot be converted to string'.

I also have tried with 'structure' instead of 'class' but I got the same
result.

Anybody knows how I can get around this problem ? ?

For the files I am using the statements :

Dim fs As New IO.Filestream(filename, IO.Filemode.Create)
dim bw As New IO.BinaryWriter(fs)

Thanks for any help.



From: Mike Williams on
On 12 Apr, 16:43, John <du...(a)agdp.de> wrote:

> I wonder if anybody could help me with a problem,
> since I am new to  the .NET environment, coming
> from VB6.

You're in the wrong group, John. This is a Visual Basic group, the
last version of which was VB6. Questions relating to the imposter
should be posted to one of the imposter's own groups, such as:

micrsosoft.public.dotnet.languages.vb

Mike

From: John on
On 12.04.2010 19:31, Mike Williams wrote:
> On 12 Apr, 16:43, John<du...(a)agdp.de> wrote:
>
>> I wonder if anybody could help me with a problem,
>> since I am new to the .NET environment, coming
>> from VB6.
>
> You're in the wrong group, John. This is a Visual Basic group, the
> last version of which was VB6. Questions relating to the imposter
> should be posted to one of the imposter's own groups, such as:
>
> micrsosoft.public.dotnet.languages.vb
>
> Mike
>

Thanks for the hint, Mike. Sorry for the mistake.
I'll follow your suggestion.

All the best !

John.