Available in:
Apps (win)
Apps (char)
Reportwriter
RPC
Standalone PL
X
void gui_util(command[,parameter]) int command expr parameter
Command | Description | Parameter |
gui_util_aclist | Sets the autocompletion dictionary. See example below. | List of dictionary words, one word per line. |
gui_util_call_parent | Calls the DVJScall function with the supplied parameter. | Parameter to pass to DVJScall(). |
gui_util_clr_lastact | Clears the last stacked action. | N/A |
gui_util_diaper | Sets the tooltip, menu, and context menu popup mode. MS .NET mode (False, default) has a popup memory leak that causes extreme garbage collection processing. Setting True looks in dv.xaml for dv_diaper_list, used for menus, or dv_diaper_text styles, tooltips. If not found the default for dv_diaper_list is foreground DarkBlue, dv_diaper_text foreground Cyan, background DarkBlue. The popup is then built using this style and avoids the memory leak. | True (1) or False (0) |
gui_util_garbage | Invokes the garbage collection. | N/A |
gui_util_heartbeat | Sets the heartbeat timeout value. | Value in milliseconds |
gui_util_help_winname | Sets the help window name. | Window name |
gui_util_key_cache | Clears and optionally configures the keystroke stack. | Optional parameter is a string "m [n]". m is the maximum number of keys in the cache stack (default 500). n is the maximum number of consecutive identical keys that will be batched with the count returned in G.aux (default 1). |
gui_util_kill_cookie | Removes the DVJS_COOKIE. | N/A |
gui_util_killwin_prompt | Sets the kill window prompt. If set, then DVJS will open a prompt box when the user tried to close the window via Alt-F4 or the X. To reset, send the command with no parameter. | String to display in the prompt |
gui_util_string | Sends a string to the evSendString handler (WPF) | String to send |
gui_util_tooltip | Sets or resets the tooltip associated with the element(WPF). See also field_tooltip. | String with "element ID tooltip". If element ID is not given, then it defaults to 0. If element ID is higher than any matching element ID, then it defaults to the last element. For example, gui_util(gui_util_tooltip,"This is a tooltip"); sets the first element's tooltip. gui_util(gui_util_tooltip,"2 This is a tooltip"); sets the third element's tooltip. |
gui_util_topmost | Sets or resets the window to be topmost (WPF) | True (1) or False (0) |
gui_util_winicon | Sets the name of the image to display as the window icon | String with the imagename, either preloaded or a URI reference |
gui_util(gui_util_heartbeat,prompt("Heartbeat timeout -> "));Create autocompletion for a field.
1. Set the Auto Complete attribute in the dvApp Define Field dialog.
2. In the field's Validation trigger,
if ((G.key == pev_window) && (G.aux == wev_autocomp)) load_aclist(upper(parm.0) ^^ "%");load_aclist:
{ #define max_items 200 list LL; LL = list_open("select unique city from zipcodes " "where upper(city) like &parm.0",max_items+1); if (list_rows(LL) > 1 && list_rows(LL) <= max_items) { clipboard(cb_free); /* just in case */ list_file(LL,"clipboard!","as"); gui_util(gui_util_aclist,clipboard(cb_extract)); } list_close(LL); }