Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
273 views
I have a RadGrid with the property UseStaticHeaders = true for freezing the header row while scrolling.
but when i set this property to true Width of Headers does not match the corresponding Column Header Width while setting that property to false keeps headers and columns width match. How can i have frozen headers matching columns width?
Ali
Top achievements
Rank 1
 answered on 14 Apr 2012
8 answers
187 views
After being unable to resolve this issue with my own code, I tried running the demo site in IE7. To my surprise, it has the same issue.

Steps to Recreate
  1. Go to: http://demos.telerik.com/aspnet-ajax/grid/examples/generalfeatures/filtering/defaultcs.aspx
  2. Filter by shipped date: enter a date or use the date picker, click on the associated filter icon
  3. View the results...

It appears as if the filter icon is behind the date picker icon.





Merritt
Top achievements
Rank 1
 answered on 14 Apr 2012
5 answers
249 views
Hi,

We have a hyperlink in the radgrid and unfortunately the filtering doesn't work.
The following ASPX code have been used:

<telerik:GridHyperLinkColumn HeaderText = "Discussion Name" DataTextField="Discussion_Name"
ItemStyle-HorizontalAlign="Left" UniqueName="Discussion_Name"
DataNavigateUrlFields="Discussion_Id" SortExpression="Discussion_Name" ItemStyle-Width="320"
DataNavigateUrlFormatString="Observation.aspx?Id={0}">
</telerik:GridHyperLinkColumn>

Any ideas why is this?

Thanks!
Nathan
Top achievements
Rank 1
 answered on 13 Apr 2012
2 answers
78 views
I have a grid that if it is empty I want to open up an insert form on page load and fill in some default values.

Most of the code works except for this.

rgvAgmtUsers.Items[0].FireCommandEvent("InitInsert", string.Empty);

Now this works if there is already a record in the grid, but if the grid is empty then it doesn't work.

after this is supposed to fire I am wanting to use the grd.MasterTableView.GetInsertItem() to grab controls and set default values.

Any ideas?

Thanks,

Dustin
Simone
Top achievements
Rank 1
 answered on 13 Apr 2012
0 answers
98 views

Is it possible?? . I trying but I dont get this. Can you help me please.
It is a feature very important for my project.   :(

thank you.
Renato
Top achievements
Rank 1
 asked on 13 Apr 2012
1 answer
103 views
I am trying to set up a RadGrid with multiple dropdownlist filters but I get an ArgumentOutOfRangeException on the MyCustomFilteringColumn 

Here is code from the MyCustomFilteringColumn  
 :
       Protected Overloads Overrides Sub SetupFilterControls(ByVal cell As TableCell)
            MyBase.SetupFilterControls(cell)
            cell.Controls.RemoveAt(0)
            Dim list As New DropDownList()
            list.ID = "list" + Me.DataField
            list.AutoPostBack = True
            AddHandler list.SelectedIndexChanged, AddressOf list_SelectedIndexChanged
            cell.Controls.AddAt(0, list)
            cell.Controls.RemoveAt(1)
            list.DataTextField = Me.DataField
            list.DataValueField = Me.DataField
            list.DataSource = _listDataSource
            list.DataBind()
        End Sub

My RadGrid columns are setup like the below (here is one of the many that I have): 

         <custom:MyCustomFilteringColumn DataField="AssessmentID" FilterControlAltText="Filter AssessmentID column"
             FilterControlWidth="80px" HeaderStyle-Width="80px" ItemStyle-Width="80px" ItemStyle-ForeColor="Black"
                                                HeaderStyle-Wrap="true" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains"
                                                ShowFilterIcon="false" HeaderText="Assessment ID" SortExpression="AssessmentID"
                                                UniqueName="AssessmentID" />


Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        For Each column As GridBoundColumn In RadGrid1.MasterTableView.Columns
            If TypeOf column Is MyStuff.MyCustomFilteringColumn Then
                CType(column, MyStuff.MyCustomFilteringColumn).ListDataSource = GetFilterTable(column.DataField)
            End If
        Next
end sub

    Private Function GetFilterTable(ByVal Field As String) As DataTable
        Dim strConnection As String = ConfigurationManager.ConnectionStrings("PKLConnectionString").ConnectionString
        Dim objConnection As New SqlConnection(strConnection)
        Dim SQLCmd As New SqlCommand() 'The SQL Command
        objConnection.ConnectionString = strConnection     'Set the Connection String
        objConnection.Open() 'Open the connection
        SQLCmd.Connection = objConnection 'Sets the Connection to use with the SQL Command
        Dim dt As New DataTable
        Dim adapter As SqlDataAdapter
        adapter = New SqlDataAdapter("SELECT distinct [" + Field + "] FROM tblAssessment", objConnection)
        objConnection.Open()
        Try
            adapter.Fill(dt)
        Finally
            objConnection.Close()
        End Try
        Return dt
    End Function

Error:
System.ArgumentOutOfRangeException was unhandled by user code
  Message=Specified argument was out of the range of valid values.
Parameter name: index
  ParamName=index
  Source=System.Web
  StackTrace:
       at System.Web.UI.ControlCollection.get_Item(Int32 index)
       at System.Web.UI.ControlCollection.RemoveAt(Int32 index)
       at MyStuff.MyCustomFilteringColumn.SetupFilterControls(TableCell cell) in D:\PKLQMW AT 04 05 2012\PKL_QMW\App_Code\MyCustomFilteringColumn.vb:line 33
       at Telerik.Web.UI.GridColumn.InitializeCell(TableCell cell, Int32 columnIndex, GridItem inItem)
       at Telerik.Web.UI.GridBoundColumn.InitializeCell(TableCell cell, Int32 columnIndex, GridItem inItem)
       at Telerik.Web.UI.GridItem.Initialize(GridColumn[] columns)
       at Telerik.Web.UI.GridItem.SetupItem(Boolean dataBind, Object dataItem, GridColumn[] columns, ControlCollection rows)
       at Telerik.Web.UI.GridTableView.CreateFilteringItem(Boolean useDataSource, GridColumn[] copiedColumnSet, GridTHead thead)
       at Telerik.Web.UI.GridTableView.CreateControlHierarchy(Boolean useDataSource)
       at Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource)
       at System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data)
       at System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data)
       at System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback)
       at System.Web.UI.WebControls.DataBoundControl.PerformSelect()
       at Telerik.Web.UI.GridTableView.PerformSelect()
       at System.Web.UI.WebControls.BaseDataBoundControl.DataBind()
       at Telerik.Web.UI.GridTableView.DataBind()
       at Telerik.Web.UI.RadGrid.DataBind()
       at System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound()
       at System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls()
       at System.Web.UI.Control.EnsureChildControls()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
  InnerException: 

