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


I have a RadGrid bound to an IList<SomeType>, where SomeType is defined as a struct with two string properties (e.g., A and B).  In the Grid, column 0 displays property A and column 1 displays property B.   Both properties contain data in mixed case.

The grid sorts the data in a case-sensitive manner, such that "AA" is the first item and "zz" is the last item, and "Music" and "music" are not next to each other:

Is there a way to make the grid perform the sort in a case-insensitive manner?  How do people normally handle this situation with the RadGrid?   Do I need to do a case-insensitive sort of the data and rebind (AKA "custom sorting")?

Thanks!

Vasil
Telerik team
 answered on 24 Mar 2011
0 answers
73 views
Hello,

I'm facing three problem with the silverlight dialog within the RTL RadEditor:
1) The Dialog is not designed well in RTL mode (Common problem for all dialogs in RTL mode).
Please view the attached image.

2) As you can see in the attached image I can't add InitParameters to the silverlight control. Is there any way to set the InitParameters without using the HTML Mode of the RadEditor (I mean manually)? Is there any way to add fields to this dialog? If it is possible, please explain to me how I can do that?

3) What does the following properties means:
    a. Windowless
    b. Auto Upgrade
    c. Enable Hml Access

Please, I need your help in order to solve the above problems.
It is apreciared to send me a code which solves the first two problems and an explaination for the third problem.

Regards,
Bader
Bader
Top achievements
Rank 1
 asked on 24 Mar 2011
3 answers
124 views
Hi there,

I'm facing the following problem:

First I had a web page that consisted of a RadTabStrip. When you clicked on any of its tabs, a RadGrid would be shown (related to its tab). There was one Radgrid in particular that when you double clicked on a row a RadWindow would show and render a PDF as its contents. As anyone might imagine for this I had to set the RadGrid's OnRowDblClick ClientSetting-ClientEvents to a javascript function.
<ClientSettings...
   <ClientEvents OnRowDblClick="RowDblClickAC" />

and the function:
function RowDblClickAC(sender, eventArgs) {
                var oWnd = window.radopen("../Catalogos/CatContent.aspx?" +
                    "NoCredito=" + eventArgs.getDataKeyValue("ID") +
                    "&FechaRegistro=" + eventArgs.getDataKeyValue("DateTrans"),
                    "uld");
                oWnd.setSize(800, 500);
                oWnd.center();
                oWnd.set_modal(true);
                oWnd.set_title = "PDF Content";
            }

and I also had the RadWindowManager code:
<telerik:RadWindowManager ID="rwm" runat="server" Skin="Outlook">
        <Windows>
            <telerik:RadWindow ID="uld" runat="server"
                AutoSize="true" VisibleTitlebar="true"
                VisibleStatusbar="false"
                ReloadOnShow="true" Modal="true" ShowContentDuringLoad="false"         
                Skin="Outlook" />
        </Windows>
    </telerik:RadWindowManager>

As anyone can see this code, everything worked OK as soon as the controls were declared declaratively. For performance reasons, I had to re-create the webpage by now loading dynamically each RadGrid. Now when I want to double click on a row, the RadWindow pops up but it stays there "forever" (with a circular loading panel) but without presenting the PDF. As I just mentioned, before everything worked OK.

Please, can someone shed some light on this?

Felix
Svetlina Anati
Telerik team
 answered on 24 Mar 2011
3 answers
86 views
I have a RadScheduler whose data source is a SiteFinity event one. In the RadScheduler_AppointmentClick event, I have access to the Appointment class, but I can't seem to gain access to properties such as the location, description, etc.

Michael
Top achievements
Rank 1
 answered on 24 Mar 2011
2 answers
137 views

Ok.  This is driving me nuts, because I'm missing what's causing this to happen.  I am creating RadGrid columns programmatically, using one grid (aspx page) for 7 different datasources, controlled by a Case statement.  My problem is that if I click either on the Edit button( GridEditCommandColumn) or on the Delete button (GridButtonColumn), the Delete button disappears on postback.  All other columns(GridBoundColumn) reappear just fine.  Here is the snippet of code. It appears in a Page Load event.  The DataSourceID is supplied with a NeedDataSource event which is why it is commented out in the snippet.  What am I missing?  Thanks in advance.

