Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
85 views
Greetings,

I am populating my footer using the following ItemDataBound Event:

protected void rGridReporting_ItemDataBound(object sender, GridItemEventArgs e)
        {
            var subList = (List<VendorSubTotal>)Session["SubList"];

            if (!(e.Item is GridFooterItem) || subList.Count == 0) return;

            var footer = (GridFooterItem)e.Item;

            var t855 = subList.Sum(v => v.Total855);
            var t856 = subList.Sum(v => v.Total856);
            var t810 = subList.Sum(v => v.Total810);
            var p855 = t855 / subList.Count;
            var p856 = t856 / subList.Count;
            var p810 = t810 / subList.Count;

            footer["vName"].Controls.Add(new LiteralControl("<div style='color: Black; font-weight: bold;'>Report Grand Totals:</div> "));
            footer["t855"].Controls.Add(new LiteralControl("<div style='color: Black; font-weight: bold;'>" + t855 + "</div> "));
            footer["p855"].Controls.Add(new LiteralControl("<div style='color: Black; font-weight: bold;'>" + p855 + "</div> "));
            footer["t856"].Controls.Add(new LiteralControl("<div style='color: Black; font-weight: bold;'>" + t856 + "</div> "));
            footer["p856"].Controls.Add(new LiteralControl("<div style='color: Black; font-weight: bold;'>" + p856 + "</div> "));
            footer["t810"].Controls.Add(new LiteralControl("<div style='color: Black; font-weight: bold;'>" + t810 + "</div> "));
            footer["p810"].Controls.Add(new LiteralControl("<div style='color: Black; font-weight: bold;'>" + p810 + "</div> "));
        }

The problem I am having occurs when I expand or collapse a column the event doesn't fire and my footer is not reloaded. When I re-order the fields of the grid or using paging the footer is reloaded just fine. Any suggestions would be most helpful.

Thanks!
Shane
Top achievements
Rank 1
 answered on 19 Aug 2010
2 answers
133 views
Issue: When adding a hyperlink using the hyperlink button in the telerik editor, the same group of documents comes up over and over when you try to navigate through the available pages

We are using MOSS 2007 and IE8. Screenshots are attached. Note the document names in browsetopage2 are the same as the ones in browsetopage1. The pages library has 670 pages in it.

Thanks for any advice you can offer - I will pass it on to our developer.
Tom
Tom
Top achievements
Rank 1
 answered on 19 Aug 2010
3 answers
119 views
Hi. We've implemented radtooltips in the scheduler by following the example here. We used a RadAjaxManagerProxy before we introduced the tooltips because we also use a custom edit/insert form and like the loadingpanel effect while waiting for the form to appear. Now that there is an updatepanel in the mix we've gotten rid of the ajaxsetting for the scheduler. Is there any way to ajaxify the scheduler (with radajaxloadingpanel) but not have it apply to the radtooltip? Thanks.

Daniel
Peter
Telerik team
 answered on 19 Aug 2010
3 answers
108 views
For some reason, when my radgrid is displayed with no data in it, the right-most columns (the number of columns varies) disappear from view.  I have the ClientSettings scrolling properites set (allowscroll="true", UseStaticHeaders="true", ScrollHeight="500px").  When I remove these settings, the described effect does not occur.  We do have a need to have the scrolling clientsettings enabled as we are showing a substantial amount of columns on the page.  Is this a known issue and is there a suggested fix to my problem?  Thanks.
Dimo
Telerik team
 answered on 19 Aug 2010
1 answer
96 views
Hi,

    I have a problem with the filter. Below is the scenario.

   1, I have a grid with 3 columns filter enabled.
   2. When i select some criteria in the first filter text box and filter by "Starts with" it is working
   3. I removed the text from the first filter text box and added some other text in the second text box
       but the deleted criteria is also displaying in the first text box alond with the second text box with is the problem. 
   4. I know there is an option call "No Filter" to do this, but when i remove any text from any of the filters
       it should not come up again with another filter criteria.

    Thanks for your help.

Thanks,
Raj
Maria Ilieva
Telerik team
 answered on 19 Aug 2010
1 answer
86 views
Hi,

I'm binding a rag grid to the data source on aspx page except one column AGE which I'm calculating in code behind. The data binding works fine but filtering doesn't work for that column. Below is my code.

<

 

telerik:RadGrid AutoGenerateColumns="false" ID="rgrdPatient" DataSourceID="dsUINList"

 

 

AllowFilteringByColumn="True" AllowSorting="True"  ShowFooter="True" AllowPaging="True" runat="server"

 

 

OnItemDataBound="rgrdPatient_ItemDataBound" AllowMultiRowSelection="true">

 

<

 

MasterTableView AutoGenerateColumns="false" EditMode="InPlace" AllowFilteringByColumn="True" DataKeyNames="ID" >

 

 

<Columns>

 

 

<telerik:GridBoundColumn DataField="DOB" HeaderText="Age" SortExpression="DOB" CurrentFilterFunction="EqualTo"

 

 

UniqueName="DOB" AutoPostBackOnFilter="true" ShowFilterIcon="true" FilterControlWidth="30px" DataType="System.Int16">

 

 

<HeaderStyle HorizontalAlign="Center" Width="30px" />

 

 

<ItemStyle HorizontalAlign="Center" Width="30px"/>

 

 

</telerik:GridBoundColumn>

 

</

 

Columns>

 

 

 

</MasterTableView>

</

 

telerik:RadGrid>


 

 

protected void rgrdPatient_ItemDataBound(object sender, GridItemEventArgs e)

 

{


 

string Age = item["DOB"].Text;

 

 

DateTime dtAge = Convert.ToDateTime(Age);

 

Age =

GeneralFunction.CalculateAge(dtAge.Year.ToString(), dtAge.Month.ToString(), dtAge.Day.ToString()).ToString();

 

item[

"DOB"].Text = Age;

 


}

Regards,
Lubna.

Maria Ilieva
Telerik team
 answered on 19 Aug 2010
4 answers
95 views
Hi, how to scale data-bound values along a given axis?  For example, the underlying data values need to be multiplied by 2 before being displayed on the Y-axis.  How to accomplish this?

Thanks
AS
Top achievements
Rank 1
 answered on 19 Aug 2010
1 answer
123 views
I'm running into a problem where resetting exceptions on a repeating appointment causes the first appointment to disappear from the Scheduler.  Using the demo project from this page in the knowledge base, the following steps will reproduce the issue.

1. Open project in VS2010
2. Run project conversion wizard
3. Convert project to .Net 4.0
4. Remove reference to old version of Telerik.Web.UI
5. Add reference to installed trial version (2010.2.713.40) of Telerik.Web.UI for .Net 4.0
6. Run project
7. Switch Scheduler to week view
8. Create and save test appointment on 8/17/2010, 9:00am-10:00am, repeats weekly on Tuesdays, no end date
9. In Scheduler, drag appointment on 8/17/2010 to a different timeslot, creating exception
10. Double click on appointment on 8/17/2010, and edit series
11. Click and confirm 'reset exceptions'
12. Click 'Save' in open appointment editor

At this point, the appointment on 8/17/2010 no longer shows up, though subsequent repeating occurrences are shown correctly.  By checking the xml data file at various steps, it appears that the appointment is being save correctly after step 11, but after step 12, the recurrence rule incorrectly shows an exception date.

after step 8
  <Appointment>
    <ID>49</ID>
    <Subject>test</Subject>
    <Start>2010-08-17T09:00Z</Start>
    <End>2010-08-17T10:00Z</End>
    <RecurrenceRule><![CDATA[DTSTART:20100817T090000Z
DTEND:20100817T100000Z
RRULE:FREQ=WEEKLY;INTERVAL=1;BYDAY=TU;WKST=
 
]]></RecurrenceRule>
  </Appointment>

after step 9
    <Appointment>
    <ID>49</ID>
    <Subject>test</Subject>
    <Start>2010-08-17T09:00Z</Start>
    <End>2010-08-17T10:00Z</End>
    <RecurrenceRule><![CDATA[DTSTART:20100817T090000Z
DTEND:20100817T100000Z
RRULE:FREQ=WEEKLY;INTERVAL=1;BYDAY=TU
EXDATE:20100817T090000Z
]]></RecurrenceRule>
  </Appointment>
  <Appointment>
    <ID>50</ID>
    <Subject>test</Subject>
    <Start>2010-08-17T10:00Z</Start>
    <End>2010-08-17T11:00Z</End>
    <RecurrenceParentID>49</RecurrenceParentID>
  </Appointment>

after step 11
    <Appointment>
    <ID>49</ID>
    <Subject>test</Subject>
    <Start>2010-08-17T09:00Z</Start>
    <End>2010-08-17T10:00Z</End>
    <RecurrenceRule><![CDATA[DTSTART:20100817T090000Z
DTEND:20100817T100000Z
RRULE:FREQ=WEEKLY;INTERVAL=1;BYDAY=TU
]]></RecurrenceRule>
  </Appointment>

after step 12
    <Appointment>
    <ID>49</ID>
    <Subject>test</Subject>
    <Start>2010-08-17T09:00Z</Start>
    <End>2010-08-17T10:00Z</End>
    <RecurrenceRule><![CDATA[DTSTART:20100817T090000Z
DTEND:20100817T100000Z
RRULE:FREQ=WEEKLY;INTERVAL=1;BYDAY=TU
EXDATE:20100817T090000Z
]]></RecurrenceRule>
  </Appointment>


Is there a way to prevent this behavior?  I've tried a few things with some of the client side events, but haven't had much luck yet.

Thanks
Peter
Telerik team
 answered on 19 Aug 2010
1 answer
244 views
Hi,

I am trying to code a RadGrid control in a web part but find the control is not consistent when developing via the designer vs developing programatically. One issue is the grid control paging. Even though all settings are configured correctly, the only way to show the paging control at the bottom of the grid was to set it to always show. I then discovered, that although the SharePoint list data is bound correctly and the data is visible, the paging control shows only "0 items in 1 pages". This is of course wrong, since I can see as many entries as the page holds (10 in the default case). I can also filter the values and see additional items, however, the page control still indicates 0 items in 1 page.

