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

The grid is based on code from a sample client side grid but I'm having a problem with data hanging around after changing pages. For this sample, assume there's 215 lines of data but the grid is set to 200 lines.  When the page changes to page 2, it correctly displays 15 lines on the screen but in the data structures that the javascript can access it sees 200 lines (which makes sense, I know the grid maintains it's original size even if it isn't showing all the lines) but all 200 lines have data bound to them (the first 15 are the new 15, the other 185 are left over from page 1).
Is it right that the extra lines on the second page still have data bound to them?  The grid seems to know to only display the first 15, how do I in my code tell which lines I should be retrieving data from for my totals?

Thanks,
Sean

 

           

function GridCommand(sender, args) {
  GetGridData(true);
}
 
function GetGridData(sendEnteredData) {
  PageMethods.GetData(currentPageIndex, tableView.get_pageSize(), sortField, sortOrder, enteredData, updateGrid, errorInCall);
}
 
function updateGrid(result) {
  var tableView = createGrid.get_masterTableView();
  tableView.set_dataSource(result);
  tableView.dataBind();
  updateTotals();
}
 
function updateTotals() {
  var items = createGrid.get_masterTableView().get_dataItems();
 
  if (items != null && items.length > 0) {
    for (var i = 0; i < items.length; i++) {
      if (items[i].get_dataItem() != null) {
        // I'm expecting only the first 15 lines would make it here if on the second page but all 200 still have data bound
      }
    }
  }
}

 

 

Martin
Telerik team
 answered on 23 Mar 2012
1 answer
110 views
Hello,

I'm attempting to create a custom field editor with a combo box with checkboxes. The problem I'm having is that only a single value is being extracted by RadFilterSqlQueryProvider.

When I walk through the code of the custom editor, the ExtractValues() method gets all the checked items. However, the SetEditorValues() method only passes in a single value.

To implement this, just use the code examples provided by Telerik and set CheckBoxes = true on the RadComboBox. Modify the ExtractValues() method to loop through the CheckedItems collection and add to the array. Then loop through the array in SetEditorValues();

Also, I am not using the Apply button I use FireApplyCommand() on PostBack. Plus, it seems that I have to use the RecreateControl() method on the RadFilter. Otherwise, I don't get any values back.

Any help would be appreciated.

Blair
Tsvetina
Telerik team
 answered on 23 Mar 2012
11 answers
174 views
Hi Guys,

I wonder if any one can shed some light on an issue we are having?

The webpage we have an issue with has a telerik:RadDateTimePicker. If the 'MultViewColumns' and 'MultiViewRow' properties are not set then the navigation works on the calendar when it pops up works fine, as does the quick month/Year selection.

However as soon as we set the 'MultiViewColumns' to 2 or more the navigation quits working, along with the quick Month/Year selection. The List of months and years pops up but selecting anything does not refresh the calendar to teh correct new month.

The html code we are using below:

<telerik:RadDateTimePicker ID="fdCourseStartDateDateTimePicker" 
        runat="server" 
        Skin="GCI"
        EnableEmbeddedSkins="false" AutoPostBackControl="Calendar" >
    <DateInput ID="DateInput2" runat="server" DateFormat="D" ReadOnly="true" >
    </DateInput>
    <TimePopupButton runat="server" Visible="false" />
    <Calendar ID="fdCourseStartDateCalendar" 
            runat="server" 
            EnableEmbeddedSkins="false" 
            Skin="GCI"
            UseRowHeadersAsSelectors="False" 
            UseColumnHeadersAsSelectors="False"
            MultiViewColumns="2" >
        <FastNavigationSettings 
            DateIsOutOfRangeMessage="Erk!" 
            EnableTodayButtonSelection="true" />
    </Calendar>
</telerik:RadDateTimePicker>

If any one can advise it will be aprreciated.

Best regards,
Dib.
Andrey
Telerik team
 answered on 23 Mar 2012
6 answers
161 views
Hi;

I have a simple grid that is connected to ObjectDataSource usinf EF. The filter works fine, but when I click on any column, i get error:
"Microsoft JScript runtime error: Could not complete the operation due to error c00ce514."

Could you please advise what to do.

Note: I have another similar Grid in another page with AllowSorting=True, but when I click on any column, nothing happens.

Thanks!
Ben Hayat
Top achievements
Rank 2
 answered on 23 Mar 2012
1 answer
125 views
hi,
I have a  public class AgendaProvider : DbSchedulerProviderBase
who implements

public

override IDictionary<ResourceType, IEnumerable<Resource>> GetResources(ISchedulerInfo schedulerInfo)

so I get my resource on my appointment form (like Users or Rooms on your template)
How can i get my selected value of my resource on the appointment form ?
I don't use the resource tag on the aspx page...just a

<WebServiceSettings  Path="~/DataSvc/SchedulerWcfService.svc" ResourcePopulationMode="ServerSide"/>

Ivana
Telerik team
 answered on 23 Mar 2012
1 answer
204 views
Greetings,

I have a radgrid with an image on each lines which opens a radwindow. When i close My radwindow i need to refresh the grid which is in the parent page.


This is how i close my radwindow:

                    
    <asp:Button ID="Validation" runat="server" Text="Enregistrer et envoyer l'offre" OnClick="Validation_Click"
OnClientClick="if(Page_ClientValidate()) CloseDialog()" UseSubmitBehavior="false"
 />
    
function GetRadWindow() {
    var oWindow = null;
    if (window.radWindow) oWindow = window.radWindow;
    else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;
    return oWindow;
}
 
function CloseDialog() {
    GetRadWindow().close();
    return true;
 
 
}


I tried to do it that way in my parent page:

<telerik:RadWindowManager ID="RadWindowManager1" runat="server" EnableShadow="true">
    <Windows>
        <telerik:RadWindow ID="RadWindow1" runat="server" Width="700px" Height="500px" Title="Details du ticket"
            Skin="WebBlue" Behaviors="Close, Move" Modal="true" OnClientClose="closeRadWindow">
        </telerik:RadWindow>
    </Windows>
</telerik:RadWindowManager>
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="RadGrid1">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="RadGrid1" />
            </UpdatedControls>
        </telerik:AjaxSetting>
        <telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="RadGrid1" />
            </UpdatedControls>
        </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManager>
JS:

<script type="text/javascript"> 
function closeRadWindow() 
{ 
    $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest();  
} 
</script>
.CS

protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e)
{
    RadGrid1.MasterTableView.SortExpressions.Clear();
    RadGrid1.MasterTableView.GroupByExpressions.Clear();
    RadGrid1.Rebind();
}


It doesn't work. Is there anything i'm missing

(got a JS error with IE ( Property id null or undefined ), & no error but not working at all with firefox)

thanks in advance
Marin Bratanov
Telerik team
 answered on 23 Mar 2012
2 answers
334 views
Hello , whether it is possible to disable Add, Delete and Remove buttons in RadUpload control, so user only can upload one file ?
Joe
Top achievements
Rank 2
 answered on 23 Mar 2012
1 answer
132 views
Hi,

 when i double clicked on any appointment, I don't want to open an appointment edit template.

Thanks,
Madhan.
Plamen
Telerik team
 answered on 23 Mar 2012
1 answer
148 views
Hi,
I am using the Radcompression module version 2011.2.915 and have enablePostbackCompression set to true along with RadHiddenFieldPageStateCompression in the App_Browsers folder.

The page in question has a RadGrid sitting within a RadAjaxPanel. The Grids datasource is being persisted in viewstate, hence it can get quite large.

I have noticed using Fiddler however that only the first callback appears to have its viewstate compressed.
The bytes sent for the pageload, followed by its subsequent callbacks are as follows with the hiddenfieldpagestatecompression on
891  21,920  250,414  232,786
the above is all in bytes
when disabled however and following the same steps I get as follows
987  118,592   250,424   233,082

I would expect the first number (the page request) to be just about the same as there is no viewstate.
As expected the first call back is significantly larger due to the lack of viewstate compression.
I was however surprised to see that the subsequent callbacks bytes sent were almost the same. This suggests to me that the viewstate compression has stopped taking place. The page still works fine however so it has not been corrupted which is good.

I was wondering if anyone else has encountered similar issues or not?
Thanks
Matt
Martin
Telerik team
 answered on 23 Mar 2012
3 answers
156 views
Hi,

I am using RadTextBox with a width specified in a stylesheet.
.InputField
{
    width: 85px !important;
}

With the previous release this was working great.

With the new release (Q1 2012) the style sheet is not working.

In the attached picture you see that in the version Q1 2012 an inline style is attached to the generated span for the RadTextBox. In version Q3 2011 this was not present. This is why the width in the css-file is ignored.

Is this a bug in Q1 2012?

Paul

 

Galin
Telerik team
 answered on 23 Mar 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?