Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
160 views

Hi Telerik team,

i'm using both client side & server side event on delete button.
The problem is server side event is not calling after confirm message ok.
After confirm was ok,i'm deleting the records.But when i was click ok the server side event is not calling.

<asp:Button ID="btnDelete" runat="server" Text="Delete" OnClientClick="return GetSelectedItems();" OnClick="btnDelete_Click" />
 <telerik:RadGrid ID="rgSamplePlanDashboard" SkinID="CustomTelerikGridSkin" runat="server"> </telerik:RadGrid>

 <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
  <telerik:AjaxSetting AjaxControlID="btnDelete">
    <UpdatedControls>
      <telerik:AjaxUpdatedControl ControlID="btnDelete" />
      <telerik:AjaxUpdatedControl ControlID="rgSamplePlanDashboard" />
    </UpdatedControls>
  </telerik:AjaxSetting>
</telerik:RadAjaxManager>

 <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">

        <script type="text/javascript">
          function GetSelectedItems()
        {
           test=($find("<%= rgSamplePlanDashboard.MasterTableView.ClientID %>").get_selectedItems().length);
           if (test==0)
            {
              alert('Please Select atleast one Sample Plan Record to delete.');
              return false;
            }
            else if (test>0)
            {
              var DeleteSampleRecors=confirm ("Sample plan record exist with associated sample(s) do you to continue click Ok or Cancel.")
                if(DeleteSampleRecors==true)
                {
                return true;
                }
                else
                {
               return false;

                }
           
            }
      }

         </script>

    </telerik:RadCodeBlock>

    can any one help out to how to overcome this problem.
    plz send the solution ASAP.

    Thanks & Regards
    Shaik Mujeebuddin

Partheepan Mani
Top achievements
Rank 1
 answered on 08 Jul 2009
1 answer
115 views
I'm loading the tree nodes on demand using a web service, but it seems like the node properties through the web service are far more limited than a server side call back.  In particular, I want to set the tooltip of my nodes, but that property is not available.  Is that property coming soon or is there a work around?

Thanks,
Matt
Veselin Vasilev
Telerik team
 answered on 08 Jul 2009
1 answer
237 views
Hi,
Is there a way to place a multiselect treeview inside the Dropdown.

I want the dropdown to shrink to original size once the selections is done(not the expanded view)
Shinu
Top achievements
Rank 2
 answered on 08 Jul 2009
2 answers
197 views
Hi,

I found that the rad controls take at least 7 seconds to render the controls on my local machine if I have about 7 controls on the page.   Thus, it would take longer time when it is through internet connection.  What should I do to speed up?

Regards,

Duy
Paul
Telerik team
 answered on 08 Jul 2009
1 answer
88 views
Hi Sir,

I use RadTreeview to list all the grouping records (single level nodes could be more than thousand) and each node with a tool tip to display the details. Sample code like this.

 

<telerik:RadTreeView ID="RadTreeView1" runat="server" CheckBoxes="True" DataSourceID="ObjectDataSource2"

 

 

DataFieldID="requirementno" DataValueField="reqno" DataFieldParentID="parentrequirementno">

 

 

<CollapseAnimation Duration="100" Type="OutQuint" />

 

 

<ExpandAnimation Duration="100" />

 

 

<NodeTemplate>

 

 

<asp:Label ID="Label6" runat="server" Text='<%# Eval("displayreqno") & "-" & Eval("ShortRequirement") & "(" & Eval("qtype_display") & ")" %>'></asp:Label>

 

 

<asp:Image ID="img1" runat="server" AlternateText="Test plan associated or not" ImageAlign="Baseline"

 

 

ImageUrl="menuimages/delete2.png" />

 

 

<telerik:RadToolTip ID="RadToolTip1" runat="server" Width="400px" Height="150px"

 

Skin="Outlook" TargetControlID="img1" Position="BottomCenter" Animation="Slide"

ManualClose="True" Text='<%# Eval("Requirement")%>'>

</telerik:RadToolTip>

 

 

 

</NodeTemplate>

 

 

</telerik:RadTreeView>

 

 

<asp:ObjectDataSource ID="ObjectDataSource2" runat="server" SelectMethod="GetAllRequirements"

 

 

TypeName="DocumentManagement">

 

 

<SelectParameters>

 

 

<asp:SessionParameter Name="projectid" SessionField="ProjectInfo" Type="Object" />

 

 

</SelectParameters>

 

 

</asp:ObjectDataSource>

when records is over thousand the performance becomes very bad. Any idea ...?

Thanks very much!

 

Paul
Telerik team
 answered on 08 Jul 2009
3 answers
136 views

Requirements

RadControls version

2009.Q2

.NET version

3.5

Visual Studio version

2008

programming language

C#

browser support

all browsers supported by RadControls


PROJECT DESCRIPTION
@Telerik: I used the dll from RadControls_for_ASP.NET_AJAX_2009_2_701_trial_hotfix.zip - but I get no trial messages. Could you please check if the DLL is really the trial version.

Assume a (common) scenario where a column of a GridRow references a different table - the "master table" holds an ID and the related table this ID and some "Name" for it.
A typical use for a GridDropDownColumn.

But sometimes I came to a point where I couldn't use a GridDropDownColum - this happened when I had to do "very special customizations".
At this time I had to use a GridTemplateColumn. For the EditItemTemplate this is no problem - simply use a RadComboBox.
But how about the ItemTemplate?
One solution is to use a RadComboBox again - but the User should not be able to change a selection (this could confuse him).
To set the RadComboBox to Enabled="false" is also not really a solution - the thing is almost impossible to read.
Another approach is to define a datasource which allows to select the "Name" by giving an ID or to get the master data from some kind of join - which could make problems if you want to update the data.
Often I use "cached data" for things like "Country, Status, Region, Role...) - so the data is there - and I can access it very fast.
And last not least - I want to do it "the easy way" - no code behind for every grid which holds such a column.

