Linking ComboBox colums to Labels/Images (1 Viewer)

Shadoz

New member
Local time
Today, 03:00
Joined
Dec 14, 2018
Messages
3
I have started working with MS Access for my employer and I have been tasked with creating a 911 floor tool for our Security staff.

When 911 is dialed by anyone in the building Security will receive an email with their name and floor number.

The idea for the tool I would be making is when a Security Officer types in the individuals name into a combobox the image of their floor would appear and their name would be highlighted where their office is. This would enable quick response from the officer if necessary.

I have attempted to do this by making the floor plans and labels not visible and trying to make them viisble by referencing a column from the combo box but I have been unsuccessful.

Any tips would be appreciated.

Thank you.
 

mike60smart

Registered User.
Local time
Today, 11:00
Joined
Aug 6, 2017
Messages
1,904
Hi

Can you upload a zipped copy of the Db so we can see the table structures?
 

Dreamweaver

Well-known member
Local time
Today, 11:00
Joined
Nov 28, 2005
Messages
2,466
While I can see how you might use a floor plan with a number of labels placed over each workstation with some sort of tag linking to each employee you would need a lot of forms depending on the number of floors or save the floor plan to a table(s)


but before you can do that you need access to the phone system so when 911 is called you can trap it and then record the event think you will need something like TAPI or a system supplied by your phone company you can access via access.
 

Shadoz

New member
Local time
Today, 03:00
Joined
Dec 14, 2018
Messages
3
Unfortunately I cannot.

My current VBA code is as follows:

Private Sub Combo10_AfterUpdate()
If Me.Combo10.Column(1) = "Label1" Then
Me.Label1.Visible = True
Me.Image0.Visible = True
ElseIf Me.Combo10.Column(1) = Label2 Then
Me.Label2.Visible = True
Me.Image1.Visible = True
EndIf
End Sub


The Labels are their names while the Images are the floor plans of the building.

The only issue is with 800 employees this code would get very long very quickly.
 

Shadoz

New member
Local time
Today, 03:00
Joined
Dec 14, 2018
Messages
3
There is already a system in place when a 911 call is received that Security receives an email with the name of employee and floor number.

The form I'm making will allow the officer to then input the persons name and find exactly where their office is.
 

Dreamweaver

Well-known member
Local time
Today, 11:00
Joined
Nov 28, 2005
Messages
2,466
the first problems you will have will be major ones in that each floor might have a different layout, employees will get moved around and the floor plan could be changed.


I haven't actully done this but create a form with an image frame to the size of the form then add a label the size of a square above the Image and try to move the label around the form you can find the postions of the label by looking at the property sheet.


you might find an example buy googling access move controls.
 

Dreamweaver

Well-known member
Local time
Today, 11:00
Joined
Nov 28, 2005
Messages
2,466
There is already a system in place when a 911 call is received that Security receives an email with the name of employee and floor number.

The form I'm making will allow the officer to then input the persons name and find exactly where their office is.


thats one problem solved lol
 

Eugene-LS

Registered User.
Local time
Today, 13:00
Joined
Dec 7, 2018
Messages
481
...when a Security Officer types in the individuals name into a combobox the image of their floor would appear and their name would be highlighted where their office is. This would enable quick response from the officer if necessary.
Thank you.
IMHO to use combobox is not best solution.

I guess you will have more then 50 rows in it (and mb much more) .
Use continuous form with textbox (in form header) to filter form with operator "Like ..." in filter string by value in that textBox.
see :
Form.Filter Property
Form.FilterOn Property
 
Last edited:

Micron

AWF VIP
Local time
Today, 06:00
Joined
Oct 20, 2018
Messages
3,478
There is already a system in place when a 911 call is received that Security receives an email with the name of employee and floor number.
I don't suppose that system could make use of tblEmpLocation in your db and include the info in the email? Regardless, all depends heavily on someone keeping location info up to date.

I once worked on a proposal that never got off the ground, but the concept was valid. That involved accepting the selection of a Visio drawing element and creating data from it. If you have Visio, it's likely that you could highlight a drawing element of a Visio drawing to show where someone is located, based on Access data, which is the reverse of that concept. I suppose any solution depends on someone being at or near their desk as opposed to calling from another location because they found someone in need of 911 assistance in another area. That situation might actually cause a delayed emergency response.
 

MajP

You've got your good things, and you've got mine.
Local time
Today, 06:00
Joined
May 21, 2018
Messages
8,527
I do not know about the utility, but it sounds doable. I do something like this, but only using a single map. However, the concept should work the same. You only have so many offices.
I have a table of cities and a large us map. I store in a table the city ID and the x, y (top, left) location. It took a while, but was not super long to figure out the x,y for each city. I was using a map which is not a true flat projection so I had to physically click on the map. If you had a scaled floor plan with known real distances on it, you may even be able to calculate the access image x,y based on the physical distance without having to physically click on the image.

In your case you would then need room ID in the employee table. In the Room table you would have Floor Plan and X, Y location. Then when you select a person it brings up the correct floor plan and moves a label on that room with their name and other information. This way the only need a single label. But if it is not too many you could just put a lot of labels on a form and give the name a room/location id. Like lblRoom123. Then hide all labels and show the label for that room. However, that sounds like what you have and not sure why it is not working. Please post the combo code.
 

Dreamweaver

Well-known member
Local time
Today, 11:00
Joined
Nov 28, 2005
Messages
2,466
I do not know about the utility, but it sounds doable. I do something like this, but only using a single map. However, the concept should work the same. You only have so many offices.
I have a table of cities and a large us map. I store in a table the city ID and the x, y (top, left) location. It took a while, but was not super long to figure out the x,y for each city. I was using a map which is not a true flat projection so I had to physically click on the map. If you had a scaled floor plan with known real distances on it, you may even be able to calculate the access image x,y based on the physical distance without having to physically click on the image.

In your case you would then need room ID in the employee table. In the Room table you would have Floor Plan and X, Y location. Then when you select a person it brings up the correct floor plan and moves a label on that room with their name and other information. This way the only need a single label. But if it is not too many you could just put a lot of labels on a form and give the name a room/location id. Like lblRoom123. Then hide all labels and show the label for that room. However, that sounds like what you have and not sure why it is not working. Please post the combo code.


Nice I will only add that he might only need one or 2 labels but it does depend on how many people call 911 so maybe 20 labels but as already commented a person might use somebody elses phone in an emergancy.
 

jdraw

Super Moderator
Staff member
Local time
Today, 06:00
Joined
Jan 23, 2006
Messages
15,377
Shadoz,

Has your employer given you any details for this floor tool?
Do you need real floor plan, or could a generic grid for each floor suffice?
Can you add on to the existing 911 system? A field for the Person' office number might be sufficient?? Especially if office numbers indicate w/n/e/s etc.

I like majP's idea and if you have floor plans or similar, all of same size, you may simplify you coordinates assignment process. Again, it would be good to know the level of detail/complexity of the proposed tool.

You may get some ideas from this link to a database by ChrisO (now deceased).
 

Users who are viewing this thread

Top Bottom