Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
76 views
Hello,

I am using Stacked Area to make a shaded background for certain Y-values. The issue I'm having is I want the Stacked Area to extend all the way to the left. Currently it starts at the same place the first chart value starts.

I have attached a screenshot where the stacked area is the green section but as you can see it extends all the way to the right but not the left. Note: the gray line does extend the full width of the graph but I also set an X value that is less than any of the displayed X values. I tried something similar with the Stacked Area but could not get it to work.

Thanks for any help.
Evgenia
Telerik team
 answered on 21 Sep 2011
1 answer
233 views
I would like to know how to disable the telerik styling for the tooltip close button.

I have set the EnableEmbeddedBaseStylesheet="false" EnableEmbeddedSkins="false" Skin="4Cast" but it still renders the telerik styling and because the styling is so specific it supersedes my syles.
This is the tooltip source...
<telerik:RadToolTip runat="server" ID="RadToolTip3" HideEvent="FromCode"
Position="BottomCenter" Animation="slide" CssClass="freeTrialWindow"
ShowEvent="OnClick" ShowDelay="0" RelativeTo="Element" TargetControlID="freeTrialHL"
EnableShadow="true" ManualClose="true" Width="200" Height="200"
EnableEmbeddedBaseStylesheet="false" EnableEmbeddedSkins="false" Skin="4Cast"
RenderInPageRoot="true" ShowCallout="true" Title="Sign up for a free trial" >

The css for the tooltip is...
.RadToolTip_4Cast a.rtCloseButton,
.RadToolTip_4Cast a.rtCloseButton:hover {
    background: url("button/tooltipClose.png") no-repeat center center transparent;
}
 
div.RadToolTip_4Cast table.rtShadow a.rtCloseButton {
    margin: -10px -10px 0 0;
    position: absolute;
    right: 0;
    top: 0;
    background-position: 0 0;
    width: 19px;
    height: 19px;
}
 
.RadToolTip_4Cast a.rtCloseButton:hover {
    background-position: 0 -20px;
}

The main part of the css that i want rendered is the negative margin. This will then display the button in the top right corner slightly out of the box.
The css that gets rendered is this...
div.RadToolTip a.rtCloseButton {
  background-position: 0 0;
  background-repeat: no-repeat;
  display: block;
  float: right;
  font-size: 1px;
  height: 12px;
  line-height: 1px;
  margin-right: 3px;
  margin-top: 3px;
  outline: medium none;
  position: absolute;
  right: 1px;
  text-indent: -9999px;
  width: 12px;
}

And that is the telerik css that is superseding my css.
I dont want to use the !important class modifier and i dont want to make my css so specific that i will never be able to supersede it for something else.

I would just like to disable the predefined styles that telerik puts in. I thought thats what the EnableEmbeddedBaseStylesheet="false" EnableEmbeddedSkins="false" Skin="4Cast"
functions were meant to do?

Thanks in advance for your help.
Bozhidar
Telerik team
 answered on 21 Sep 2011
1 answer
114 views
Hi telerik team,
  I am using radTabStrib in our application which contains 6 tab pages and i have implemented both OnClientTabSelected and OnTabClick events on it.Here i am not getting OnClientTabSelected  result.
This is my code..
   <telerik:RadTabStrip ID="CampaignRadTabStrip" runat="server" SelectedIndex="0" Skin="Default"
                                MultiPageID="RadMultiPage1" Width="100%" ValidationGroup="UpdateValidationGroup(this);"
                                CausesValidation="true" OnTabClick="CampaignRadTabStrip_TabClick" OnClientTabSelected="bind"  >
