Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
137 views
Hi Team,

I am developing the line chart by using RadChart in asp.net with C#(visual studio 2010), data is binding dynamically from the DB, I have the following issues,
1)  Need to display the MarkersAppearance for each point.
2) I need to draw the line at current month, to differentiate the past and future months.
3) Need to display the chart title in center, with background color to the entire area.
for reference please see the attachment.

I already refer the following links, but unable to fix above issues.
a) http://www.telerik.com/help/aspnet-ajax/htmlchart-types-line-chart.html
b) http://www.telerik.com/help/aspnet-ajax/chart-building-programmatic-create-complex.html



Thanks in advance.
Evgenia
Telerik team
 answered on 24 Apr 2013
1 answer
98 views
I'm having problems zooming out my RadChart. I have a telerik:RadButton that calls a script to zoomOut on the RadChart but it seems that the zoom out is overwritten by an Ajax refresh that sets the chart back to where it was. 

I've read that RadScriptBlock runs after Ajax refresh but this does not seem to resolve the issue.

Looking at this thread http://www.telerik.com/community/forums/aspnet-ajax/chart/zoomout-method-not-working.aspx#742256
I can see the answer here was the use of an asp:Button and, yes this solution works. But the same solution does
not seem to work when the button that calls the script is a <telerik:RadButton>

            <div id="div3">
                <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" Height="200px" Width="300px">

                <telerik:RadButton ID="RadButton1" runat="server" text="Zoom Out" onclientclicked="ZoomOutChart1" >
                </telerik:RadButton>

                
                    <telerik:RadScriptBlock ID="RadScriptBlock1" runat="server">
                        <script type="text/javascript">
                            function ZoomOutChart1() {
                                //scale XAxis by factor 3 
                                var chart = $find("<%=RadChart1.ClientID%>");
                                if (chart != null)
                                    chart.zoomOut();
                            }
                        </script>
                    </telerik:RadScriptBlock>

                <telerik:RadChart ID="RadChart1" runat="server" DefaultType="Line" 
                     Height="500px" Width="500px" Skin="BabyBlue"> <%-- --%>
                    <Appearance>
                        <FillStyle MainColor="239, 255, 254">
                        </FillStyle>
                        <Border Color="188, 229, 231" Width="8" />
                    </Appearance>
                    <Series>
                        <telerik:ChartSeries Name="Series 1" Type="Line">
                            <Appearance>
                                <FillStyle MainColor="194, 230, 252" FillType="Solid">
                                </FillStyle>
                                <TextAppearance TextProperties-Color="78, 168, 188">
                                </TextAppearance>
                                <Border Color="177, 215, 250" />
                            </Appearance>
                        </telerik:ChartSeries>
                    </Series>
                    <ClientSettings EnableZoom="true" ScrollMode="XOnly" XScale="4" /><%-- --%>
                </telerik:RadChart>
               </telerik:RadAjaxPanel>
            </div>

If I comment out the RadAjaxPanel then zoom out works fine
If I replace the telerik:RadButton with an asp:Button it also works fine

