Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / New Users / September 2007

Tip: Looking for answers? Try searching our database.

ComboBox results

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Steve - 20 Sep 2007 14:50 GMT
I have a ComboBox on a form with the following in the Row Source "SELECT
tblWorkOrders.ID, tblWorkOrders.[Work Order Number],
tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
JackPoland - 20 Sep 2007 15:48 GMT
It looks like there is no records with tblWorkOrders.Status "Open".

> I have a ComboBox on a form with the following in the Row Source "SELECT
> tblWorkOrders.ID, tblWorkOrders.[Work Order Number],
> tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
scubadiver - 20 Sep 2007 15:50 GMT
You are selecting three columns.

In the format list in the properties set the number of columns to "3" and
change the widths.

In the data tab set the "bound column" to the appropriate number

Signature

"Loose Change 2nd Edition" has been seen by almost 7 million people on
Google video

> I have a ComboBox on a form with the following in the Row Source "SELECT
> tblWorkOrders.ID, tblWorkOrders.[Work Order Number],
> tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
Steve - 20 Sep 2007 16:20 GMT
I have made sure that there are rows with Status= "Open" and even set Column
Headers to display. The number of columns was set to 3 and the widths set and
the Bound Column is set to 1. No display on the form. I'm dumbfounded or
maybe just dumb.

> You are selecting three columns.
>
[quoted text clipped - 7 lines]
> > tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> > Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
Steve - 20 Sep 2007 16:48 GMT
I sometimes now get the following error
Syntax error (missing operator) in query expression '[Work Order Number]
where tblWorkOrders.Status="Open"

> I have made sure that there are rows with Status= "Open" and even set Column
> Headers to display. The number of columns was set to 3 and the widths set and
[quoted text clipped - 12 lines]
> > > tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> > > Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
Steve - 20 Sep 2007 17:42 GMT
If I remove the Where clause I get a list of all work orders but as soon as I
try to enter a "Where" clause to only get the "Open" work orders I get the
previously sent error message. The table is "tblWorkOrders", the field is
"Status" and  valid data is "Open". Help please.

> I sometimes now get the following error
> Syntax error (missing operator) in query expression '[Work Order Number]
[quoted text clipped - 16 lines]
> > > > tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> > > > Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
scubadiver - 20 Sep 2007 18:12 GMT
What I normally do is create the query first in design view, view it and
then select it from the list in the "data" properties of the combo (just so I
know the information is correct).

I am at a loss as to why this is happening.

Are you sure the column you are selecting to be stored in the table is valid
for the field.

> If I remove the Where clause I get a list of all work orders but as soon as I
> try to enter a "Where" clause to only get the "Open" work orders I get the
[quoted text clipped - 21 lines]
> > > > > tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> > > > > Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
Steve - 20 Sep 2007 18:38 GMT
Thanks
I tried using a Query instead of my Select statement in the Row Source and
it worked perfectly. Thanks mucho

> What I normally do is create the query first in design view, view it and
> then select it from the list in the "data" properties of the combo (just so I
[quoted text clipped - 30 lines]
> > > > > > tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> > > > > > Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
Cheese_whiz - 20 Sep 2007 20:38 GMT
Hi Steve,

I can't swear to it because I've never tried it your way, but I've always
used this order:  Select somefield(s) from sometable where somecondition
order by somefield(s).

You put the where clause last.

Could that make a difference?

CW

> Thanks
> I tried using a Query instead of my Select statement in the Row Source and
[quoted text clipped - 34 lines]
> > > > > > > tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> > > > > > > Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
Steve - 20 Sep 2007 20:42 GMT
Cheezie
Thanks for the thought. I'll try it next time.
Steve

> Hi Steve,
>
[quoted text clipped - 46 lines]
> > > > > > > > tblWorkOrders.Description FROM tblWorkOrders ORDER BY [Work Order Number]
> > > > > > > > Where tblWorkOrders.Status="Open"". The box opens up blank. What am I missing?
Tom Wickerath - 21 Sep 2007 09:40 GMT
Hi CW,

You nailed the issue. Good catch!

Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________

> Hi Steve,
>
[quoted text clipped - 7 lines]
>
> CW
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.