Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
56 views

Hello,

I'm a new user of your controls. I have been studying the documentation for the RadGrid, and find that it is terribly lacking in the basic content needed to understand how to use this control.

 

My questions:

I placed a RadGrid on a form, configured a few columns and supplied it with a datasource. Many columns from the datasource are hidden in the grid. When I click the link to add a new record, only the columns configured as visible appear in the resulting dropdown form.

1. Is it possible to configure this dropdown form to contain the columns/fields necessary to fully describe the new record?

2. If so, can this be done in the control's designer? If so, how?

3. Is it possible to validate user entry into the fields in the add new record dropdown form? If so, please describe in detail the steps I need to take to accomplish this.

4. Is it possible to configure validation in the designer for the RadGrid control?

 

Space limitations dictate that there is no room in the grid for additional columns, such as Edit and Delete. Therefore, I assume I need to configure a CommandItemTemplate which adds new buttons to the toolbar above the grid. I have done this.

1. Is it possible to code the custom buttons to behave precisely as when clicking the built-in edit and delete columns?

2. If so, please describe the exact steps I need to take to effect this. As before, please describe if and how the control designer may be used to do this. For example code, please note that I use VB.Net.

 

Visibility of the buttons:

I used Example 1 from http://docs.telerik.com/devtools/aspnet-ajax/controls/grid/data-editing/commanditem/command-item-template#custom-commanditemtemplate. I fail to see a good reason for the Edit and Delete buttons being visible unless one or more rows is selected in the grid. If there is a good reason for this, please let me know. Is it simply a matter of preference?

1. Please describe how I may control button visiblity based upon the count of selected rows in the grid.

 

I note that the Delete button from the sample includes
CommandName="DeleteSelected". When I select a row and click the button,
the record is not deleted. The grid is bound to a SqlDataSource. I assume that the delete command would remove the selected record(s) from the datasource, then effect an Update against the database.

1. How is basic CRUD done when using custom buttons in the toolbar?

2. How is basic CRUD done when using the built-in command columns?

 

I note that a RadGrid contains one or more views. I also note that, in the designer, there are some identical options for both the Grid and the MasterTableView. It seems that one must at times make use of the options associated with the Grid and, at other times, make use of those associated with the MasterTableView.

1. How am I supposed to know which of the duplicate options to use? Which one actually effects the desired behavior?

2. Is my perception correct that the use of these options in the designer is inconsistently applied?

 

Thank you.

 

 

bob
Top achievements
Rank 1
 answered on 25 May 2017
13 answers
1.6K+ views
Hi All

I'm getting the following error:
"Selection out of range Parameter name:"

I know what is causing the error - I'm using simple data binding, and the value I'm binding to the ComboBox doesn't exist in its list of values.  I'm looking for a way to work around this, because it's always possible that someone has changed a value in the database to one that doesn't exist in the ComboBox.

I've read that setting AllowCustomText="true" will allow values to be entered that aren't currently in the list, however it still seems to crash if the value I'm binding doesn't exist in the datasource.

Ideally, the functionality I want is:
The list will auto-populate from the datasource.
If the value I bind to the ComboBox doesn't exist in the datasource, then that value is automatically added to ComboBox and can be selected like any other value.
The users can only select values from the list, I wouldn't want them to be able to enter any value they like (which is what I think AllowCustomText does).

Is there any way to do this?
Serge Aranda
Top achievements
Rank 1
 answered on 25 May 2017
1 answer
78 views

Is Telerik ASP.NET AJAX Q2 2011 SP1 compatible with Internet Explorer 11? My Telerik control events are not firing unless I put my browser in compatibility mode.

Thanks

TB
Dimitar
Telerik team
 answered on 25 May 2017
10 answers
1.2K+ views
I would like rto see a form builder component like the form builder in site finity that we could use for our sites.  Does this exist?
Marin Bratanov
Telerik team
 answered on 25 May 2017
