NXOpen .NET Reference Guide  1899
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties
Classes | Static Public Member Functions | List of all members
NXOpenUI.NXInputBox Class Reference

Provides static methods for creating simple text or numeric entry dialogs using Windows Forms controls. More...

Classes

class  NXInputBoxForm
 Represents the Windows Forms controls for the NXInputBox.
 

Static Public Member Functions

static double GetInputNumber (string prompt)
 Displays a simple text entry dialog to the user and returns the number the user enters. More...
 
static double GetInputNumber (string prompt, string caption)
 Displays a simple text entry dialog to the user and returns the number the user enters. More...
 
static double GetInputNumber (string prompt, string caption, string initialText)
 Displays a simple text entry dialog to the user and returns the number the user enters. More...
 
static double GetInputNumber (string prompt, string caption, double initialNumber)
 Displays a simple text entry dialog to the user and returns the number the user enters. More...
 
static string GetInputString (string prompt)
 Displays a simple text entry dialog to the user and returns the string the user enters. More...
 
static string GetInputString (string prompt, string caption)
 Displays a simple text entry dialog to the user and returns the string the user enters. More...
 
static string GetInputString (string prompt, string caption, string initialText)
 Displays a simple text entry dialog to the user and returns the string the user enters. More...
 
static System.Boolean ParseInputNumber (string prompt, string caption, string initialText, System.Globalization.NumberStyles style, System.IFormatProvider provider, out double result)
 Displays a simple text entry dialog to the user, parses the string the user enters, and if it is a valid number, sets result to the value the user entered and returns true. More...
 
static System.Boolean ParseInputNumber (string prompt, string caption, double initialNumber, System.Globalization.NumberStyles style, System.IFormatProvider provider, out double result)
 Displays a simple text entry dialog to the user and returns the string the user enters. More...
 

Detailed Description

Provides static methods for creating simple text or numeric entry dialogs using Windows Forms controls.

Member Function Documentation

static double NXOpenUI.NXInputBox.GetInputNumber ( string  prompt)
inlinestatic

Displays a simple text entry dialog to the user and returns the number the user enters.

Throws a FormatException if the input text does not form a valid number.

Throws an OverflowException if the input text is outside the valid range for doubles.

Parameters
promptPrompt string to the user for the text entry box.
static double NXOpenUI.NXInputBox.GetInputNumber ( string  prompt,
string  caption 
)
inlinestatic

Displays a simple text entry dialog to the user and returns the number the user enters.

Throws a FormatException if the input text does not form a valid number.

Throws an OverflowException if the input text is outside the valid range for doubles.

Parameters
promptPrompt string to the user for the text entry box.
captionCaption string for the window title to the text entry dialog.
static double NXOpenUI.NXInputBox.GetInputNumber ( string  prompt,
string  caption,
string  initialText 
)
inlinestatic

Displays a simple text entry dialog to the user and returns the number the user enters.

Throws a FormatException if the input text does not form a valid number.

Throws an OverflowException if the input text is outside the valid range for doubles.

Parameters
promptPrompt string to the user for the text entry box.
captionCaption string for the window title to the text entry dialog.
initialTextInitial text to use as default text in the text entry box.

This initial text should form a valid double number.

static double NXOpenUI.NXInputBox.GetInputNumber ( string  prompt,
string  caption,
double  initialNumber 
)
inlinestatic

Displays a simple text entry dialog to the user and returns the number the user enters.

Throws a FormatException if the input text does not form a valid number.

Throws an OverflowException if the input text is outside the valid range for doubles.

Parameters
promptPrompt string to the user for the text entry box.
captionCaption string for the window title to the text entry dialog.
initialNumberInitial double to use as a default number in the text entry box.
static string NXOpenUI.NXInputBox.GetInputString ( string  prompt)
inlinestatic

Displays a simple text entry dialog to the user and returns the string the user enters.

Parameters
promptPrompt string to the user for the text entry box.
static string NXOpenUI.NXInputBox.GetInputString ( string  prompt,
string  caption 
)
inlinestatic

Displays a simple text entry dialog to the user and returns the string the user enters.

Parameters
promptPrompt string to the user for the text entry box.
captionCaption string for the window title to the text entry dialog.
static string NXOpenUI.NXInputBox.GetInputString ( string  prompt,
string  caption,
string  initialText 
)
inlinestatic

Displays a simple text entry dialog to the user and returns the string the user enters.

Parameters
promptPrompt string to the user for the text entry box.
captionCaption string for the window title to the text entry dialog.
initialTextInitial text to use as default text in the text entry box.
static System.Boolean NXOpenUI.NXInputBox.ParseInputNumber ( string  prompt,
string  caption,
string  initialText,
System.Globalization.NumberStyles  style,
System.IFormatProvider  provider,
out double  result 
)
inlinestatic

Displays a simple text entry dialog to the user, parses the string the user enters, and if it is a valid number, sets result to the value the user entered and returns true.

Throws a FormatException if the input text does not form a valid number.

Throws an OverflowException if the input text is outside the valid range for doubles.

Parameters
promptPrompt string to the user for the text entry box.
captionCaption string for the window title to the text entry dialog.
initialTextInitial text to use as default text in the text entry box.

This initial text should form a valid double number.

Parameters
styleThe permitted format of the input number defined as a combination of one or more System.Globalization.NumberStyles constants.
providerA format provider that defines the valid culture-specific format for the input number.
resultAn out parameter containing the parsed number input by the user. If the method returns true, result contains a valid double number.
static System.Boolean NXOpenUI.NXInputBox.ParseInputNumber ( string  prompt,
string  caption,
double  initialNumber,
System.Globalization.NumberStyles  style,
System.IFormatProvider  provider,
out double  result 
)
inlinestatic

Displays a simple text entry dialog to the user and returns the string the user enters.

Throws a FormatException if the input text does not form a valid number.

Throws an OverflowException if the input text is outside the valid range for doubles.

Parameters
promptPrompt string to the user for the text entry box.
captionCaption string for the window title to the text entry dialog.
initialNumberInitial double to use as a default number in the text entry box.
styleThe permitted format of the input number defined as a combination of one or more System.Globalization.NumberStyles constants.
providerA format provider that defines the valid culture-specific format for the input number.
resultAn out parameter containing the parsed number input by the user. If the method returns true, result contains a valid double number.

The documentation for this class was generated from the following file:
Copyright 2019 Siemens Product Lifecycle Management Software Inc. All Rights Reserved.