Dynamic Forms

  • Thread starter Thread starter Dan Diephouse
  • Start date Start date
D

Dan Diephouse

I need to implement a couple forms for our application which are
dynamic. For instance, I have a question and several possible answers
which the user can select. I don't know the question/answers at design
time, so I need to create the form on the fly. My question is: when I'm
placing these controls whats the best/easiest way to tell how much space
I need for a label given the text string?

For instance the question "Do you like ice cream?" will certainly take
less space than "Do you like chocolate-fudge-peanut-butter ice cream?"
I need to figure out how many lines they will take given a font and font
size.

Cheers,

- Dan
 
in my custom controls i m using Graphics.MeasureString. it gives the
size (width and height) of a string according to the font.
i don't know if it could help you.
 
Naim said:
in my custom controls i m using Graphics.MeasureString. it gives the
size (width and height) of a string according to the font.
i don't know if it could help you.

Thats perfect. Thanks!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Continuous Forms and Requery 1
Continuous Forms and Requery 1
Lactose free recipies? 2
VLOOKUP 2
ASPX Form Process 3
Old age? 7
pop up a form based on a check box 5
Too many Eggs ... Bread Pudding sugestions? 16

Back
Top