Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
106 views
Hi,
I'm new to teleriks.Anyway i want to validate textboxes in edit form.I want to use some regular expression also.How can i do this?
Is there any place to add egular expressions?.Please help me to solve this isssues.
Trs
Top achievements
Rank 1
 answered on 04 Jan 2013
8 answers
1.6K+ views
Radcombobox change java script not fired,
how i achieve this one



RadComboBox DedSer1 = (RadComboBox)e.Item.FindControl("DedSer1");
 
DedSer1.Attributes.Add("onChange", string.Format("CalculationAmount('{0}','{1}','{2}','{3}','{4}','{5}','{6}');", InvFinalamount.ClientID, DedValue.ClientID, DedInvoiceMinus.ClientID, GetValueSev.ClientID, GstInvoice.ClientID, InvoiceType.ClientID, DedSer1.ClientID));


Thanks Advance,
Mohamed.
mohamed
Top achievements
Rank 1
 answered on 04 Jan 2013
2 answers
72 views
Good afternoon,

I have a grid with the following layout:

<telerik:RadGrid ID="o_Results" runat="server" Width="938px" AllowMultiRowSelection="True" EnableViewState="True">
    <ClientSettings>
        <ClientEvents OnRowDeselected="SelectionChanged" OnRowSelected="SelectionChanged" />
        <Scrolling AllowScroll="True" UseStaticHeaders="True" ScrollHeight="144px" />
        <Selecting AllowRowSelect="True" />
    </ClientSettings>
    <MasterTableView DataKeyNames="cod_GUID,mov_GUID" AutoGenerateColumns="false">
        <Columns>
            <telerik:GridBoundColumn DataField="cod_GUID" Visible="False" HeaderText="CashOnDeliveryID" UniqueName="CashOnDeliveryID"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="mov_GUID" Visible="False" HeaderText="MovementID" UniqueName="MovementID"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="str_CodCompany" Visible="True" HeaderText="Azienda">
                <HeaderStyle Width="80px" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="car_Code" Visible="True" HeaderText="Corriere">
                <HeaderStyle Width="80px" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="mov_RunningNumber" Visible="True" HeaderText="TV2">
                <HeaderStyle Width="50px" />
                <ItemStyle HorizontalAlign="Right" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="str_MoveNumber" Visible="True" HeaderText="DDT">
                <HeaderStyle Width="50px" />
                <ItemStyle HorizontalAlign="Right" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="dte_InsertDate" Visible="True" HeaderText="Data DDT" DataFormatString="{0:dd/MM/yyy HH:mm}" DataType="System.DateTime">
                <HeaderStyle Width="100px" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="cod_Amount" Visible="True" HeaderText="Valore" DataFormatString="{0:C2}" DataType="System.Double" UniqueName="CashOnDeliveryAmount">
                <HeaderStyle Width="60px" />
                <ItemStyle HorizontalAlign="Right" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="mov_SimpleAddress" Visible="True" HeaderText="Indirizzo"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="ch8_CallCode" Visible="True" HeaderText="DDT">
                <HeaderStyle Width="60px" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="cos_Code" Visible="True" HeaderText="CoD">
                <HeaderStyle Width="60px" />
            </telerik:GridBoundColumn>
        </Columns>
        <EditFormSettings>
            <EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
        </EditFormSettings>
    </MasterTableView>
    <FilterMenu EnableImageSprites="False"></FilterMenu>
</telerik:RadGrid>

and then the following JavaScript

<script type="text/javascript" id="telerikClientEvents1">
    //<![CDATA[
 
    function SelectionChanged(sender, args) {
        var grid = $telerik.findGrid("<%= o_Results.ClientID %>");
        grid = $telerik.toGrid(grid);
        var masterTable = grid.get_masterTableView();
        var selectedRows = masterTable.get_selectedItems();
        for (var i = 0; i < selectedRows.length; i++) {
            var row = selectedRows[i];
            // var rowIndex = row.get_itemIndexHierarchical();
            // console.log("get_itemIndexHierarchical() = " + index);
            var amount = row.get_dataItem("CashOnDeliveryAmount");
            console.log(amount);
        }
    }
    //]]>
</script>

Everything works fine !
However, when I try to obtain the value of "CashOnDeliveryAmount" ( UniqueName ) or "cod_Amount" ( DataField ) I always get "null".