If Not IsPostBack Then
            Dim intReport As Integer = Request("Report")
            Select intReport
                Case 0
                    ' Comments
                    'rgDisplay.DataSourceID = "CommentsDS"
                    rgDisplay.MasterTableView.DataKeyNames = New String() {"CMT_REC_ID"}
                    rgDisplay.Width = Unit.Percentage(90)
                    rgDisplay.PageSize = 5
                    rgDisplay.AllowPaging = True
                    rgDisplay.PagerStyle.Mode = GridPagerMode.NextPrevAndNumeric
                    rgDisplay.AutoGenerateColumns = False
                    rgDisplay.Skin = "Hay"
                    rgDisplay.MasterTableView.PageSize = 20
                    rgDisplay.MasterTableView.Width = Unit.Percentage(100)
                    rgDisplay.MasterTableView.EditMode = GridEditMode.InPlace
                    Dim colEdit As GridEditCommandColumn
                    colEdit = New GridEditCommandColumn
                    colEdit.UniqueName = "EditCommandColumn"
                    colEdit.ItemStyle.Width = Unit.Pixel(25)
                    rgDisplay.MasterTableView.Columns.Add(colEdit)
                    Dim colDel As GridButtonColumn
                    colDel = New GridButtonColumn
                    colDel.Visible = True
                    colDel.CommandName = "Delete"
                    colDel.UniqueName = "cmdDelete"
                    colDel.Text = "Delete"
                    colDel.ItemStyle.Width = Unit.Pixel(25)
                    rgDisplay.MasterTableView.Columns.Add(colDel)
                    Dim colBound As GridBoundColumn
                    colBound = New GridBoundColumn
                    rgDisplay.MasterTableView.Columns.Add(colBound)
                    colBound.DataField = "CMT_REC_ID"
                    colBound.HeaderText = "Number"
                    colBound.UniqueName = "CMTRecID"
                    colBound = New GridBoundColumn
                    rgDisplay.MasterTableView.Columns.Add(colBound)
                    colBound.DataField = "CMT_DESCRIPTION"
                    colBound.HeaderText = "Description"
                    colBound.UniqueName = "CMTDescription"
Chuck Harrington
Top achievements
Rank 1
 answered on 24 Mar 2011
3 answers
256 views
Hi All,

I have the follow scenario:

There are 2x RadDateTimePickers on a RadWindow along with a checkbox. When the checkbox is checked they both become enabled.

I pass the dates back to my main window when the RadWindow is closed. I would like to prevent the RadWindow from closing and alert the user when their values are invalid. Examples: The input fields are enabled, but empty. The second field is larger than the first, etc. 

The main problem here is that my close function which closes the RadWindow fires before the form validation. I read that to avoid this I should move my close function to server-side, but I am not sure this is a viable solution because I pass arguments back from the RadWindow to the main window.

How can I fix this?

Sean

Marin Bratanov
Telerik team
 answered on 24 Mar 2011
3 answers
118 views
Hello,
I am running into a strange error when trying to implement a version of http://blogs.telerik.com/toddanglin/posts/08-12-12/showing_radtooltip_on_radinput_input_error.aspx.  The error is "htmlFile: Unspecified error." and is called from var n=q.getClientRects(); which is in turn called from var b=$telerik.getLocation(a) in the Telerik JavaScript.

Any help in pointing out the cause of this would be appreciated.

Steps To Reproduce:
  1. Enter a valid mm/yyyy value in the first textbox, e.g. 1/2011
  2. Click outside of the textbox and ensure it loses focus

Svetlina Anati
Telerik team
 answered on 24 Mar 2011
2 answers
553 views
I am using a radGrid with UserControl to handle editing and inserts.

I am binding the grid at runtime, similar to the example on http://demos.telerik.com/aspnet-ajax/grid/examples/dataediting/usercontroleditform/defaultvb.aspx

After executing the insert command, I would like the grid to return to default mode (i.e. leave insert mode), but have been unable to do this.  I am using the UpdateCommand - code as below.  The item is successfully added to the database, but I get a jscript error

"Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: Insert item is available only when grid is in insert mode."

Basically, I am looking for the ASP.Net gridview equivalent of edititemindex = -1.  Are you able to assist.

Thanks
Ben


Private Sub RadGrid1_UpdateCommand(ByVal source As Object, ByVal e As Telerik.Web.UI.GridCommandEventArgs) Handles RadGrid1.UpdateCommand

    Dim editedItem As GridEditableItem = CType(e.Item, GridEditableItem)

 

 

 

    Dim userControl As UserControl = CType(e.Item.FindControl(GridEditFormItem.EditFormUserControlID), UserControl)

 

        strID =

CType(userControl.FindControl("txtID"), TextBox).Text    

 

        DataComponent.SaveAsset(strID)

        RadGrid1.MasterTableView.IsItemInserted = False

 

 

 

 

        Me.RadGrid1.Rebind()

 

 

 

    

 

 

 

