Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
112 views
Hi,
 
I have defined a RadMenu in a Master Page which loads its content from an XML.
When I login from a Default.aspx, if successful login it loads the Savings Page ; SC.aspx which is called within this MasterPage.
My problem is that :
1. the Savings Item on the RadMenu is not "hilighted" - a state to show that the current page is the "Savings" page (something i saw in the various demo). I expect to see the current page to be "hilighted".
2. When i click on another Page on the Menu, it navigates to the other page and again the Clicked Menu is not hilighted after it's loaded.

How can i achieve the hilighted items if i'm on the page?

Thanks for your help

<telerik:RadMenu ID="rmMainNav" runat="server" Skin="GMSkin" EnableEmbeddedSkins="false"  DataSourceID="dsMainNavXML"
     DataTextField="title" DataNavigateUrlField="url" DataValueField="title" OnItemClick="RadMenu_ItemClick"
     Width="100%">
 </telerik:RadMenu>

<?xml version="1.0" encoding="utf-8" ?>
<menu>
  <item url="#" title="   "  description="   " />
  <item url="../Pages/SC.aspx" title="Savings"  description="Savings" />
  <item url="../Pages/SL.aspx" title="Shopping"  description="Shopping" />
  <item url="../Pages/BI.aspx" title="Items"  description="Items" />
  <item url="../Pages/FD.aspx" title="Deals"  description="Deals" />
  <item url="../Pages/MP.aspx" title="Profile"  description="Profile" />
</menu>
Gotcha
Top achievements
Rank 1
 answered on 04 Sep 2011
5 answers
323 views
Hi 
I require a graph as shown in the attached file.
For the graph i have used stacked bar chart with orientation set to "horizontal"
Can any one please help me set the "target line " in the graph.
It looks marked zone and line chart requires at least two points to display it.
Pls help
my current code is attached
ChartSeries chartSeries1 = new ChartSeries();
          chartSeries1.Type = ChartSeriesType.Line;
 
          chartSeries1.Name = "TARGET";
          //chartSeries1.DefaultLabelValue = "TARGET";
 
          chartSeries1.Appearance.ShowLabels = false;
          //chartSeries1.Appearance.LegendDisplayMode = ChartSeriesLegendDisplayMode.Nothing;
          chartSeries1.Appearance.LabelAppearance.FillStyle.MainColor = Color.Red;
          chartSeries1.Appearance.LabelAppearance.FillStyle.SecondColor = Color.Red;
 
          chartSeries1.ActiveRegionToolTip = "Target";//+ objArea.type.ToString();
          chartSeries1.Appearance.LineSeriesAppearance.Color = Color.Red;
          chartSeries1.Appearance.LineSeriesAppearance.Width = 1;
          chartSeries1.Appearance.FillStyle.SecondColor = Color.Red;
          chartSeries1.Appearance.FillStyle.MainColor = Color.Red;
          chartSeries1.Appearance.Border.Visible = false;
          chartSeries1.AddItem(Convert.ToDouble(Target));
          chartSeries1.AddItem(Convert.ToDouble(Target));
          chartSeries1.AddItem(Convert.ToDouble(Target));
          chartSeries1.AddItem(Convert.ToDouble(Target));
         
          rad.Series.Add(chartSeries1);
          ChartMarkedZone objZone = new ChartMarkedZone();
          objZone.Label.TextBlock.Text = "Target";
          objZone.Label.Appearance.Position.AlignedPosition = AlignedPositions.Right;
          objZone.ValueStartX = -5;
          objZone.ValueEndX = 10;
          objZone.ValueStartY = 0;
          objZone.ValueEndY = 2200;
          
              objZone.Appearance.FillStyle.MainColor = Color.Red;
          objZone.Label.Appearance.Visible = true;
          objZone.Label.TextBlock.Visible = true;
 
 
          rad.PlotArea.MarkedZones.Add(objZone);
         // chartSeries1.PlotArea.MarkedZones.Add(objZone);
          
          int i = 0;
          double max = 0;
          foreach (KeyValuePair<int, double> pair in output.PensionAmount)
          {
              ChartSeries chartSeries = new ChartSeries();
              chartSeries.Type = ChartSeriesType.StackedBar;
              chartSeries.Appearance.LabelAppearance.Visible = false;
              chartSeries.Appearance.LineSeriesAppearance.Color = barColors[i];
              chartSeries.Appearance.FillStyle.SecondColor = barColors[i];
              chartSeries.Appearance.FillStyle.MainColor = barColors[i];
              chartSeries.Appearance.Border.Width = 0;
              chartSeries.Appearance.BarWidthPercent = 40;
              chartSeries.AddItem(pair.Value);
              rad.Series.Add(chartSeries);
              i++;
              
                  max =max+ pair.Value;
              
          }
          rad.SeriesOrientation = ChartSeriesOrientation.Horizontal;
          rad.PlotArea.YAxis.Appearance.MinorGridLines.Visible = false;
          rad.PlotArea.YAxis.Appearance.MajorGridLines.Color = Color.White;
          rad.PlotArea.YAxis.Appearance.MajorGridLines.PenStyle = DashStyle.Solid;
          rad.PlotArea.YAxis.Appearance.MajorGridLines.EndCap = LineCap.NoAnchor;
          rad.PlotArea.YAxis.Appearance.MajorGridLines.Visible = true;
          rad.PlotArea.YAxis.Appearance.Color = Color.Transparent;
          rad.PlotArea.XAxis.Appearance.Color = Color.Transparent;
          rad.Height = 180;
          rad.Width = 480;
          rad.PlotArea.Appearance.Dimensions.Margins.Bottom = new Telerik.Charting.Styles.Unit(70, Telerik.Charting.Styles.UnitType.Pixel);
          rad.PlotArea.Appearance.Dimensions.Margins.Right = new Telerik.Charting.Styles.Unit(40, Telerik.Charting.Styles.UnitType.Pixel);
          rad.PlotArea.YAxis.AutoScale = false;
          rad.PlotArea.YAxis.AddRange(0, max, 2000);