What I am trying to do is to create a total based on the selectedRows that is displayed somewhere else on the page.
I seem not to be able to find anything similar in the examples or in the forums ( which obviously does not mean that there isn't ).

Any help would be appreciated.

SR
Shinu
Top achievements
Rank 2
 answered on 04 Jan 2013
1 answer
340 views
Hi,

I am trying to access some controls in EditItemTemplate within GridTemplateColumn in RadGrid. But they are not there during ItemDataBound event.

protected void rgDiscount_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
{
if
(e.Item is GridDataItem)
{
GridDataItem gridDataItem = e.Item
as GridDataItem;
        RadDatePicker rdpFrom = gridDataItem.FindControl("rdpFrom") as RadDatePicker;
}
}


Could you please help me how can I get them in code (C#) to be able to work with them?

Thank you!

Patrik
Shinu
Top achievements
Rank 2
 answered on 04 Jan 2013
0 answers
48 views



Hi,

I have done chart before but this one little complex for me. because first column is "Unit"  should be shown based on Month columns like Dec2012,Jan2013,Feb2013..etc  .  Grand Total no need to display.

Database query output is :



Desired Rad Chart Output is :


Please find the link below for project contains database. please give me code to display result like as above.

https://docs.google.com/open?id=0B2iTYXKyTlBpa0MtOFdDbUZSRjg


Cannot hard code Months in the series,because may have more than 2 columns like Dec2012,Jan2013,Feb2013,Mar2013...etc..  

Cannot hard code Unit also,because may have more than 2 values like 001,002,003....etc..
 

Thank you in advance.










Madhu Palakurthi
Top achievements
Rank 1
 asked on 04 Jan 2013
1 answer
92 views
Is there a code download for the binding to XML demo? I wanted to see what the XML file looked like from this demo:  http://demos.telerik.com/aspnet-ajax/scheduler/examples/xmlschedulerprovider/defaultcs.aspx


Thanks,
Sam

Sam
Top achievements
Rank 1
 answered on 03 Jan 2013
0 answers
98 views
Hi,

We want to build some social aspect into our web application - an Activity Stream to start.
I notice that Telerik has built this feature into their TeamPulse product, but was wondering if anyone has built a similar capability into their web application using RadGrid or RadListView or some other Rad control(s).

I would prefer to use one or more Rad controls rather than pursue another 3rd party solution (or open source), since we are familiar (and happy) with the Telerik ASP.NET AJAX controls.

Thanks in advance.

Jim

jlj30
Top achievements
Rank 2
 asked on 03 Jan 2013
2 answers
109 views

I have set up a custom attribute "CustNo" on the standard AdvancedFormVB.ascx to hold a customer number. This is all working perfectly, and anything I type into this custom attribute's textbox is correctly saving to the database along with the appointment information, and is later being retrieved correctly when I reopen the appointment.

I am opening a RadWindow from a button on my AdvanceFormVB.ascx so that my users can create a customer record.
From my RadWindow's code behind I am:
1. Saving the newly created customer record to my database.
2. Storing the ID (Customer Number) of the newly created record in to a session variable.
3. Calling a clientside javascript function to close the Radwindow.

I have been able to verify from a javascript alert window that after the RadWindow closes my session variable still contains the correct ID (Customer Number).

What I would like to be able to do is, when the RadWindow closes,
1. put this ID straight into the "CustNo" Attribute Textbox of the still open AdvancedForm.
2. Call a refresh/postback of the AdvancedFormVB so that I can do some additional display stuff.

I'm assuming that populating the custom attribute textbox and calling a postback on the AdvancedForm must be done using javascript/jquery? But I'm a javascript/jquery newbie and have no idea how to go about it.



Arlety
Top achievements
Rank 1
 answered on 03 Jan 2013
4 answers
541 views
We have a RadToolTip containing a RadScheduler and two RadGrids. We want to keep these objects in sync, so we've employed a RadAjaxManager. Unfortunately, the events that we want to sync after are fired from controls within the NestedViews of the RadGrids. When EnableAjax is set to false, the following error is thrown:

Exception Details: System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
Parameter name: ItemHierarchicalIndex

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
Parameter name: ItemHierarchicalIndex]
   Telerik.Web.UI.GridItemCollection.get_Item(String hierarchicalIndex) +153
   Telerik.Web.UI.GridDataItemCollection.get_Item(String hierarchicalIndex) +50
   Telerik.Web.UI.RadGrid.LoadClientState(Dictionary`2 clientState) +7307
   Telerik.Web.UI.RadCompositeDataBoundControl.LoadPostData(String postDataKey, NameValueCollection postCollection) +305
   Telerik.Web.UI.RadCompositeDataBoundControl.System.Web.UI.IPostBackDataHandler.LoadPostData(String postDataKey, NameValueCollection postCollection) +73
   System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +1068
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2773

What can we do? Thanks.
Matthew
Top achievements
Rank 1
 answered on 03 Jan 2013
1 answer
74 views
I have an autoCompleteBox with InputType="Token" and AutoPostBack="True". When I click the "x" in a token the EntryRemoved event does not fire server side - client EntryRemoving event works. Anyone else running into this? Thanks.
Kalina
Telerik team
 answered on 03 Jan 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?