FarleySoftware
Programmer
I'm working with a client who has a FormView on an ASP.NET (VB) page, displaying a single record pulled from SQL using a SQLDataSource on the page.
Some of the data are address or phone fields that may be blank. If they're blank, there should be no white space/blank lines, and any accompanying labels must be hidden.
Example:
123 Any Town
Somewhere, NY 10101
Phone: 212-555-1212
Toll-Free:
Should look like:
123 Any Town
Somewhere, NY 10101
Phone: 212-555-1212
("Phone:" appears in a label)
Two questions:
1. Is a databound FormView the best choice of control in this situation?
2. What's the best way to hide controls, without leaving white space? (thinking use of a panel would do the trick if that's not overkill, but wasn't sure ofhow exactly to refer to the controls within ItemTemplate of a formview)
Thanks in advance.
Farley Software Solutions
Some of the data are address or phone fields that may be blank. If they're blank, there should be no white space/blank lines, and any accompanying labels must be hidden.
Example:
123 Any Town
Somewhere, NY 10101
Phone: 212-555-1212
Toll-Free:
Should look like:
123 Any Town
Somewhere, NY 10101
Phone: 212-555-1212
("Phone:" appears in a label)
Two questions:
1. Is a databound FormView the best choice of control in this situation?
2. What's the best way to hide controls, without leaving white space? (thinking use of a panel would do the trick if that's not overkill, but wasn't sure ofhow exactly to refer to the controls within ItemTemplate of a formview)
Thanks in advance.
Farley Software Solutions