| protected void HandleNodeBound(object sender, RadTreeNodeEventArgs NodeEventArgs) |
| { |
| DataRowView dataSourceRow = (DataRowView)e.NodeBound.DataItem; |
| e.NodeBound.Image = dataSourceRow["Image"].ToString(); |
| ... |
| } |
| <rad:RadTreeView |
| ID="RadTree1" |
| runat="server" ... |
| OnNodeBound="HandleNodeBound"/> |
<telerik:RadSlider ID="SliderLivingArea" runat="server" Height="22px"
IsSelectionRangeEnabled="True" ItemType="Tick" LargeChange="10"
MaximumValue="50" MinimumValue="10" SelectionEnd="50" Skin="Black"
SlideStep="5" TrackPosition="TopLeft" Width="200px" >
</telerik:RadSlider>
Now in the scenario, where I need to access Minimum Value and Maximum Value ( Once the user changes the default minimum Value and Maximum Value to apply his own filters).
I am not able to fetch the user SelectionStart(which will be the new Minimum Value) and SelectionEnd (which will be new Maximum Value).
As I need to implement this on LINQ dynamic query, the selections are not been reflected onto the query on execution i.e on a ButtonClick where all the user selections should change the default data in the grid to the DATA(that needs to be based on User Filters Selections).
I have 4 different Sliders in the same page.
Any suggestions, regarding how to implement:
SliderLivingArea.MinmumValue=SliderLivingArea.SelectionStart;
SliderLivingArea.MaximumValue=SliderLivingArea.SelectionEnd;
.
.
.
var _query = from....
(SliverLivingArea.MinimumValue==SliderLivingArea.SelectionStart) && (q.LivingArea.???)
How to proceed on this situation.
Ideas..???
Thanks
Hi,
I am getting the following error in compilation at this part of the code ((SliderLivingArea.SelectionStart) && (q.LivingArea == SliderLivingArea.SelectionStart))
Error Desc: Error 1 Operator '&&' cannot be applied to operands of type 'int' and 'bool'
Though I tried Type casting but it didnt helped.
Any Ideas or suggesstions?
Another question, For the slider's Minimum value am I using the right property as .SelectionStart or Do I need to use .MinimumValue instead?
Cheers!
| <asp:UpdatePanel ID="UpdatePanel2" runat="server" onload="UpdatePanel2_Load"> |
| <ContentTemplate> |
| <telerik:RadTreeView ID="rtvLayoutListe" runat="server" AutoPostBack="true" Height="450px" |
| Skin="Office2007" OnClientNodeClicking="ClientClickHandler" |
| oncontextmenuitemclick="rtvLayoutListe_ContextMenuItemClick" |
| OnNodeClick="rtvLayoutListe_NodeClick" |
| onclientcontextmenuitemclicking="ContextMenuClicking" |
| onclientnodeclicked="ClientClickedHandler" |
| onclientnodeeditstart="startEdit" |
| onnodeedit="rtvLayoutListe_NodeEdit" |
| OnClientContextMenuShowing="onClientContextMenuShowing" > |
| <ContextMenus> |
| ... |
| </ContextMenus> |
| </telerik:RadTreeView> |
| </ContentTemplate> |
| <Triggers> |
| <asp:AsyncPostBackTrigger ControlID="btnRefresh" /> |
| </Triggers> |
| </asp:UpdatePanel> |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| if (!IsPostBack) |
| { |
| GenerateTreeView(); |
| } |
| } |
| public void GenerateTreeView() |
| { |
| rtvLayoutListe.Nodes.Clear(); |
| layoutsql lsql = new layoutsql(); |
| DataSet ds = lsql.GetLayoutsForManager(); |
| RadTreeNode rootNode = new RadTreeNode("Layouts", "folder-0"); |
| rootNode.ImageUrl = "../../images/folder.png"; |
| rootNode.ToolTip = "Layouts - Please select a Layout or Container"; |
| rootNode.Expanded = true; |
| rootNode.ContextMenuID = "RootMainContextMenu"; |
| rtvLayoutListe.Nodes.Add(rootNode); |
| foreach (DataRow folderRow in ds.Tables["LayoutFolder"].Rows) |
| { |
| RadTreeNode folderNode = new RadTreeNode(folderRow["LgName"].ToString(), |
| "folder-" + folderRow["lgid"].ToString()); |
| folderNode.ImageUrl = "../../images/folder.png"; |
| folderNode.ToolTip = "Folder"; |
| folderNode.ContextMenuID = "MainContextMenu"; |
| rootNode.Nodes.Add(folderNode); |
| foreach (DataRow layoutRow in folderRow.GetChildRows("FolderLayouts")) |
| { |
| RadTreeNode layoutNode = new RadTreeNode(layoutRow["LName"].ToString(), |
| "layout-" + layoutRow["LID"].ToString()); |
| layoutNode.ImageUrl = "../../images/desktop.png"; |
| layoutNode.ToolTip = "Layout " + layoutRow["LName"].ToString(); |
| layoutNode.ContextMenuID = "LayoutFolderCMenu"; |
| folderNode.Nodes.Add(layoutNode); |
| foreach (DataRow containerRow in layoutRow.GetChildRows("LayoutContainers")) |
| { |
| RadTreeNode containerNode = new RadTreeNode(containerRow["CName"].ToString(), |
| "container-" + containerRow["CID"].ToString()); |
| containerNode.ImageUrl = "../../images/gif.png"; |
| containerNode.ToolTip = "Layout Container " + containerRow["CName"].ToString(); |
| containerNode.ContextMenuID = "EmptyFolderContextMenu"; |
| layoutNode.Nodes.Add(containerNode); |
| } |
| } |
| } |
| int anzahl = rtvLayoutListe.Nodes.Count; =====>>>>>> Always 1 |
| //if (Session["cnewvalue"] != null) |
| //{ |
| // if (int.Parse(Session["cnewvalue"].ToString()) > 0) |
| // { |
| // foreach (RadTreeNode node in rtvLayoutListe.Nodes) |
| // { |
| // if (node.Value == tempcontainer) |
| // { |
| // node.Selected = true; |
| // node.Expanded = true; |
| // } |
| // else |
| // { |
| // node.Selected = false; |
| // } |
| // } |
| // } |
| //} |
| } |
Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; GTB6.3; .NET CLR 3.5.30729; .NET CLR 3.0.30618; OfficeLiveConnector.1.4; OfficeLivePatch.1.3)
Timestamp: Sun, 29 Nov 2009 15:02:58 UTC
Message: 'childNodes' is null or not an object
Line: 221
Char: 1
Code: 0
URI: ScriptResource.axd?d=JNhyLrLqW0xLaIfAooEFB847ZeDVYQU53nV7V_xFiBSjA1DlaLTQMRGDmaaK8YTJNaraWW2oQrhmxoXEbDP6Lg2&t=8c4884c
i am going around and round in circles trying to fix this, any ideas?! my website is www.prsc.com.au
thanks in advance