Pavlina
Telerik team
 answered on 13 Apr 2012
1 answer
381 views
Hi, 
I apologize for my bad English I'll try to explain as best as possibleThis is my first ticket:you can call a vb sub from javascript written on the same page.

<script type="text/javascript"> LANGUAGE="JavaScript"

      / / Open window 
     OpenFabbricatiRadWindow function () {
         var wnd = $ find ("<= Fabbricati.ClientID%>");
         wnd.setUrl ("Form_Job / radwindow_Fabbricati.aspx");
         wnd.set_modal (true);
         wnd.show ();
     }
     / / Get selected value
     Fabbricatoselect function (senderEventArgs{
         eventArgs.get_argument var args = ();
         if (arg) {
            Varfabbricato.value = arg.Fabbricato;
            Vargestione.value = arg.Gestione;
       
   Call here ************************** **************** sub Leggi'

  }
     }

    
<script>

in the page vb.aspx

Protected Sub Leggi ()
         Dim query = From c In Archivio.Tabelle_Spesa
         In joins and Archivio.Stato On c.Tab_Stato Equals e.Id_Stato
         Select ID_Tabella c.ID_Tabella =Description = c.Tab_DescrizioneAcronym =c.Tab_Siglathousandths = c.Tab_MillesimiState = e.Stato_Descrizione
         Query = RadGrid1.DataSource
         RadGrid1.DataBind ()

     end Sub



Thank

Fabio Cirillo
Top achievements
Rank 1
 answered on 13 Apr 2012
2 answers
79 views
Hi, i have a radgrid with allowpaging.
I need to make a verification in all items in the grid before saving in the database, but the code just verify only ten itens that displayed in the first page. How can i make a solution to resolve this problem ? 

Actually, my code do this: 

      foreach (GridDataItem item in rgdRebanho.Items)
                {
                    CheckBox ckbItem = (CheckBox)((item).FindControl("ckbItem"));
                    if (ckbItem.Checked == true && ckbItem.Enabled == true)
                    {
                            RadDateInput dt_ocorrencia = (RadDateInput)((item).FindControl("dt_ocorrencia"));
                            if (dt_ocorrencia.SelectedDate == null)
                            {
                                erro = true;
                            }
   
                    }
                }



Sorry if have some words wrong, but i don´t speak english very well.


Thanks!
Diego
Top achievements
Rank 1
 answered on 13 Apr 2012
10 answers
254 views
Hi I have a problem I need to change the background color of a timeslot container , when i click over it and is not assigned to a appointment ?

How can i do that ,pleasse help me?
NEX
Top achievements
Rank 1
 answered on 13 Apr 2012
1 answer
96 views
Hi, I have a wizard running as part of a custom add-in for Outlook 2010. In one of the wizard dialogs I have a Telerik GridView control. The wizard dialog window that contains the Grid is re-sizable and I would like to have the Telerik Grid dynamically resize as the user re-sizes the Wizard dialog.

Any suggestions on how to achieve this would be greatly appreciated.

Thanks
Gary 
Pavlina
Telerik team
 answered on 13 Apr 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?