Base : subform row count

Hi,

I have a Main Form and a Sub form.
Two text fields are entered in the Main Form.

Move to the Sub form the Sub Form is displayed as a Grid and data navigation control placed into Sub Form
Data is entered into Sub Form (2 records).

How can the record count ( using above record count = 2) be displayed in the Sub Form without using the data navigation control (ie. 1 of 2) and how can the count be passed to the Main Form?

An example will be great.

As stated elsewhere, moving information from sub form to main form will require a macro. Do you have any macro coding experience?

no I don’t

I don’t think displaying the count of the records on a subform is a problem. Create a query & display it in a control on another form (sub sub form). Moving that information to the main form is the problem. You need a macro.

There are problems with getting someone else to provide you with the necessary macro code. If things change you have no way of making the necessary code changes to accommodate the changes. Secondly, it is usually best for the person writing the code to have complete access to the .odb in order to get specific information about the forms/tables/controls.

For example, to get the number of records displayed is fairly simple with this line:

iCount = ThisComponent.Drawpage.Forms.getByName("YOUR_FORM").getByName("YOUR_SUBFORM").RowCount

But even with this you can see the form & subform names are still needed. Along with this is then needed the control names for where to display on subform & what to do with it on the main form.

@jocko1 It appears to me from this question & your previous one, you need some information pieced together for some other reason. Why not explain what you have and what you actually need as an end result? It seems (at least on the surface) a query might do the job.