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

I need some help changing my jquery code to work with the radComboBox instead of a select. I have the following code that selects 2 select boxes.

How can I do the same with 2 radComboBoxes?

var $filters = $('#filters select[name=\"filter\"]');
Shinu
Top achievements
Rank 2
 answered on 18 Oct 2012
2 answers
135 views
When using Add Paragraph button in the HTML editor, if the paragraph is inside a table cell, then we will create some <p> tag nested within another <p> tag. HTML standard doesn't support <p> nested inside another <p> tag. 

Steps to reproduce,


1. Create a 1 cell table, add some text to the table cell in any HTML editor
2. Now select the text and click center align icon , increase the fornt, change the font -> switch to HTML view and you will notice the <p align> being added
3. Go back to the design view -> Click on the empty space between aligned text -> click on "Enter" to go to next line >  Click the Add Paragraph icon twice -> You should have the nested <P> tag. I've put the result HTML code in the comment section.
 

The datatags marked in yellow is nested inside datatag marked in red, this should not be the case.

 This datatag is in IE

<P>

<TABLE>

    <TBODY>

        <TR>

            <TD>

            <P align=left>&nbsp;<SPAN style="FONT-FAMILY: 'Palatino Linotype', 'Book Antiqua', Palatino, serif; FONT-SIZE: 16px">this is my final <BR>

            <P>&nbsp;</P>

            <P>&nbsp;</P>

            <P>&nbsp;</P>

            <P  align=left>text</P>

            </SPAN></P>

            <P align=left>&nbsp;</P>

            </TD>

        </TR>

    </TBODY>

</TABLE>

</P>


The nested P tag is creating random issues in the past and it's creating junk code under some circumstances.  Can we fix this?

Arjun
Top achievements
Rank 1
 answered on 18 Oct 2012
1 answer
165 views
Hello,

I have a RadButton with which is a CheckBox with text (ButtonType = ToggleButton, ToggleType = CheckBox).
I want that the text is a link. 
Setting the NavigateUrl isn't exactly what I'm looking for since checking will also redirect.

How can I set up the RadButton so that the text is a link but the checkbox is not?

Thanks!
Princy
Top achievements
Rank 2
 answered on 18 Oct 2012
2 answers
105 views
I have a RadDatePicker attached to a RequiredFieldValidator as part of a Template column.

I want the validation to fire whenever the grid attempts to page.  Looks like, by default, this does not occur.  Even if the RadDatePicker is empty, the validation does not fire when I page the grid.

Is there anyway I can force this?

I attempted to respond to the OnCommand client event when it is of type "Page", force the validation.  

function grid_OnCommand(sender, eventArgs) {
                var c = eventArgs.get_commandName();
                if (c == "Page") {
                    if (!Page_ClientValidate()) {
                        eventArgs.set_cancel(true);
                    }
                }
            }

While the validation does fire and the grid's data does not refresh, the pager still moves to the next page.  The set_cancel does not seem to take effect fully when paging.

Any help would be greatly appreciated.
Robert
Top achievements
Rank 1
 answered on 18 Oct 2012
6 answers
529 views
Hello,

I'm trying to hide the command item section on a grid based on user preferences, something like this:

if(user has no access)
{
    grid.AllowAutomaticInserts = false;
    grid.MasterTableView.CommandItemDisplay = GridCommandItemDisplay.None;
    //also I perform some code to hide columns
}

I use PreRender event to execute it. Hiding columns works fine but I still get the CommandItem section on the top of the grid. However, if I click on "Add new record" link, that section disappears after postback, showing the grid the way I want it. This is fine, I mean the user can't add items, but I don't want him to see the option as available.

If I call Rebind() after the above code is executed, the command section goes away. That's fine but the DataBind event is called twice, a behavior I don't want.

Am using the right event (PreRender) to execute the code? 

One more thing, my grid is inside a RadDock.

Thanks
Ching Luo
Top achievements
Rank 1
 answered on 17 Oct 2012
1 answer
50 views
Hey,

I'm working with mvc and asp.net. I have a telerik grid with 10 columns. But I need the first 5 columns grouped under 1 header and the last 5

f.e.

Before christ   |  After christ
1  |2  |3  |4  |5  | 1 |2  |3  |4  |5


I already found this link:
http://demos.telerik.com/aspnet-ajax/grid/examples/programming/multicolumnheaders/defaultcs.aspx

But that is for an ajax grid and that is not what I need. I'm using a razor view. Anyone has any ideas?
Angel Petrov
Telerik team
 answered on 17 Oct 2012
1 answer
172 views

Hello everyone,

I need your help, i have 2 RadGrid which each depend on other grid.
Each grid can sort. But if i sort the first grid i lost the first row selected item and the second grid give me error of grid1 cant be null

So, i would like to know how i can set the focus on the last selected item or just focus on the first row?
I use VB.NET

I have tried sample i found here, and nothing change like 

RadGrid1.MasterTableView.Items(0).Selected = True

for now in my Page_Load to get the focus i use radgrod1.items(0).focus()
but it doesn't work on the SortCommand sub, i get a javascript error message

In this sub, i get a new DataSource and i rebind the radgrid.
I have tried RadGrid1.SelectedIndexes.Add(0) with my .focus and same JS error.

Thanks for your help.

Pavlina
Telerik team
 answered on 17 Oct 2012
1 answer
73 views
Hi,
I want to create a component with the following setup

  • RadGrid: In the FormTemplate I have multiple components:
  • RadTextBox: Allows to search a tree in search-as-you-type manner (via AJAX), continuously updating a 
  • RadTreeView: As soon as I click there I want to put the selected item (via AJAX) into a 
  • asp:Label (inside an asp:UpdatePanel) and return it to the RadGrid
  • There are other RadTextBox and RadTreeView elements in the form as well, allowing search-as-you type on different trees as well.

I've got the latter four working in a separate page, but have not yet succeeded to integrate with the RadGrid.

It seems that there is a problem with Ajaxified controls within all RadGrid FormTemplates: According to this post it is not possible to put individual AJAX-enabled components into any RadGrid form, right? (I am afraid it is no option for me to put all of these components into a combined AJAX control as I have to update all the contained components individually).

Is there any workaround for me?
Is the problem the same in RadComboBox popups?

Thanks for your help,
Jürgen
Pavlina
Telerik team
 answered on 17 Oct 2012
2 answers
796 views
I'm trying to get the ClientID of a RadGrid from a sender object in a javascript event.   I need to get the RadGrid from a filteritem keypress event.  How do I get that?

This is crude but I can get it like this:

                var RadGrid1 = $find(sender.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.id);

Anybody got any idea how to get the uniquename from the sender object?
Darren
Top achievements
Rank 1
 answered on 17 Oct 2012
13 answers
284 views
Hi,

I am forming my grid cells by merging multiple rows as shown here :
http://www.telerik.com/community/forums/aspnet-ajax/grid/can-i-use-html-code-like-lt-td-rowsapn-2-gt-in-grid.aspx#1144543

I have different color for my alternate rows. But with the merged cell functionality the css is all mixed up as shown in the screen shot. Could you suggest how to put have the non-merged cells as the alternate row?
Galin
Telerik team
 answered on 17 Oct 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?