1 answer
74 views
I’ve noticed when I enable D&D on a list box in my app, certain keyboard functions no longer work in the list box.  For instance, the up and down arrows do not change the selection, and pressing an alpha key does not move the selection down to the first item starting with that letter.  I also tested your List box demos.  Everywhere D&D is enabled, the keyboard functions I mentioned do not work.

I see no reason why D&D should disable those keyboard functions.  Is this a known issue?  Is this issue scheduled to be fixed in a future release?
Peter Milchev
Telerik team
 answered on 25 May 2017
0 answers
147 views

Hi,

if the column is a grid template column, how can I find the control that is inside the <Item Template> without actually knowing the name.

I know that id can get server side 

foreach (GridColumn column in RadGrid1.Columns)
    {
        if (column.GetType().Name == "GridTemplateColumn")
        {
            foreach (GridDataItem item in RadGrid1.MasterTableView.Items)
            {
                foreach (Control control in item["IsTrue"].Controls)
                {
                    string ColType = control.GetType().Name;
                    string Id = control.ID;
                    if (ColType.Equals("CheckBox"))
                    {
                        string value = ((CheckBox)(control)).Checked.ToString();
                    }
                }
            }
        }
    }

 

But How to write and get above code in the client side ?

Thank you in advance.

Narsa
Top achievements
Rank 1
 asked on 25 May 2017
2 answers
352 views
Hi,

I would like to know how to implement client side validation on controls in edit mode of any row. LIke on clicking edit button we get the edit template dispalyed. Now let us say i have a text box which should take input as integer, if the user enters any value other integet i should give a error message. And this validation should happen on the client side itself may on text changed or on last focus and when the user clicks update button it should not allow the user to submit. Any help would be appreciated./
Reena
Top achievements
Rank 1
 answered on 25 May 2017
1 answer
114 views
I'm working with the RadGrid in Batch mode and I would like to be able to evaluate a cell's value and possibly modify it and write it back to the cell (from 4 to 4:00, for example).  I've been trying to do this in the onBatchEditCellValueChanging event where I can easily read the new value but I have had no luck overriding it.  Any help or javascript samples will be greatly appreciated.
Stephen
Top achievements
Rank 1
 answered on 24 May 2017
2 answers
557 views

Dear All,

One of our web pages is taking nearly 10 – 12 seconds to load. I analyzed the issue and realized that at server it is taking only 4 seconds and immediately I assumed that the remaining time is taken at the client side to load. I did the following to prove my assumption:

 

I have a Rad splitter and two Rad grids are enclosed in the Rad splitter. The OnClientLoad property of the Rad Splitter is assigned with the javascript method OnClientLoad. Under client events of RadAjaxManager  the OnResponseEnd property is assigned with "responseEnd" javascript mehtod.

 

 

         
--------------------------
   <telerik:RadSplitter ID="RadSplitter1" runat="server" Orientation="Horizontal"

                ResizeMode="AdjacentPane" OnClientLoad="OnClientLoad"    Style="height: auto !important;"

                Width="100%" BorderSize="0">

 

 

 

     
-------------------------------------
   <ClientEvents OnRequestStart="requestStarted" OnResponseEnd="responseEnd" />

    </telerik:RadAjaxManager>

 

 

I declared global variables and assigned the time when these two events were fired and finally read those variables at the end of responseEnd method by calling alert function to show these variable values in a message box.

 


From these values I observed that the time difference is 6 seconds.

 


From the above observation I concluded that the rendering time of the grids is taking nearly 6 seconds.

 
When user click on the search button in the web page the first rad grid is shown. And when the user clicks on one of the link buttons which is there on every row in the first grid an ajax call is made and the second grid is displayed. Data bind happens to both the grids on the server side during the ajax call.

 
Around 130 rows are displayed in the second grid. And only one column has editable text box. I am using Rad Input Manager control. There are no other calls being made once the page start loading at the client 


Is my above analysis and assumptions are correct? If it is correct, what I can do to improve performance of rendering the grid. Is this an expected behavior for that amount of data?

 

khawar
Top achievements
Rank 1
 answered on 24 May 2017
0 answers
110 views

Hi,

