Telerik Forums
UI for ASP.NET AJAX Forum
11 answers
1.7K+ views
Hi

I have a grid set up with AllowMutltiRowSelection = "True", a GridClientSelectColumn and the following ClientSettings

<ClientSettings>

<Selecting AllowRowSelect="True" EnableDragToSelectRows="false" />

</ClientSettings>

Selection is working fine.

What I would like to be able to do is, in the ItemDataBound event for the grid, disable the selection of one or more of the bound rows depending on certain conditions (e.g. a control has a paticular value).

I can use e.item.enabled = false but this doesn't stop the selection of the row by either clicking on the row or checking the GridClientSelectColumn's select all checkbox in the grid header.

Can anyone suggest how this can be acheived other than using server-side selection?

Perhaps the grid is lacking a GridDataItem.AllowSelection property that could be checked client side?

Thanks

Andy

Using:
.NET 3.5
WinXP SP2
IE 7.0
RadControls for ASP.NET AJAX Q1 2008
VB.NET
Doncho
Telerik team
 answered on 05 Nov 2020
1 answer
376 views

I run into a scenario where controls in an EditForm loses their values when performing a postback, after recently cancelling an event.

 

For example:

1. Add new item (perform InitInsert), or edit existing item (perform Edit)

2. Make changes to control values

3. If adding, perform PerformInsert command, otherwise Update command

4. I have logic that would cancel the event (whether on ItemCommand or PerformInsert level) based on some values

5. Event cancelled, fire NeedDataSource in the background by default

6. On the EditForm, perform any postback (via cancel or attempt an insert/update again)

7. The control values within the EditForm lose their value

 

I thought if I cancelled on the ItemCommand level, the control values would persist, but this was not the case.

 

Any ideas on what I could do?

Attila Antal
Telerik team
 answered on 04 Nov 2020
10 answers
689 views
I'm currently evaluating RadGrid (Q2 2008) and I'm finding that the column resizing behavior doesn't seem to work properly when I attempt to use the following settings:
  • AllowScroll = true
  • UseStaticHeaders = true (works properly if set to false)
  • AllowResize = true
  • EnableRealTimeResize = true (still breaks if false is set, just not as obvious)
When UseStaticHeaders is set, the column resize action seems to change the column width to a value that is exponentially greater than the user's click-and-drag operation would suggest. Also, attempting to shrink the width of a column actually makes that column wider. If UseStaticHeaders is set to false, the grid behaves as expected.

Is anyone else experiencing this problem? Is this a defect in the product or a defect in my implementation?

-K

Attila Antal
Telerik team
 answered on 04 Nov 2020
9 answers
1.8K+ views

Hi,

I have pdf files stored as a blob in sql database.  Is it possible to load them to PdfViewer? I found this example but it's for MVC.  Do you have an example for webform?

 

 

Thank you,

Helen

 

 

 

Rumen
Telerik team
 answered on 04 Nov 2020
1 answer
142 views
hello. the recurrence exception generated from scheduler is in the format 20201028T053000Z. how can i parse it to datetime in c#?
Vessy
Telerik team
 answered on 03 Nov 2020
4 answers
145 views

I have a RadEditor control on a page with several lines of notes. All lines appear on the page, but when the page is printed some lines are cutoff at the bottom. Are there any RadEditor or CSS settings that will resolve this?

<telerik:RadEditor
    ID="reNotes" runat="server"
    EditModes="Preview" ContentAreaMode="Div" NewLineMode="P"
    ToolsFile="~/App_Data/RadEditor/Tools.xml" ToolbarMode="ShowOnFocus"
    AutoResizeHeight="true" Height="100%" Width="100%"
    Content='<%# Bind("Notes") %>' ContentFilters="RemoveScripts,StripCssExpressions,StripDomEventAttributes"
    OnClientLoad="RadEditorOnClientLoad">
</telerik:RadEditor>
Rumen
Telerik team
 answered on 03 Nov 2020
2 answers
351 views

Hi,

I have the telerik:RadAutoCompleteBox  in aspx page server side. It works five. Postback works fine on the tab key or loosing focus of the text field. But now I need to have what was selected if user selected a value with click in the dropdown selection box. Here are the steps:

