Skip to the content.

PromptPlus API:IControlMaskEdit

Build Publish License NuGet Downloads

Back to List Api

IControlMaskEdit

Namespace: PPlus.Controls

Represents the interface with all Methods of the MaskEdit control

public interface IControlMaskEdit : IPromptControls<ResultMasked>

Implements IPromptControls<ResultMasked>

Methods

AcceptEmptyValue(Boolean)

Accept empty value
Valid only for type not equal MaskedType.Generic, otherwise this set will be ignored.

IControlMaskEdit AcceptEmptyValue(bool value)

Parameters

value Boolean
Accept empty value

Returns

IControlMaskEdit

AddValidators(params Func<Object, ValidationResult>[])

Add a validator to accept sucessfull finish of control.
Tip: see to validators embedding

IControlMaskEdit AddValidators(params Func<Object, ValidationResult>[] validators)

Parameters

validators Func<Object, ValidationResult>[]
the function validator.

Returns

IControlMaskEdit

AmmoutPositions(Int32, Int32, Boolean)

Defines integer length, decimal length and accept signl.
Valid only for type MaskedType.Number or Currency, otherwise this set will be ignored.
This set is Requeried for these types.

IControlMaskEdit AmmoutPositions(int intvalue, int decimalvalue, bool acceptSignal)

Parameters

intvalue Int32
integer length

decimalvalue Int32
decimal length

acceptSignal Boolean
True accept signal; otherwise, no.

Returns

IControlMaskEdit

ChangeDescription(Func<String, String>)

Dynamically change the description using a user role

IControlMaskEdit ChangeDescription(Func<String, String> value)

Parameters

value Func<String, String>
function to apply change

Returns

IControlMaskEdit

Config(Action<IPromptConfig>)

Custom config the control.

IControlMaskEdit Config(Action<IPromptConfig> context)

Parameters

context Action<IPromptConfig>
action to apply changes. IPromptConfig

Returns

IControlMaskEdit

Culture(CultureInfo)

CultureInfo to validate input when the type is not generic.
Default value is global Promptplus Cultureinfo

IControlMaskEdit Culture(CultureInfo value)

Parameters

value CultureInfo
CultureInfo to use on validate

Returns

IControlMaskEdit

Culture(String)

CultureInfo to validate input when the type is not generic.
Default value is global Promptplus Cultureinfo

IControlMaskEdit Culture(string value)

Parameters

value String
Name of CultureInfo to use on validate

Returns

IControlMaskEdit

Default(String)

Default value (with mask!) when stated.

IControlMaskEdit Default(string value)

Parameters

value String
Value default

Returns

IControlMaskEdit

DefaultIfEmpty(String, Boolean)

Default value (with mask!) when finished value is empty.

IControlMaskEdit DefaultIfEmpty(string value, bool zeroIsEmpty)

Parameters

value String
Finished value default

zeroIsEmpty Boolean
Valid only for type MaskedType.Number or MaskedType.Currency, otherwise this set will be ignored.

Returns

IControlMaskEdit

FillZeros(Boolean)

Fill zeros mask.Default false.
Not valid for type MaskedType.Generic (this set will be ignored).
When used this feature the AcceptEmptyValue feature will be ignored.
When MaskedType.Number or MaskedType.Currency this feature is always on.

IControlMaskEdit FillZeros(bool value)

Parameters

value Boolean
Fill zeros mask

Returns

IControlMaskEdit

FormatTime(FormatTime)

Defines time parts input.
Valid only for type MaskedType.TimeOnly or DateTime, otherwise this set will be ignored.

IControlMaskEdit FormatTime(FormatTime value)

Parameters

value FormatTime
FormatTime

Returns

IControlMaskEdit

FormatYear(FormatYear)

Defines if year is long or short.
Valid only for type MaskedType.DateOnly or DateTime, otherwise this set will be ignored.

IControlMaskEdit FormatYear(FormatYear value)

Parameters

value FormatYear
FormatYear

Returns

IControlMaskEdit

HistoryEnabled(String)

