Access 2013 Column in Continuous Form

* Please try a lower page number.

* Please enter only numbers.

* Please try a lower page number.

* Please enter only numbers.

I might use a blank unbound form with 3 subforms on it.

-Tom.
Microsoft Access MVP
Phoenix, AZ

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Hi Dave,

you say:

If I drag the header table into my form I get told "A form with a subform object cannot have its DefaultProperty set to Continuous Form"

after the message, set again in main form Continuos form.

Mimmo

Se la risposta ti ha aiutato "Vota Utile".
Se ha risolto il problema "Segna Risposta.
Rome, Italy

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Hi Mimmo

Believing that this would never work, I nevertheless did as you suggested and to my sheer disbelief it worked! Thank you. I think I understand the message even less now.

My problem is not yet resolved as I now have the issue of adding new detail records (i.e. the many part of the one to many relationship).  Thus  item 2) above is still to be solved:

.... , then when I add records in the continuous form I get told that I cannot add or change the record because a related item is required in the "Header" table (naturally).

Perhaps I could try an "On Event" action to populate the "foreign key" field with the contents of the "key" field from the Header table record. Unless there is a simpler way?

Many thanks for your help. Work in progress...

Dave

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Hi Dave,

if I understood in the forms BeforeUpdate event set the fields from header.

Mimmo

Se la risposta ti ha aiutato "Vota Utile".
Se ha risolto il problema "Segna Risposta.
Rome, Italy

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

I think you are complicating maters by thinking in terms of Header and Detail sections. What it sounds like you have is a One to many relationship between Table A (what you refer to as the Header) and Table B (what you refer to as the Detail).

The standard way this is setup on a form is with a mainform/subform. You create your main form, bound to Table A. You create a second form (the subform) in Tabular format (Continuous form) bound to Table B. You then use the Subform wizard to embed the Table B form inside the main form. The wizard will prompt you to select the parent and child fields in the respective tables.

As I said, this is SOP.

Hope this helps,
Scott<>
Blog: http://scottgem.wordpress.com
Microsoft Access MVP since 2007

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Did you remember to set the subform control's Link Master/Child properties?  The link Master should be set to the one side table's primary key field and the Link Child to the foreign key field in the many side table.

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Hi Scott

I used the term "Header" and "Detail" because they aptly describe the content of the data being collected and in the full knowledge that these terms have their own particular meaning/section on the Access Form. The problem I had with applying the standard setup was......

If I drag the header table into my form I get told  "A form with a subform object cannot have its DefaultProperty set to Continuous Form"

... which seemed at loggerheads with the standard approach. However, Mimmo57's helpful reply to ignore the message and just re-set it - seems to have done the trick.

If by "SOP" you mean "Sales Order Processing" then yes my intended form certainly mirrors those attributes.

Many thanks for your reply which is very much appreciated,

Best regards

Dave

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

While it is possible to include a subform in a form in continuous forms view after a fashion by means of the header/footer section of the parent form, it's a rather crude approach which limits the layout possibilities.  A more flexible method is to put two bound subforms in continuous forms view in an unbound form as Tom suggested, and correlate the subforms by means of a parameter in the second subform's query which references the key of the first subform.  You'll find an example as CorrelatedSubs.zip in my public databases folder at:

https://skydrive.live.com/?cid=44CC60D7FEA42912&id=44CC60D7FEA42912!169

If you have difficulty opening the link copy its text (NB, not the link location) and paste it into your browser's address bar.

This little demo uses data from Northwind as an example and correlates an orders subform (of dates)  with an order details subform so that the latter is requeried (in the Current event procedure of the former) as the user navigates from row to row in the former, the latter shows the details for the order of that date.  In my case the parent form is bound to show a customer, and the first subform is linked to the parent form in the usual way, but  that's not relevant to this issue.

When a new row is inserted into the product detail subform, the value of the foreign key OrderID column is inserted by means of the following code:

Private Sub Form_BeforeInsert(Cancel As Integer)

On Error GoTo Err_Handler

Me.OrderID = Me.Parent.frmsubOrders.Form.OrderID

Exit_Here:
Exit Sub

Err_Handler:
MsgBox Err.Description & " (" & Err.Number & ") ", vbExclamation, "Error"
Resume Exit_Here

End Sub

BTW you'll sometimes see recommended a method for correlating subforms via a hidden control in the parent form which references the key of the first subform.  This is easy to implement, but performance tends to be very poor in comparison with the use of a parameter in the second subform's query.

_____________________
Ken Sheridan,
Cannock, England

"Don't write it down until you understand it!" - Richard Feynman

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

SOP stands for Standard Operating Procedure.

What it sounds like you did was create a form in Continuous form mode THEN drag the One table onto the form. Frankly, that's doing it backwards. I start with a main form, then I create a form in Continuous form mode, get that form to look the way I want. THEN I use the Subform Wizard to embed that form on my main form.

To me, dragging your header table onto a continuous form is the illogical process. You start with the head and then build the body.

Hope this helps,
Scott<>
Blog: http://scottgem.wordpress.com
Microsoft Access MVP since 2007

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

Hi Ken

Thank you very much for sharing this with me. I do like the idea of the two continuous sub-forms within an un-bound form particularly if it allows for more flexibility in layout design as you suggest. I also like your example which I have downloaded. With relatively few tables and forms within your example I think it makes it easier to follow than wading through the Northwind database.  Hopefully now that I have got passed that message "A form with a subform object cannot have its DefaultProperty set to Continuous Form" which had been a mental barrier - I can make progress.

Thank you.


Dave

Was this reply helpful?

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this reply?

Thanks for your feedback.

* Please try a lower page number.

* Please enter only numbers.

* Please try a lower page number.

* Please enter only numbers.

scottbrerefrommen.blogspot.com

Source: https://answers.microsoft.com/en-us/msoffice/forum/all/microsoft-access-2013-continuous-forms-with-linked/9dccbdcb-06f7-4aa7-9963-bb7f80776895

0 Response to "Access 2013 Column in Continuous Form"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel