Hopefully this will be the last question I need to ask for this current GUI (well, at least for a while!).
I have a grid object on a panel in the main frame of my GUI. When I double-click on a cell in the grid, the GUI launches another frame that contains the details of the record represented in that row of the grid, for editing / updating.
I need to figure out how I go about updating the grid to show the new values in the record once I accept any changes I made on the 'edit frame'.
Can anyone help me work out the syntax to use from the click event of the 'Update' button on the 'edit frame' to update the grid object on the main frame of my GUI?
Have you ever used a wx.TextEntryDialog? You know how you can use...
dlg = wx.TextEntryDialog(...)
rslt = dlg.ShowModal()
val = None
if rslt == wx.ID_OK:
val = dlg.GetValue()
dlg.Destroy()
To get a value from a dialog?
Yeah, you can make that kind of thing happen (though your "frame" needs
to subclass from wx.Dialog), or you can keep a reference in your "frame"
to the parent control and update the data in the parent when you hit the
"update" button.
Hopefully this will be the last question I need to ask for this current
GUI (well, at least for a while!).
I have a grid object on a panel in the main frame of my GUI. When I
double-click on a cell in the grid, the GUI launches another frame that
contains the details of the record represented in that row of the grid,
for editing / updating.
I need to figure out how I go about updating the grid to show the new
values in the record once I accept any changes I made on the 'edit frame'.
Can anyone help me work out the syntax to use from the click event of
the 'Update' button on the 'edit frame' to update the grid object on the
main frame of my GUI?
Many thanks and much warmth,
Murray
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org
I need to be able to edit more than 1 value on the 'edit frame', so I'm not sure the TextEntryDialog is the appropriate solution.
I'll have to give some thought to how I pass a reference to the main frame to the edit frame, though. Conceptually I think I understand what you mean, but I'll have to play around with actually getting it to happen.
Thanks for the reply!
Much warmth,
Murray
···
On 2/01/2006 4:53 PM, Josiah Carlson wrote:
Have you ever used a wx.TextEntryDialog? You know how you can use...
dlg = wx.TextEntryDialog(...)
rslt = dlg.ShowModal()
val = None
if rslt == wx.ID_OK:
val = dlg.GetValue()
dlg.Destroy()
To get a value from a dialog?
Yeah, you can make that kind of thing happen (though your "frame" needs
to subclass from wx.Dialog), or you can keep a reference in your "frame"
to the parent control and update the data in the parent when you hit the
"update" button.
Hopefully this will be the last question I need to ask for this current GUI (well, at least for a while!).
I have a grid object on a panel in the main frame of my GUI. When I double-click on a cell in the grid, the GUI launches another frame that contains the details of the record represented in that row of the grid, for editing / updating.
I need to figure out how I go about updating the grid to show the new values in the record once I accept any changes I made on the 'edit frame'.
Can anyone help me work out the syntax to use from the click event of the 'Update' button on the 'edit frame' to update the grid object on the main frame of my GUI?
Many thanks and much warmth,
Murray
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org