Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms Programming / July 2007

Tip: Looking for answers? Try searching our database.

Delete Button on a form

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
stephen.belyea@gmail.com - 17 Jul 2007 17:36 GMT
The title for this may be a little simpler than the problem I'm trying
to explain.

In my database, I have:

tblPCName
PCNameID (autonumber)
PCName (text)

tblPCName.PCName is the source for the combobox of another field in a
different table (tblPC.PC) which is related to a number of tables.

Is there a way that I can configure a delete button to not only delete
the PC from tblPCName.PCName (and remove it from the combobox list)
but also delete that PCName from all of the records in the database as
well?

Thanks in advance - this newsgroup has been a tremendous resource for
me so far (I've figured out how to do a search box, many to many
relationships, etc. :-D).
Carl Rapson - 17 Jul 2007 20:54 GMT
I would hope that you're storing PCNameID in your other table, not PCName.
If you're storing PCName, you should modify your table to store PCNameID
instead.

If you set up referential integrity with cascading delete (in the
Relationships window), deleting the record from tblPCName should delete
corresponding records in other (related) tables as well, with no additional
action required on your part. You will need to requery the combo box,
though.

Carl Rapson

> The title for this may be a little simpler than the problem I'm trying
> to explain.
[quoted text clipped - 16 lines]
> me so far (I've figured out how to do a search box, many to many
> relationships, etc. :-D).
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.