Show / Hide Table of Contents

Method dialog.showInputNumber


Overload

Shows dialog with a number edit field and gets that number.

public static bool showInputNumber(out int i, string text1 = null, string text2 = null, int? editText = null, DFlags flags = 0, AnyWnd owner = default)
Parameters
i  (int)

Variable that receives the number.

text1  (string)

Main instruction. Bigger font.

text2  (string)

Read-only text below main instruction, above the edit field.

editText  (int?)

Initial edit field text.

flags  (DFlags)
owner  (AnyWnd)

Owner window. See dialog.SetOwnerWindow.

Returns
bool

true if selected OK.

Exceptions
Win32Exception

Failed to show dialog.

Remarks

Calls dialog.showInput and converts string to int.

Examples

int i;
if(!dialog.showInputNumber(out i, "Example")) return;
print.it(i);