Search tool in current form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a wonderfully designed form with lots of sub forms and tabs and command buttuons and what not, but I am stuck on trying to create a search tool

I have so many tables of info its crazy

The idea of this database is to findout what type of items are in certain room during the construction of an office building

The main tables I need to get info from are a Fixtures table and a Furniture table, both of these tables are related to another tables called Rooms adn they are related to the Rooms tables by a PK, RoomID

Basicly what I need to do is Search for a specific item in a table and the quantity of that item and I need that to 'magically' pop up on the form somewhere

I am dazed and confused about how I need to go about this.

Any help would be really apperciated

Dave
 
Your tables should look like:

TblFixture
FixtureID
FixtureName

TblFurniture
FurnitureID
FurnitureName

TblRooms
RoomID
RoomNum

TblFixtureInRoom
FixtureInRoomID
RoomID
FixtureID
QuantityOfFixture

TblFurnitureInRoom
FurnitureInRoomID
RoomID
FurnitureID
QuantityOfFurniture

You can search for fixtures and quantity in a certain room by using the DCount
function. Your form apparently contains RoomID so you just need to add a
combobox to get the fixtureID. Put the DCount function in the control source of
a textbox:
=DCount("[QuantityOfFixture]","TblFixtureInRoom","[RoomID] = " &
Forms!NameOfYourForm!RoomID & " [FixtureID] = " &
Forms!NameOfYourForm!NameOfFixtureComboBox")

Furniture and quantity would be found the same way.


--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
(e-mail address removed)
www.pcdatasheet.com


Dave said:
I have a wonderfully designed form with lots of sub forms and tabs and command
buttuons and what not, but I am stuck on trying to create a search tool.
I have so many tables of info its crazy.

The idea of this database is to findout what type of items are in certain room
during the construction of an office building.
The main tables I need to get info from are a Fixtures table and a Furniture
table, both of these tables are related to another tables called Rooms adn they
are related to the Rooms tables by a PK, RoomID.
Basicly what I need to do is Search for a specific item in a table and the
quantity of that item and I need that to 'magically' pop up on the form
somewhere.
 
Back
Top