Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > Styling DetailView or FormView

Reply
Thread Tools

Styling DetailView or FormView

 
 
Larry Charlton
Guest
Posts: n/a
 
      12-22-2005
Does anyone have sites or references on applying layout and style to
DetailView and/or FormView controls?

It just seems like microsoft made these a bit rough to apply style sheets
to. DetailView you can apply a style to the label, but to format the data
you have to apply a format to the row (which I'm assuming would be there, and
not desireable, when it switches to edit view)

The formview layout seems just wrong. prompt control <br/>? How do you
format the prompt to be a consistent width or on top of the controls, etc.
Leaving you to manually change the HTML for *3* versions of the same form?

Also is does anyone know if there is an easy way to add new styles (of your
own design) to the list of styles supplied by Microsoft? Say to use your
color scheme.
 
Reply With Quote
 
 
 
 
Phillip Williams
Guest
Posts: n/a
 
      12-22-2005
Hi Larry,

To style the FormView in your own way, use the templates, e.g. ItemTemplate,
EditItemTemplate, etc.. Here is an example:
http://www.webswapp.com/CodeSamples/...FormView1.aspx
--
HTH,
Phillip Williams
http://www.societopia.net
http://www.webswapp.com


"Larry Charlton" wrote:

> Does anyone have sites or references on applying layout and style to
> DetailView and/or FormView controls?
>
> It just seems like microsoft made these a bit rough to apply style sheets
> to. DetailView you can apply a style to the label, but to format the data
> you have to apply a format to the row (which I'm assuming would be there, and
> not desireable, when it switches to edit view)
>
> The formview layout seems just wrong. prompt control <br/>? How do you
> format the prompt to be a consistent width or on top of the controls, etc.
> Leaving you to manually change the HTML for *3* versions of the same form?
>
> Also is does anyone know if there is an easy way to add new styles (of your
> own design) to the list of styles supplied by Microsoft? Say to use your
> color scheme.

 
Reply With Quote
 
 
 
 
Larry Charlton
Guest
Posts: n/a
 
      12-28-2005
Thanks Phillip. What I'm trying to do, is see if anyone knows a way to apply
css to the pregenerated content to acheive layout. I'd like to provide
prompt properties independantly from the data properties and I'd like to do
it without editing the templates. If I have to resort to editing, I'll just
build a wizard that will output a sane template that can be styled without
editing. It just seems so close to actually being usable and I'm hoping it
just because I'm so new to CSS that I can't seem to get layout and coloring
to work.

"Phillip Williams" wrote:

> Hi Larry,
>
> To style the FormView in your own way, use the templates, e.g. ItemTemplate,
> EditItemTemplate, etc.. Here is an example:
> http://www.webswapp.com/CodeSamples/...FormView1.aspx
> --
> HTH,
> Phillip Williams
> http://www.societopia.net
> http://www.webswapp.com
>
>
> "Larry Charlton" wrote:
>
> > Does anyone have sites or references on applying layout and style to
> > DetailView and/or FormView controls?
> >
> > It just seems like microsoft made these a bit rough to apply style sheets
> > to. DetailView you can apply a style to the label, but to format the data
> > you have to apply a format to the row (which I'm assuming would be there, and
> > not desireable, when it switches to edit view)
> >
> > The formview layout seems just wrong. prompt control <br/>? How do you
> > format the prompt to be a consistent width or on top of the controls, etc.
> > Leaving you to manually change the HTML for *3* versions of the same form?
> >
> > Also is does anyone know if there is an easy way to add new styles (of your
> > own design) to the list of styles supplied by Microsoft? Say to use your
> > color scheme.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
detailview or formview JohnE ASP .Net 1 04-08-2010 09:11 AM
2 columned FormView or DetailView? CWagon ASP .Net 0 08-16-2007 05:39 PM
Formview within Formview Chris ASP .Net 0 05-19-2007 04:12 PM
FormView/Repeater/ Eval(FormView data) David Thielen ASP .Net Web Controls 2 06-16-2006 07:56 PM
Formview Detailview null values and insert edit with foreign keys =?Utf-8?B?SGF3aw==?= ASP .Net 0 05-03-2006 06:22 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57