I'm trying to populate my table row data in a dialog box with Radiogroup and editText control.

I successfully get the column value list from popupMenu control after selecting the table and column popupmenu.

But i wanted to populate from the column value list i selected, the row data from my selected table and update the Radiogroup and EditText every time i select a column value list.

  • Can you elaborate a bit more on what you are trying to do? Do you want to show the value from a selected record in the dialog or? Nov 20 '14 at 16:26
  • Good day Peter. I was trying to show the table row information whenever i selected a value in a popupmenu ((1) when i selected a table, (2) when i selected a column and (3) when i selected a value in a column). It is possible to populate the that table row information to dialog box (same dialog box) to get the choices and show in radiogroup and edit text control? br.. ivan
    – Ivan
    Nov 21 '14 at 6:26
  • Hi Ivan, so you select a table and a column and then the values should be shown. I assume this is for one selected record, right? Nov 23 '14 at 13:34
  • Yes, for one record only, and possible to edit / update that values on the dialog and as well on the table it self.
    – Ivan
    Nov 24 '14 at 6:03

You need to add a handler/procedure to your list control holding the column names. When the user clicks on this list the handler will be called and you can read the value from the column from the selection.

You should define your Dialog like this - at least. You will probably need some extra controls as well.

  Control PopupMenu Width 200 ID 100
     Title From Variable marrColumns
     Calling Handler_ColumnClicked
  Control EditText  Width 200 ID 200
  Control OKButton

This is how your handler could look:

Sub Handler_ColumnClicked

Dim nItem As Integer
Dim aCol As Alias

  '**100 is the ID of your popupmenu/list control
  nItem = ReadControlValue(100)

  Fetch First From Selection
  '**marrColumns is a array variable holding your column names
  aCol = "Selection." & marrColumns(nItem)

  '**200 is the ID of your EditText control
  Alter Control 200 Value aCol

End Sub

Not the answer you're looking for? Browse other questions tagged or ask your own question.