aldweb

Close I. aldweb

Close II. PC Freeware

Close III. Palm Freeware

Close IV. Palm Shareware

Close V. iziBasic Palm

Close VI. Palm Knowledge

Close VII. Pocket Computer

Close VIII. miniPortail

Special !



Mobile version of
the aldweb Site

m.aldweb.com


Neither French, nor English?

Try one of these flags then:
[de] [es] [it] [pt]
Search




Weather / Spam / www

Lyon Weather


aldweb against spam


Newsletter
To receive news about this website, consider subscribing to our Newsletter.
Subscribe
Unsubscribe
298 Subscribers
Family's web sites

Webmaster - Infos
Friends News
Visits

   visitors

   visitors online

Poll
What do you think of the new design of the aldweb Site?
 
Great !
Beautiful
Average
So ugly...
Results
forum.gifForum - iziBasic - Topic #1304

Forum - Forum
iziBasic - iziBasic


Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 257

active  Topic # 1304  Question about POPUPCHOICE

29/11/2005 @ 21:46
by Michael Green

Anonymous



The following is a fragment from a program. I get a syntax error in the POPUPCHOICE statement and I don't understand why.
A$­­(27)="Daily"
A$­­(28)="2x Per Day"
A$­­(29)="3x Per Day"
A$­­(30)=""
POPUPCHOICE #102,1,A$­­(27),3,118,100,40,30
As an extension to isiBasic, I'd suggest a simple choice list without the popup. Sometimes it's more useful to show the choices on the display all the time even though it takes up screen real estate.
Write to Michael Green   Post an answer  Top

[]   

StartPrevious [ 1 2 ] NextEnd

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 1
--------
30/11/2005 @ 19:30
by aldweb

Anonymous

visitor
Hello Michael,

The correct syntax is this one:
POPUPCHOICE #102,1,"A$­­­­
(27)",3,118,100,40,30


Cheers,
aldweb
Write to aldweb   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 2
--------
23/04/2008 @ 08:27
by Lee Mulcahy

Anonymous

visitor
I had this same question. When I tried your answer, it did not work. All it displayed was the string "A$(27)", not the contents of A$(27).

I am using v6.0 of iziBasic.

Thanks,

Lee
Write to Lee Mulcahy   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 3
--------
26/04/2008 @ 00:17
by Nate Weil

Anonymous

visitor
Michael you mean adding a list instead of a popup menu-like list? I really want that too... I've made an app launcher of sorts, but I really really really could use a list or table to do it... also why can't izibasic run palm-made apps? Only 3rd party stuff shows up...
Write to Nate Weil   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 4
--------
26/04/2008 @ 23:36
by aldweb

Anonymous

visitor
Hello,

I just tried the following code, and it does work:

DIM A$(30)
BEGIN
A$­­(27)="Daily"
A$­­(28)="2x Per Day"
A$­­(29)="3x Per Day"
A$­­(30)=""
POPUPCHOICE #102,1,"A$(27)",3,118,100,40,30
REPEAT
E=WAITEVENT
UNTIL E=-1
END


Nate, I don't get your point when you say "also why can't izibasic run palm-made apps? Only 3rd party stuff shows up...".
Do you mean that some applications cannot be launched with the RUN statement?

Cheers,
aldweb
Write to aldweb   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 5
--------
27/04/2008 @ 05:53
by Lee Mulcahy

Anonymous

visitor
Hi,

It turns out that I was trying to initialize the A$() elements BEFORE the BEGIN statement. When I moved them inside, it worked. However, when the App is first started, the dropdown list shows 'A$(27)' until it is clicked on the first time. This happened with your example also. What am I doing wrong?

Thanks,

Lee
Write to Lee Mulcahy   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 6
--------
27/04/2008 @ 18:15
by nate Weil

Anonymous

