
Interface Injectable
Description
In BBj 8.0 and higher, a BBjControl implements the Injectable interface if the control has the setInjectString and getInjectString methods, corresponding to the INJECT Mnemonic.
Implementing Classes
BBjButton, BBjMenuButton, BBjToolButton
Methods of Injectable
Return Value |
Method |
string |
|
void |
setInjectString(string injectString) |
Remarks
None.
Example
Copy
Interface Injectable Example
rem ' Interface Injectable (setInjectString, getInjectString)
declare BBjSysGui sysgui!
declare BBjWindow window!
declare Injectable button!
sysgui = unt
open (sysgui)"X0"
sysgui! = bbjapi().getSysGui()
window! = sysgui!.addWindow(100,100,200,75,"Injectable",$00090003$,$$)
button! = window!.addButton(101,50,25,100,25,"Button",$$)
inject$ = "xyzzy"
print "button!.setInjectString: ",inject$
button!.setInjectString(inject$)
print "button!.getInjectString: ",
print button!.getInjectString()
print "Each time you click the button, the injected text will"
print "appear in the console typeahead buffer."
print "To quit, click the close box in this console window."
while 1
input text$
print text$
wend
See Also
See the BBj Object Diagram for an illustration of the relationship between BBj Objects.