1. User began typing and mouse-clicked on some line in the dropdownbox. The text was populated. No post-back event fired. The text is, let's say, "My selection 1"

2. User changed the text (to My selection 2) and clicked on an another field. Post-back event fired. And I have the text value "My selection 2" in the post-back method on the server.

What I need is a post-back event to save the "My selection 1" value after the step 1. Is it possible to do?

Here is my code:

<telerik:RadAutoCompleteBox ID="txtAgtName" AllowCustomEntry="true" RenderMode="Lightweight" runat="server" TabIndex="15" EmptyMessage="Please type Agent's name here"
                                            DataSourceID="SqlDataAgentName" DataTextField="AgentName" InputType="Text" Width="170px" DropDownWidth="150px" OnTextChanged="txtAgent2Email_TextChanged">
                                            <TextSettings SelectionMode="Single" />
                                        </telerik:RadAutoCompleteBox>

Andrey
Top achievements
Rank 1
Veteran
 answered on 03 Nov 2020
17 answers
2.1K+ views
Hi All,

this is my first post here, but I'm having a problem with the PageSizes setting for a grid.

Here is my markup for the Pager:
<PagerStyle Mode="NextPrevAndNumeric" PageSizeLabelText="Page Size: " PageSizes="{1, 10, 20, 50, 100, 200, 250}" />


And attached is an image showing what this produces (the grid has been removed because of client info).

As you can see, the first and last options are not present in the dropdown.  Why is this?

My second question would be this:  If I wanted (site-wide) to have 10,20, 50, 100, 200 as my page sizes, and 50 as the default...is there a way to do that without modifying all grids in my system individually?

Vessy
Telerik team
 answered on 03 Nov 2020
5 answers
248 views

When using Telerik controls with Bootstrap theme and Bootstrap 3.x the radWindow title has cosmetic issue (see attached).

It appeared that Bootstrap global box-sizing: border-box is the reason. 

The workaround is to set box-sizing: content-box  in rwTitleWrapper

It could easily reproduced here https://demos.telerik.com/aspnet-ajax/window/examples/browserdialogboxes/defaultcs.aspx 

Please fix in your next release(s).

Rumen
Telerik team
 answered on 02 Nov 2020
9 answers
291 views
Hi,

I don't know why, but the hyperlink manager doesn't work, it shows up but the buttons doesn't display its caption and doesn't work. even the style drop down menu doesn't work.

<

 

telerik:RadEditor ID="RadEditor1" runat="server" ToolsFile="~/RadControls/Editor/ToolsFileContent.xml"

 

 

Height="600px" Skin="Windows7"

 

 

NewLineBr="False" AutoResizeHeight="True" ContentFilters="FixUlBoldItalic, FixEnclosingP, IECleanAnchors, MozEmStrong, ConvertFontToSpan, ConvertToXhtml, IndentHTMLContent, EncodeScripts, OptimizeSpans"

 

 

StripFormattingOptions="MSWordRemoveAll" OnClientCommandExecuting="OnClientCommandExecuting">

 

 

<CssFiles>

 

 

<telerik:EditorCssFile Value="~/stylesheets/RadEditorCss.css" />

 

 

</CssFiles>

 

 

<Content>

 

 

</Content>

 

 

<Tools>

 

 

<telerik:EditorToolGroup>

 

 

<telerik:EditorDropDown Name="FormatedLiks" Text="Formated Liks" ItemsPerRow="1" PopupWidth="90" PopupHeight="90">

 

 

<telerik:EditorDropDownItem Name ="Video Link" value="<li class='video'>Video Link</li>" />

 

 

<telerik:EditorDropDownItem Name ="Standard" value="<li class='standard'>Video Link</li>" />

 

 

<telerik:EditorDropDownItem Name ="Pack Link" value="<div style='margin-top: 11px;'><a class='bodylinks' style='font-size: 11px;' href='#'>PackLink</a></div>" />

 

 

</telerik:EditorDropDown>

 

 

</telerik:EditorToolGroup>

 

 

</Tools>

 

 

</telerik:RadEditor>

 



Attached a screenshot.

Regards,
Rumen
Telerik team
 answered on 30 Oct 2020
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?