English Amiga Board

English Amiga Board (http://eab.abime.net/index.php)
-   Coders. Blitz Basic (http://eab.abime.net/forumdisplay.php?f=126)
-   -   [blitz] and gadtools cycle gadget (http://eab.abime.net/showthread.php?t=99315)

peceha 22 October 2019 13:12

[blitz] and gadtools cycle gadget
 
Hi,
I need this:
Quote:

GTCY_Labels (STRPTR *) - Pointer to NULL-terminated array of strings
looks like ordinary blitz's array is not working here.. just shows trash on the gadget
Code:

text$(0)="0"
text$(1)="1"
text$(2)="2"
text$(3)="3"
...
... GTCY_Labels, &text$(0)

Thanks in advance :)

Daedalus 22 October 2019 13:21

Hmmm, it's a long time since I messed with GadTools in C, but I think it's an array of pointers that's needed (with a null after the last pointer), rather than an actual array of strings. In Blitz I usually just use the built-in command which takes a string containing the entries as an argument.

peceha 22 October 2019 13:26

Thanks for suggestion, I'll try it out.

peceha 22 October 2019 13:34

You were right :great
just array to the pointers and 0 as last array's item

Thanks.


All times are GMT +2. The time now is 23:29.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.

Page generated in 0.04887 seconds with 11 queries