Here are the grid settings being loaded.

rgdIncidentList =

new Telerik.Web.UI.RadGrid();

 

rgdIncidentList.Width =

Unit.Pixel(1070);

 

rgdIncidentList.GridLines =

GridLines.Vertical;

 

rgdIncidentList.ShowHeader =

true;

 

rgdIncidentList.HorizontalAlign =

HorizontalAlign.Center;

 

rgdIncidentList.SelectedIndexChanged +=

new System.EventHandler(rgdIncidentList_SelectedIndexChanged);

 

pnlIncidentList =

new Panel();

 

pnlIncidentList.ID =

"pnlIncidentList";

 

pnlIncidentList.Controls.Add(rgdIncidentList);

CreateColumn(

"LinkTitle", 75, "MLE #", true, true, true);

 

CreateColumn(

"Incident_x0020__x0023_", 70, "Incident #", true, true, true);

 

CreateColumn(

"Location", 90, "Location", true, true, true);

 

CreateColumn(

"Zone", 70, "Zone", true, true, true);

 

CreateColumn(

"On_x0020_Scene", 50, "On Scene", false, true, true);

 

CreateColumn(

"Contact", 70, "Contact", true, true, true);

 

CreateColumn(

"Action_x0020_Type", 70, "ActionType", true, true, true);

 

CreateColumn(

"Action_x0020_Taken", 70, "Action Taken", true, true, true);

 

CreateColumn(

"Additional_x0020_Action", 70, "Additional Action", true, true, true);

 

CreateColumn(

"Noise_x0020_Type", 10, "Noise Type", false, false, false);

 

CreateColumn(

"Tickets_x0020_Issued", 10, "Tickets", false, false, false);

 

CreateColumn(

"Action_x0020_By", 10, "Action By", false, false, false);

 

CreateColumn(

"Officer", 10, "Officer", false, false, false);

 

CreateColumn(

"Badge", 10, "Badge", false, false, false);

 

CreateColumn(

"Contact_x0020_DOB", 10, "Contact DOB", false, false, false);

 

CreateColumn(

"Owner", 10, "Owner", false, false, false);

 

CreateColumn(

"Owner_x0020_Contact", 10, "Owner Contact", false, false, false);

 

CreateColumn(

"Entered", 10, "Entered", false, false, false);

 

CreateColumn(

"Comment", 10, "Comment", false, false, false);

 

CreateColumn(

"Created_x0020_By", 10, "Created By", false, false, false);

 

CreateColumn(

"Modified_x0020_By", 10, "Modified By", false, false, false);

 

rgdIncidentList.AllowPaging =

true;

 

rgdIncidentList.AllowCustomPaging =

true;

 

rgdIncidentList.PagerStyle.Mode =

GridPagerMode.NextPrevAndNumeric;

 

rgdIncidentList.PagerStyle.PageButtonCount = 10;

rgdIncidentList.PagerStyle.ShowPagerText =

true;

 

rgdIncidentList.PagerStyle.Visible =

true;

 

rgdIncidentList.PageSize = 10;

rgdIncidentList.AllowFilteringByColumn =

true;

 

rgdIncidentList.AutoGenerateColumns =

false;

 

rgdIncidentList.AllowSorting =

true;

 

rgdIncidentList.ClientSettings.AllowColumnsReorder =

true;

 

rgdIncidentList.ClientSettings.Selecting.AllowRowSelect =

true;

 

rgdIncidentList.ClientSettings.Scrolling.SaveScrollPosition =

true;

 

rgdIncidentList.AutoGenerateColumns =

false;

 

rgdIncidentList.MasterTableView.AllowCustomPaging =

true;

 

rgdIncidentList.MasterTableView.AllowPaging =

true;

 

rgdIncidentList.MasterTableView.AllowSorting =

true;

 

rgdIncidentList.MasterTableView.AllowFilteringByColumn =

true;

 

rgdIncidentList.MasterTableView.AutoGenerateColumns =

false;

 

rgdIncidentList.PagerStyle.AlwaysVisible =

true;

 


I've attached two screenshots, one of the grid control created by the designer and displayed on an aspx page. The other is of the grid control created programatically and displayed as a web part in a SharePoint 2007 site. The data is ordered a bit differently in the two examples, but the information is queried from the same SharePoint list. The web page uses an SQL query and the data model is bound to the control. The web part performs dll calls from the SharePoint library to obtain the same list information, the data model of which is bound to the control.

What needs to be changed or added such that the paging works correctly for RadGrid within a web part?

Any help is greatly appreciated.

Michael
Iana Tsolova
Telerik team
 answered on 19 Aug 2010
3 answers
242 views
I am using RadEditor on our company Intranet for users to post News Announcments.  Is there a way to make a custom tool with a paper clip to attach a file to that current post.  I am worried that the document manager will be to complex for most of the users because the would have to figure out how to upload it and the insert that document.  I would like to have it where they clicked the paper clip and a dialog box came up to browse their computer and then they choose it and click attach. 

Thank you in advance for your help and suggestions.
Rumen
Telerik team
 answered on 19 Aug 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
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?