Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Displaying fields of grids on opened new form

Status
Not open for further replies.

kosta

Programmer
Feb 9, 2001
186
CA
Hi All,
i've form (like parent-child,private datesession,buffermode=5 etc. suitable for multiuser ) master fields on textbox and child fields on the grid.
i wantto open new form when user press the enter key and want to edit selected row fields on the new form ( new form datasession will be default this i know) . Now , how can i store fields to the textbox automatically for edit and for new record.

i can store tablename.fieldname to thisform.text1.value etc.. while editing but i doesnt come to me pratically and while adding new record appe blank and then replace tablename.fieldname with thisform.text1.value . should be better way for this . i've no good idea please help ...

TIA

Soykan OEZCELIK
 
Why not just bind the control to the data using the ControlSource? Set each of the textbox.ControlSource to the tablename.fieldname. Using the form's default datasession will (as you noted) already have access to the current record. No need to add anything to the form's dataenvironment as the form will use the datasession of the calling form.


_RAS
VFP MVP
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top