visitor
so I go through all the apps on my palm and put them in a list so I can see them all. Apps made by me show up, apps made by others show up, anything that did not come with the palm. Media player does not show up, calendar, notes, contacts, etc.. They can not be run/found.
Write to nate Weil   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 7
--------
30/04/2008 @ 18:18
by aldweb

Anonymous

visitor
Lee,

Try this code instead:
DIM A$(30)
BEGIN
A$­­(27)="Daily"
A$­­(28)="2x Per Day"
A$­­(29)="3x Per Day"
A$­­(30)=""
POPUPCHOICE #102,"Daily","A$(27)",3,118,100,40,30
REPEAT
E=WAITEVENT
UNTIL E=-1
END


Cheers,
aldweb
Write to aldweb   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 8
--------
30/04/2008 @ 18:22
by aldweb

Anonymous

visitor
Hello Nate,

Running the following code works like a charm in all my devices, returning all applications, either in ROM or in RAM.
' Listing generated by ViziBasic v2.2
' 30/04/2008 @ 18:15:19

{CREATORID "LDTE"}
{VERSION "1.0"}
{MINOSVERSION "5.0"}
{PARSER ON}
'{KEYEVENTS OFF}
'{SECUREFILES ON}
'{CONSOLEFONT ON}

DIM %EVT%,%P1%,%P2%,%P3%
DIM %P1$,%P2$,%P3$

DIM A$(500)


BEGIN
GOSUB _OnAppStart
GOSUB _GenerateGUI
GOSUB _EventsLoop
GOSUB _OnAppExit
END

_GenerateGUI:
%P2$="A$(30)"
'%P1$="¶" : %P3%=1 : %P2%=LEN(%P2$)
'FOR %P1%=1 TO %P2%
' %P3$=CHAR$(%P2$,%P1%)
' IF %P3$=%P1$ INC %P3%
'NEXT
%P3%=10
%P1$="Select Application"
SETFONT 0
POPUPCHOICE #1,%P1$,%P2$,%P3%,10,20,100,12
%P1$="Run"
SETFONT 0
BUTTON #2,%P1$,60,140,40,14
RETURN

_EventsLoop:
REPEAT
%EVT%=WAITEVENT
SELECT CASE %EVT%
CASE 1
GOSUB _POPUPCHOICE_1
CASE 2
GOSUB _BUTTON_2
END SELECT
UNTIL %EVT%=-1
RETURN

_POPUPCHOICE_1:
S=SELECTEDCHOICE+29
RETURN

_BUTTON_2:
A=(S>30) AND (S<=I)
IF A=TRUE THEN
A$=A$(S)
RUN A$
ENDIF
RETURN

_OnAppStart:
A$(30)="Select Application"
I=30
A$=FINDFIRST$("appl","")
WHILE A$<>""
INC I : A$(I)=A$
A$=FINDNEXT$ '("appl","")
WEND
SORT A$,31,I
RETURN

_OnAppExit:

RETURN


Cheers,
aldweb
Write to aldweb   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 9
--------
30/04/2008 @ 18:49
by nate Weil

Anonymous

visitor
I believe you mentioned before your devices are older... I have a tungsten E2 maybe the device has to do with it, what with updates and all that. I always get the same results though...
Write to nate Weil   Post an answer  Top

Warning: A non-numeric value encountered in /web5/aldweb/www/aldweb_com/www/thread.php on line 497
Answer n° 10
--------
30/04/2008 @ 19:01
by aldweb

Anonymous

visitor
I tested this code in a Tungsten C and a TX. I did not take the time to test it in my Tréo 680, but I see no reason why it would work in the TX and not the Tréo.

Cheers,
aldweb
Write to aldweb   Post an answer  Top
StartPrevious [ 1 2 ] NextEnd
active topic active   closed topic closed   Sticky Sticky   New New message   -   Correct Correct message   Close Close topic   Make sticky Make sticky
[]
Forum Topic  Forum 



 
^ Top ^