Gammatech Posted November 3, 2010 Share Posted November 3, 2010 I have a ComboBox called TrendParameterCombo with 7 Choices of parameter to display that I make visible on a button press. As it becomes visible I would like to have something in the box such as 'Select' or similar. I have tried adding the line Component.TrendParameterCombo.StrContents = "Select" immediately before the line that shows the comboBox Component.TrendPrameterCombo.Visible = 1 but this seems to have no effect. The properties of the Component show under Contents only the StrSetChannel = TrendParameter Which is as I set it up. There is no entry for StrContents Clicking on the small down arrow shows the 7 choices I have given and after one has been selected the box then has that displayed but there is still no corresponding entry in the properties. Watching the StrContents of the component shows the word 'Select' initially and then the chosen parameter but I can't seem to get it to display on the screen. What am I doing wrong? Martin Link to comment Share on other sites More sharing options...
AzeoTech Posted November 3, 2010 Share Posted November 3, 2010 You have the correct syntax, however, the string you select MUST be one of the choices in the combo box. So, if "Select" isn't a choice, it won't fill it in. Link to comment Share on other sites More sharing options...
Gammatech Posted November 3, 2010 Author Share Posted November 3, 2010 So is there no other way of prompting the user to select from the available choices. If not I will just have to load one of the choices by default or add the 'select parameter' prompt to the choices with an easily detectable value so that I can trap it out. Could this be added to the wish list for improvements in a later version. Martin Link to comment Share on other sites More sharing options...
AzeoTech Posted November 3, 2010 Share Posted November 3, 2010 Sure, add it to the wish list section of the forum. The truth is that this is a standard Windows characteristic of combo boxes that don't let the user type things in, so I'm not completely sure its feasible. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.