mvm_gui_set_htmlT_mvm_gui_set_htmlMvmGuiSetHtmlMvmGuiSetHtml (Operator)

Name

mvm_gui_set_htmlT_mvm_gui_set_htmlMvmGuiSetHtmlMvmGuiSetHtml — Set inner HTML of an HTML element.

Signature

mvm_gui_set_html( : : ServerHandle, ConnectionHandle, HtmlId, Tuple : )

Herror T_mvm_gui_set_html(const Htuple ServerHandle, const Htuple ConnectionHandle, const Htuple HtmlId, const Htuple Tuple)

void MvmGuiSetHtml(const HTuple& ServerHandle, const HTuple& ConnectionHandle, const HTuple& HtmlId, const HTuple& Tuple)

static void HHdevguiServerExtpack.MvmGuiSetHtml(HTuple serverHandle, HTuple connectionHandle, HTuple htmlId, HTuple tuple)

Description

Sets the inner HTML of an HTML element specified by HtmlIdHtmlIdHtmlIdHtmlIdhtmlId for a connected webclient specified by ConnectionHandleConnectionHandleConnectionHandleConnectionHandleconnectionHandle.

Multiple connections can be specified as tuple. A ConnectionHandleConnectionHandleConnectionHandleConnectionHandleconnectionHandle with the value 'all'"all""all""all""all" means that the message is sent to all connected clients and is the default. A value of 'first'"first""first""first""first" addresses only the first connection. Additionally, an optional custom error handling can be specified in ConnectionHandleConnectionHandleConnectionHandleConnectionHandleconnectionHandle. For further explanations on connection handles and custom error handling, see the MachineVisionMakers / HDevGUI chapter documentation for this extension package.

The HTML ID HtmlIdHtmlIdHtmlIdHtmlIdhtmlId must match the ID of an existing HTML element.

The following is an example HTML target element: <div id="myHtmlTarget">

If the option ackTimeoutMillis is set to a positive value (default), the operator mvm_gui_set_htmlmvm_gui_set_htmlMvmGuiSetHtmlMvmGuiSetHtmlMvmGuiSetHtml waits for an acknowledge package from the client. If there is no acknowledge package within the given timeout the operator mvm_gui_set_htmlmvm_gui_set_htmlMvmGuiSetHtmlMvmGuiSetHtmlMvmGuiSetHtml returns with error code HDGERR_SERVER_ACK_TIMEOUT. If the HTML ID HtmlIdHtmlIdHtmlIdHtmlIdhtmlId was not found in the client HTML code, the error code HDGERR_SERVER_ACK_NOT_HANDLED will be returned.

Execution Information

Parameters

ServerHandleServerHandleServerHandleServerHandleserverHandle (input_control)  serial HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

GUI server handle

ConnectionHandleConnectionHandleConnectionHandleConnectionHandleconnectionHandle (input_control)  socket(-array) HTupleHTupleHtuple (handle / string) (IntPtr / IntPtr) (HHandle / HString) (handle / char*)

The destination connection handle

Default value: 'all' "all" "all" "all" "all"

List of values: 'ack_error_ignore'"ack_error_ignore""ack_error_ignore""ack_error_ignore""ack_error_ignore", 'ack_error_lowlevel'"ack_error_lowlevel""ack_error_lowlevel""ack_error_lowlevel""ack_error_lowlevel", 'ack_error_raise'"ack_error_raise""ack_error_raise""ack_error_raise""ack_error_raise", 'all'"all""all""all""all", 'connection_error_ignore'"connection_error_ignore""connection_error_ignore""connection_error_ignore""connection_error_ignore", 'connection_error_lowlevel'"connection_error_lowlevel""connection_error_lowlevel""connection_error_lowlevel""connection_error_lowlevel", 'connection_error_raise'"connection_error_raise""connection_error_raise""connection_error_raise""connection_error_raise", 'first'"first""first""first""first"

HtmlIdHtmlIdHtmlIdHtmlIdhtmlId (input_control)  string HTupleHTupleHtuple (string) (string) (HString) (char*)

HTML element ID

TupleTupleTupleTupletuple (input_control)  integer(-array) HTupleHTupleHtuple (string / integer / real) (string / int / long / double) (HString / Hlong / double) (char* / Hlong / double)

The tuple to be sent

Example (HDevelop)

mvm_gui_set_html (ServerHandle, 'all', 'message', '<span style="color: yellow;">Warning: No part could be found!</span>')

See also

mvm_gui_send_tuplemvm_gui_send_tupleMvmGuiSendTupleMvmGuiSendTupleMvmGuiSendTuple

Module

Foundation