Topbar
Topbar
Sign in
|
Join
|
Client Center
Home
Products
Client Center
Contact
Purchase
Support forums
»
Products
»
Cute Editor for .NET
»
Re: Dynamically set editor background colour VB Re Post 8845
Re: Dynamically set editor background colour VB Re Post 8845
08-03-2009, 5:54 AM
Kenneth
Joined on 02-13-2008
Posts 3,886
Re: Dynamically set editor background colour VB Re Post 8845
Reply
Quote
vb
Public
ReadOnly
Property
bgcol()
As
String
Get
If
Request.QueryString(
"bgcol"
)
Is
Nothing
Then
Return
Nothing
Else
Return
Request.QueryString(
"bgcol"
).ToString()
End
If
End
Get
End
Property
Protected
Overloads
Overrides
Sub
OnLoad(
ByVal
e
As
EventArgs)
If
bgcol IsNot
Nothing
Then
Editor1.EditorBodyStyle =
"background-color:"
& bgcol
End
If
End
Sub
c#
public
string
bgcol
{
get
{
return
(Request.QueryString[
"bgcol"
] ==
null
) ?
null
: Request.QueryString[
"bgcol"
].ToString();
}
}
protected
override
void
OnLoad(EventArgs e)
{
Editor1.EditorBodyStyle =
"background-color:"
+ ((bgcol ==
null
) ?
string
.Empty : bgcol);
}
Ken
View Complete Thread