htmlInputText
Single-line text input control class
[Previous] [Main] [Next]


Description
htmlInputText encapsulates the <INPUT TYPE="TEXT"></INPUT> tags. It's used to add single-line text input areas to htmlForm objects. To add multi-line input areas, use the htmlInputTextArea class.  
 
Declaration
#include <dcmicro/htmlpp/inputtxt.h>  
 
Hierarchy
htmlinputtext.gif  
 
See Also
htmlForm, htmlInputTextArea  
 
Related Constants/Definitions
None.  
 
Constructors
htmlInputText()  
Constructs an empty text input object.  
 
htmlInputText( const String& name, int display_length = 0, int max_length = 0 )  
Constructs an empty text input object, using the specified name and dimensions. If display_length or max_length is zero, the browser default values will be used.  
 
htmlInputText( const String& name,  
   const String& value,  
   int display_length = 0,  
   int max_length = 0 )  
Constructs an empty text input object, using the specified name and dimensions, populating it with the intial string value. If display_length or max_length is zero, the browser default values will be used.  
 
Destructor
virtual ~htmlInputText()  
Destroys the object.  
 
Member Methods
Name   htmlInputText& Name( const String& name )  
Sets the control name to name, and returns a reference to the object.  
 
Name   String Name() const  
Returns the control name as a string.  
 
Value   htmlInputText& Value(const String& value )  
Sets the control value to value, and returns a reference to the object.  
 
Value   String Name() const  
Returns the control value as a string.  
 
DisplayLengthhtmlInputText& DisplayLength( int display_length )  
Sets the maximum number of characters to be displayed to display_length, and returns a reference to the object.  
 
DisplayLengthint DisplayLength() const  
Returns the number of characters to be displayed, or zero if not set.  
 
MaxLength   htmlInputText& MaxLength( int max_length )  
Sets the maximum number of characters the control will accept to max_length, and returns a reference to the object.  
 
MaxLength   int MaxLength() const  
Returns the maximum number of characters the control will accept, or zero if not set.  
 
Clone   htmlObject FAR * Clone() const  
Returns a base-class pointer to a deep copy of the object.  
 
Example
 
See Tutorial: Forms: Single-line Text Input  
 



©1998 DC Micro Development. All rights reserved.
No portion of this document may be c opied or reproduced without expressed written consent.
html++ is a trademark of DC Micro Development.