this is my javascript code:
                function bindConfirmation(sender, args) {
        //            debugger;
                    var tabText = args.get_tab().get_text();
                    var fromName = document.getElementById('<%= txtFromName.ClientID %>').value;

                   var sunjectLine = document.getElementById('<%= txtSubject.ClientID %>').value;
                    var txtFromAddress = document.getElementById('<%= lblFromAddress.ClientID%>').innerHTML;
                    var txtSelectedDate = document.getElementById('<%= txtSelectedDate.ClientID %>').value;
                    var lstBoxListNames = document.getElementById('<%= lstBoxListNames.ClientID%>');
                    //var RadEditor = document.getElementById('<%= RadEditor1.ClientID%>');
                    //var text = RadEditor.GetText();
                    //var textRadEditor = document.getElementById('<%= textRadEditor.ClientID%>');
                    var editor = $find("<%=RadEditor1.ClientID%>"); //get a reference to RadEditor client object
                    var oSelElem = editor.get_text();
                    var Texteditor = $find("<%=textRadEditor.ClientID%>"); //get a reference to RadEditor client object
                    var TSelElem = Texteditor.get_text();
                    var chkTrackReads = document.getElementById('<%= chkTrackReads.ClientID%>');
                    if (tabText == "Confirmation") {

                        if (fromName.length > 0) {
                            document.getElementById('<%=imgFromName.ClientID%>').src = "../Images/Approved-icon.png";
                            document.getElementById('<%=lblFromNameget.ClientID%>').innerHTML = fromName;
                        }
                        else
                            document.getElementById('<%=imgFromName.ClientID%>').src = "../Images/delete-icon.png";

                        if (sunjectLine.length > 0) {
                            document.getElementById('<%=imgSubject.ClientID%>').src = "../Images/Approved-icon.png";
                            document.getElementById('<%=lblSubjectget.ClientID%>').innerHTML = sunjectLine;
                        }
                        else
                            document.getElementById('<%=imgSubject.ClientID%>').src = "../Images/delete-icon.png";


                        if (txtFromAddress.length > 0) {
                            document.getElementById('<%=imgFromAddress.ClientID%>').src = "../Images/Approved-icon.png";
                            document.getElementById('<%=lblFromAddressget.ClientID%>').innerHTML = txtFromAddress;
                        }
                        else
                            document.getElementById('<%=imgFromAddress.ClientID%>').src = "../Images/delete-icon.png";

                        if (lstBoxListNames.length > 0) {
                            document.getElementById('<%=imgContacts.ClientID%>').src = "../Images/Approved-icon.png";
                            document.getElementById('<%=lblContactsget.ClientID%>').innerHTML = lstBoxListNames[0].innerHTML;
                        }
                        else
                            document.getElementById('<%=imgContacts.ClientID%>').src = "../Images/delete-icon.png";

                        if (txtSelectedDate.length > 0) {
                            document.getElementById('<%=imgDeliveryDate.ClientID%>').src = "../Images/Approved-icon.png";
                            document.getElementById('<%=lblDeliveryDateget.ClientID%>').innerHTML = "Later/Schduled";
                        }
                        else {
                            document.getElementById('<%=imgDeliveryDate.ClientID%>').src = "../Images/Approved-icon.png";
                            document.getElementById('<%=lblDeliveryDateget.ClientID%>').innerHTML = "Immediate/Schduled";
                        }

                        if (oSelElem != "")
                            document.getElementById('<%=imgHtmlContent.ClientID%>').src = "../Images/Approved-icon.png";
                        else
                            document.getElementById('<%=imgHtmlContent.ClientID%>').src = "../Images/delete-icon.png";


                        if (TSelElem != "")
                            document.getElementById('<%=imgTextContent.ClientID%>').src = "../Images/Approved-icon.png";
                        else
                            document.getElementById('<%=imgTextContent.ClientID%>').src = "../Images/delete-icon.png";


                        if (chkTrackReads.type == "checkbox") {
                            if (chkTrackReads.checked == true) {
                                document.getElementById('<%=imgLinkTracked.ClientID%>').src = "../Images/Approved-icon.png";

                            }
                            else
                                document.getElementById('<%=imgLinkTracked.ClientID%>').src = "../Images/delete-icon.png";

                        }

                    

                    }

                    return false;     

}

