Hello
In the documentation I found the example to use a TMSFMXEditBtn with a TreeView:
TMSFMXEditBtn1.PopupControl := TreeView1;
This is working, the TreeView is opening, but how can I take the selected entry in the TreeView to the TMSFMXEditBtn edit field and how can I close the TreeView?
Thomas
Sorry wrong Forum : I post it in FNX Components again
Hi,
You use the OnNodeClick event and close the popup with the following code:
procedure TForm1.TMSFMXTreeView1NodeClick(Sender: TObject;
ANode: TTMSFMXTreeViewVirtualNode);
begin
TMSFMXEditBtn1.Text := ANode.Text[0];
TMSFMXEditBtn1.Popup.IsOpen := False;
end;
Hi Pieter
I don't found the TreeViewNodeClick event, but with a ListBox it works similar:
procedure TForm1.ListBoxListe1temClick(
const Sender: TCustomListBox; const Item: TListBoxItem);
begin
TMSFMXEdit1.Text := Item.Text;
TMSFMXEdit1.Popup.IsOpen := False;
end;
It works now, thanks a lot!
Thomas