Xojo Listbox insert text while EditCell active

I can do:

    Listbox.Cell(0, 0) = "New Text"
    Listbox.EditCell(0,0)

Which will put new text in the cell and make it editable, but I’d like to be able to put the new text in there AS IF I were typing it so that if I press Esc it would revert to the previous text.
Of course I can store the previous value add a KeyDown event looking for escape, and revert it, but I wonder if there’s another way to just “paste” text into the cell AFTER .EditCell is called, since EditCell already has that functionality…

I can see how to put text into the clipboard, is there a way to “perform” a paste function after the ListBox is in Edit Mode?

Var c As New Clipboard
Var s As String
Listbox.Cell(0, 0) = c.Text
c.Close

In edit mode a TextBox is added and in there you can paste text normally, but after the edit mode, this control is hidden and has not real relation with the cell. The ListBox is not really a text control so you cant “perform” a paste command directly .

1 Like

< cough > subclass and implement the menu handler for "EDitPaste </ cough >
there are things this is the ONLY way you can make them work
placing an instance on a layout wont let you do this quite so easily

As in setting “New Text” in the CellGotFocus event?