FORM Toggle between notes (1 Viewer)

Dragonmouse

New member
Local time
Today, 13:52
Joined
Feb 1, 2016
Messages
7
I'm new and dumb :( to forms

I've created a form based on a database with multiple tables:

The main table holds info (for example cars rented):
Color
Model
VIN
GPS

Each item (color, model, VIN, GPS) has it's own table for "NOTES"

(I wish I could upload a picture)

Each item will have a radio button next to it. If the user on the form clicks the radio button I want the corresponding NOTE to appear in a "single" NOTE box. (remember each NOTE is on a separate table- I didn't build this data base...I'm working with an old one)

(radio button on Color Note)
Items NOTES

Color Red * Damage on right fender
Model Pris
VIN 12345C
GPS Garmin


(Different radio button selected):
NOTES:
Color Red
Model Pris * Purchased 2016
VIN 12345C
GPS Garmin
 

tabitha

Registered User.
Local time
Today, 11:52
Joined
Apr 24, 2015
Messages
62
I think you could leave the Notes textbox as unbound, then in the AfterUpdate event of the radio button, do a dlookup to find the Notes that are associated with that record.
 

Dragonmouse

New member
Local time
Today, 13:52
Joined
Feb 1, 2016
Messages
7
Ok I'm really SLOW. Do I use "Build Event" on the Radio button or on the NOTES block? I created 4 Radio buttons and a single NOTES block

I went to the radio button and right clicked on "Build Event" and selected "expression builder" and I found the "AFTER UPDATE" but I'm rather confused with what comes next. :confused:

I seriously haven't done many forms before.
 

tabitha

Registered User.
Local time
Today, 11:52
Joined
Apr 24, 2015
Messages
62
Can you tell me a little more about how the tables are set up? You said you have a different one for each thing, can you tell me the parent table's pk and how it gets the notes for each category?
 

Dragonmouse

New member
Local time
Today, 13:52
Joined
Feb 1, 2016
Messages
7
To the best I can tell there is a relationship between the "ID". On the MAIN table (Cars Rented) the ID are 1-60 it apparently has a one to many relationship so the COLOR table has a ID that marries up with COLORTABLEID on the Cars Rented table. Same with the Model Table.
 

tabitha

Registered User.
Local time
Today, 11:52
Joined
Apr 24, 2015
Messages
62
So [CarsRented].[ID] = [ColorTable].[ColorTableID] and [CarsRented].[ID] = [Model].[ModelTableID]? And there's a Notes field in both the ColorTable and the Model table.

So I would say in the After Update event for the Color toggle write :
Code:
Dim GetID as string
GetID = Dlookup("Notes","ColorTable","ColorTableID =" & Me!ColorNameOfID)
Me!NotesTextBox = GetID

Then swap out the name and ID for the Model table for that toggle button.
 

ddcessex

Registered User.
Local time
Today, 11:52
Joined
Jan 14, 2016
Messages
23
From one Newbie to another ....

Assuming that you are editing a Rental Record and that each rental stores details such as Colour that is selected from a lookup list of Colours (in the colour table) then the Notes about that rental colour should be stored in the Rental Record and not the Lookup Table of Colours.

This assumes that the Notes on the colour Red will change from rental to rental?

Good luck
 

Dragonmouse

New member
Local time
Today, 13:52
Joined
Feb 1, 2016
Messages
7
Thanks everybody for everything. I'm going to have to take some time to fiddle with this.
 

Users who are viewing this thread

Top Bottom