BBjCEdit::removeAll

Description

In BBj 5.00 and higher, this method removes all paragraphs from the BBjCEdit control.

Syntax

Return Value

Method

void

removeAll()

Parameters

None.

Return Value

None.

Example

rem ' BBjCEdit::removeAll Example

rem ' removeAll.txt
sysgui = unt
open (sysgui)"X0"
sysgui! = bbjapi().getSysGui()
window! = sysgui!.addWindow(50,50,350,300,"removeAll",$00090003$)
window!.setCallback(window!.ON_CLOSE,"eoj")
addParagraph! = window!.addButton(1,25,25,100,25,"addParagraph")
addParagraph!.setCallback(addParagraph!.ON_BUTTON_PUSH,"addParagraph")
removeAll! = window!.addButton(2,150,25,100,25,"removeAll")
removeAll!.setCallback(removeAll!.ON_BUTTON_PUSH,"removeAll")
paragraphs! = window!.addButton(3,275,25,50,25,"",$$)
paragraphs!.setCallback(paragraphs!.ON_BUTTON_PUSH,"getNumberOfParagraphs")
cedit! = window!.addCEdit(101,25,75,300,200,"",$0004$)
para = 0
gosub getNumberOfParagraphs
process_events

eoj:
release

addParagraph:
    cedit!.addParagraph(-1,"Paragraph "+str(para))
    para = para + 1
    gosub getNumberOfParagraphs
return

removeAll:
    cedit!.removeAll()
    para = 0
    gosub getNumberOfParagraphs
return

getNumberOfParagraphs:
    paragraphs!.setText(str(cedit!.getNumberOfParagraphs()))
return

See Also

BBjAPI

BBjSysGui

BBjControl

BBjWindow

See the BBj Object Diagram for an illustration of the relationship between BBj Objects.