Form transfer issue?

jackie77

Jackie
Local time
Today, 20:16
Joined
Jul 18, 2007
Messages
85
Hi all :o

I am having some problems with a form I am working on. The form is for documenting work that is carried out by an engineer. I need to report any faults that occur with the job, which is often more than one so I have created a different table for this. What I am looking to do is when I click on the button ‘report fault’ on the form (see screen shot attached) the fault page appears but is it possible to carry over the job details for example the job ID ?

As you can tell I am a novice so any advice would be appricated

Thanks

Jackie
 

Attachments

  • access screen shot 2.jpg
    access screen shot 2.jpg
    42.5 KB · Views: 129
Jackie,

Code for the button:

DoCmd.OpenForm "frmFaultPage",,,"[JobID] = " & Me.JobID

At least I think it's three commas.
The IntelliSense will guide you as you type.

Wayne
 
Hi there

Thanks for the reply, I have added in the code you suggested, but changed the names etc, however the faults page opens but the Job ID does not transfer over, is blank :(

The code I have now is:

---------------------------------------

Private Sub Report_Fault_Click()

DoCmd.OpenForm "Reported Faults", , , "[Job ID#] = " & Me.Job_ID

End Sub

---------------------------------

Any other suggestions?

Jackie
 
Sorry I should have added:

before it takes me to the fault form a box appears which asks me to enter parameter values for the Job ID so it looks like it is looking for the Job ID not transfering it over

Any suggestions?

Jackie
 
I have managed to get it to work

code I used:

----------------
Private Sub Report_Fault_Click()

DoCmd.OpenForm "Reported Faults", acNormal
Forms("Reported Faults").Job_ID = Me.Job_ID

End Sub
----------------

Thanks for your help

Jackie
 
Jackie,

Glad to hear that it's working. Just for future reference, was the name of
your JobID field --> [Job ID] with the space?

Those spaces and special characters will hurt you.

Wayne
 

Users who are viewing this thread

Back
Top Bottom