Formview doesn't work on update with asp:Table. Now what?

D

David

I'm pretty new at ASP.Net, and I have run into a problem. I have been tasked
to write an application, and it is supposed to mimic an existing form,
including layout, as closely as possible. A page contains information about
a single part, but there are lots of fields.

An asp:formview object seemed like an obvious choice, so I made one of
those. Then, since I had to specify layouts to match an existing form, I
needed a way to position the fields properly, so I used an asp:Table, along
with asp:TableRow and asp:TableCell objects. So far so
good....except....there's a bug and asp:Table objects don't end up updating
the database when you put them in an EditItemTemplate, so you can't really
use them in a FormView.

I have substited a plain old <table> object, with <tr> and <td> tags, and
that seems to work, but it isn't as easy to deal with as their <asp:>
equivalents.

Is there a more "standard" way of dealing with forms that take their data
from a single data row, and have to be formatted with particular layouts that
aren't based on a grid-like layout?
 
A

Allen Chen [MSFT]

Hi David,
Is there a more "standard" way of dealing with forms that take their data
from a single data row, and have to be formatted with particular layouts that
aren't based on a grid-like layout?

I believe what you did is the "standard" way. To get a more flexible
layout, <div> is a better choice than <table>, however. The following
article compares <div> with <table>.

http://css-discuss.incutio.com/?page=TablesVsDivs

Please try to use <div> and feel free to ask if you have additional
questions.

Regards,
Allen Chen
Microsoft Online Support

Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
(e-mail address removed).

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subscriptions/aa948868.aspx#notifications.

Note: MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 2 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions. Issues of this
nature are best handled working with a dedicated Microsoft Support Engineer
by contacting Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/en-us/subscriptions/aa948874.aspx
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
 
A

Allen Chen [MSFT]

Hi David,
Is there a more "standard" way of dealing with forms that take their data
from a single data row, and have to be formatted with particular layouts that
aren't based on a grid-like layout?

Do you have any progress on this issue?

Regards,
Allen Chen
Microsoft Online Support
 

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

Members online

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,708
Latest member
SherleneF1

Latest Threads

Top