the above function is working properly when i remove Server side tab click event.But i need to use both the events.
           
Kevin
Top achievements
Rank 2
 answered on 21 Sep 2011
5 answers
1.5K+ views
wanna change it to my labguage(translate)

tnx team
Mahbubeh
Top achievements
Rank 1
 answered on 21 Sep 2011
2 answers
148 views
HI all,

Can any one please tell me the default font-family in the telriks RadGrid?.
Ivan Zhekov
Telerik team
 answered on 21 Sep 2011
1 answer
71 views
Hi, 

I am using rad combobox. Here is the issue that I am facing.
I am expanding the combo-box to view the list of items.After that I am scrolling the page using mouse. The list of items scrolls along with the page in IE 6.
Is there a way this can be stopped?

Thanks...
Ivan Zhekov
Telerik team
 answered on 21 Sep 2011
2 answers
105 views
Hello,

We just shifted our code from one server to another.
Now I am not able to see the RadControls runtime. I can see them on the page, design time though.

Please help.

Thanks,
Shweta
Ivan Zhekov
Telerik team
 answered on 21 Sep 2011
1 answer
164 views
Hi,

Very new to the RAD controls so please bear with me as I have moved over from Infragistics and CSOM is totally different.
I have implemented a context menu using the RadContextMenu and so far so good.  However I can't work out how to access the data for the selected row client side.

What I am trying to do is to get a value from a cell in the row clicked on when the context menu was invoked.  I have tried :-

var commandName = args.get_item().get_text();
if (commandName == "Properties")
{
// Get the row selected in the tree
var treeList = $find("<%= componentTree.ClientID %>");
var row = treeList.get_selectedItems()[0]; 
var componentID = treelist.getCellByColumnUniqueName(row, 'EmployeeID');
alert(componentID); 

// ...amd from the row get the component id
window.open("./componentproperties.aspx?componentid=" + componentID + "&src=compview"); 

}

But this does not work - reading a bit further I don't think that the get_selectedItems is returning the selected rows which is a bit of a flaw in my understanding of this.  Any advice please on how to get the value of  call from the selected row?
Mira
Telerik team
 answered on 21 Sep 2011
6 answers
790 views
Hello All,

How can I programatically change the source (src) attribute of an iframe that's in a RadPageView which is in turn tied to a RadTabStrip tab? Meaning.. I would like to achieve something like this:

If variable temp1's value is 1:
<telerik:RadPageView ID="RadPageView2" runat="server">
                <iframe width="100%" height="100%" src="Page1.aspx" ></iframe>
</telerik:RadPageView>

If variable temp1's value is 2:
<telerik:RadPageView ID="RadPageView2" runat="server">
                <iframe width="100%" height="100%" src="Page2.aspx" ></iframe>
</telerik:RadPageView>

Something on the line of:
if(temp1 == 1)
{
               RadPageView2.iframe.setSource("Page1.aspx");
}
else if (temp1 == 2)
{
               RadPageView2.iframe.setSource("Page2.aspx");
}

Thanks in advance !!
Dimitar Terziev
Telerik team
 answered on 21 Sep 2011
13 answers
252 views

Hi,

I am trying to figure out why I am having a problem with RadDock when I use a master page. If I split the same functionality up using a master page then I seem to have problems when I dynamically create a RadDock. I think it might have something to do with the fact that the first time a RadDock is created it is in a postback click handler, subsequent creation of the RadDock happen in the init handler. However, I only see this problem when I use a master page. I do not see the same problem when all code is within a single page.

The problem I am having is that I create a RadDock in a click handler and then I attempt to move the RadDock to a different zone, the RadDock 'snaps' back to the zone it was created in, if I then try to move the RadDock I am successful.

