I'm trying to understand some rather weird behavior using the grid control.
I can add only one new record to a browse, and when I try to add an additional one, the information overwrites the previous record's information.
My form is exremely simple and contains two objects:
I want to allow the user to enter the first two fields of information and have the last field populated with the value of the variable. Very simple, very straightforward.
There are no restrictions at either the form or the browse level.
The browse has a single event OnSave defined as follows:
Screen 1:
When I enter the form, a line for a new record is displayed.
Screen 2:
I enter information into the first field, then tab to the second field enter information.
Screen 3:
I tab to the third field and it is automatcally populated by the Action Script with the value of the variable.
So far, so good.
But then something weird happens.
Screen 4:
Instead of creating another <New record line>, the browse freezes.
The new record line (*) does not display a blank field for the first field instead is populated with the value of the previous line.
When I type and overwrite the value of the first field, when I tab to the second field, three weird things happen:
Screen 6:
1. The value I just typed in overwrites the PREVIOUS record's value
2. The tab advances to the second field of the previous record and assumes that I want to overwrite the value there
3. Amazingly, the <New record> line appears
When I try to enter a new record, the browse just tabs through the previous records fields.
I've tried the OnEnter event at the form level and the OnSave at the browse level and still have these problems.
If I remove the Action Script, the browse behaves correctly.
Note that the records on this form are not child records, but are from the same table as that of the Parent form which opens this form. Otherwise I probably could use the form.ViewLinked() method.
Am I doing something wrong or is this a bug?
Bob McGaffic
Pittsburgh, PA
I can add only one new record to a browse, and when I try to add an additional one, the information overwrites the previous record's information.
My form is exremely simple and contains two objects:
Code:
Variable: mTopic_id Embedded browse displayes these fields: Subtopic_No Line_Text Topic_id
There are no restrictions at either the form or the browse level.
The browse has a single event OnSave defined as follows:
Code:
Set value property of the objects in which window? Current form or browse window Set value property of the following objects Browse1: Topic_Id How will you specify the value property? Specify a variable that contains the value Variable? mTopic_Id
When I enter the form, a line for a new record is displayed.
Screen 2:
I enter information into the first field, then tab to the second field enter information.
Screen 3:
I tab to the third field and it is automatcally populated by the Action Script with the value of the variable.
So far, so good.
But then something weird happens.
Screen 4:
Instead of creating another <New record line>, the browse freezes.
The new record line (*) does not display a blank field for the first field instead is populated with the value of the previous line.
When I type and overwrite the value of the first field, when I tab to the second field, three weird things happen:
Screen 6:
1. The value I just typed in overwrites the PREVIOUS record's value
2. The tab advances to the second field of the previous record and assumes that I want to overwrite the value there
3. Amazingly, the <New record> line appears
When I try to enter a new record, the browse just tabs through the previous records fields.
I've tried the OnEnter event at the form level and the OnSave at the browse level and still have these problems.
If I remove the Action Script, the browse behaves correctly.
Note that the records on this form are not child records, but are from the same table as that of the Parent form which opens this form. Otherwise I probably could use the form.ViewLinked() method.
Am I doing something wrong or is this a bug?
Bob McGaffic
Pittsburgh, PA
Comment