I have multiple Radwindow on the same page:

<telerik:RadWindow ID="RadWindow2" runat="server" Modal="true" Animation="Fade" AutoSizeBehaviors="Default" Width="600px" Height="330px"
VisibleStatusbar="false" AutoSize="false" Behaviors="Move" Skin="Outlook"  Title = "Request"
EnableEmbeddedSkins="true" EnableEmbeddedBaseStylesheet="true" KeepInScreenBounds="true" EnableShadow="false" VisibleOnPageLoad="False">
<ContentTemplate>
<p style=" font-family:Verdana; font-size:small; color:#195695; margin:10px; text-align:justify;">
<b>SPC schedule in Galaxy does not match EIS Portal created 'saved' request.</b>
</p>
<p style="font-family:Verdana; font-size:small; color:Navy; text-align:justify; padding-left:5px;">
To see EIS Portal initiated 'saved' request information,please follow instruction below:
</p>
<p style=" font-family:Verdana; font-size:small; color:Navy; text-align:justify; padding-left:5px;">
1. In the 'SEARCH CRITERIA' please choose option 'All' from dropdownlist of the 'Record Stat'.
</p>
<p style=" font-family:Verdana; font-size:small; color:Navy; text-align:justify; padding-left:5px;">
2. Click 'SEARCH' button.

</p>
<p style=" font-family:Verdana; font-size:small; color:Navy; text-align:justify;padding-left:5px;">
On the screen look below 'Employee request(s) Information' and there will be a listing of all requests that
have been made.For this request you will see two lines:
</p>
<p style=" font-family:Verdana; font-size:small; color:Navy; text-align:justify;padding-left:5px;">
1. 'Rec Status' 'G' - Galaxy Generated current request
</p>
<p style=" font-family:Verdana; font-size:small; color:Navy; text-align:justify;padding-left:5px;">
2. 'Rec Status' 'H' - EIS Portal Initiated invalid history request
</p>
<p style=" font-family:Verdana; font-size:small; color:Navy; text-align:justify; margin:10px;">
<b>To update information and send the request for approval you can use 'G' record only.</b>
</p>
<div style="text-align:center;" >
<asp:Button ID="FormButton" runat="server" Text="Go to Form" Width="80px" CssClass="button" OnClick="FormButton_Click"/>
<asp:Button ID="CancelButton" runat="server" Text="Close" Width="80px" CssClass="button" />
</div>

 

<telerik:RadWindow ID="RadWindow3" runat="server" Modal="true" Animation="Fade" AutoSizeBehaviors="Default" Width="600px" Height="190px"
VisibleStatusbar="false" AutoSize="false" Behaviors="Move" Skin="Outlook" Title="AVAILABLE OPTIONS"
EnableEmbeddedSkins="true" EnableEmbeddedBaseStylesheet="true" KeepInScreenBounds="true" EnableShadow="false" VisibleOnPageLoad="False">
<ContentTemplate>
<p style=" font-family:Verdana; font-size:small; color:Navy; padding-left:10px; text-align:justify;">
This option should be use to create 'Place Holder' for the new schedule only.
if you want to proceed click on <asp:Button ID ="SubmitBtn" runat="server" Text="Go To Form"
Width="80px" CssClass="button" OnClick="SubmitBtn_Click" />
</p>
<p style=" font-family:Verdana; font-size:small; color:Navy; text-align:justify; margin:15px; ">
If currently approved schedule already exists for this employee, you can modify it
by clicking on 'Link to Form' Button on the home page.
if you want to proceed with this option click on <asp:Button ID="HomeBtn" runat="server" Text="Home Page"
Width="80px" CssClass="button"/>  
</ContentTemplate>
</telerik:RadWindow>

I would like to have different style of titles for this radwindow.

For example for first RadWindow I want color Navy for second RadWindow I Want color Red and different font sizes as well.

How can I achieve this?

thanks so much for your help.

Vitaly.

 


 

 

Vitaly
Top achievements
Rank 1
Iron
Iron
 asked on 24 May 2017
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?