Interface MessageContainer
- All Known Subinterfaces:
ArticleControl
,AsideControl
,BarcodeControl
,BasicBlockControl
,BootstrapColumnControl
,BootstrapContainerControl
,BootstrapRowControl
,ButtonColumnControl
,ButtonControl
,CanvasControl
,ContainerControl
,Control
,DynamicMenuItemControl
,EbaseButtonControlProperties
,FieldColumnControl
,FieldControl
,FileUploadControl
,FileUploadTextControl
,FinishButtonControl
,FooterControl
,GridCellControl
,GridControl
,GroupAndPagePanelProperties
,GroupPanelControl
,HeaderControl
,HeadingControl
,HorizontalLineControl
,HorizontalMenuControl
,HTMLControl
,HyperlinkControl
,ImageColumnControl
,ImageControl
,IncludeControl
,InitiateUploadControl
,LayoutControl
,ListControl
,ListHyperlinkControl
,ListItemControl
,ListPanelControl
,ListTextControl
,MainControl
,MenuControl
,MenuItemControl
,MessageControl
,NavControl
,NextPageButtonControl
,Page
,PageBreakControl
,PageControl
,PageNavigationPanel
,PagePanelControl
,PanelControl
,PrevPageButtonControl
,RepeatingTableControl
,RepeatingTableListControl
,RepeatingTableListRowControl
,RepeatingTableRowControl
,RestoreButtonControl
,SaveButtonControl
,SectionControl
,SpacerControl
,StaticMenuItemControl
,TabControl
,TableControl
,TablePageControl
,TabSetControl
,TextControl
,TitlePanelControl
,VerticalMenuControl
,WebForm
,WebFormEventOwner
public interface MessageContainer
MessageContainer
represents any element (a Control
or Page
) that supports the addition of error and
warning messages.- Since:
- V4.4
-
Method Summary
Modifier and Type Method Description void
addErrorMessage(int messageNo)
Deprecated.void
addErrorMessage(int messageNo, java.lang.String[] replaceParameters)
Deprecated.From V5.0 useaddErrorMessageText(Text, String[])
insteadvoid
addErrorMessage(int messageNo, java.lang.String[] replaceParameters, boolean stopProcessing)
Deprecated.From V5.0 useaddErrorMessageText(Text, String[], boolean)
insteadvoid
addErrorMessage(java.lang.String message)
Adds an error message that will be displayed to the user.void
addErrorMessage(java.lang.String message, boolean stopProcessing)
Adds an error message that will be displayed to the user.void
addErrorMessageText(Text text)
Adds an error message that will be displayed to the user, sourced from an existing text.void
addErrorMessageText(Text text, java.lang.String[] replaceParameters)
Adds an error message that will be displayed to the user, sourced from an existing text.void
addErrorMessageText(Text text, java.lang.String[] replaceParameters, boolean stopProcessing)
Adds an error message that will be displayed to the user, sourced from an existing text.void
addInfoMessage(java.lang.String message)
Adds an information message that will be displayed to the user.void
addInfoMessage(java.lang.String message, boolean stopProcessing)
Adds an information message that will be displayed to the user.void
addInfoMessageText(Text text)
Adds an info message that will be displayed to the user, sourced from an existing text.void
addInfoMessageText(Text text, java.lang.String[] replaceParameters)
Adds an info message that will be displayed to the user, sourced from an existing text.void
addInfoMessageText(Text text, java.lang.String[] replaceParameters, boolean stopProcessing)
Adds an info message that will be displayed to the user, sourced from an existing text.void
addWarningMessage(int messageNo)
Deprecated.From V5.0 useaddWarningMessageText(Text)
insteadvoid
addWarningMessage(int messageNo, java.lang.String[] replaceParameters)
Deprecated.From V5.0 useaddWarningMessageText(Text, String[])
insteadvoid
addWarningMessage(int messageNo, java.lang.String[] replaceParameters, boolean stopProcessing)
Deprecated.From V5.0 useaddWarningMessageText(Text, String[], boolean)
insteadvoid
addWarningMessage(java.lang.String message)
Adds a warning message that will be displayed to the user Messages are removed automatically by the system once they have been displayed to the user.void
addWarningMessage(java.lang.String message, boolean stopProcessing)
Adds a warning message that will be displayed to the user.void
addWarningMessageText(Text text)
Adds a warning message that will be displayed to the user, sourced from an existing text.void
addWarningMessageText(Text text, java.lang.String[] replaceParameters)
Adds a warning message that will be displayed to the user, sourced from an existing text.void
addWarningMessageText(Text text, java.lang.String[] replaceParameters, boolean stopProcessing)
Adds a warning message that will be displayed to the user, sourced from an existing text.boolean
existErrorMessages()
Returnstrue
if undisplayed error messages exist for this element, otherwise returnsfalse
.boolean
existInfoMessages()
Returnstrue
if undisplayed info messages exist for this element, otherwise returnsfalse
.boolean
existMessages()
Returnstrue
if undisplayed info, warning or error messages exist for this element, otherwise returnsfalse
.boolean
existWarningMessages()
Returnstrue
if undisplayed warning messages exist for this element, otherwise returnsfalse
.
-
Method Details
-
addErrorMessage
void addErrorMessage(java.lang.String message)Adds an error message that will be displayed to the user. Messages are removed automatically by the system once they have been displayed to the user.This method is equivalent to
addErrorMessage(message, true)
.All processing for the current event is stopped immediately and the page is redisplayed to the user so the error can be corrected.
Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addErrorMessage("Please supply a valid reference code");
- Parameters:
message
- the message to be added- Since:
- V4.4
- See Also:
addErrorMessage(String, boolean)
,existErrorMessages()
-
addErrorMessage
void addErrorMessage(java.lang.String message, boolean stopProcessing)Adds an error message that will be displayed to the user. Messages are removed automatically by the system once they have been displayed to the user.When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user so the error can be corrected. WhenstopProcessing
isfalse
, processing continues normally, except that the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. theWebForm.gotoPage(Page)
method.Set
stopProcessing
tofalse
when there is a requirement to display multiple error messages on a page.EventContext.stopExecution()
can then be used at a later point to stop processing and display the messages to the user.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addErrorMessage("Please supply a valid reference code", false);
- Parameters:
message
- the message to be addedstopProcessing
- whentrue
, immediately stops processing for the current event- Since:
- V4.4
- See Also:
existErrorMessages()
,EventContext.stopExecution()
-
addErrorMessage
@Deprecated void addErrorMessage(int messageNo, java.lang.String[] replaceParameters) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionDeprecated.From V5.0 useaddErrorMessageText(Text, String[])
insteadAdds an error message that will be displayed to the user. This method supports the addition of a pre-defined message that supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.This method is equivalent to
addErrorMessage(messageNo, replaceParameters, true)
.A message is added using its message number. Numbered messages are defined within each project using the Messages Editor - double click on the Messages element within each project in the designer tree. Within each message, a substitutable variable is identified by &&. Any substitutable variables in the message are replaced with values in the
replaceParameters
parameter (see example below).All processing for the current event is stopped immediately and the page is redisplayed to the user so the error can be corrected.
Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addErrorMessage(1006, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value]);
If message 1006 in languageEN
contains text:
Order type && is invalid for customer type &&
this might be displayed as:
Order type CREDIT is invalid for customer type PUBLIC- Parameters:
messageNo
- the message number to be addedreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V4.4
- See Also:
addErrorMessage(String)
,existErrorMessages()
-
addErrorMessage
@Deprecated void addErrorMessage(int messageNo) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionDeprecated.From V5.0 useaddErrorMessageText(Text)
insteadAdds an error message that will be displayed to the user. This method is equivalent toaddErrorMessage(messageNo, null)
.- Parameters:
messageNo
- the message number to be added- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V4.4
- See Also:
addErrorMessage(String)
-
addErrorMessage
@Deprecated void addErrorMessage(int messageNo, java.lang.String[] replaceParameters, boolean stopProcessing) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionDeprecated.From V5.0 useaddErrorMessageText(Text, String[], boolean)
insteadAdds an error message that will be displayed to the user. This method supports the addition of a pre-defined message that supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.A message is added using its message number. Numbered messages are defined within each project using the Messages Editor - double click on the Messages element within each project in the designer tree. Within each message, a substitutable variable is identified by &&. Any substitutable variables in the message are replaced with values in the
replaceParameters
parameter (see example below).When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user so the error can be corrected. WhenstopProcessing
isfalse
, processing continues normally, except that the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. theWebForm.gotoPage(Page)
method.Set
stopProcessing
tofalse
when there is a requirement to display multiple error messages on a page.EventContext.stopExecution()
can then be used at a later point to stop processing and display the messages to the user.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addErrorMessage(1006, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value], false);
If message 1006 in languageEN
contains text:
Order type && is invalid for customer type &&
this might be displayed as:
Order type CREDIT is invalid for customer type PUBLIC- Parameters:
messageNo
- the message number to be addedreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&stopProcessing
- whentrue
, immediately stops processing for the current event- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V4.4
- See Also:
addErrorMessage(String)
,existErrorMessages()
,EventContext.stopExecution()
-
addErrorMessageText
Adds an error message that will be displayed to the user, sourced from an existing text. This method is equivalent toaddErrorMessageText(text, null)
.- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts files- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.0
- See Also:
addErrorMessage(String)
-
addErrorMessageText
void addErrorMessageText(Text text, java.lang.String[] replaceParameters) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionAdds an error message that will be displayed to the user, sourced from an existing text. This method supports the addition of a message from a configured text and supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.This method is equivalent to
addErrorMessageText(text, replaceParameters, true)
.Any accessible text can be displayed as a message; this includes local texts defined using the form/component text editor and linked texts which exist in linked texts files. Within each text, a substitutable variable is identified by &&. Any substitutable variables in the text are replaced with values in the
replaceParameters
parameter (see example below).All processing for the current event is stopped immediately and the page is redisplayed to the user so the error can be corrected.
Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addErrorMessageText(texts.Txt29, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value]);
If text Txt29 in languageEN
contains text:
Order type && is invalid for customer type &&
this might be displayed as:
Order type CREDIT is invalid for customer type PUBLIC- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts filesreplaceParameters
- an array of values to replace any substitutable parameters in the text defined as &&- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.0
- See Also:
addErrorMessage(String)
,existErrorMessages()
-
addErrorMessageText
void addErrorMessageText(Text text, java.lang.String[] replaceParameters, boolean stopProcessing) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionAdds an error message that will be displayed to the user, sourced from an existing text. This method supports the addition of a message from a configured text and supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.Any accessible text can be displayed as a message; this includes local texts defined using the form/component text editor and linked texts which exist in linked texts files. Within each text, a substitutable variable is identified by &&. Any substitutable variables in the text are replaced with values in the
replaceParameters
parameter (see example below).When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user so the error can be corrected. WhenstopProcessing
isfalse
, processing continues normally, except that the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. theWebForm.gotoPage(Page)
method.Set
stopProcessing
tofalse
when there is a requirement to display multiple error messages on a page.EventContext.stopExecution()
can then be used at a later point to stop processing and display the messages to the user.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addErrorMessageText(texts.Txt29, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value], false);
If text Txt29 in languageEN
contains text:
Order type && is invalid for customer type &&
this might be displayed as:
Order type CREDIT is invalid for customer type PUBLIC- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts filesreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&stopProcessing
- whentrue
, immediately stops processing for the current event- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.0
- See Also:
addErrorMessage(String)
,existErrorMessages()
,EventContext.stopExecution()
-
addWarningMessage
void addWarningMessage(java.lang.String message)Adds a warning message that will be displayed to the user Messages are removed automatically by the system once they have been displayed to the user.This method is equivalent to
addWarningMessage(message, false)
.When a warning or error message exists on a page, the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. the
WebForm.gotoPage(Page)
method.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addWarningMessage("Extra charges apply for this service");
- Parameters:
message
- the message to be added- Since:
- V4.4
- See Also:
addWarningMessage(String, boolean)
,existWarningMessages()
-
addWarningMessage
void addWarningMessage(java.lang.String message, boolean stopProcessing)Adds a warning message that will be displayed to the user. Messages are removed automatically by the system once they have been displayed to the user.When a warning or error message exists on a page, the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. the
WebForm.gotoPage(Page)
method.When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addWarningMessage("Extra charges apply for this service", false);
- Parameters:
message
- the message to be addedstopProcessing
- whentrue
, immediately stops processing for the current event- Since:
- V4.4
- See Also:
existWarningMessages()
-
addWarningMessage
@Deprecated void addWarningMessage(int messageNo) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionDeprecated.From V5.0 useaddWarningMessageText(Text)
insteadAdds a warning message that will be displayed to the user. This method is equivalent toaddWarningMessage(messageNo, null)
.- Parameters:
messageNo
- the message number to be added- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V4.4
- See Also:
addWarningMessage(String)
-
addWarningMessage
@Deprecated void addWarningMessage(int messageNo, java.lang.String[] replaceParameters) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionDeprecated.From V5.0 useaddWarningMessageText(Text, String[])
insteadAdds a warning message that will be displayed to the user. This method supports the addition of a pre-defined message that supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.This method is equivalent to
addWarningMessage(messageNo, replaceParameters, false)
.A message is added using its message number. Numbered messages are defined within each project using the Messages Editor - double click on the Messages element within each project in the designer tree. Within each message, a substitutable variable is identified by &&. Any substitutable variables in the message are replaced with values in the
replaceParameters
parameter (see example below).When a warning or error message exists on a page, the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. the
WebForm.gotoPage(Page)
method.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addWarningMessage(1006, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value]);
If message 1006 in languageEN
contains text:
An additional charge of && applies to this service
this might be displayed as:
An additional charge of $100.00 applies to this service- Parameters:
messageNo
- the message number to be addedreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V4.4
- See Also:
addWarningMessage(String)
,existWarningMessages()
-
addWarningMessage
@Deprecated void addWarningMessage(int messageNo, java.lang.String[] replaceParameters, boolean stopProcessing) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionDeprecated.From V5.0 useaddWarningMessageText(Text, String[], boolean)
insteadAdds a warning message that will be displayed to the user. This method supports the addition of a pre-defined message that supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.A message is added using its message number. Numbered messages are defined within each project using the Messages Editor - double click on the Messages element within each project in the designer tree. Within each message, a substitutable variable is identified by &&. Any substitutable variables in the message are replaced with values in the
replaceParameters
parameter (see example below).When a warning or error message exists on a page, the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. the
WebForm.gotoPage(Page)
method.When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addWarningMessage(1006, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value], false);
If message 1006 in languageEN
contains text:
An additional charge of && applies to this service
this might be displayed as:
An additional charge of $100.00 applies to this service- Parameters:
messageNo
- the message number to be addedreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&stopProcessing
- whentrue
, immediately stops processing for the current event- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V4.4
- See Also:
addWarningMessage(String)
,existWarningMessages()
-
addWarningMessageText
Adds a warning message that will be displayed to the user, sourced from an existing text. This method is equivalent toaddWarningMessageText(text, null)
.- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts files- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.0
- See Also:
addWarningMessage(String)
-
addWarningMessageText
void addWarningMessageText(Text text, java.lang.String[] replaceParameters) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionAdds a warning message that will be displayed to the user, sourced from an existing text. This method supports the addition of a message from a configured text and supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.This method is equivalent to
addWarningMessageText(text, replaceParameters, true)
.Any accessible text can be displayed as a message; this includes local texts defined using the form/component text editor and linked texts which exist in linked texts files. Within each text, a substitutable variable is identified by &&. Any substitutable variables in the text are replaced with values in the
replaceParameters
parameter (see example below).When a warning or error message exists on a page, the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. the
WebForm.gotoPage(Page)
method.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addWarningMessageText(texts.Txt29, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value]);
If text Txt29 in languageEN
contains text:
An additional charge of && applies to this service
this might be displayed as:
An additional charge of $100.00 applies to this service- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts filesreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.0
- See Also:
addWarningMessage(String)
,addWarningMessageText(Text, String[], boolean)
,existWarningMessages()
-
addWarningMessageText
void addWarningMessageText(Text text, java.lang.String[] replaceParameters, boolean stopProcessing) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionAdds a warning message that will be displayed to the user, sourced from an existing text. This method supports the addition of a message from a configured text and supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.Any accessible text can be displayed as a message; this includes local texts defined using the form/component text editor and linked texts which exist in linked texts files. Within each text, a substitutable variable is identified by &&. Any substitutable variables in the text are replaced with values in the
replaceParameters
parameter (see example below).When a warning or error message exists on a page, the user is prevented from navigating forwards to another page using a Next Page Button Control or the next page button within a Page Navigation Panel Control. Note that the same restriction does not apply when navigating to another page using other methods e.g. the
WebForm.gotoPage(Page)
method.When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addWarningMessageText(texts.Txt29, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value], false);
If text Txt29 in languageEN
contains text:
An additional charge of && applies to this service
this might be displayed as:
An additional charge of $100.00 applies to this service- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts filesreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&stopProcessing
- whentrue
, immediately stops processing for the current event- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.0
- See Also:
addWarningMessage(String)
,existWarningMessages()
-
addInfoMessage
void addInfoMessage(java.lang.String message)Adds an information message that will be displayed to the user. Messages are removed automatically by the system once they have been displayed to the user.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addInfoMessage("The document has been updated");
- Parameters:
message
- the message to be added- Since:
- V5.3
- See Also:
addInfoMessage(String, boolean)
,existInfoMessages()
-
addInfoMessage
void addInfoMessage(java.lang.String message, boolean stopProcessing)Adds an information message that will be displayed to the user. Messages are removed automatically by the system once they have been displayed to the user.When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user. WhenstopProcessing
isfalse
, processing continues normally.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addInfoMessage("Account saved", true);
- Parameters:
message
- the message to be addedstopProcessing
- whentrue
, immediately stops processing for the current event- Since:
- V5.3
- See Also:
existInfoMessages()
,EventContext.stopExecution()
-
addInfoMessageText
Adds an info message that will be displayed to the user, sourced from an existing text. This method is equivalent toaddInfoMessageText(text, null)
.- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts files- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.3
- See Also:
addInfoMessage(String)
-
addInfoMessageText
void addInfoMessageText(Text text, java.lang.String[] replaceParameters) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionAdds an info message that will be displayed to the user, sourced from an existing text. This method supports the addition of a message from a configured text and supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.This method is equivalent to
addInfoMessageText(text, replaceParameters, true)
.Any accessible text can be displayed as a message; this includes local texts defined using the form/component text editor and linked texts which exist in linked texts files. Within each text, a substitutable variable is identified by &&. Any substitutable variables in the text are replaced with values in the
replaceParameters
parameter (see example below).Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addInfoMessageText(texts.Txt29, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value]);
If text Txt29 in languageEN
contains text:
Order && updated for customer &&
this might be displayed as:
Order 1234567 updated for customer Acme Enterprises- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts filesreplaceParameters
- an array of values to replace any substitutable parameters in the text defined as &&- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.3
- See Also:
addInfoMessage(String)
,existInfoMessages()
-
addInfoMessageText
void addInfoMessageText(Text text, java.lang.String[] replaceParameters, boolean stopProcessing) throws com.ebasetech.xi.exceptions.FormRuntimeExceptionAdds an info message that will be displayed to the user, sourced from an existing text. This method supports the addition of a message from a configured text and supports multiple languages and the substitution of variables. Messages are removed automatically by the system once they have been displayed to the user.Any accessible text can be displayed as a message; this includes local texts defined using the form/component text editor and linked texts which exist in linked texts files. Within each text, a substitutable variable is identified by &&. Any substitutable variables in the text are replaced with values in the
replaceParameters
parameter (see example below).When
stopProcessing
istrue
, all processing for the current event is stopped immediately and the page is redisplayed to the user. WhenstopProcessing
isfalse
, processing continues normally.Messages can be displayed either locally to the message owner (a control or page) or at another location on the same page represented by a Message Control. For further information on the location and styling of messages, please see the online documentation available from the Help menu, search on message options, then follow the link to Message Options For Controls.
Javascript example:
event.owner.addInfoMessageText(texts.Txt29, [fields.ORDER_TYPE.value, fields.CUSTOMER_TYPE.value], true);
If text Txt29 in languageEN
contains text:
Order && updated for customer &&
this might be displayed as:
Order 1234567 updated for customer Acme Enterprises- Parameters:
text
- the text to be added as a message, texts can be defined in form/component texts or in linked texts filesreplaceParameters
- an array of values to replace any substitutable parameters in the message defined as &&stopProcessing
- whentrue
, immediately stops processing for the current event- Throws:
com.ebasetech.xi.exceptions.FormRuntimeException
- Since:
- V5.3
- See Also:
addInfoMessage(String)
,existInfoMessages()
,EventContext.stopExecution()
-
existErrorMessages
boolean existErrorMessages()Returnstrue
if undisplayed error messages exist for this element, otherwise returnsfalse
. Undisplayed error messages will be displayed when the page is next presented to the user.- Since:
- V4.4
-
existWarningMessages
boolean existWarningMessages()Returnstrue
if undisplayed warning messages exist for this element, otherwise returnsfalse
. Undisplayed warning messages will be displayed when the page is next presented to the user.- Since:
- V4.4
-
existInfoMessages
boolean existInfoMessages()Returnstrue
if undisplayed info messages exist for this element, otherwise returnsfalse
. Undisplayed info messages will be displayed when the page is next presented to the user.- Since:
- V5.3
-
existMessages
boolean existMessages()Returnstrue
if undisplayed info, warning or error messages exist for this element, otherwise returnsfalse
. Undisplayed messages will be displayed when the page is next presented to the user.- Since:
- V4.5.1
-
addErrorMessageText(Text)
instead