What is the best way to do this dynamic UI?

What is the best way to do this dynamic UI?

Post by CP » Wed, 31 Oct 2001 11:03:00



Hello,
I am about to start a project where I will read various items from some
files and create 2 colums of drop down menus on each row for each item read.
Would this be just what is described in the Palmdocs as the Dynamic UI, if
so I can just read it, but if now let me know
Thanks.
Brian
 
 
 

What is the best way to do this dynamic UI?

Post by The Capta » Thu, 01 Nov 2001 03:58:35


I would look into MenuAddItem for your problem and add strings to it
that you want to display.  If your thinking about listboxes, use
something like the code below to fill in the listboxes.

        UInt16 retVar;
        int NumRecs = 0;
        ListType *listP;
        char **FieldStr;
        FormPtr frmP;
        char *listChoice;
        char *ReadFromFileStr;

        frmP = FrmInitForm (OpenForm);

        NumRecs = DmNumRecords (UxDrawings);
        (char **)FieldStr = (char **)MemPtrNew(NumRecs*21);
        (void *)listP = FrmGetObjectPtr(frmP, FrmGetObjectIndex(frmP,
OpenOpenList));

        if (NumRecs > 0) {
                for (int i=0; i < NumRecs; i++) {
                        (char *)FieldStr[i] = (char *)MemPtrNew(21);
                        StrCopy(FieldStr[i], ReadFromFileStr);
                }

                LstSetListChoices (listP, FieldStr, NumRecs);
        }
        retVar = FrmDoDialog (frmP);                                    // Display the About Box.

I'm a Palm developer who asks questions on this site as well but I
think you have to be more clear with what you mean by create 2 columns
of drop down menus.  Columns refer to tables.


> Hello,
> I am about to start a project where I will read various items from some
> files and create 2 colums of drop down menus on each row for each item read.
> Would this be just what is described in the Palmdocs as the Dynamic UI, if
> so I can just read it, but if now let me know
> Thanks.
> Brian


 
 
 

What is the best way to do this dynamic UI?

Post by CP » Fri, 02 Nov 2001 10:32:15


Sorry I wasn't more clear, but I didn't know enough to be clear.  I have
read some more and I know what I want to do, but I don't see if it is
possible.  So let me know if it is.

1) I want to have a table that each cell is a pop up trigger to a list.
Though I don't know until at runtime how many rows I need.  I see there are
methods for creating form objects at runtime, but I don't see anything about
a pop-up button.  Can I do this?

2) And I would like to be able to scroll the table.  Can I do this?

Thanks.
Brian


> I would look into MenuAddItem for your problem and add strings to it
> that you want to display.  If your thinking about listboxes, use
> something like the code below to fill in the listboxes.

> UInt16 retVar;
> int NumRecs = 0;
> ListType *listP;
> char **FieldStr;
> FormPtr frmP;
> char *listChoice;
>         char *ReadFromFileStr;

> frmP = FrmInitForm (OpenForm);

> NumRecs = DmNumRecords (UxDrawings);
> (char **)FieldStr = (char **)MemPtrNew(NumRecs*21);
> (void *)listP = FrmGetObjectPtr(frmP, FrmGetObjectIndex(frmP,
> OpenOpenList));

> if (NumRecs > 0) {
> for (int i=0; i < NumRecs; i++) {
> (char *)FieldStr[i] = (char *)MemPtrNew(21);
> StrCopy(FieldStr[i], ReadFromFileStr);
> }

> LstSetListChoices (listP, FieldStr, NumRecs);
> }
> retVar = FrmDoDialog (frmP); // Display the About Box.

> I'm a Palm developer who asks questions on this site as well but I
> think you have to be more clear with what you mean by create 2 columns
> of drop down menus.  Columns refer to tables.




- Show quoted text -

Quote:> > Hello,
> > I am about to start a project where I will read various items from some
> > files and create 2 colums of drop down menus on each row for each item
read.
> > Would this be just what is described in the Palmdocs as the Dynamic UI,
if
> > so I can just read it, but if now let me know
> > Thanks.
> > Brian

 
 
 

What is the best way to do this dynamic UI?

Post by Ben Combe » Fri, 02 Nov 2001 15:39:14



Quote:> Sorry I wasn't more clear, but I didn't know enough to be clear.  I
have
> read some more and I know what I want to do, but I don't see if it is
> possible.  So let me know if it is.

> 1) I want to have a table that each cell is a pop up trigger to a
list.
> Though I don't know until at runtime how many rows I need.  I see
there are
> methods for creating form objects at runtime, but I don't see anything
about
> a pop-up button.  Can I do this?

Tables can have pop-up triggers as native items.  One of the styles that
can get set using TblSetItemStyle is popupTriggerTableItem.  The item's
"int" is the index of the item, while the "ptr" points to a ListType
object that will popup.
 
 
 

What is the best way to do this dynamic UI?

Post by CP » Tue, 06 Nov 2001 01:09:53


How do you connect a LstNewList to the popupTriggerTableItem cell type?
Thanks,
Brian




> > Sorry I wasn't more clear, but I didn't know enough to be clear.  I
> have
> > read some more and I know what I want to do, but I don't see if it is
> > possible.  So let me know if it is.

> > 1) I want to have a table that each cell is a pop up trigger to a
> list.
> > Though I don't know until at runtime how many rows I need.  I see
> there are
> > methods for creating form objects at runtime, but I don't see anything
> about
> > a pop-up button.  Can I do this?

> Tables can have pop-up triggers as native items.  One of the styles that
> can get set using TblSetItemStyle is popupTriggerTableItem.  The item's
> "int" is the index of the item, while the "ptr" points to a ListType
> object that will popup.

 
 
 

1. Reply - When is DOS enough & Plain DOS is the best RTOS for PC

Reply - When is DOS enough & Plain DOS is the best RTOS for PC


Dear Bill,

I saw your posting in comp.arch.embedded as a response to ScottW about
how "Plain DOS is the best RTOS for the PC."  I agree about DOS being a
fine platform for embedded systems.  Although it would make more sense
if the DOS were truly reentrant and provided multitasking functionality
in the base.  After leaving Microsoft's NT team five years ago, I wrote
a real-time DOS for the PC, and it has real threads, timers, events,
mutexes, and the like built into it.  It is also fully reentrant-- making
it possible to call an INT 21h function at interrupt time (not that you'd
probably want to do that.)  However, it does make it easy to create
applications that spin-off threads to do work in parallel, such as flushing
buffers in the background while screen-painting happens at a different
priority.

I formed a company based on this product and it is now in pretty wide
usage in embedded systems (it is not intended to be a desktop DOS).
If you're interested you can log-in to our BBS at 206-454-5894 and
download a sample that will boot on your PC.

Product Development Group
General Software, Inc.
tel: 206.454.5755
fax: 206.454.5744

2. byteserving being done here?

3. Ways Of Removing MSN IA 5.4 ---- Which Is Best?

4. 10baset tester

5. Best Ways to Learn SAS?

6. Application life

7. Best Ways To Learn SAS?

8. GAME DELAYS

9. Best ways to change fonts in SAS output

10. 2 diff ways of obtaining an object ref. Which is best?

11. RFI - Best ways to sync data across platforms

12. Pagis Pro 2.0's built-in UI vs. Twain UI, and OCR quality.

13. Sure Interview // Sure Closure // Flex UI and Java UI // CA // 12 months