Mario
Top achievements
Rank 1
 answered on 04 Sep 2011
3 answers
261 views
I need to disable sorting property of a rad grid column and setting its sorting expression if sortable dynamically according to some dfata form the database , but setting "sorting expression=string.empty" in the "PreRender" event is not working , any other ideas ????
Jayesh Goyani
Top achievements
Rank 2
 answered on 03 Sep 2011
2 answers
86 views
Anyone know of an easy way where I can have a secondary Selected node style?  For example node levels 1 - 4 would have Style1 and Nodes 5 & 6 would have Sytle2?

I used the Visual Style Build to create my basic theme, the only problem is that I need to have a secondary "Selected" style depending on the node's level.

On the server side I am simply responding to the Node_Expand event, looping though my data and adding new nodes to the node that was passed in.
Plamen
Telerik team
 answered on 03 Sep 2011
3 answers
61 views
Hi,

I observe that reminder window appears on the page where RadSchedular control is present.
but user might be on anypage of the website.  I want that reminder should appear on which ever page the user is. Possible ?

Regards
Plamen
Telerik team
 answered on 03 Sep 2011
3 answers
219 views
I have a radgrid the column is a decimal value 1 or 0,

I have code in ItemDataBound to change 1 to Yes and 0 to No. everything is fine. But when do the filter, Nomattter I put Yes or No as filter, everything returned.
GridDataItem item = (GridDataItem)e.Item;
  
if (item["myfield"].Text == "1")
{
item["myfield"].Text = "Yes"
}
else
{
item["myfield"].Text = "No"
}
Please help
Jayesh Goyani
Top achievements
Rank 2
 answered on 03 Sep 2011
1 answer
159 views
Hi,

I have some dialog windows which pop-up. They hold an .aspx file for content. I was hoping to make the load times snappier for first load. Is this possible? I know that the window has the option of being cached after first display, which is nice, but sometimes I feel like it takes way too long to display a RadWindow because of the controls I'm having to load.

In addition, I've got two types of windows. Some of them have completely static controls -- what is being displayed is always what is going to be displayed. Others get pre-populated with data before being displayed to the user. It would be nice to be able to pre-load the page without the data, then only have to take the time for client-side scripts to execute before displaying to the user. Is this possible?

Cheers,

Sean 
Marin Bratanov
Telerik team
 answered on 03 Sep 2011
2 answers
164 views
Is there  an example of combobox load on demand
without  using datasource control  but directly from business object at runtime  ?
Kalina
Telerik team
 answered on 03 Sep 2011
5 answers
1.0K+ views
Hi,
I am using the 2011 Q2 release (radgrid version 2011.2.712.40) in my application.
I notice that the header column width sometimes exceeds the item column width. I am not able trace out a pattern under which such scenario occurs. I am attaching the screenshot to explain the issue in mote detail. Notice the blue outlined header box. I got this blue outline from IE developer toolbar.
Can you let me what can cause such behaviour.
Below is the page mark up:

