Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
102 views
Hi, I recently purchased the Ulimate Collection and have started working with the RadGrid as I'm developing a KPI for Sharepoint WSS (2007). I have come across, what I think is a bug in the control and I can replicate it easily now as I have played around with it for the last 3-4 days.

Keep in mind that I am creating this control entirely in a class that inherits from WebPart. This can be either Microsoft.SharePoint.WebPartPages.WebPart OR System.Web.UI.WebControls.WebParts.WebPart. They are both derived from the same parent so I don't think this is the issue. At least I HOPE not.

Issue #1
The following code does NOT render the Header Image OR Text at all! Nothing! So I can't sort on the column.
If I change the ShowSortIcon to = true, then I get the Image to display in the header. This leads to Issue #2 and then Issue #3 which is the killer.

_radGrid = new RadGrid
 {
     ID = "telerikInspections",
     DataSource = _siteSpecificAreas,
     AutoGenerateColumns = false,
     AllowPaging = false,
     EnableViewState = true,
     AllowSorting = true,
     ShowHeader = true,
     ShowFooter = true,
     ShowStatusBar = false,
     GroupingEnabled = false,
     ShowGroupPanel = false,
     Skin = "Forest"
 };
  
gbc = new GridBoundColumn
 {
     UniqueName = "CountPendingInspection",
     DataField = "CountPendingInspection",
     HeaderImageUrl = "/_layouts/images/custom.images/Purple-P-16.png",              
     ShowSortIcon = false,
     HeaderText = "Pending Inspection",
     Aggregate = GridAggregateFunction.Sum
 };
 _radGrid.Columns.Add(gbc);

Issue #2
So I have the above code with 2 other columns to the right of it. Just Grid Bound Columns with Text Headers, NOT Image ones.

Scenario.
1. I click the Column with the Image in the Header to sort it and it works nice. I get the Sort Icon too. All is good. The column is highlighted.
2. I click it again to sort it the other way and it works. The column is highlighted
3. I click it a 3rd time and it's now unsorted and the column is no longer sorted and hence NOT highlighted. Still all is good.
4. Now this is where it goes wonky. I click the same column a 4th time, note it is once again sorted and highlighted.
5. Now I click the column to the right BUT the focus jumps to the 3rd column!!

What I think is happening is that the SortIcon, along with the Header Image, is causing an offset in the number of controls in the header, which is forcing the focus to jump to the next column to the right. I hope there is a work around to this because it will confuse the users for sure.

Moreover, there is a more serious issue to this

Issue #3!!  (die, die, die)
If I add columns to the left of the Image Header Column and start sorting those, within 2 clicks it blows up in my face with the following error.

An error has occurred because a control with id 'Inspections1$telerikInspections$ctl00$ctl02$ctl00$ctl05' could not be located or a different control is assigned to the same ID after postback. If the ID is not assigned, explicitly set the ID property of controls that raise postback events to avoid this error. 

It's not always the same id, but it ALWAYS blows up. If I remove the HeaderImageUrl attribute then all is fine and dandy and the sorting works 100%. But as soon as I re-introduce a column with an image in the header it blows up, or I get that strange offset to the right of the image header column.

The important thing to remember here is that the when I have, say 4 columns (1,2,3,4). If column 2 is the image header column then nothing blows up (just acts strange) UNTIL I click that column to the LEFT (number 1) of the Image column!

One more interesting thing to mention is that if EnableViewState is set to False for the Grid then the sorting on the Graphic header does not work, however it will work on the Text Headers, but ONLY on the Text headers to the right of the Graphic headers

This has been a long hard slog to get to this point, but I know (1000 million%) how to reproduce this Problem so I'm looking for some serious help here. Please and Thank You.

Best Regards
Dave Stuart
Dave
Top achievements
Rank 2
 answered on 11 Feb 2011
3 answers
965 views
Hi,
    Recently, I found an issue that when an image is corrupted, and we try to assign it to RadBinaryImage, we get error "Parameter is not valid". Thats OutOfMemory exception, seems .NET can't load image properly then. However, this cause ASP.NET application to throw an "unhandled" exception.

   I wonder, if it was possible for telerik component to validate the image as it was assigned to it (like DataValue property) and throw an exception to indicate that assigned value is NOT a valid image. Currently, I have to load image, and if loads successfully, then I use my routine to convert the image to bytes and assign to DataValue property. 

   Though I see many threads on this topic "Parameter is not valid", as per I know, its "mysterious" ASP.net message and most of the time, caused by OutOfMemory exception. I wonder if this "check of validity of image" should be implemented in other controls of telerik, like reporting etc.

   Thanks,
   Sameers
Mira
Telerik team
 answered on 11 Feb 2011
1 answer
124 views
Hello in my radgrid grid sorting not working proper

my column value likes this
99
88
65
888
8
94
now sorted reslut
99
94
88
888
8
65
its wrong i need output likes this
888
99
94
88
65
8

don't know why this happened, Here i attached screen shot for this
 
Jayesh Goyani
Top achievements
Rank 2
 answered on 11 Feb 2011
1 answer
123 views
Hi,

I wanted to pass RadSchedulerRecurrenceEditor's recurrence rule to into the RecurrenceData field of a sharepoint's calendar list item. RecurrenceData Field expects a XML format of Recurrence rule.  Could someone help me to resolve this. It would be great if someone shares the code. Its really urgent.

Thanks, Mulagundla
Veronica
Telerik team
 answered on 11 Feb 2011
3 answers
124 views

Hi

I have a RADGrid with one button column and rest bound columns as follows;

<telerik:RadGrid ID="DocsList" runat="server" AllowPaging="True" GridLines="None"
    OnNeedDataSource="DocsList_NeedDataSource">
    <MasterTableView AutoGenerateColumns="False">
        <Columns>
            <telerik:GridBoundColumn FooterText="Document" UniqueName="Document" SortExpression="ContactTitle"
                HeaderText="Document" DataField="Document" Resizable="true">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn FooterText="Index" UniqueName="Index" HeaderText="Index"
                DataField="Index" Display="false">
                <ItemStyle Width="0px" />
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn FooterText="MediaURL" UniqueName="MediaURL" HeaderText="MediaURL"
                DataField="MediaURL" Display="false">
                <ItemStyle Width="0px" />
            </telerik:GridBoundColumn>
            <telerik:GridButtonColumn FooterText="View" ButtonType="ImageButton" UniqueName="View"
                HeaderText="View" ItemStyle-HorizontalAlign="Center" HeaderStyle-HorizontalAlign="Center"
                CommandName="Select" DataTextField="CustomerID" ImageUrl="~/Resources/Images/submit.png">
                <ItemStyle Width="20px" />
            </telerik:GridButtonColumn>
        </Columns>
    </MasterTableView>
</telerik:RadGrid>

I have a few questions;

1. How can I attach an onclick event to the buttons in the button column so when a button in a row is clicked then value of one of the bound columns in the same row is returned?

2. The button images' seems to have an annoying shadow (image1.jpg attached). How can this be removed?

3. When this web page is being viewed in browser and browser window is scaled down the buttons start to crop instead of grid rescaling to allow the button to remain fully visible (image2.jpg attached). How can this be fixed?

Many Thanks

Regards

 

Mira
Telerik team
 answered on 11 Feb 2011
1 answer
74 views
It looks like the usage of global resources isn't fully implemented yet in the latest version 2010.3.1317.40. For example the GridPagerItem still contains quite a few hardcoded texts. Furthermore I think it would be nice if the item commands would support globalization too. Is there any chance of an ETA for the completion of globalization support for RadGrid?
Mira
Telerik team
 answered on 11 Feb 2011
2 answers
91 views
Hello,
     I have a problem with the RadGrid. I can't grouping draging a header to group panel. If I group by code like the following, it works. When the page is loaded the grid appears grouped, but if I remove the group draging it out from the group panel the grid is ungrouped and then I can't to group again draging a header or even reorder headers draging them.

<MasterTableView>
        
       <GroupByExpressions>
       <telerik:GridGroupByExpression>
       <GroupByFields>
       <telerik:GridGroupByField FieldName="Usuario.Login" />
       </GroupByFields>
       <SelectFields>
       <telerik:GridGroupByField FieldName="Usuario.Login" />
       </SelectFields>
       </telerik:GridGroupByExpression>
       </GroupByExpressions>
       </MasterTableView>

I have GroupingEnabled property set to true and also ShowGroupPanel. I was looking for a solution in the forum and I haven't found anybody with the same issue.

Can anybody help me.  Thanks in advance.





Tajes
Top achievements
Rank 1
 answered on 11 Feb 2011
1 answer
178 views
 I had the latest ver. (trial) of asp.net telerik, then my computer died and Dell come over and replaced my motherboard!

After that the ASP.NET AJAX Telerik will not run in localhost.
I run it in Visual Studio 2010 and run it there from!

If I copy the project to another computer it will work but no longer in my project!

See the screen attached file!

I have repaird, and reinstalled the ASP.NET AJAX Telerik, but I got the same problem!

Anybody got a tip of this issue?



Markus
Top achievements
Rank 1
 answered on 11 Feb 2011
1 answer
123 views

Hi,
There is an issue with Rad Upload control not loading File Open dialog box in Fire Fix. Please find belwo Rad Upload markup and Javascript function. This javascript function working perfectly in IE but not in Fire Fox because it doesn't allow File Input control to be clicked. Please provide a workaround for this issue.

Thanks in advance.

Rad Upload markup:

<telerik:RadUpload id="fileUploadImport" OnClientAdded="MakeKeyBoardAccessible"      OnClientFileSelected="validateBrowse" ReadOnlyFileInputs="true" EnableEmbeddedSkins="false" Skin="Default" AllowedFileExtensions=".txt"  ControlObjectsVisibility="None"  ToolTip="Browse"  runat="server">
<Localization Select = "Browse"/>
</telerik:RadUpload>


Javascript function:

function MakeKeyBoardAccessible(radUplaod, args) {

        args._row.all[3].onkeydown = function(e) {

            var keycode;

            if (window.event) keycode = window.event.keyCode;

            else if (e) keycode = e.which;

            else return true;

 

            if (keycode == 13) {

                args._row.all[1].click();

            }

        }

 }



Regards,
Bhaskar
Genady Sergeev
Telerik team
 answered on 11 Feb 2011
1 answer
48 views
I have the following code in my aspx page for the RadTreeViewContext Menu. It is simple code. For some reason when I click on a node and the menu comes up I click on a menu item but the page will NOT submit. The context menu item does nothing when I click it. Any ideas. Please see code below it is simple code ...

<telerik:RadTreeView ID="RadTreeView1" Runat="server">
  
     <ContextMenus>
       <telerik:RadTreeViewContextMenu OnContextMenuItemClick="RadTreeView1_ContextMenuItemClick" runat="server" ID="HelpDeskMenu"  ClickToOpen="True" Skin="Vista">
           <Items>
           <telerik:RadMenuItem Text="Add Lesson Component" Value="xyz"></telerik:RadMenuItem>
           </Items>                      
       </telerik:RadTreeViewContextMenu>
   </ContextMenus>
  
   </telerik:RadTreeView>
  
  
// CODE TO POPULATE TREE 
  
  RadTreeNode node = new RadTreeNode("Test Google");
              
                   RadTreeNode node2 = new RadTreeNode("Test Google 2");
                   RadTreeView1.Nodes.Add(node);
            RadTreeView1.Nodes.Add(node2);
Yana
Telerik team
 answered on 11 Feb 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?