I have included a DockNoMaster.aspx/cs which works as I expect. I can click on Add Module and a RadDock is created in the middle zone. I can move the RadDock to the right or left zone and click Postback and the RadDock 'remebers' its position.

--DockNoMaster.aspx

 

 

<telerik:RadScriptManager ID="ScriptManager1" runat="server" />

 

 

 

 

 

 

<telerik:RadDockLayout runat="server" ID="RadDockLayout1" EnableEmbeddedSkins="false" >

 

 

 

 

 

 

<table>

 

 

 

 

 

<tr>

 

 

 

 

 

<td bgcolor="#99ffcc">

 

 

 

 

 

<telerik:RadDockZone runat="server" ID="leftZone" Width="200" MinHeight="200" Orientation="vertical" Style="border: 0px;" />

 

 

 

 

 

</td>

 

 

 

 

 

<td bgcolor="#99ffcc">

 

 

 

 

 

<asp:Button runat="server" ID="btnAddModule" OnClick="btnAddModule_Click" Text="Add Module" />

 

 

 

 

 

&nbsp;<asp:Button runat="server" ID="btnPostback" OnClick="btnPostback_Click" Text="Postback" />

 

 

 

 

 

<br /><br />

 

 

 

 

 

<telerik:RadDockZone runat="server" ID="middleZone" Width="200" MinHeight="200" Orientation="vertical" Style="border: 0px;" />

 

 

 

 

 

</td>

 

 

 

 

 

<td bgcolor="#99ffcc">

 

 

 

 

 

<telerik:RadDockZone runat="server" ID="rightZone" Width="200" MinHeight="200" Orientation="vertical" Style="border: 0px;" />

 

 

 

 

 

</td>

 

 

 

 

 

</tr>

 

 

 

 

 

</table>

 

 

 

 

 

 

</telerik:RadDockLayout>

 

 

 

--DockNoMaster.cs

 

public

 

partial class Test_Templates_DockNoMaster : System.Web.UI.Page

 

 

 

 

 

{

 

protected void Page_Load(object sender, System.EventArgs e)

 

{

 

if (!IsPostBack)

 

{

}

}

 

private List<DockState> CurrentDockStates

 

{

 

get

 

 

 

 

 

{

 

List<DockState> _currentDockStates = (List<DockState>)Session["CurrentDockStatesDynamicDocks"];

 

 

if (Object.Equals(_currentDockStates, null))

 

{

_currentDockStates =

new List<DockState>();

 

Session[

"CurrentDockStatesDynamicDocks"] = _currentDockStates;

 

}

 

return _currentDockStates;

 

}

 

set

 

 

 

 

 

{

Session[

"CurrentDockStatesDynamicDocks"] = value;

 

}

}

 

private RadDock CreateRadDockFromState(DockState state)

 

{

 

RadDock dock = new RadDock();

 

dock.DockMode =

DockMode.Docked;

 

dock.ID =

string.Format("RadDock{0}", state.UniqueName);

 

dock.ApplyState(state);

dock.Commands.Add(

new DockCloseCommand());

 

dock.Commands.Add(

new DockExpandCollapseCommand());

 

dock.AutoPostBack =

true;

 

dock.CommandsAutoPostBack =

true;

 

 

return dock;

 

}

 

void dock_DockPositionChanged(object sender, DockPositionChangedEventArgs e)

 

{

}

 

private RadDock CreateRadDock()

 

{

 

int docksCount = CurrentDockStates.Count;

 

 

RadDock dock = new RadDock();

 

dock.DockMode =

DockMode.Docked;

 

dock.UniqueName =

Guid.NewGuid().ToString();

 

dock.ID =

string.Format("RadDock{0}", dock.UniqueName);

 

dock.Title =

"Dock";

 

dock.Text =

string.Format("Added at {0}", DateTime.Now);

 

dock.Width =

Unit.Pixel(300);

 

dock.Commands.Add(

new DockCloseCommand());

 

dock.Commands.Add(

new DockExpandCollapseCommand());

 

dock.AutoPostBack =

true;

 

dock.CommandsAutoPostBack =

true;

 

 

return dock;

 

}

 

protected void Page_Init(object sender, EventArgs e)

 

{

 

RadDockLayout dockLayout = RadDockLayout1;

 

dockLayout.LoadDockLayout +=

new DockLayoutEventHandler(dockLayout_LoadDockLayout);

 

dockLayout.SaveDockLayout +=

new DockLayoutEventHandler(dockLayout_SaveDockLayout);

 

 

 

 

 

 

for (int i = 0; i < CurrentDockStates.Count; i++)

 

{

 

RadDock dock = CreateRadDockFromState(CurrentDockStates[i]);

 

dockLayout.Controls.Add(dock);

}

}

 

protected void dockLayout_LoadDockLayout(object sender, DockLayoutEventArgs e)

 

{

 

foreach (DockState state in CurrentDockStates)

 

{

e.Positions[state.UniqueName] = state.DockZoneID;

e.Indices[state.UniqueName] = state.Index;

}

}

 

protected void dockLayout_SaveDockLayout(object sender, DockLayoutEventArgs e)

 

{

 

RadDockLayout dockLayout = RadDockLayout1;

 

CurrentDockStates = dockLayout.GetRegisteredDocksState();

}

 

protected void btnAddModule_Click(object sender, EventArgs e)

 

{

 

RadDockLayout dockLayout = RadDockLayout1;

 

 

RadDock dock = CreateRadDock();

 

middleZone.Controls.Add(dock);

}

 

protected void btnPostback_Click(object sender, EventArgs e)

 

{

}

}

 

