How to do these things ?

Cyberslam

Registered User.
Local time
Today, 14:28
Joined
Sep 1, 2005
Messages
35
Hello all !

I am kinda new to access and made a transport database but it needs some changes which are out of my knowledege so i am hoping that you guys can help me out. There are the 2 things that i would like to do in my forms:

1=, I have a form where all the new cars are added to DB. Fields are Vehicle Code, Type, Brand, Model and Model year. Then I have a transaction form where vehicles are either assigned to employees or to garage etc.. What i would like to do in this form is that when i select a Vehicle Code, the remaining fields i.e. Type, Brand, Model and Model year of that partcular Vehicle Code should appear in thier respective fields of the transaction form.

2=, Now a little difficult part, in the same transaction form i want a field where the name of the current username appears and also a field with current date.

Now moving on to Transaction Type thingy. I want to two options button ( Issue Vehicle and Cancel Vehicle). If option " Issue Vehicle" is selected, a field i.e. a combo box consisting of To Employee and To Garage appears. And then when "To Employee" is selected two fields i.e. Employee No. and Name appear in a kind of frame.( data of both these fields are in other table and will appear in combox boxes). When "To Garage" is selected a field "reason" appear in a frame in place of above stated two fields.

I hope i am making some sense. I know i have to make a table for all these fields but dunno how to do all these things in forms..

Looking forward to your replies and thanks in advance.
 
Yeah but how do i implement it on my first 1st and 2nd questions ?
 
^ Thanks for the help Pat Hartman.

But whats "WhereTo" in the code ?

And do i have to put both of these codes in expression builder of both the options control ( i.e. Option 1 and Option 2 ) ? Or first code in the Option 1 and the other code in the Optios 2 ?

I am new to these access coding so please bear it with me.
 
Last edited:
^ it isn't working. I have created two options "Issue Vehicle" and "Cancel Vehicle" and edited the code like this:

For "Issue Vehicle" option:

Code:
If Me.Issue Vehicle= "Issue Vehicle" then      
Me.Issue Vehicle.Visible = True  Else      
Me.Issue Vehicle.Visible = False  
End If

For "Cancel Vehicle" option:

Code:
If Me.Cancel Vehicle = "Cancel Vehicle" Then      
Me.Reason.Visible = True  Else      
Me.Reason.Visible = False  
End If

The image attached is how my form looks like. As i explanied earlier in my first post, when "Issue Vehicle" is selected, all the fields that i need should appear in a kind of separate frame ( i have bound object frame in my form , is it correct ? ) and same for the "Cancel Vehicle" option.
 

Attachments

  • DRC_DB.JPG
    DRC_DB.JPG
    20.2 KB · Views: 184
Last edited:
Pat Hartman, i really appreciate your help but the problem is that i am kind of a beginner in Access and i would be really greatful to you if you can explain in some steps ( a kinda detail ).

Thanks once again for your help and i am really looking to your reply.
 

Users who are viewing this thread

Back
Top Bottom