Enabled saved history inputs.
The history file is saved in in the ‘PromptPlus.History’ folder.

IControlMaskEdit HistoryEnabled(string value)

Parameters

value String
name of file to saved history

Returns

IControlMaskEdit

HistoryMaxItems(Byte)

Set maximum items saved on history.After maximum the items are rotates.

IControlMaskEdit HistoryMaxItems(byte value)

Parameters

value Byte
maximum items saved

Returns

IControlMaskEdit

HistoryMinimumPrefixLength(Int32)

Minimum chars to enabled history feature. Default value is 0.
History items are filtered by the starts with entry.
When command FilterType set to Disabled History items the value must be zero

IControlMaskEdit HistoryMinimumPrefixLength(int value)

Parameters

value Int32
Minimum chars number

Returns

IControlMaskEdit

HistoryPageSize(Int32)

Set max.item view per page on history.Default value for this control is 10.

IControlMaskEdit HistoryPageSize(int value)

Parameters

value Int32
Number of Max.items

Returns

IControlMaskEdit

HistoryTimeout(TimeSpan)

Set timeout to valid items saved on history. Default value is 365 days.

IControlMaskEdit HistoryTimeout(TimeSpan value)

Parameters

value TimeSpan
timeout value

Returns

IControlMaskEdit

InputToCase(CaseOptions)

Transform char input using CaseOptions.

IControlMaskEdit InputToCase(CaseOptions value)

Parameters

value CaseOptions
Transform option

Returns

IControlMaskEdit

Mask(String, Nullable<Char>)

Defines mask input. Rules for Generic type:
9 - Only a numeric character
L - Only a letter
C - OnlyCustom character
A - Any character
N - OnlyCustom character + Only a numeric character
X - OnlyCustom character + Only a letter
\ - Escape character
{ - Initial delimiter for repetition of masks
} - Final delimiter for repetition of masks
[-Initial delimiter for list of Custom character
] - Final delimiter for list of Custom character

IControlMaskEdit Mask(string value, Nullable<Char> promptmask)

Parameters

value String
text of masked.

promptmask Nullable<Char>
Prompt mask overwriter. Default value is ‘■’/’_’

Returns

IControlMaskEdit

Mask(MaskedType, Nullable<Char>)

Defines type of mask control.

IControlMaskEdit Mask(MaskedType maskedType, Nullable<Char> promptmask)

Parameters

maskedType MaskedType
MaskedType

promptmask Nullable<Char>
Prompt mask overwriter. Default value is ‘■’/’_’

Returns

IControlMaskEdit

OverwriteDefaultFrom(String, Nullable<TimeSpan>)

Overwrite default start value with last result saved on history.

IControlMaskEdit OverwriteDefaultFrom(string value, Nullable<TimeSpan> timeout)

Parameters

value String
name of file to save history

timeout Nullable<TimeSpan>
The timeout for valid items saved. Default value is 365 days

Returns

IControlMaskEdit

ShowTipInputType(FormatWeek)

Show the tip of type input.

IControlMaskEdit ShowTipInputType(FormatWeek week)

Parameters

week FormatWeek
show name of week for type date. FormatWeek

Returns

IControlMaskEdit

Styles(MaskEditStyles, Style)

Overwrite Styles

IControlMaskEdit Styles(MaskEditStyles content, Style value)

Parameters

content MaskEditStyles
The MaskEditStyles content

value Style
The Style to apply

Returns

IControlMaskEdit

SuggestionHandler(Func<SuggestionInput, SuggestionOutput>)

Add Suggestion (with mask!) Handler feature

IControlMaskEdit SuggestionHandler(Func<SuggestionInput, SuggestionOutput> value)

Parameters

value Func<SuggestionInput, SuggestionOutput>
function to apply suggestions. SuggestionInput and SuggestionOutput

Returns

IControlMaskEdit

ValidateOnDemand(Boolean)

Execute validators foreach input

IControlMaskEdit ValidateOnDemand(bool value)

Parameters

value Boolean
true execute validators foreach input; otherwise, only at finish.

Returns

IControlMaskEdit


Back to List Api