Using Structures In Procedures
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
Restored from previous forum. Originally posted by SoulTaker.
Hi,
Ok big problem for me need some help on this. I'm converting my Visual Basic Custom API Drawing Procedures to PureBasic for all.
Problem:
Procedure A()
B(BackColor.l)
EndProcedure
Procedure B(Color.l)
heres the problem, i need to access 2 Structure here in B
VB Code:
Dim Brush As LOGBRUSH (Structure)
Dim lpRect As RECT (Structure)
EndProcedure
How do I get access to these 2 Structures?
I know that i can pass a pointer to the structures.
*lpRect.RECT and *Brush.LOGBRUSH
But i only need to use them in Procedure B not A.
Procedure A calls Procedure B.
Any help on this would be appreciated.
Thank you.
Abit BD7-II Raid P4 1.9 gHz 384 Ram Xtasy GFroce 3 TI 200 CD-RW DirectX 9.0 Beta 2 Sound Blaster Live! XP Pro, Registered PureBasic version 3.30 For Windows.
Hi,
Ok big problem for me need some help on this. I'm converting my Visual Basic Custom API Drawing Procedures to PureBasic for all.
Problem:
Procedure A()
B(BackColor.l)
EndProcedure
Procedure B(Color.l)
heres the problem, i need to access 2 Structure here in B
VB Code:
Dim Brush As LOGBRUSH (Structure)
Dim lpRect As RECT (Structure)
EndProcedure
How do I get access to these 2 Structures?
I know that i can pass a pointer to the structures.
*lpRect.RECT and *Brush.LOGBRUSH
But i only need to use them in Procedure B not A.
Procedure A calls Procedure B.
Any help on this would be appreciated.
Thank you.
Abit BD7-II Raid P4 1.9 gHz 384 Ram Xtasy GFroce 3 TI 200 CD-RW DirectX 9.0 Beta 2 Sound Blaster Live! XP Pro, Registered PureBasic version 3.30 For Windows.
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
Restored from previous forum. Originally posted by Danilo.
cya,
...Danilo
(registered PureBasic user)
Code: Select all
Procedure B(Color.l) Brush.LOGBRUSH
lpRect.RECT
EndProcedure
Procedure A()
B(BackColor.l)
EndProcedure...Danilo
(registered PureBasic user)
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
Restored from previous forum. Originally posted by Berikco.
maybe this will help
Regards,
Berikco
http://www.benny.zeb.be
maybe this will help
Code: Select all
Global lpRect.RECT
Global Brush.LOGBRUSH
lpRect\left=10
Procedure B(Color.l)
Debug lpRect\left
EndProcedure
Procedure A()
B(BackColor.l)
EndProcedure
a()Berikco
http://www.benny.zeb.be
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
Restored from previous forum. Originally posted by Berikco.

Regards,
Berikco
http://www.benny.zeb.be
Uups, dit not read whole question...Dilo was quicker, and better solutionOriginally posted by SoulTakerBut i only need to use them in Procedure B not A.
Regards,
Berikco
http://www.benny.zeb.be
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
Restored from previous forum. Originally posted by SoulTaker.
Thank yo Guys.
When i get this all converted and running, it will allow you to write your own controls say like a database grid what ever you can think up.
And Danilo i did download your ToolBar Pro nice job.
Abit BD7-II Raid P4 1.9 gHz 384 Ram Xtasy GFroce 3 TI 200 CD-RW DirectX 9.0 Beta 2 Sound Blaster Live! XP Pro, Registered PureBasic version 3.30 For Windows.
Thank yo Guys.
When i get this all converted and running, it will allow you to write your own controls say like a database grid what ever you can think up.
And Danilo i did download your ToolBar Pro nice job.
Abit BD7-II Raid P4 1.9 gHz 384 Ram Xtasy GFroce 3 TI 200 CD-RW DirectX 9.0 Beta 2 Sound Blaster Live! XP Pro, Registered PureBasic version 3.30 For Windows.
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
-
BackupUser
- PureBasic Guru

- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm