One-to-one primary data synchronization

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello all

I have a one-to-one relationship between the (primary) SubcriberID field (Autonumber datatype) in tblSub and the (primary) CoSubscriberID field (number datatype) in tblCoSub. I have set up a main form with an embedded subform based on this relationship, but I'd really like to have a linked form (via a command button), while still enjoying the autonumber/number sychronization described below.

When data is added to the main form, not only does the Subscriber autonumber field populate automatically in the main form, but the SAME number automatically populates in the CoSubscriberID (number) field as a result of the subform linkage and the fact that SubscriberID is driving CoSubscriberID. This sychronization happens automatically in an embedded situation - a very nice feature indeed

However, In the interest of screen real estate, I would like to have the "subform" pop-up (perhaps after pressing a command button), but still inherit the current number from the main form (autonumber field)

Does anyone know how I can essentially duplicate the sychronization effect with a pop-up form

Most appreciated
Jod
 
When your data is related one-to-one, unless a set of the data needs to be kept
isolated for some reason such as sensitive personnel information, all your data
should be in one table. I sense you truly do not need tblCoSub and feel that all
the data you have in that table should more correctly be in TblSub. It sounds
like you separated the CoSub data out due to a perceived lack of screen
realestate for all the Sub and CoSub data.

What I see working nicely for you is a tabcontrol that allows you to group your
data in sets on various tabs. You could use a tabcontrol with tabs so you click
on a tab to go to a set of data or you could use a tabless tabcontrol and
activate the pages with command buttons, option buttons or radio buttons. The
latter gives a very slick appearance where the pages popup like subforms.


--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
(e-mail address removed)
www.pcdatasheet.com


Jody said:
Hello all,

I have a one-to-one relationship between the (primary) SubcriberID field
(Autonumber datatype) in tblSub and the (primary) CoSubscriberID field (number
datatype) in tblCoSub. I have set up a main form with an embedded subform based
on this relationship, but I'd really like to have a linked form (via a command
button), while still enjoying the autonumber/number sychronization described
below.
When data is added to the main form, not only does the Subscriber autonumber
field populate automatically in the main form, but the SAME number automatically
populates in the CoSubscriberID (number) field as a result of the subform
linkage and the fact that SubscriberID is driving CoSubscriberID. This
sychronization happens automatically in an embedded situation - a very nice
feature indeed.
However, In the interest of screen real estate, I would like to have the
"subform" pop-up (perhaps after pressing a command button), but still inherit
the current number from the main form (autonumber field).
 
Thanks for your response, PC Datasheet. I actually separated the CoSubcriber data into its own table because it is an occasional subset of the Subscriber data (it happens only 2% of the time), as to not leave many null fields in the Subscriber table. I have used the tabless tab control before, but it still presents a screen real estate problem in this case. So I come back to my original question

I would like to have the "subform" pop-up (perhaps after pressing a command button), but still inherit the current number from the main form (autonumber field). Do you know how I can essentially duplicate the sychronization effect with a pop-up form

Thanks so much
Jody
----- PC Datasheet wrote: ----

When your data is related one-to-one, unless a set of the data needs to be kep
isolated for some reason such as sensitive personnel information, all your dat
should be in one table. I sense you truly do not need tblCoSub and feel that al
the data you have in that table should more correctly be in TblSub. It sound
like you separated the CoSub data out due to a perceived lack of scree
realestate for all the Sub and CoSub data

What I see working nicely for you is a tabcontrol that allows you to group you
data in sets on various tabs. You could use a tabcontrol with tabs so you clic
on a tab to go to a set of data or you could use a tabless tabcontrol an
activate the pages with command buttons, option buttons or radio buttons. Th
latter gives a very slick appearance where the pages popup like subforms


-
PC Datashee
Your Resource For Help With Access, Excel And Word Application
(e-mail address removed)
www.pcdatasheet.co


Jody said:
Hello all
(Autonumber datatype) in tblSub and the (primary) CoSubscriberID field (numbe
datatype) in tblCoSub. I have set up a main form with an embedded subform base
on this relationship, but I'd really like to have a linked form (via a comman
button), while still enjoying the autonumber/number sychronization describe
belowfield populate automatically in the main form, but the SAME number automaticall
populates in the CoSubscriberID (number) field as a result of the subfor
linkage and the fact that SubscriberID is driving CoSubscriberID. Thi
sychronization happens automatically in an embedded situation - a very nic
feature indeed"subform" pop-up (perhaps after pressing a command button), but still inheri
the current number from the main form (autonumber field)
 
Hello Jody,

The only way that Access will 'auto fill' the linking id is by using a main
form with a sub form. If you want a sub form that 'pops up' then you would
have to code everything to keep all records in Sync. (which is a lot
harder). You would need some code in the BeforeInsert event of the popup
form checking to see if

i) the main form is open
ii) the main form is not on a new record
iii) the main form has been updated successfully

Only then, should you be able to insert data intp the popup form.

This is only the beginning of the problem. I bet the tab control doesn't
seem like a bad idea now... :-)

Neil.

Jody said:
Thanks for your response, PC Datasheet. I actually separated the
CoSubcriber data into its own table because it is an occasional subset of
the Subscriber data (it happens only 2% of the time), as to not leave many
null fields in the Subscriber table. I have used the tabless tab control
before, but it still presents a screen real estate problem in this case. So
I come back to my original question:
I would like to have the "subform" pop-up (perhaps after pressing a
command button), but still inherit the current number from the main form
(autonumber field). Do you know how I can essentially duplicate the
sychronization effect with a pop-up form?
 
Back
Top