<div id="divList" runat="server" style="width: 100%; height: 505px;">
                                                <telerik:RadGrid ID = "dgList" runat="server" AllowMultiRowSelection="True" 
                                                    Skin = "XXX" CellSpacing="0" CellPadding="0" BorderStyle="Solid" 
                                                    BorderWidth="0px" Width="100%" Height="510px" AutoGenerateColumns="False"
                                                    GridLines="None" AllowSorting = "True" ImagesPath="~/Skins/XXX/Grid"
                                                    OnItemDataBound="dgList_ItemDataBound" OnSortCommand = "dgList_SortCommand"
                                                    HeaderStyle-Height = "30px" EnableEmbeddedSkins="False">
                                                <ClientSettings>
                                                    <Scrolling AllowScroll = "true" UseStaticHeaders = "true" />
                                                    <Selecting AllowRowSelect = "true"/>
                                                    <ClientEvents OnRowSelected="RowSelected" OnRowDeselected="RowDeSelected"  />
                                                </ClientSettings>
                                                    <HeaderStyle Font-Underline="False" Height="30px" />
                                                <ItemStyle Wrap = "true" />
                                                <MasterTableView TableLayout="Fixed" AllowNaturalSort = "true"   AllowCustomSorting="true" ShowHeadersWhenNoRecords="true" NoMasterRecordsText="No details found.">
                                                          
                                                        <Columns>
                                                        <telerik:GridClientSelectColumn  UniqueName="ClientSelectColumn" >
                                                        <HeaderStyle Width="3%"/>
                                                        <ItemStyle HorizontalAlign="Center" />
                                                        </telerik:GridClientSelectColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "ID" 
                                                                    DataField = "ID" 
                                                                    HeaderText = "ID"
                                                                    Display = "false">
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "Details" 
                                                                    DataField = "Details" 
                                                                    HeaderText = "Description"
                                                                    HeaderStyle-Width = "13%"
                                                                    SortExpression = "Details">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center"/>
                                                                <ItemStyle 
                                                                    Wrap = "false"
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "VersionID" 
                                                                    DataField = "VersionID" 
                                                                    HeaderText = "Version"
                                                                    HeaderStyle-Width = "7%"
                                                                    SortExpression = "VersionID">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle 
                                                                    Wrap = "false"
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "ContentID" 
                                                                    DataField = "ContentID" 
                                                                    HeaderText = "ContentType"
                                                                    HeaderStyle-Width = "12%"
                                                                    SortExpression = "ContentID">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle 
                                                                    Wrap = "false" 
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "PublishedDate" 
                                                                    DataField = "PublishedDate" 
                                                                    HeaderText = "Published"
                                                                    SortExpression = "PublishedDate"
                                                                    HeaderStyle-Width = "7%">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle 
                                                                    Wrap = "false" 
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "PlatformID" 
                                                                    DataField = "PlatformID" 
                                                                    HeaderText = "Platform" 
                                                                    SortExpression = "PlatformID"
                                                                    HeaderStyle-Width = "10%">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle 
                                                                    Wrap = "false" 
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridBoundColumn>
                                                             <telerik:GridButtonColumn 
                                                                    UniqueName = "btnDetails" 
                                                                    ButtonType="ImageButton"
                                                                    ImageUrl="~/Images/info.png"
                                                                    HeaderText = "Details"
                                                                    Text = "Details"
                                                                    HeaderStyle-Width = "5%">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle 
                                                                    HorizontalAlign = "Center" 
                                                                    Height = "100%"
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridButtonColumn>
                                                            <telerik:GridBoundColumn
                                                                    UniqueName = "Ob" 
                                                                    DataField = "Ob" 
                                                                    HeaderText = "Obsolete"
                                                                    SortExpression = "Ob"
                                                                    HeaderStyle-Width = "7%">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle 
                                                                    Wrap = "false" 
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Center" 
                                                                    CssClass = "RadGridRow" />
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "Size" 
                                                                    DataField = "size" 
                                                                    HeaderText = "Size[KB]"
                                                                    SortExpression = "size"
                                                                    HeaderStyle-Width = "6%">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle 
                                                                    Wrap = "false" 
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow" />
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "Name" 
                                                                    DataField = "Name" 
                                                                    HeaderText = "FileName"
                                                                    SortExpression = "Name"
                                                                    ItemStyle-Wrap = "true"
                                                                    HeaderStyle-Width = "16%">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle
                                                                    Wrap = "false" 
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn 
                                                                    UniqueName = "Collection" 
                                                                    DataField = "Collection" 
                                                                    HeaderText = "CollectionName"
                                                                    SortExpression = "Collection"
                                                                    ItemStyle-Wrap = "true"
                                                                    HeaderStyle-Width = "0%"
                                                                    Display = "false">
                                                                <HeaderStyle 
                                                                    HorizontalAlign = "Center" />
                                                                <ItemStyle
                                                                    Wrap = "true" 
                                                                    Height = "100%"
                                                                    HorizontalAlign = "Left" 
                                                                    CssClass = "RadGridRow"/>
                                                            </telerik:GridBoundColumn>
                                                        </Columns>
                                                   </MasterTableView
                                                </telerik:RadGrid>
                                            </div>

Is there a specific CSS property to set for this?

Regards,
Ripunjay
Mira
Telerik team
 answered on 03 Sep 2011
5 answers
210 views

Hi,
 I have needs to make RadGrid scroll Horizontally, here is my code:

RadGrid1.Width = Unit.Percentage(100);
RadGrid1.MasterTableView.Width = Unit.Pixel(2100);
RadGrid1.ClientSettings.Scrolling.AllowScroll = true;

It's not working, the grid just extends horizontally. it will work if I assign a fixed width to RadGrid1 instead of using 100%, but tha's not what I want. 

Please help 
Pavlina
Telerik team
 answered on 03 Sep 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?