I have also included DockWithMaster.aspx/cs and DockMaster.master/cs which does not work as I expect. If I click Add Module then a RadDock is created in the middle zone. However, if I drag the RadDock to the left or right zone it immediately goes back to the middle zone. The second time I move the RadDock to the left or right zone, it will remember its position.

In the master sample the RadDockLayout and the left and right RadDockZone are in the DockMaster.master file. The middle RadDockZone and the add and postback buttons are in the DockWithMaster.aspx file. The saving and loading of dock state is handled in the content .aspx file, not the master.

-- DockMaster.master

 

 

<telerik:RadScriptManager ID="ScriptManager1" runat="server" />

 

 

 

<telerik:RadDockLayout runat="server" ID="RadDockLayout1" EnableEmbeddedSkins="false" >

 

 

 

<table>

 

 

<tr>

 

 

<td bgcolor="#99ffcc">

 

 

<telerik:RadDockZone runat="server" ID="leftZone" Width="200" MinHeight="200" Orientation="vertical" Style="border: 0px;" />

 

 

</td>

 

 

<td bgcolor="#99ffcc">

 

 

<asp:ContentPlaceHolder id="middleContent" runat="server" />

 

 

</td>

 

 

<td bgcolor="#99ffcc">

 

 

<telerik:RadDockZone runat="server" ID="rightZone" Width="200" MinHeight="200" Orientation="vertical" Style="border: 0px;" />

 

 

</td>

 

 

</tr>

 

 

</table>

 

 

 

</telerik:RadDockLayout>

-- DockMaster.cs does not have anything in it

-- DockWithMaster.aspx

 

 

 

<

 

asp:Content ID="Content1" ContentPlaceHolderID="middleContent" runat="server">

 

 

<asp:Button runat="server" ID="btnAddModule" OnClick="btnAddModule_Click" Text="Add Module" />

 

 

&nbsp;<asp:Button runat="server" ID="btnPostback" OnClick="btnPostback_Click" Text="Postback" />

 

 

<br /><br />

 

 

<telerik:RadDockZone runat="server" ID="middleZone" Width="200" MinHeight="200" Orientation="vertical" Style="border: 0px;" />

 

</

 

asp:Content>

 

 

 

-- DockWithMaster.cs

 

