Converting Some C Code To PureBasic

Just starting out? Need help? Post your questions and find answers here.
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by SoulTaker.

Ok me again sorry LOL.

Here's what i need to convert, i have almost all the structures converted now and the CallBack Procedures written.

Structure CallBacks
DllMeassageCallBack.l
EndStructure

I need to put the @DllMessage() Procedure Address into the Structure's DllMessageCallBack

Also another one:

;where UzpVer is defined as:

Structure UzpVer
structlen.l ;/* length of the struct being passed */
flag.l ;/* bit 0: is_beta bit 1: uses_zlib */
betalevel.s ;/* e.g., "g BETA" or "" */
date.s ;/* e.g., "4 Sep 95" (beta) or "4 September 1995" */
zlib_version.s ;/* e.g., "1.0.5" or NULL */
; _version_type unzip;
; _version_type zipinfo;
; _version_type os2dll; This is what needs to be CONVERTED!
; _version_type windll; _version_type is another Structure BELOW.
EndStructure

;} UzpVer;

;And _version_type is defined as:

Structure _version_type
major.b ;/* e.g., integer 5 */
minor.b ;/* e.g., 2 */
patchlevel.b ;/* e.g., 0 */
not_used.b
EndStructure

;} _version_type;

The first Structure is using the other one! I was able to convert that one.

Thank you very much.


Abit BD7-II Raid P4 1.9 gHz 384 Ram Xtasy GFroce 3 TI 200 CD-RW DirectX 9.0 Beta 3 Sound Blaster Live! XP Pro, Registered PureBasic version 3.40 For Windows.
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by tinman.
Originally posted by SoulTaker
The first Structure is using the other one! I was able to convert that one.
Have I missed something? You just need to define the _version_type structure before the one that uses it and call the field names in your other structure things like

osdll._version_type


--
It's not minimalist - I'm increasing efficiency by reducing input effort.
(Win98first ed. + SP1, PB3.30)
Post Reply