End Sub

 


Ben
Top achievements
Rank 1
 answered on 24 Mar 2011
4 answers
143 views
I have a panel bar in a master page and I have code in my vb of the master page to set the selected link to show like so

Dim clickedItem As RadPanelItem = RadPanelBar1.FindItemByUrl(Request.Url.PathAndQuery)
 
If Not (clickedItem Is Nothing) Then
    clickedItem.ExpandParentItems()
    Dim childItem As RadPanelItem
    For Each childItem In clickedItem.PanelBar.GetAllItems()
        childItem.CssClass = ""
    Next childItem
 
    clickedItem.CssClass = "rpSelected"
 
End If

The problem is, I have some pages you can get to by links within other pages that aren't in the panel bar. I would like to manually set the panel bar on these pages. However, I'm having trouble figuring out how I can get the control because it's in a master page. I've tried something like this 
        Dim clickedItem As RadPanelItem = Master.FindControl("Radmenu1")
        Dim rad As RadPanelItem = clickedItem.FindItemByUrl("Leads/LeadList.aspx")
but I can't seem to figure out how to get the control to set which item. Any ideas?
Web Services
Top achievements
Rank 2
 answered on 24 Mar 2011
3 answers
93 views
Hi
I am using the following master deatil grid. When user view 's this page, it is exapanding only the first record and shows it's detials. I would like view all the records as expanded.  This is the workflow, i want the user to view all the records at once. How can i do this?


<telerik:RadGrid ID="grdWorkFlow" runat="server" Width="100%" ShowStatusBar="True" AutoGenerateColumns="False"
                                            PageSize="7" AllowSorting="True" AllowPaging="True" GridLines="None">
                                            <PagerStyle Mode="NumericPages"></PagerStyle>
                                            <ClientSettings EnableRowHoverStyle="true">
                                                <Selecting AllowRowSelect="true" />
                                            </ClientSettings>
                                            <MasterTableView Width="100%" DataKeyNames="Record_Status_ID" AllowMultiColumnSorting="True"
                                                AllowFilteringByColumn="False" ExpandCollapseColumn-Display="True">
                                                <DetailTables>
                                                    <telerik:GridTableView DataKeyNames="ID" Name="Workflow_list" Width="100%" AllowPaging="True" PageSize="5" AlternatingItemStyle-BackColor="AliceBlue">
                                                        <Columns>
                                                          
                                                            <telerik:GridBoundColumn SortExpression="ID" HeaderText="ID#"
                                                                HeaderButtonType="TextButton" DataField="ID" Visible="true">
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn SortExpression="Name" HeaderText="Name" HeaderButtonType="TextButton"
                                                                DataField="Name" UniqueName="Name">
                                                            </telerik:GridBoundColumn>
                                                            <telerik:GridBoundColumn SortExpression="Date" HeaderText="Date"
                                                                HeaderButtonType="TextButton" DataField="Date" UniqueName="Date">
                                                            </telerik:GridBoundColumn>
                                                           <telerik:GridTemplateColumn UniqueName="View">
                                                                <ItemTemplate>
                                                                    <asp:LinkButton ID="lnkView" runat="server" CausesValidation="false" CommandArgument='<%# Eval("ID") %>'
                                                                        CommandName="View" Text="View"></asp:LinkButton>
                                                                </ItemTemplate>
                                                                <HeaderStyle Width="10px" />
                                                            </telerik:GridTemplateColumn>
                                                           
                                                           
                                                           
                                                        </Columns>
                                                    </telerik:GridTableView>
                                                </DetailTables>
                                                <ExpandCollapseColumn Visible="True">
                                                </ExpandCollapseColumn>
                                                <Columns>
                                                    <telerik:GridBoundColumn SortExpression="Record_Status_ID" HeaderText="Record_Status_ID"
                                                        HeaderButtonType="TextButton" DataField="Record_Status_ID" Visible="False">
                                                    </telerik:GridBoundColumn>
                                                    <telerik:GridBoundColumn SortExpression="Status Description" HeaderText="Work Flow Item"
                                                        HeaderButtonType="TextButton" DataField="Description">
                                                    </telerik:GridBoundColumn>
                                                    <telerik:GridBoundColumn SortExpression="Num" HeaderText="Number of records" HeaderButtonType="TextButton"
                                                        DataField="Num">
                                                    </telerik:GridBoundColumn>
                                                </Columns>
                                            </MasterTableView>
                                        </telerik:RadGrid>


Thank you,
usr9999
Top achievements
Rank 1
 answered on 24 Mar 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?