I can't drop down a combo box why?

I have a drop down combo in property sheet page and I added
three items with this code (I can't tell whether it actually adds the items and when I run it onlt shows the first item.

This the code

BOOL Page1::OnInitDialog()
{
      CPropertyPage::OnInitDialog();

      m_Paper.AddString("A4");
      m_Paper.AddString("A4R");
      m_Paper.AddString("A3");
      m_Paper.AddString("Acetate");
      m_Paper.SetCurSel(0);
      
      return TRUE;  // return TRUE unless you set the focus to a control
}

help!!

Thanks
LVL 12
gbzhhuAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
captainkirkConnect With a Mentor Commented:
Thank you ...
0
 
captainkirkCommented:
You only see the first item until you click on the arrow button of the combo box. If on the other hand, this is not the problem, the only thing I have run into is that you need to right click on the arrow button when in the form designer and drag the outline down so that you can resize the displayed list... try that and let me know if that was the issue...
0
 
gbzhhuAuthor Commented:
Hi captainkirk

I do click on the arrow button of the combo box, but it still does not show anything.  It shows a little underline at the bottom of the combo as if about to drop down, but that is about it.

I tried your idea and I don't seem to be able to drag the outline.  When I right click it I only get the context menu, so how can you help.  Info: I have win 98 2nd version and Visual Studio 6 (without the Service Packs)

Please get back to me soon.  I have a lot of points to give and a few easy questions which are hard for me as I am a beginner to VC++

Cheers
0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
captainkirkCommented:
Sorry - I said right click on the combo box's arrow button when in the form designer when I meant left click...
0
 
gbzhhuAuthor Commented:
By the way, I have just created a new app wizard dialog based application, put my combo code and it works fine.

The only difference is that my application is not  dialog based. It is a property sheet based application.  Do you any problems with property sheets.  I wanted at first to have a dialog based app with a tab control (CTabCtrl) in the dialog, but I could not put controls like combo in the right tab, I mean I could not attach controls to the tab that they should appear.  If this can be done I would very happy.  Now I have the property sheet app which was my second option, I have this problem with the combo box.  Is VC++ always like this or am I just a bad beginner

Cheers
0
 
captainkirkCommented:
Shouldn't be any difference between putting the ComboBox on a dialog or a PropertySheet... it's still going to be a child window...

did you try the left click on the combo box's arrow when designing your form??
0
 
gatkinsoCommented:

Make sure the resource element is drawn large enough to show the list box portion of the combobox.  
0
 
gbzhhuAuthor Commented:
Captiankirk,

Thanks, your solution worked, mid you I had to uncheck the Vertical Scroll property, before it would let me see the outline.

Please put a dummy question so that i can give the points.

Thank you other guys for contributing your ideas

 
0
 
captainkirkCommented:
You will have to first reject any outstanding answers, then it will open up for another answer to be posted...

thanks...
0
 
gbzhhuAuthor Commented:
Your answer was correct, but you failed to tell me how to make the combo large and as I am a beginner captainkirk told me and he will have the points.

Thanks for participating
0
 
gbzhhuAuthor Commented:
cheers captainkirk
0
All Courses

From novice to tech pro — start learning today.