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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Vertical Caption in MSForm

Status
Not open for further replies.

PBAPaul

Programmer
Aug 3, 2002
140
GB
Hi

I have a form where I have 20 combo-boxes in a line. These represent the useage of rooms in a hotel.

I want to place captions above each of these combo-boxes to show the name of the appropriate room. The best way would be for the captions to read vertically ie text turned through 90 degrees. I have to fill the captions via VBA with the room names.

Does anyone have any idea how I can do this?

Merry Christmas to all.

Paul
 
1. 20 comboboxes in a line? That is a lot of horizontal distance. Why are you do it that way?

2. Why is it the best way to have the "caption" vertical - and I am assuming you actually mean separate labels...yes? Comboboxes do not have captions.

3. Perhaps unfortunately (although I personally do not think so) text in labels is kerned. You can TRY playing around with resizing the label to get it to show only one letter - assuming of course you have Word Wrap as True. But because it IS kerned it is very difficult to get single letters vertically.

I do not know what your UserForm looks like, but perhaps a rethink on the design may be a good idea.

Gerry
 
Create Images (in an application like paint) and use the images as the labels for your combo boxes.

HTH,
CMP

Not sure if this works, I only skimmed the book that came with the software.
 
It can be done. Here's one of the hard bits: rotating the text: thread222-45652

Note that the code there requires an hDC, which is not normally presented by the MS Forms library used by VBA - so I'll leave it as an exercise for you on getting hold of one ...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top