Mark i do this trick by using Button like with a style sheet:- ..buttonStyle { FONT-WEIGHT: bold; FONT-SIZE: 7pt; TEXT-TRANSFORM: capitalize; COLOR: white; FONT-FAMILY: Verdana; BACKGROUND-COLOR: #7da1e9 } <asp:ButtonColumn Text="Hello" ButtonType="PushButton" /> And on ItemCreated i set the CSClass by :- Dim myButton As Button = CType(e.Item.Cells(0).Controls(0), Button) myButton.CssClass = "buttonStyle" Hope it helps Patrick *** Sent via Developersdex http://www.developersdex.com ***
Hi, Is there any way to modify the style of the button portion of an HtmlInput control? I have a CSS class which I use for all of the buttons to try to make them a little less ugly than the standard grey but, if I apply this to an HtmlInput control, all that does is change the background and foreground colours in the textbox portion. Similarly, if I modify the style attribute, that only applies to the textbox portion too. Is there any way to change the appearance of the button portion of an HtmlInput control? Any assistance gratefully received. Best, Mark Rae
[quoted text, click to view] "Patrick Olurotimi Ige" <ige@iprimus.com.au> wrote in message news:%23TSwm4EIFHA.572@tk2msftngp13.phx.gbl... > with a style sheet:- > > buttonStyle { FONT-WEIGHT: bold; FONT-SIZE: 7pt; TEXT-TRANSFORM: > capitalize; COLOR: white; FONT-FAMILY: Verdana; BACKGROUND-COLOR: > #7da1e9 } > > <asp:ButtonColumn Text="Hello" ButtonType="PushButton" /> > > And on ItemCreated i set the CSClass by :- > > Dim myButton As Button = CType(e.Item.Cells(0).Controls(0), Button) > myButton.CssClass = "buttonStyle"
Patrick, Unless I'm much mistaken, this code is to change the style of a ButtonColumn in a DataGrid...?
Man, your question is throwing me in circles. You keep going back and forth. The HTMLInputText does not have a button, its just a plain old textbox. Are you referring tot he HTML File upload control?? I suggest you post a url where you page is hosted or something. [quoted text, click to view] "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message news:OMsyXNwIFHA.1860@TK2MSFTNGP15.phx.gbl... > Does anyone have any thoughts on this...? > > "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message > news:OhknAcEIFHA.2656@TK2MSFTNGP09.phx.gbl... >> Hi, >> >> Is there any way to modify the style of the button portion of an >> HtmlInput control? I have a CSS class which I use for all of the buttons >> to try to make them a little less ugly than the standard grey but, if I >> apply this to an HtmlInput control, all that does is change the >> background and foreground colours in the textbox portion. >> >> Similarly, if I modify the style attribute, that only applies to the >> textbox portion too. >> >> Is there any way to change the appearance of the button portion of an >> HtmlInput control? >> >> Any assistance gratefully received. >> >> Best, >> >> Mark Rae >> > >
Does anyone have any thoughts on this...? [quoted text, click to view] "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message news:OhknAcEIFHA.2656@TK2MSFTNGP09.phx.gbl... > Hi, > > Is there any way to modify the style of the button portion of an HtmlInput > control? I have a CSS class which I use for all of the buttons to try to > make them a little less ugly than the standard grey but, if I apply this > to an HtmlInput control, all that does is change the background and > foreground colours in the textbox portion. > > Similarly, if I modify the style attribute, that only applies to the > textbox portion too. > > Is there any way to change the appearance of the button portion of an > HtmlInput control? > > Any assistance gratefully received. > > Best, > > Mark Rae >
For that control, I think the same style for the button and the textbox would have to be the same. I don't think you can split the style between the two by default. You can always inherit from controls and style them the way you want, even though this is a pain in the a$$ sometimes. [quoted text, click to view] "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message news:OeoyQbzIFHA.2136@TK2MSFTNGP14.phx.gbl... > "Tampa.NET Koder" <anonymous@microsoft.com> wrote in message > news:%23KbDCvwIFHA.1172@TK2MSFTNGP12.phx.gbl... > > Sorry, I'm referring to HtmlInputFile... :-( > > >> "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message >> news:OMsyXNwIFHA.1860@TK2MSFTNGP15.phx.gbl... >>> Does anyone have any thoughts on this...? >>> >>> "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message >>> news:OhknAcEIFHA.2656@TK2MSFTNGP09.phx.gbl... >>>> Hi, >>>> >>>> Is there any way to modify the style of the button portion of an >>>> HtmlInput control? I have a CSS class which I use for all of the >>>> buttons to try to make them a little less ugly than the standard grey >>>> but, if I apply this to an HtmlInput control, all that does is change >>>> the background and foreground colours in the textbox portion. >>>> >>>> Similarly, if I modify the style attribute, that only applies to the >>>> textbox portion too. >>>> >>>> Is there any way to change the appearance of the button portion of an >>>> HtmlInput control? >>>> >>>> Any assistance gratefully received. >>>> >>>> Best, >>>> >>>> Mark Rae >>>> >>> >>> >> >> > >
[quoted text, click to view] "Tampa.NET Koder" <anonymous@microsoft.com> wrote in message news:%23KbDCvwIFHA.1172@TK2MSFTNGP12.phx.gbl...
Sorry, I'm referring to HtmlInputFile... :-( [quoted text, click to view] > "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message > news:OMsyXNwIFHA.1860@TK2MSFTNGP15.phx.gbl... >> Does anyone have any thoughts on this...? >> >> "Mark Rae" <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote in message >> news:OhknAcEIFHA.2656@TK2MSFTNGP09.phx.gbl... >>> Hi, >>> >>> Is there any way to modify the style of the button portion of an >>> HtmlInput control? I have a CSS class which I use for all of the buttons >>> to try to make them a little less ugly than the standard grey but, if I >>> apply this to an HtmlInput control, all that does is change the >>> background and foreground colours in the textbox portion. >>> >>> Similarly, if I modify the style attribute, that only applies to the >>> textbox portion too. >>> >>> Is there any way to change the appearance of the button portion of an >>> HtmlInput control? >>> >>> Any assistance gratefully received. >>> >>> Best, >>> >>> Mark Rae >>> >> >> > >
[quoted text, click to view] "Tampa.NET Koder" <anonymous@microsoft.com> wrote in message news:Oxpvkm0IFHA.3064@TK2MSFTNGP12.phx.gbl... > For that control, I think the same style for the button and the textbox > would have to be the same.
No matter what I try, any styles I set are applied to the textbox portion only - seems it's impossible to modify the style of the button portion.
On Mon, 7 Mar 2005 19:39:44 -0000, "Mark Rae" [quoted text, click to view] <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote: >"Tampa.NET Koder" <anonymous@microsoft.com> wrote in message >news:Oxpvkm0IFHA.3064@TK2MSFTNGP12.phx.gbl... > >> For that control, I think the same style for the button and the textbox >> would have to be the same. > >No matter what I try, any styles I set are applied to the textbox portion >only - seems it's impossible to modify the style of the button portion.
Forget ASP.NET for a minute. Just create a simple HTML webform with a file input control on it, and try to change the style on the button. It's pretty much impossible to do it. pj --
[quoted text, click to view] "pj" <pj@psychedelicjones.com> wrote in message news:vhep2113goa0av3m7qjsfjdvrromlnfhk1@4ax.com... > Forget ASP.NET for a minute. Just create a simple HTML webform with a > file input control on it, and try to change the style on the button. > It's pretty much impossible to do it.
Yes indeed - anybody know how...?
On Mon, 7 Mar 2005 20:56:41 -0000, "Mark Rae" [quoted text, click to view] <mark@mark-N-O-S-P-A-M-rae.co.uk> wrote: >"pj" <pj@psychedelicjones.com> wrote in message >news:vhep2113goa0av3m7qjsfjdvrromlnfhk1@4ax.com... > >> Forget ASP.NET for a minute. Just create a simple HTML webform with a >> file input control on it, and try to change the style on the button. >> It's pretty much impossible to do it. > >Yes indeed - anybody know how...?
No, nobody does :-). I just put the "pretty much" in to CMA. I think what you're trying to do is in fact impossible. pj --
Mark sorry i posted another style.. But u can also apply a similar style to input button. <input type="button" style="PUT UR STYLE HERE"/> Hope it helps Patrick *** Sent via Developersdex http://www.developersdex.com ***
[quoted text, click to view] "Patrick Olurotimi Ige" <ige@iprimus.com.au> wrote in message news:eklmI58IFHA.3928@TK2MSFTNGP09.phx.gbl... > But u can also apply a similar style to input button. > <input type="button" style="PUT UR STYLE HERE"/> > Hope it helps
How does this apply to an HtmlInputFile control...?
Don't see what you're looking for? Try a search.
|