![]() |
|
|||||||
| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
| Questions & Help Needed Post any question regarding Basic4ppc. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
||||
|
Hi,
I'm tryingf to add an image in rumtime, but am getting sintax error... here the line thath error out addimage(control("panel"&NumbPanel+1),"icon",180,0 ,20,20) "Panel"&NumbPanel is a runtime created panel if i replace "Panel"&NumbPanel by panel2, wich i know is created, it works...
__________________
Paulo Gomes Porto, Portugal PC: Dual-Core 1,8Ghz, 2GB RAM, 80GB HD PPC: Qtek9000, 1GB SD DLL Version Listing |
|
||||
|
HI,
Thanks RandomCoder, Ialready thought of that, and I can't see the error... The entire sub is as follows Sub Button1_Click 'adds a first panel addpanel(form1,"panel"&NumbPanel,50,50,150,100) control("panel"&NumbPanel).color=csilver 'adds a panel within the previous panel addpanel(form1,"panel"&NumbPanel+1,50,50,150,20) control("panel"&NumbPanel+1).color=cblue 'necessary to bring the correct panel to front control("panel"&NumbPanel).BringToFront control("panel"&NumbPanel+1).BringToFront 'ads an image to the second panel addimage(panel2,"icon",130,0,20,20) control("icon").image="close.png" control("icon").BringToFront End Sub
__________________
Paulo Gomes Porto, Portugal PC: Dual-Core 1,8Ghz, 2GB RAM, 80GB HD PPC: Qtek9000, 1GB SD DLL Version Listing |
|
||||
|
I could be way off the mark here but if NumbPanel hasn't beeb assigned a value then it is set to zero. Therefore NumbPanel+1 is equal to 1 not 2.
But you say that it works with the message box present but errors when its removed. That makes me think that its a timing issue? Regards, RandomCoder
__________________
Desktop: Pentium D 920 (2.8GHz, 4MB L2 Cache, 800MHz FSB), 1024MB, 256MB Radeon X600, 250GB HD. Device : Axim X51v XScale 624MHz, 3.7" VGA, 64MB SDRAM, 256MB Flash ROM + 1Gb SD. "Defeat never comes to any man until he admits it."Josephus Daniels |
|
||||
|
thanks Erel, I was starting to go cuco....
__________________
Paulo Gomes Porto, Portugal PC: Dual-Core 1,8Ghz, 2GB RAM, 80GB HD PPC: Qtek9000, 1GB SD DLL Version Listing |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Newbie having trouble with brush1.New1() | mjcoon | Questions & Help Needed | 6 | 05-28-2008 08:11 PM |
| Table trouble | Lasse | Questions & Help Needed | 1 | 01-15-2008 10:37 PM |
| addimage don't load picture? | tvrman | Questions & Help Needed | 5 | 09-03-2007 05:55 PM |
| Table Trouble | RandomCoder | Questions & Help Needed | 2 | 07-15-2007 10:07 AM |
| Table trouble | RandomCoder | Questions & Help Needed | 5 | 05-09-2007 07:31 AM |