Code: Select all
<?xml version="1.0" encoding="iso-8859-1"?>
<application id="app">
<window id="win" title="Tasks" height="800" width="900">
<vgroup>
<hgroup>
<choice id="datefilter">
<item>All</item>
<item>Past</item>
<item>Today</item>
<item>Days 1 to 7</item>
<item>Days 8 to 39</item>
<item>Days 40 to 364</item>
<item>Days from 365</item>
</choice>
<button id="applydatefilter">Apply Date filter (open tasks only)</button>
<text id="filter">Additional Filter</text>
</hgroup>
<treeview id="tv" height="600" notify="active">
<column title="Priority"/>
<column title="Title"/>
<column title="Due Date"/>
<column title="Due Time"/>
<column title="Category"/>
<node id="tasks" name="My Tasks">
<node id="open" name="Open Tasks">
</node>
<node id="closed" name="Closed Tasks">
</node>
</node>
</treeview>
<texteditor id="kommentar" notify="cursorpos;undoavailable;redoavailable;italic;bold;underline;areamarked;haschanged" styled="true" nowrap="true"/>
<hgroup>
<button id="newtask">New Task</button>
<button id="edittask">Edit Task</button>
<button id="delete">Delete selected</button>
<button id="undo">Undo Delete/Edit</button>
</hgroup>
<hgroup>
<button id="sort">Sort by</button>
<button id="openclosed">Toggle Open/Closed</button>
<button id="admin">Admin</button>
</hgroup>
</vgroup>
</window>
</application>
<text id="filter">Additional Filter</text>
I tried it the following ways
first
Code: Select all
local filterText = rap.GUI.getTextById("filter") ;-- Get the current text of the text field
filterText = "New Text" ;-- Assign the new text
rap.GUI.setTextById("filter", filterText) ;-- Set the new text to the text field using the assigned variablesecond
Code: Select all
local win = rap.GUI.getWindowById("win") ;-- Get the window
local filterText = win:getChildById("filter") ;-- Get the text field
filterText:setText("New Text") ;-- Set the new text for the text field
Error in line 337 (TaskManager_WIP.hws): Table rap{} not found!
Any idea?