TopMostItem and enumeration population...


Author
Message
StarkMike
StarkMike
StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)
Group: Forum Members
Posts: 436, Visits: 944
I'm filling a comboboxedit based on an enumeration and using the TopMostItem property... however whenI run my app... the topmost item doesnt appear in my comboboxedit by default.



I've tried setting the selectedvalue to -1 in both the Load and Shown events of the form and tried to set it to -1 on a click event... still no luck.



Any thoughts?
Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
Do you get the same behavior with the StrataFrame combo?
StarkMike
StarkMike
StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)
Group: Forum Members
Posts: 436, Visits: 944
Yes.
Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
THen you must not be setting the TopMostItem properly.  How are you setting this?  You just need to provide a description and a value.  This will only work if you are using an automated population property like the Enumeration.
StarkMike
StarkMike
StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)
Group: Forum Members
Posts: 436, Visits: 944
Here's a screenshot of it's properties. Sorry for the large size... I wanted  you to be able to read it.

I didn't think I was doing anything out of the ordinary.

Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
Give this sample a try Smile
Attachments
TopmostSample.zip (69 views, 34.00 KB)
StarkMike
StarkMike
StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)StrataFrame User (498 reputation)
Group: Forum Members
Posts: 436, Visits: 944
Ok, I FINALLY figured it out... I was trying to set the SelectedValue property to -1 INSTEAD of setting the SelectedIndex property to 0! (0 because I am using the DevExpress wrapped ComboBoxEdit) I HATE it when I make those STUPID mistakes. They are SO frustrating.

Thanks for your help. Wink

Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
LOL...don't worry about it Smile  We have all been there!
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search