I'm fairly new to working with OS X widgets and wanted to create a simple widget for myself which should simply get the stringValue of a textbox, add it to a fixed string and open this in a browser.
I already figured out the last part can be done with widget.openURL(string) but the rest is too confusing for me. I could not find any usefull code completion, neither did my experience in Obj-C or any other language help a bit.
To retrieve the value once you have the textbox part, you just get its value member:
textBox.value
.For example, you can search the DOM for the element by the ID which you set for the textbox in the Dashcode Inspector.
If your text box is editable, you can just set the value.
To set the value for text parts which aren't editable like buttons or labels, set the
innerText
of the part.