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 / General 2 / April 2008

Tip: Looking for answers? Try searching our database.

deleting data ijust in a tab control

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
natalie - 09 Apr 2008 21:43 GMT
for my project i am doing a database and interfaces for a surveying company.

in the form header i have got some data fields such as report number,
address, staff ID etc.  on my form in the detail section i have got a tab
control which has different data on each tab such as room details, floor
details etc...  is there a way i can create a button which empty's the data
only in the tab control and keeps the header details showing.  i want to be
able to create new tab control data but keep the data in the header section.
Many thanks
John W. Vinson - 09 Apr 2008 22:25 GMT
>for my project i am doing a database and interfaces for a surveying company.
>
[quoted text clipped - 5 lines]
>able to create new tab control data but keep the data in the header section.
>Many thanks

STOP.

Data is *NOT* stored in tab controls.
Data is *NOT* stored in forms.

A Form (with or without tab controls to arrange screen real estate) is just a
window. The data exists in your Tables, and only in your Tables.

What is the structure of your tables?
What is the recordsource of your Form?
What is on the tab pages: controls bound to the main table, subforms, or what?
Signature


            John W. Vinson [MVP]

natalie - 09 Apr 2008 22:38 GMT
thanks for your reply, it was very quick!
i know data is not stored on the tab control, but i have got a button that
saves the data that is put on the tab control that saves it into the
database.  basically, i am creating a surveying report on buildings.  twith
his particular form, i have saved all of the details into a database, but if
the user wants to add another room into the database on the same report, i
want the data in the tab to be deleted so i can create a new room but under
the same report.
John W. Vinson - 10 Apr 2008 00:03 GMT
>thanks for your reply, it was very quick!
>i know data is not stored on the tab control, but i have got a button that
[quoted text clipped - 4 lines]
>want the data in the tab to be deleted so i can create a new room but under
>the same report.

I think what you actually want is not to "delete" the data (which implies
permanently and irrevokably deleting the data from your Table), but just to
move the form to display the new, empty record. This can be done using the
builtin navigation buttons with no effort at all, and with only a tiny bit
more effort to create a new command button to move to the new record.

The user will see a blank form (or subform) ready for new data entry.

Bear in mind that a Report in Access jargon is NOT a data entry form and is
not editable - it's a way of printing data out. A Form is what you would use
for this kind of data entry and editing.

I'd still be interested to know your table structure. If you have a one to
many relationship from Buildings to Rooms, then I would hope that you have a
one to many relationship between a table of Buildings (displayed on your
mainform) and a separate table of Rooms (displayed on a subform). My advice is
predicated on this assumption; if the assumption is wrong please post back
with your actual structure.
Signature


            John W. Vinson [MVP]

natalie - 10 Apr 2008 14:43 GMT
Yeah you are right, that is what I want to do.

My tables and relationships are a little more complicated, but I tried to
simple it down in my initial posting.
For my project, the surveyor will go out to  a property and create a
surveyor report.  This includes the creation of a report number, selecting
surveyor ID and choosing the property address.  In the “detail” section of
the form, it has a tab control which has a different area to select data bout
the room and problems.  Such as, the first tab is about what floor it is on,
2nd is about the room, 3rd is about the problems and solutions the surveyor
picks.  Once created and saved in the database, a worker will need to create
their work report which is based on this.
On the work report form, the worker selects the property address which then
searches for all of the fields in the Surveyor report and displays them. They
can now see what work needs to be done and where. They have two fields they
can use which is the “solution1done” and “solution2done”.  As they complete
the solutions, they tick the checkboxes.  This is save din the database.  

For my relationships for these two reports, I have:
SurveyorReport:Report number
        SurveyorID
        SiteID
        FloorSelection
        RoomSelection
        BedroomNumber
        Locatoion of work
        Problem1
        Problem2
        Solution
        SubSolution
WorkReport:StaffId
        ReportNumber
        StartDate
        EndDate
        Solution1Done
        Solution2Done
I have got that 1 surveyor can do many surveyor reports, and 1 worker can do
many work report.  Both reports are related by their Reportnumber
Sorry it is long winded-my project is hard to describe!
 
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.