SilverScreen Solid Modeler

box_prompt_multiple

box_prompt_multiple

Previous topic Next topic  

box_prompt_multiple

Previous topic Next topic JavaScript is required for the print function  

SilverScreenAPI

 

int box_prompt_multiple ( char *message, int sort_flag )

 

char *message;           // box_prompt messages

int   sort_flag;         // enables/disables item sorting

 

 




Synopsis

#include "silver.h"

 

box_prompt_multiple is like box_prompt , except that multiple items may be selected from the list of text items. The items are displayed in a box panel. Items are added to the list by previous calls to attach_box_item.  Selected items may be retrieved by successive calls to get_generic .

 

 

Parameters

message is a null-terminated string with three components, separated by vertical bars ('|'), as described in box_prompt , except for the third component:

 

    <text1>|<text2>|<text3>

 

where :

 

    <text1> is the title of the panel.

    <text2> is the text that appears beneath the title, if this text is "*", then no text will be displayed.

    <text3> should be "*".

 

sort_flag , if non-zero, will cause the items to be sorted alphabetically; otherwise, they will retain the order in which they were received.

 

 

Return Value

If the user successfully selects at least one item then box_prompt_multiple returns 1; otherwise, 0 is returned.

 

 

See Also

attach_box_item , get_generic

 

 

Example

C / C++ Code

 

 attach_box_item ( "One" );

 attach_box_item ( "Two" );

 attach_box_item ( "Three" );

 attach_box_item ( "Four" );

 attach_box_item ( "Five" );

 

 if ( box_prompt_multiple ( "Numbers|Select numbers|*", 0 ) )

       {

       for ( i = 1 ; get_generic ( i, xxx ) ; ++i )

               ss_command ( "note xxx: [%s] i: [%d]", xxx, i );

       }