public

 

partial class Test_Templates_DockWithMaster : System.Web.UI.Page

 

{

 

protected void Page_Load(object sender, System.EventArgs e)

 

{

 

if (!IsPostBack)

 

{

}

}

 

private List<DockState> CurrentDockStates

 

{

 

get

 

{

 

List<DockState> _currentDockStates = (List<DockState>)Session["CurrentDockStatesDynamicDocks"];

 

 

if (Object.Equals(_currentDockStates, null))

 

{

_currentDockStates =

new List<DockState>();

 

Session[

"CurrentDockStatesDynamicDocks"] = _currentDockStates;

 

}

 

return _currentDockStates;

 

}

 

set

 

{

Session[

"CurrentDockStatesDynamicDocks"] = value;

 

}

}

 

private RadDock CreateRadDockFromState(DockState state)

 

{

 

RadDock dock = new RadDock();

 

dock.DockMode =

DockMode.Docked;

 

dock.ID =

string.Format("RadDock{0}", state.UniqueName);

 

dock.ApplyState(state);

dock.Commands.Add(

new DockCloseCommand());

 

dock.Commands.Add(

new DockExpandCollapseCommand());

 

dock.AutoPostBack =

true;

 

dock.CommandsAutoPostBack =

true;

 

 

return dock;

 

}

 

void dock_DockPositionChanged(object sender, DockPositionChangedEventArgs e)

 

{

}

 

private RadDock CreateRadDock()

 

{

 

int docksCount = CurrentDockStates.Count;

 

 

RadDock dock = new RadDock();

 

dock.DockMode =

DockMode.Docked;

 

dock.UniqueName =

Guid.NewGuid().ToString();

 

dock.ID =

string.Format("RadDock{0}", dock.UniqueName);

 

dock.Title =

"Dock";

 

dock.Text =

string.Format("Added at {0}", DateTime.Now);

 

dock.Width =

Unit.Pixel(300);

 

dock.Commands.Add(

new DockCloseCommand());

 

dock.Commands.Add(

new DockExpandCollapseCommand());

 

dock.AutoPostBack =

true;

 

dock.CommandsAutoPostBack =

true;

 

 

return dock;

 

}

 

protected void Page_Init(object sender, EventArgs e)

 

{

 

RadDockLayout dockLayout = (RadDockLayout)this.Master.FindControl(middleZone.LayoutID);

 

dockLayout.LoadDockLayout +=

new DockLayoutEventHandler(dockLayout_LoadDockLayout);

 

dockLayout.SaveDockLayout +=

new DockLayoutEventHandler(dockLayout_SaveDockLayout);

 

 

for (int i = 0; i < CurrentDockStates.Count; i++)

 

{

 

RadDock dock = CreateRadDockFromState(CurrentDockStates[i]);

 

dockLayout.Controls.Add(dock);

}

}

 

protected void dockLayout_LoadDockLayout(object sender, DockLayoutEventArgs e)

 

{

 

 

foreach (DockState state in CurrentDockStates)

 

{

e.Positions[state.UniqueName] = state.DockZoneID;

e.Indices[state.UniqueName] = state.Index;

}

}

 

protected void dockLayout_SaveDockLayout(object sender, DockLayoutEventArgs e)

 

{

 

RadDockLayout dockLayout = (RadDockLayout)this.Master.FindControl(middleZone.LayoutID);

 

CurrentDockStates = dockLayout.GetRegisteredDocksState();

}

 

protected void btnAddModule_Click(object sender, EventArgs e)

 

{

 

RadDockLayout dockLayout = (RadDockLayout)this.Master.FindControl(middleZone.LayoutID);

 

 

RadDock dock = CreateRadDock();

 

middleZone.Controls.Add(dock);

}

 

protected void btnPostback_Click(object sender, EventArgs e)

 

{

}

}

Slav
Telerik team
 answered on 21 Sep 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?