my server side code is as follows:

  protected void Page_Load(object sender, EventArgs e)
    {

        if (!IsPostBack)
        {
            int[] intArray = new int[100];
            Random random = new Random();

            int currentValue = 50;
            for (int pos = 0; pos < 100; pos++)
            {
                currentValue += random.Next(-5, 5);
                intArray[pos] = currentValue;
            }

            RadChart1.DataSource = intArray;
            RadChart1.DataBind();
            RadChart1.ClientSettings.EnableAxisMarkers = false;
            RadChart1.PlotArea.YAxis.Appearance.MinorGridLines.Visible = false;
            RadChart1.PlotArea.XAxis.Appearance.MinorGridLines.Visible = false;

            RadChart1.PlotArea.XAxis.Appearance.MinorGridLines.Visible = false;
            RadChart1.PlotArea.YAxis.Appearance.MinorGridLines.Visible = false;
        }
Maria Ilieva
Telerik team
 answered on 24 Apr 2013
2 answers
817 views
Hi all if I enter the text as 012 this is displaying the result as 12, but I would like to have my value as per I entered. What should I do.

This is my design

<telerik:RadNumericTextBox ID="txtbankRoutingNumber" NumberFormat-GroupSeparator=""
             Width="200px" runat="server" Type="Number" MaxLength="9"
            IncrementSettings-InterceptMouseWheel="false" IncrementSettings-InterceptArrowKeys="false">
            <NumberFormat DecimalDigits="0" />
        </telerik:RadNumericTextBox>
Reshma
Top achievements
Rank 1
 answered on 24 Apr 2013
1 answer
168 views

Hi, 
I have a radigrid which i bind client side, it have max rows 100 and for every page i bind only the 100 items. I get the data with PageMethods. Everything worked fine until chrome latest update 26.0.1410.64 m after that when the radgrid gets the data the tab is freezing  and the loader gif i have freeze. Also every time i change the page tha same freezing happend. The whole page performance is very slow.

The page in chrome when the radgrid paints the data is very slow and the waiting is for minities. I have tested with devtools and i saw that the freezing happed after the client side gets the data and try to databind. In  IE 8 also freeze for a sorter time than chrome, this performance improved in IE10 and my page is a lot faster. In Firefox there is a tiny freeze only for a sec. 

I have try to improve performance for the grid and for the page 
http://www.telerik.com/products/aspnet-ajax/getting-started/top-performance.aspx
http://www.telerik.com/help/aspnet-ajax/grid-viewstate-reduction-techniques.html

but nothing. And everything happend after the latest update of chrome. In IE of course it always happend but our client does not used much. The telerik version i have is v.2012.2.815.35
and this the code of the rad grid 

 

<telerik:RadGrid ID="dltBroadcast" EnableViewState="false" runat="server" AllowPaging="true"
                                        AllowSorting="True" PageSize="100" AllowMultiRowSelection="True" ClientSettings-EnableRowHoverStyle="True"
                                        Width="956px" CellPadding="0" CellSpacing="0" Skin="RadGridCustomBlack" EnableEmbeddedSkins="False">
                                        <PagerStyle Mode="NextPrevAndNumeric" Position="TopAndBottom" HorizontalAlign="Justify"
                                            AlwaysVisible="True" />
                                        <MasterTableView ClientDataKeyNames="ElementId,SentimentDesc,CrawledDateTime" AllowMultiColumnSorting="true"
                                            TableLayout="Fixed">
                                            <Columns>
                                                <telerik:GridBoundColumn DataField="ElementId" HeaderText="ElementId" ReadOnly="True"
                                                    UniqueName="colElementId" Visible="False">
                                                </telerik:GridBoundColumn>
                                                <telerik:GridClientSelectColumn UniqueName="SelectColumn" DataTextField="ElementId"
                                                    Resizable="false">
                                                    <HeaderStyle Width="30px" />
                                                </telerik:GridClientSelectColumn>
                                                <telerik:GridTemplateColumn ItemStyle-HorizontalAlign="Left" ItemStyle-Width="20px"
                                                    HeaderStyle-Width="20px" UniqueName="colSentiment" Visible="True" ItemStyle-BorderStyle="None"
                                                    Resizable="false">
                                                    <ItemTemplate>
                                                        <div>
                                                            <a id="linkSentimentPositive" runat="server">
                                                                <img id="ImageSentimentPositive" runat="server" width="15" height="14" border="0"
                                                                    alt="" src="Images/positiveNormal.png" class="dtgridSentimentImages" /></a>
                                                            <br />
                                                            <a id="linkSentimentNeutral" runat="server">
                                                                <img id="ImageSentimentNeutral" runat="server" width="15" height="14" border="0"
                                                                    alt="" src="Images/neutralNormal.png" class="dtgridSentimentImages" /></a>
                                                            <br />
                                                            <a id="linkSentimentNegative" target="_self" runat="server">
                                                                <img id="ImageSentimentNegative" runat="server" width="15" height="14" border="0"
                                                                    alt="" src="Images/negativeNormal.png" class="dtgridSentimentImages" /></a>
                                                            <br />
                                                            <a id="linkSentimentUnassigned" runat="server">
                                                                <img id="ImageSentimentUnassigned" runat="server" width="15" height="14" border="0"
                                                                    alt="" src="Images/unassignedNormal.png" /></a>
                                                        </div>
                                                    </ItemTemplate>
                                                </telerik:GridTemplateColumn>
                                                <telerik:GridHyperLinkColumn DataTextField="Title" UniqueName="colTitle" HeaderText="Title"
                                                    ItemStyle-Font-Underline="true" ItemStyle-Width="200px" HeaderStyle-Width="200px"
                                                    ItemStyle-Wrap="true">
                                                    <HeaderStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" Wrap="False" />
                                                    <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" BorderStyle="None" Wrap="True" />
                                                </telerik:GridHyperLinkColumn>
                                                <telerik:GridBoundColumn DataField="Snippet" HeaderText="Snippet" ItemStyle-Width="200px"
                                                    HeaderStyle-Width="200px" ReadOnly="false" UniqueName="colSnippet">
                                                    <HeaderStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" Wrap="False" />
                                                    <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Left" BorderStyle="None" Wrap="True" />
                                                </telerik:GridBoundColumn>
                                                <telerik:GridBoundColumn DataField="Tags" HeaderText="Keywords" ReadOnly="True" UniqueName="colkeywords"
                                                    ItemStyle-Width="70px">
                                                    <HeaderStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" Wrap="False" />
                                                    <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" BorderStyle="None" Wrap="True" />
                                                </telerik:GridBoundColumn>
                                                <telerik:GridBoundColumn DataField="HostNameToShow" HeaderText="Source" ReadOnly="True"
                                                    UniqueName="colHostName" ItemStyle-Width="80px">
                                                    <HeaderStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" Wrap="False" />
                                                    <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" BorderStyle="None" Wrap="True" />
                                                </telerik:GridBoundColumn>
                                                <telerik:GridBoundColumn DataField="CrawledDateTime" HeaderText="Date" DataType="System.DateTime"
                                                    ItemStyle-Width="70px" HeaderStyle-Width="70px" DataFormatString="{0:dd/MM/yyyy HH:mm}"
                                                    ReadOnly="True" UniqueName="colCrawledDateTime">
                                                    <HeaderStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" Wrap="False" />
                                                    <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" BorderStyle="None" Wrap="True" />
                                                </telerik:GridBoundColumn>
                                                <telerik:GridBoundColumn DataField="TagName" HeaderText="User Tags" ReadOnly="True"
                                                    UniqueName="colTags">
                                                    <HeaderStyle Font-Bold="True" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" Wrap="False" />
                                                    <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                        Font-Underline="False" HorizontalAlign="Center" BorderStyle="None" Wrap="True" />
                                                </telerik:GridBoundColumn>
                                                <telerik:GridTemplateColumn UniqueName="colButtons" Visible="True" ItemStyle-Width="55px"
                                                    HeaderStyle-Width="55px" ItemStyle-BorderStyle="None" Resizable="false">
                                                    <ItemTemplate>
                                                        <div>
                                                            <a id="linkTag" runat="server">
                                                                <img id="ImageTag" runat="server" width="13" height="13" border="0" title="Tag" alt="Tag"
                                                                    src="Images/tag.gif" class="dtgridButtonsLeft" /></a> <a id="linkdelete" runat="server">
                                                                        <img id="Imgdelete" runat="server" width="13" height="13" border="0" title="Delete"
                                                                            alt="Delete" src="Images/delete.gif" class="dtgridButtonsRight" /></a><br />
                                                            <a id="linkSendEmail" runat="server">
                                                                <img id="ImgSendEmail" runat="server" width="13" height="13" border="0" title="Email"
                                                                    alt="Email" src="Images/email.gif" class="dtgridButtonsLeft" /></a> <a id="LinkHighlited"
                                                                        runat="server">
                                                                        <img id="ImgHighlited" runat="server" width="12" height="12" border="0" title="Highlight"
                                                                            alt="Highlight" src="Images/highlighted.png" class="dtgridButtonsRight" /></a><br />
                                                            <a id="linkEnagagedCommunity" runat="server">
                                                                <img id="ImgEnagagedCommunity" runat="server" width="13" height="13" border="0" title="Engaged Community"
                                                                    alt="Engaged Community" src="Images/details.gif" class="dtgridButtonsLeft" /></a>
                                                            <a id="LinkUrlAspect" runat="server">
                                                                <img id="ImgUrlAspect" runat="server" width="14" height="12" border="0" title="Aspects"
                                                                    alt="Aspects" src="Images/aspect.png" class="dtgridButtonsRight" /></a>
                                                        </div>
                                                    </ItemTemplate>
                                                </telerik:GridTemplateColumn>
                                            </Columns>
                                        </MasterTableView>
                                        <ClientSettings>
                                            <ClientEvents OnCommand="dltBroadcast_Command" OnRowDataBound="dltBroadcast_RowDataBound"
                                                OnColumnClick="dltBroadcast_ColumnClick" />
                                            <Selecting AllowRowSelect="true" />
                                            <Resizing AllowColumnResize="true" AllowRowResize="false" ResizeGridOnColumnResize="false"
                                                ClipCellContentOnResize="true" EnableRealTimeResize="true" AllowResizeToFit="true" />
                                            <Scrolling AllowScroll="false" UseStaticHeaders="false"></Scrolling>
                                        </ClientSettings>
                                    </telerik:RadGrid>


and this is my javascript 

function updateGridWithBinding(result) {
              var tableView = $find("<%= dltBroadcast.ClientID %>").get_masterTableView();
              tableView.clearSelectedItems();
              tableView.set_dataSource(result);
              tableView.dataBind();
                        }

Can you help me?

Thanks.


Martin
Telerik team
 answered on 24 Apr 2013
1 answer
302 views
Hello,

I have a RadGrid for which I use the OnItemCommand event. As expected, in the event handler I can find the GridDataItem from which the event was sent in the GridCommandEventArgs.Item.

Now I add a client side event handler for the event ClientSettings-ClientEvents-OnCommand. After this (javascript) event handler is called, a postback occurs and the server side OnItemCommand event is fired. But the GridCommandEventArgs.Item is now always referring to the first item in the grid and not the item that caused the event to be fired!

Am I doing something wrong?

Cheers,
Paul.
Andrey
Telerik team
 answered on 24 Apr 2013
3 answers
142 views
hi i have a vb web app. im using a radgrid to display the information from a SQL view and the popup edit form to edit the information in a SQL table the radgrid works and the data from the table is binded to the edit components but when i click the update button it returns a message in visual studio i have attached a screen print.
Any help to get the update working would be much appreciated.
<telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
        <script type="text/javascript">
            function RowDblClick(sender, eventArgs) {
            sender.get_masterTableView().editItem(eventArgs.get_itemIndexHierarchical());
            }
        </script>
 
    </telerik:RadCodeBlock>
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadGrid1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RadGrid1" LoadingPanelID="RadAjaxLoadingPanel1">
                    </telerik:AjaxUpdatedControl>
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
 
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server"
        IsSticky="True">
    </telerik:RadAjaxLoadingPanel>
 
    <div style="position: static">
 
<telerik:RadGrid ID="RadGrid1" Skin="Office2010Blue" runat="server"
        AllowAutomaticInserts="True" AllowAutomaticUpdates="True"
        DataSourceID="SqlDataSource1"
        CellSpacing="0" GridLines="None"
        AutoGenerateColumns="false">
         
        <MasterTableView EditMode="PopUp" CommandItemDisplay="Top"
            DataKeyNames="Log_ID">
            <Columns>
                <telerik:GridEditCommandColumn HeaderStyle-Width="40px">
                </telerik:GridEditCommandColumn>
                <telerik:GridBoundColumn DataField="Log_ID" HeaderText="Log_ID" UniqueName="Log_ID" HeaderStyle-Width="50px">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="VUpdated" HeaderText="Updated" UniqueName="VUpdated">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="VWho" HeaderText="Who" UniqueName="VWho">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="VCompany" HeaderText="Company" UniqueName="VCompany">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="VContact" HeaderText="Contact" UniqueName="VContact">
                </telerik:GridBoundColumn>
                <telerik:GridTemplateColumn DataField="VNotes" HeaderText="Notes" UniqueName="VNotes">
                    <ItemTemplate>
                    <div style="width:70px;height:19px;overflow:hidden">
                    <%# DataBinder.Eval(Container.DataItem, "VNotes")%>
                    </div>
                    </ItemTemplate>
                </telerik:GridTemplateColumn>
                <telerik:GridBoundColumn DataField="VSR" HeaderText="SR" UniqueName="VSR">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="VLocation" HeaderText="Location" UniqueName="VLocation">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="VDue_Date" HeaderText="Due_Date" UniqueName="VDue_Date">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="VComplete_Flag" HeaderText="Complete" UniqueName="VComplete_Flag">
                </telerik:GridBoundColumn>
            </Columns>
             <EditFormSettings InsertCaption="Add new item" CaptionFormatString="Edit Log_ID: {0}" CaptionDataField="Log_ID" EditFormType="Template" PopUpSettings-Modal="true">
             <PopUpSettings Modal="true" Width="900px" />
              <FormTemplate>
              <table id="table1" cellspacing="1" cellpadding="1" width="250" border="0">
              <tr>
                <td>
                    Log_ID:
                </td>
                <td>
                    <asp:Label ID="lblLog_ID" runat="server" Text='<%# Bind( "Log_ID" ) %>'></asp:Label>
                </td>
                <td rowspan="9">
 
                    <telerik:RadGrid ID="RadGrid2" runat="server" Width="400px" DataSourceID="SqlDataSource2" AutoGenerateColumns="False">            
                    <MasterTableView>
                        <Columns>
 
                            <telerik:GridBoundColumn DataField="Who" HeaderText="Who" UniqueName="Who"></telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Created" HeaderText="Created" UniqueName="Created"></telerik:GridBoundColumn>
                            <telerik:GridTemplateColumn DataField="Comments" HeaderText="Comments" UniqueName="Comments">
                            <ItemTemplate>
                                <asp:ListBox ID="ListBox1" runat="server"></asp:ListBox>
                            </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridBoundColumn DataField="Action_Type" HeaderText="Action" UniqueName="Action_Type"></telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Action_Date" HeaderText="Action_Date" UniqueName="Action_Date"></telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Due_Date" HeaderText="Due_Date" UniqueName="Due_Date"></telerik:GridBoundColumn>
                            <telerik:GridBoundColumn DataField="Complete_Flag" HeaderText="Complete" UniqueName="Complete_Flag"></telerik:GridBoundColumn>
                        </Columns>
                    </MasterTableView>
                    </telerik:RadGrid>
                 
                </td>
                </tr>
                <tr>
                <td>
                    Updated:
                </td>
                <td>
                    <asp:Label ID="lblUpdated" runat="server" Text='<%# Bind( "Updated" ) %>'></asp:Label>
                </td>
                </tr>
 
                <tr>
                <td>
                    Who:
                </td>
                <td>
                    <asp:Label ID="lblWho" runat="server" Text='<%# Bind( "Who" ) %>'></asp:Label>
 
                </td>
                </tr>
         
                <tr>
                <td>
                    Company:
                </td>
                <td>
                    <asp:TextBox ID="txtCompany" runat="server" Text='<%# Bind( "Company") %>' TabIndex="2">
                    </asp:TextBox>
                </td>
                </tr>
 
                <tr>
                <td>
                    Contact
                </td>
                <td>
                    <asp:TextBox ID="txtContact" Text='<%# Bind( "contact") %>' runat="server" TabIndex="9">
                    </asp:TextBox>
                </td>
                </tr>
 
                <tr>
                <td>
                    Header
                </td>
                <td>
                    <asp:TextBox ID="txtNotes" Text='<%# Bind( "Notes") %>' runat="server" TabIndex="8">
                    </asp:TextBox>
                </td>
                </tr>
 
                <tr>
                <td>
                    SR:
                </td>
                <td>
                    <asp:TextBox ID="txtSR" Text='<%# Bind( "SR") %>' runat="server" TabIndex="9">
                    </asp:TextBox>
                </td>
                </tr>
 
                <tr>
                <td>
                    Location:
                </td>
                <td>
                    <asp:TextBox ID="txtLocation" Text='<%# Bind( "Location") %>' runat="server" TabIndex="11">
                    </asp:TextBox>
                    <%--<telerik:RadComboBox ID="RadComboBox1" SelectedValue='<%# Bind( "Location") %>' runat="server" Skin="Office2010Blue">
                    </telerik:RadComboBox>--%>
                </td>
                </tr>
 
                <tr>
                <td>
                    Due_Date:
                </td>
                <td>
                    <telerik:RadDateTimePicker ID="RadDateTimePicker1" DbSelectedDate='<%# Bind( "Due_Date") %>' runat="server">
                    <Calendar ID="Calendar2" runat="server" EnableKeyboardNavigation="true">
                    </Calendar>
                    <DateInput ToolTip="Date input" runat="server"></DateInput>
                    </telerik:RadDateTimePicker>
                </td>
                </tr>
 
                <tr>
                <td>
                    Complete:
                </td>
                <td>
                    <telerik:RadComboBox ID="RadDropDownList1" SelectedValue='<%# Bind( "Complete_Flag") %>' runat="server" Skin="Office2010Blue">
                    <Items>
                    <telerik:RadComboBoxItem Value="1" Text="Yes" />
                    <telerik:RadComboBoxItem Value="2" Text="No" />
                    </Items>
                    </telerik:RadComboBox>
                                         
                </td>
                </tr>
                </Table>
             <table id="Table2" style="width: 100%">
                        <tr>
                            <td align="right" colspan="2">
                                 
                                  
                                <asp:ImageButton ID="ImageButton2" runat="server" ImageUrl="images/btnUpdate.png" CausesValidation="False" CommandName='<%# Iif (TypeOf Container is GridEditFormInsertItem, "PerformInsert", "Update") %>'/>
                                 
                                <asp:ImageButton ID="ImageButton1" runat="server" ImageUrl="images/btnCancel.png" CausesValidation="False" CommandName="Cancel"/>
                            </td>
                        </tr>
                    </table>
              
             </FormTemplate>
            </EditFormSettings>
 
        </MasterTableView>
 
 
        <ClientSettings>
        <Resizing   AllowColumnResize="False"  ClipCellContentOnResize="true" AllowResizeToFit="True" />
            <ClientEvents OnRowDblClick="RowDblClick"></ClientEvents>
            <Scrolling AllowScroll="True" UseStaticHeaders="True" ScrollHeight="550px" />
        </ClientSettings>
 
<FilterMenu EnableImageSprites="False"></FilterMenu>
 
    </telerik:RadGrid>
   </div>
 
   <asp:SqlDataSource ID="SqlDataSource1" runat="server"
        ConnectionString="<%$ ConnectionStrings:MYSQL_ISDB %>"
        ProviderName="<%$ ConnectionStrings:MYSQL_ISDB.ProviderName %>"
        SelectCommand="SELECT t_diary_all.Log_ID, vrqsummary.VUpdated, vrqsummary.VWho, vrqsummary.VCompany, vrqsummary.VContact, vrqsummary.VNotes, vrqsummary.VSR, vrqsummary.VLocation, vrqsummary.VDue_Date, vrqsummary.VComplete_Flag,
                      t_diary_all.Updated, t_diary_all.Who, t_diary_all.Company, t_diary_all.Contact, t_diary_all.Notes, t_diary_all.SR, t_diary_all.Location, t_diary_all.Due_Date, t_diary_all.Complete_Flag FROM t_diary_all INNER JOIN vrqsummary ON t_diary_all.Log_ID = vrqsummary.Log_ID"
        InsertCommand="INSERT INTO [t_diary_all] ([Log_ID], [Updated], [Who], [Company], [contact], [Notes], [SR], [Loc], [Due_Date], [Complete_Flag]) VALUES (@Log_ID, @Updated, @Who, @Company, @contact, @header, @SR, @Loc, @Due_Date, @Complete)"
        UpdateCommand="UPDATE [t_diary_all] SET [Updated] = @Updated, [Who] = @Who, [Company] = @Company, [Contact] = @Contact, [Notes] = @Notes, [SR] = @SR, [Loc] = @Loc, [Due_Date] = @Due_Date, [Complete_Flag] = @Complete_Flag WHERE [Log_ID] = @Log_ID">
        <InsertParameters>
            <asp:Parameter Name="Updated" Type="DateTime" />
            <asp:Parameter Name="Who" Type="String" />
            <asp:Parameter Name="Company" Type="String" />
            <asp:Parameter Name="Contact" Type="Int32" />
            <asp:Parameter Name="Notes" Type="String" />
            <asp:Parameter Name="SR" Type="String" />
            <asp:Parameter Name="Location" Type="Int32" />
            <asp:Parameter Name="Due_Date" Type="DateTime" />
            <asp:Parameter Name="Complete_Flag" Type="Int32" />
        </InsertParameters>
        <UpdateParameters>
            <asp:Parameter Name="Updated" Type="DateTime" />
            <asp:Parameter Name="Who" Type="String" />
            <asp:Parameter Name="Company" Type="String" />
            <asp:Parameter Name="Contact" Type="Int32" />
            <asp:Parameter Name="Notes" Type="String" />
            <asp:Parameter Name="SR" Type="String" />
            <asp:Parameter Name="Location" Type="Int32" />
            <asp:Parameter Name="Due_Date" Type="DateTime" />
            <asp:Parameter Name="Complete_Flag" Type="Int32" />
            <asp:Parameter Name="Log_ID" Type="Int32" />
        </UpdateParameters>
    </asp:SqlDataSource>
 
    <asp:SqlDataSource ID="SqlDataSource2" runat="server"
    ConnectionString="<%$ ConnectionStrings:T_Diary_Actions %>"
    ProviderName="<%$ ConnectionStrings:T_Diary_Actions.ProviderName %>"
    SelectCommand="SELECT Log_Line_ID, Log_ID, Who, Created, Comments, Action_Type, Action_Date, Due_Date, Complete_Flag FROM t_diary_actions WHERE Log_ID = '4108'">
 
     
    </asp:SqlDataSource>

Andrey
Telerik team
 answered on 24 Apr 2013
3 answers
486 views
Hi,

I found a demo of a shopping cart (url:http://demos1x.telerik.com/aspnet/Controls/Examples/Integration/Ajax/GridAndTabstrip/DefaultVB.aspx?product=controls)

Is there any way that i can download the project?

Greetings,

Frank
Alex
Top achievements
Rank 1
 answered on 24 Apr 2013
1 answer
89 views
I want to refresh or rebind a nested radgrid from a radbutton located outside of the grid. How do I get to the nested radgrid from here?

    Private Sub rbtnSave_Click(sender As Object, e As System.EventArgs) Handles rbtnSave.Click
        Try
            If SaveBuilding() Then
                'Dim GrantProjectID As Integer = Convert.ToInt32(Session(Const_Session.SELECTED_GRANT_PROJECT_ID).ToString)
                'grvGroupBuildings.DataSource = GetGroupAgenciesDataSource(GrantProjectID)
                'grvGroupBuildings.DataBind()
                ShowMessage("Update saved!")
            End If
        Catch ex As Exception
            ShowError(ex.Message)
        End Try
    End Sub
Shinu
Top achievements
Rank 2
 answered on 24 Apr 2013
1 answer
139 views
i'm using radgrid but the grouping doesn't work 
Here's my code:
 
<telerik:RadGrid ID="gvEvenement" runat="server" AllowPaging="True" CellSpacing="0"
            Culture="fr-FR" AllowSorting="True" AutoGenerateColumns="False" OnNeedDataSource="gvEvenement_NeedDataSource"
            Skin="WebBlue" GridLines="None" OnPreRender="gvEvenement_PreRender" AllowMultiRowSelection="True"
            ShowFooter="True" AllowAutomaticInserts="True" AllowCustomPaging="True" AllowFilteringByColumn="True"
            ShowGroupPanel="True" >
            <ClientSettings EnablePostBackOnRowClick="false" EnableRowHoverStyle="true" AllowColumnsReorder="true"
                AllowDragToGroup="True">
Princy
Top achievements
Rank 2
 answered on 24 Apr 2013
3 answers
146 views
I am trying to change the row background to a picture if the cell text equals EOL.  Tried changing the attributes but cannot find the correct syntax.  and is there a way to format the size of the jpg doing this as well to change the height and width.

Protected Sub myRadGrid_ItemDataBound(sender As Object, e As GridItemEventArgs) Handles myRadGrid.ItemDataBound
       If TypeOf e.Item Is GridDataItem Then
           Dim item As GridDataItem = CType(e.Item, GridDataItem)
           Dim Cell As TableCell = item("Type")
           Dim text As String = Cell.Text
 
           If text = "EOL" Then
               item.Attributes.Add(Style.background = "../Images/wallpaper_big-wDD_cs.jpg")
           End If
       End If
   End Sub
Princy
Top achievements
Rank 2
 answered on 24 Apr 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?