[Gambas-user] Unsigned int

Leonardo Miliani leonardo at ...1237...
Fri Jul 28 00:34:23 CEST 2006


Fabien Bodard ha scritto:
> 
> no !
>  public TYPE tutype
>    mystring as string[32]
>    mySTaticarray[12] as integer
>  end type
>  public TYPE montype
>    mystring as string[32]
>    mySTaticarray[12] as integer
>    mytutipe[3] as tutype
>  end type
> 
> 
> 
> dim myudt as UDT.Montype
> 
> mydut.mystring="hello"
> myudt.mystringarray[0]="coucou"
> myudt.mytutipe.mystring = "word"
> 
> 
> or
> 
> TYPE StringData
> Name as string * 10
> FirstName as string *10
> END TYPE
> dim myString data as stringdata
> Read #file, MystringData, TypeLen(MyStingData) 'who is = to 20
> 
> in the file :
> 'Bodard    Fabien    '
> 
> now i can draw a function  in gambas like :
> FileRead(File as stream, type as type, n)
> (chhht!! it's fread in c in fact)
> 
> but i like the idea to have the capability to load ad save binary data in one 
> time like in C.

I was trying to convert this code in _real_ Gambas code but I didn't...
Maybe was this a VB example? I cannot find the Type construct in Gambas...

-- 
Ciao.
Leo

Visita il mio sito personale: www.leonardomiliani.com
e-mail: leonardo at ...1237...




More information about the User mailing list