Hello,
I have basic, local reporting working very well in my Windows Forms application via ReportParameters.
On my report, I have a TextBox, the value of which is bound to a parameter.
It is possible that this value can be empty (or null, if you wish). If this is the case, then I do not want the TextBox to appear at all. Specifically, I want it to shrink and I'd like all of the other controls (also TextBoxes) beneath it to shift "up". It's basically a Shrink operation, but I can't figure out how to get a TextBox to shrink completely, depending on its value, at runtime...
Thanks for any help,
--Mike

How to conditionally hide a TextBox on a Report, shifting the rest of the contents up?
Clinton Cherry
Fran-1980
One thing I've tried is to make the TextBox height 0 inches, with the hope of getting them to "grow" automatically with the presence of any text. I would then need to do something similar for the spacing, putting in an empty string (or null value ) to get it to expand if necessary.
I feel though that this is kind of hacky/kludgy, and was hoping for direction on a more appropriate way to do this.
Thank you,
--Mike
Justin Tang
Mike,
Can you elaborate on your "with a few tweaks"
TIA
JacobEgholm
Thanks so much for your response. I did exactly as you suggest, and with a few tweaks I have the report output pretty much perfect. I know you're busy--thanks for the response, and thanks to you and Brian for all of your help over the past few days.
It's really great to have an effective reporting solution built in! I never was a fan of the alternatives.
Good job, guys!
--Mike