A
Anton
Hi,
I have made a composite control with in it the Ajax
CollapsiblePanelExtender.
If i use the CollapsiblePanelExtender on its own i can use a skinfile
to set both the CollapsedImage and the ExpandedImage.
In my composite control however the image cannot be found. The problem
is probably in the way i pass the information from mycontrol to the
CollapsiblePanelExtender control.
Below some code:
Skin File:
<cc1:MyControl runat="server"
CollapsedImage="Images/Panels/expand.jpg"
ExpandedImage="Images/Panels/collapse.jpg" />
MyControl.cs:
..
..
public virtual string ExpandedImage
{
get
{
string s = (string)ViewState["ExpandedImage"];
return (s == null) ? String.Empty : s;
}
set {ViewState["ExpandedImage"] = value;}
}
// CollapsedImage is the same
..
..
protected override void CreateChildControls()
{
..
..
extender = new CollapsiblePanelExtender();
extender.ExpandedImage = ExpandedImage;
extender.CollapsedImage = CollapsedImage;
..
..
}
The result is that the image src is set to the relative path of the
current aspx page.
Anyone can help me with this?
I have made a composite control with in it the Ajax
CollapsiblePanelExtender.
If i use the CollapsiblePanelExtender on its own i can use a skinfile
to set both the CollapsedImage and the ExpandedImage.
In my composite control however the image cannot be found. The problem
is probably in the way i pass the information from mycontrol to the
CollapsiblePanelExtender control.
Below some code:
Skin File:
<cc1:MyControl runat="server"
CollapsedImage="Images/Panels/expand.jpg"
ExpandedImage="Images/Panels/collapse.jpg" />
MyControl.cs:
..
..
public virtual string ExpandedImage
{
get
{
string s = (string)ViewState["ExpandedImage"];
return (s == null) ? String.Empty : s;
}
set {ViewState["ExpandedImage"] = value;}
}
// CollapsedImage is the same
..
..
protected override void CreateChildControls()
{
..
..
extender = new CollapsiblePanelExtender();
extender.ExpandedImage = ExpandedImage;
extender.CollapsedImage = CollapsedImage;
..
..
}
The result is that the image src is set to the relative path of the
current aspx page.
Anyone can help me with this?