The idea - I want to have a kind of Label which acts exactly like a ComboBox - I have a datasource(id), a selected value and so on.
As a result I get the same as with a ComboBox - but not a "unreadable" disabled thing - I just get a label (some kind of static text).
In simple words - I get the same result as with a GridDropDownColumn - but with full customization capabilities.

I built such a control (rough done -- Css class and other attributes are not rendered) and here it is.
The use is almost identical to a RadComboBox - here an example for a templated column using this control.
<telerik:GridTemplateColumn DataField="FunctionID" DataType="System.Int32" HeaderText="Function" SortExpression="FunctionID" UniqueName="FunctionID">  
    <ItemTemplate> 
        <cc1:ComboLabel runat="server" DataTextField="FunctionName" DataValueField="FunctionID" DataSourceID="odsTestFunctions" SelectedValue='<%# Eval("FunctionID") %>' /> 
        &nbsp;&nbsp;(<%# (string)((int)Eval("FunctionID")<2 ? "<style='color:red;'>Handle with care</b>" : "Teasing enabled") %>)  
    </ItemTemplate> 
    <EditItemTemplate> 
        <telerik:RadComboBox ID="cbFunctionID" runat="server" DataTextField="FunctionName" DataValueField="FunctionID" DataSourceID="odsTestFunctions" SelectedValue='<%# Bind("FunctionID") %>' /> 
    </EditItemTemplate> 
</telerik:GridTemplateColumn> 
 
You can see - both controls are almost identical - I set exactly the same values for
DataTextField, DataValueField, DataSourceID and SelectedValue

I use this control very often - and hope it is useful for you also.
To enhance the thing (more render capabilities) just change the function Render in ComboLabel (last function at the end).

Kind Regards

Manfred
Yavor
Telerik team
 answered on 08 Jul 2009
2 answers
103 views
I'm looking to make some small changes to a couple of the embeded skins. Is it possible to override specific styles, or do I have to use a custom skin if I want to make any changes?
Paul
Telerik team
 answered on 08 Jul 2009
0 answers
65 views
Hi
     I am using Radgrid having filtering controls. I used to call each filter control event at code behind. But theproblem is i could get filtered data only from the last control event fired,though i preserved the first control value it didnt take an account that value by the last control event value only taken.

So i need the filtering based on all control values even though i used to select randomly

My cs code:

//First Combo
protected void JurisdictionCodeComboBox_IndexChanged(object o, RadComboBoxSelectedIndexChangedEventArgs e)
    {
        string filterExpression = "";
        string query = "";

        if (e.Text.IndexOf(",") > -1)
        {
            string[] values = e.Text.Split(',');

            for (int i = 0; i < values.Length; i++)
            {
                query += "'" + values[i] + "',";
            }

            query = query.Remove(query.Length-1, 1);
        }
        else
        {
            query = "'" + e.Text + "'";
        }
        if (e.Value != "All")
        {
            filterExpression = "([JurisdictionCode] in (" + query + "))";
        }
        else
        {
            filterExpression = "([JurisdictionCode] <> '')";
        }
        hdnJurisdictionCode.Value = e.Text.ToString();
        RadGrid1.MasterTableView.FilterExpression = filterExpression;
       

    }

    //Second Combo
    protected void FergTechNumComboBox_IndexChanged(object o, RadComboBoxSelectedIndexChangedEventArgs e)
    {
        string filterExpression = "";
        string query = "";

        if (e.Text.IndexOf(",") > -1)
        {
            string[] values = e.Text.Split(',');

            for (int i = 0; i < values.Length; i++)
            {
                query += "'" + values[i] + "',";
            }

            query = query.Remove(query.Length - 1, 1);
        }
        else
        {
            query = "'" + e.Text + "'";
        }
        

        if (e.Value != "All")
        {
            filterExpression = "([FergTechNum] in (" + query + "))";
        }
        else
        {
            filterExpression = "([FergTechNum] <> '')";
        }
        hdnFergTechNum.Value = e.Text.ToString();
        RadGrid1.MasterTableView.FilterExpression = filterExpression;
      
    }
   

Appu

Appu
Top achievements
Rank 1
 asked on 08 Jul 2009
2 answers
286 views
I'm just starting to demo the RadGrid and decided to copy the example from:-
http://demos.telerik.com/aspnet-ajax/grid/examples/programming/slider/defaultcs.aspx

I pasted in the sample code from the DefaultCS.aspx and DefaultVB.aspx.vb sections.  I did some slight modifications so I was calling data from our own database and ran the project.  I noticed in SQL Server profiler that my query was being called twice everytime I used the page slider.  After looking at the sample code that I pasted in I noticed that if I remove:-

OnNeedDataSource="RadGrid1_NeedDataSource"

... from the HTML (DefaultCS.aspx) if only fires once.  Everything still seems to work fine still.  Is this a mistake in your sample and is it not required or have I maybe done something wrong when I cut and pasted the sample code into our application?  I am just checking that removing this from the HTML will not have any implications.

Thanks
Chris
Top achievements
Rank 2
 answered on 08 Jul 2009
2 answers
68 views
Following on from this thread :
http://www.telerik.com/community/forums/aspnet-ajax/calendar/input-elemens-causing-section-508-failure.aspx

I can't get this example to work - my site continually complains that it is:
Unable to find control with id 'dnn_ctr604_EditCMIS_Meetings_txtcalMeetingDate_DateInput1_text that is associated with the Label 'Label2'.

Is there an implementation of this technique to label all parts of the calendar that is more up to date?
Holly
Top achievements
Rank 1
 answered on 08 Jul 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?