SilverScreen Solid Modeler

prompt_entity

prompt_entity

Previous topic Next topic  

prompt_entity

Previous topic Next topic JavaScript is required for the print function  

SilverScreenAPI

 

int prompt_entity ( char *message, int e_type, char *buf )

 

char *message;      // prompt message string

int   e_type;       // entity type mask

char *buf;          // character buffer to receive entity path

 

 




Synopsis

#include "silver.h"

 

The prompt_entity function prompts the user to select an entity from the current drawing, based on the e_type filter. The prompt specified by message is displayed at the bottom of the screen. This function uses either pick mode or scan mode to select an entity, depending on the current pick/scan setting.

 

 

Parameters

message is a null-terminated string containing a prompt message. e_type is an integer value specifying which entity types are to be considered for picking: BITS_BLOCK , BITS_DETAIL , BITS_OBJECT , BITS_SYMBOL , or BITS_TEXT may be or'ed together to obtain e_type . buf is the address of a character buffer that is to receive the full path name of the selected entity.

 

 

Return Value

If a selection is successfully made, then 1 is returned and the path name of the selected entity is copied into buf ; otherwise, 0 is returned.

 

 

See Also

pick_entity , scan_entity

 

 

Example

C / C++ Code

 

 char path[100], txt[100];

 

 if ( prompt_entity ( "Select object", BITS_OBJECT, path ) )

    ss_command (“note Path of selected object: %s”,path );