Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Invisible Results in Combo Box 1

Status
Not open for further replies.

joebb3

Programmer
Feb 27, 2006
87
US
This has been asked before with no resolution... I pasted the question below because the user did a good job of explaining it.

-----

I just created a new form that used a query to populate a drop down list box.

The bizzare thing is that if you click on the box, nothing shows up in the list, but if you select a line (blank) and click on it, the value that would show up appears in the top of the dropdown box.

----

Here is the weird part. Its a 2 column query, Month and a sort order...

Month Sort
OCT 1
NOV 2
...
SEP 12

If I show BOTH columns, the SORT column is VISIBLE (you can see the numbers) but the actual months are invisible as stated above.

I have 2 other combo boxes on the same form that work perfectly and have the exact same properties! The only differences are:

Name: MONTH
Row Source: MONTH QUERY (Contains above data.)

I'm NOT new to Access BY FAR and lets face it, an unbound combo box with a Table/Query Row Source Type off of a static query isn't rocket science, but this has go me stumped!!!

Is it an issue of a protected word (month) or something unusual like that?
 
A couple of amplifing remarks:

The actual query runs fine and all data shows in query view.

I tried a NEW form with a brand new combo box, default properties, and the same thing happens!
 
I have tried various settings there... ALL of which should have worked. None did. Right now I have,

Column count: 2
Column Widths: 1";0"
Bound Column: 1
List Rows: 8
List Width: Auto

I have checked the formatting of the box as well... The

Fore Color: 0
Font Name: Times Roman
Font Size: 10
Font Weight: Normal
Text Align: Left


Thanx for the reply!

Joe
 
Month" is the name of a function so you should never use "Month" as the name of anything.

I agree with pwise. How about providing all the significant properties of the combo box since we aren't sitting at your computer.

Duane
Hook'D on Access
MS Access MVP
 
try
Column count: 2
Column Widths: 1";0"
Column Widths: 0";1"
Bound Column: 1
List Rows: 8
List Width: Auto
 
What is the SQL view of MONTH QUERY? Why does your combo box have 2 columns when you display the same column that is bound? Are you reference the value of the 2nd column some where?

Duane
Hook'D on Access
MS Access MVP
 
dhookom,
I changed all the lables, tables, querys and field names to stay away from possible protected words... No Joy. The properties are posted above.

pwise,
No Joy... The Name of the Month is in the first column, the sort is in the second. when I did as you suggested, I got the sort numbers VISIBLE.

1
2
3
...
12

Changing it back gives me invisible Months again.
 
Try this Sql
Code:
Select MonthName
From TableName
Order by SortColumn

Column count: 1
Column Widths: 1"
Bound Column: 1
List Rows: 8
List Width: Auto
 
dhookom,

SELECT MonthVals.MNTH, MonthVals.FYM
FROM MonthVals
ORDER BY MonthVals.FYM;


Notice, I changed all the names to get rid of the possible protected word.

Basically, the actual month name goes into the data (user request) from column 1, I use the sort Column (FYM) to sort the months by ficsal year. The sort is the only reason for the second column.
 
use This

Code:
SELECT MonthVals.MNTH
FROM MonthVals
ORDER BY MonthVals.FYM;

Column count: 1
Column Widths: 1"
Bound Column: 1
List Rows: 8
List Width: Auto

 
No joy. Arrgh! It makes me feel like I failed Basis Access 101!

my query now as suggested:

Code:
SELECT MonthVals.MNTH
FROM MonthVals
ORDER BY MonthVals.FYM;

I have a screen shot, but have no way to get it to a server from work.

Basically it shows, a blank combo box with a blank line selected, if you click the blank line, "January" VISIBLE appears as the selected value.

If I do a VALUE list, and manually type in alll the months, the combo works fine.
 
how about


SELECT MonthVals.MNTH
FROM MonthVals
Where MonthVals.MNTH>""
ORDER BY MonthVals.FYM;
 
I see where you are going, but the thing is the query (in query view) displays perfectly with no "extra" lines... I DID as you suggested and... No joy.
 
All STOP! I found it!

In my table, under format, I had a > sign. I took it ou and all works now.

So if you are having a similar issue, you may want to look really close at your table. Don't over do formatting. I had a > under formatting in my query too, but that is ok.

Thanx guys!
 
Yes I am... Known issue?

If anyone has a good like to known issues, it would be appreciated! =)
 
A Quick Testimonial:

I am so thankful that, years ago, I stumbled on to Tek-tips!

In my various jobs, I have implemented various databases over the years, and the information that I have found here at Tek-tips has been invaluable.

I learned VBA by the seat of my pants. Knowing that databases should be MORE than a place to keep a table of data, I set out to develop data APPLICATIONS vice data store houses.

Whenever I ran into a snag, needed a fresh idea or was down right STUCK... The Tek-tips community was there to point me in the right direction. Most of the time the posters would only give me a nudge toward the correct path enabling me to LEARN how to overcome a bump rather than flatten it for me, but if I couldn't quite figure it out, the community was also willing to fix the code to get me past the bump.

I cannot thank this community enough. My data applications have greatly improved and my knowledge level has increase tremendously thanks to your expert council!

Forever Grateful,
Joe Barneski
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top