I have a tabbed form with several subforms on the tabs. The database is an IT problem management database. The first tab has the information for the Failed Component, the thing that originally broke and made everything else go haywire. The Failed Component tab has a subform named fsubFailedComponent with the name of the failed component. FsubFailedComponent contains fsubFCImpact which is a continuous form that has all of the start and end times times for the failed component.
The next tab is for the various User Facing Applicaitions that were impacted by the failure of the Failed Component. It can have several applications, several locations and within the locations several business units. It has a subform named fsubUserFacingApps which is pretty much like fsubFailedComponent. It has the name of the application and a subform, fsubUFAImpact, with the detail info. My boss wants me to add a button to fsubUFAImpact that a user can click which will copy and paste the start and end times from fsubFCImpact tab to fsubUFAImpact, but still make it editable in case the impact started later or ended earlier.
Thanks!!
5 2627
I have a tabbed form with several subforms on the tabs. The database is an IT problem management database. The first tab has the information for the Failed Component, the thing that originally broke and made everything else go haywire.
The Failed Component tab has a subform named fsubFailedComponent with the name of the failed component. FsubFailedComponent contains fsubFCImpact which is a continuous form that has all of the start and end times times for the failed component.
The next tab is for the various User Facing Applicaitions that were impacted by the failure of the Failed Component. It can have several applications, several locations and within the locations several business units.
It has a subform named fsubUserFacingApps which is pretty much like fsubFailedComponent. It has the name of the application and a subform, fsubUFAImpact, with the detail info.
My boss wants me to add a button to fsubUFAImpact that a user can click which will copy and paste the start and end times from fsubFCImpact tab to fsubUFAImpact, but still make it editable in case the impact started later or ended earlier.
Thanks!!
You will need something like the following code. Substitute your Main Form name for [MainFormName] and correct the names of the StartTime and EndTime fields and substitute your command button name for cmdButtonName. -
-
Private Sub cmdButtonName_Click()
-
-
Me.StartTime = [Forms]![MainFormName]![fsubFailedComponent].Form![fsubFCImpact].Form![StartTime]
-
Me.EndTime = [Forms]![MainFormName]![fsubFailedComponent].Form![fsubFCImpact].Form![EndTime]
-
-
End Sub
-
Hi M,
I tried your solution which was similar to what I did before posting and got the same results. It doesn't seem to 'write' the copied dates to the table. I have a field which calculates the duration of the outage, it showed #ERROR when I did it at first, then when I tried your solution, it showed the same result it had when I hard coded my birthday in on a previous try. Then when I closed the form and reopened it on that record, the copied dates were gone. I'll try a requery or refresh and check back here again.
Thanks,
John
Hi M,
I tried your solution which was similar to what I did before posting and got the same results. It doesn't seem to 'write' the copied dates to the table. I have a field which calculates the duration of the outage, it showed #ERROR when I did it at first, then when I tried your solution, it showed the same result it had when I hard coded my birthday in on a previous try. Then when I closed the form and reopened it on that record, the copied dates were gone. I'll try a requery or refresh and check back here again.
Thanks,
John
John
Have you set the control source of the controls to the appropriate fields?
Mary
John
Have you set the control source of the controls to the appropriate fields?
Mary
That was it!! I just noticed that for some reason the fields were unbound! I guess I inadvertantly did that while messing around with it before. Thanks for pointing me in the right direction Mary! It works like a charm now!
Reason: chair to keyboard interface malfunction
I've had one of those before.
I sympathise
Mary
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Tlm |
last post by:
Hello All,
I have a form (FrmA) with a subform (SubFrmB) embedded in it. SubFrmB also
has a subform embedded in it (SubFrmC) The form's recordsource is based on a
table (TblA). SubFrmB's...
|
by: david |
last post by:
Hi,
I've been reading tons of posts on how to copy records, but to no
avail....i'm still stuck.
There are three tables: Main, Sub-Form1 & Sub-Form2
I have a form which displays some data....
|
by: David Rysdam |
last post by:
I have a large amount of data that I copy in and out of Sybase very
often. Now I also want to copy this data in and out of postgres. I
have an existing script that creates the entire database(s)...
|
by: Stephen D Cook |
last post by:
I have a search form with a query-linked subform.
One of the fields in the subform are date fields.
Is there a way to autopopulate the DateFilled field when the person
enters the field? I need...
|
by: Shawn Yates |
last post by:
I have a form with two subforms on it which are both continous forms.
The subform on the left shows the tasks that the employee was assigned
to accomplish (each as a seperate record) while the one...
|
by: Ericks |
last post by:
I want to highlight new data that has been entered in my database since a last meeting so it is easy to see in a subform’s table what info is new.
In my database I have a table called...
|
by: Mclaren |
last post by:
Hi
I have a main single record form that has a date field on it pupulated from primary table, i have subform (datasheet view) which is populated from the many table. the subform has a field that...
|
by: informankur |
last post by:
Hi All,
I am trying to create a form for updating values. I have a Table - ASP with Date, Product, Q1,Q2,Q3,Q4 fields. I have a Form ASP_Main with "Date" field for filtering by the date selected....
|
by: OzNet |
last post by:
I have a form with a subform and I need to filter the records in the subform by dates. (Access 2007)
The main form has two unbound text boxes called StartFilter and EndFilter. Both use the...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| |