Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
98 views
Here's a weird phenomenon.
Everything was working fine with our RadTabStrip until upgrading to the latest Telerik version.
We have a tab strip where new pageViews are being created dynamically.
In one pageView we have a few RadDateInputs among other input fields.
Upon completion, you click a submit button that takes you to the next tab (a page with RadGrid where you can manage attachments - edit, delete and add files).
If you wishes to go back and correct your input you may click the earlier tab and edit your input.
This was running with no problem before the upgrade.
Now, the first submission goes without a hitch. However, if one goes back and re-submit, we get this error:

Text property cannot be set. String was not recognized as a valid DateTime.   
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.   
 
Exception Details: System.InvalidCastException: Text property cannot be set. String was not recognized as a valid DateTime.  
 
Source Error:   
 
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.    
 
Stack Trace:   
 
 
[InvalidCastException: Text property cannot be set. String was not recognized as a valid DateTime.]  
   Telerik.Web.UI.RadDateInput.RangeTextProperty(String value) +192  
   Telerik.Web.UI.RadDateInput.set_Text(String value) +22  
   Telerik.Web.UI.RadInputControl.LoadPostData(String postDataKey, NameValueCollection postCollection) +103  
   Telerik.Web.UI.RadDateInput.LoadPostData(String postDataKey, NameValueCollection postCollection) +26  
   Telerik.Web.UI.RadWebControl.System.Web.UI.IPostBackDataHandler.LoadPostData(String postDataKey, NameValueCollection postCollection) +13  
   System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +346  
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1743  
 
   
 
 
--------------------------------------------------------------------------------  
Version Information: Microsoft .NET Framework Version:2.0.50727.3603; ASP.NET Version:2.0.50727.3082  

Anyone has encountered such problems after upgrade.
We've been going wild over this problem for two whole days now, trying to figure out where the problem is...
If there's a problem with the date format, how does it go through the first time?

Many thanks for any clue.
Chanan Zass
Top achievements
Rank 1
 answered on 27 Nov 2009
5 answers
122 views
Hi

In the FormTemplate of my RadGrid there's an ajax postback taking place. It just gets some data and fills it into a RadEditor - which works fine.
Further I added another control - a button - beneath the RadEditor, with no functionality so far. The weird thing is: After such an ajax request is done and I click this button, an IndexOutOfBounds exception occurs. Unfortunately the error is not popping up in my (self-written) code, but in an earlier stage.

I searched the forums, still, before flooding you with code and stuff I'd like to know if this is a common issue and if there's already a solution?

Fyi, I will not be able to answer before next wednesday 'cause I'm away :)

Thanks in advance for some help!
Best
Roman
Rosen
Telerik team
 answered on 27 Nov 2009
1 answer
51 views
Hi,

I am dragging an item from radgrid and dropping them in treeview.
I am using it with plain server side code i.e. when row is dropped on node of treeview postback happens.
Now when i drag the row entire row is moved, but i want while moving only Title of grid item should appear as moving.

Please let me know any settings which i am missing.
I have already crosschecked this forum:
http://www.telerik.com/community/forums/aspnet-ajax/general-discussions/treeview-and-radgrid-drag-and-drop.aspx

But this does not seems to be working in case of postback.


Regards,
Amit Tuteja
Rosen
Telerik team
 answered on 27 Nov 2009
6 answers
363 views
Hello everyone,

I have a splitbutton with an radtoolbarbutton that is a template. The template works fine and displays perfectly, however when I do a postback on the page, the template disappears and i see nothing. Has anyone experienced this before. The RadToolBar is below:

 <telerik:RadToolBar ID="RadToolBarGridMenu" runat="server" Width="100%"  
            onbuttonclick="RadToolBarGridMenu_ButtonClick" Skin="Black" > 
            <Items> 
                <telerik:RadToolBarButton Text="Bulk Edit Selected" Value="Edit"></telerik:RadToolBarButton> 
                <telerik:RadToolBarButton Text="Update Data" Visible="false" Value="Update"></telerik:RadToolBarButton> 
                <telerik:RadToolBarButton Text="Cancel Bulk Edit" Visible="false" Value="Cancel"></telerik:RadToolBarButton> 
                <telerik:RadToolBarButton IsSeparator="true" />           
                <telerik:RadToolBarButton Text="Disable Paging" Value="Paging"></telerik:RadToolBarButton>       
                <telerik:RadToolBarButton Text="Expand All" Value="Expand" Visible="false" /> 
                <telerik:RadToolBarButton Text="Collapse All" Value="Collapse" Visible="false" />      
                <telerik:RadToolBarButton IsSeparator="true" /> 
                <telerik:RadToolBarDropDown Text="Export"
                    <Buttons> 
                        <telerik:RadToolBarButton Text="Export To PDF" CommandName="PDF" /> 
                        <telerik:RadToolBarButton Text="Export To Word" CommandName="Word" /> 
                        <telerik:RadToolBarButton Text="Export To Excel" CommandName="Excel" /> 
                    </Buttons> 
                </telerik:RadToolBarDropDown>     
                <telerik:RadToolBarButton IsSeparator="true" /> 
                <telerik:RadToolBarSplitButton Value="View" > 
                    <Buttons> 
                        <telerik:RadToolBarButton Text="All Projects">                            
                        </telerik:RadToolBarButton> 
                        <telerik:RadToolBarButton IsSeparator="true" Value="Separator" /> 
                        <telerik:RadToolBarButton CssClass="logo" Value="SaveTemplate"
                            <ItemTemplate>            
                                <div onclick="StopPropagation(event)">                  
                                     <table id="NewView" width="250px" style="margin-left:28px"
                                        <tr><td>View Name:</td><td><asp:TextBox ID="TextBoxViewName" runat="server" Width="150px" MaxLength="200" /></td></tr> 
                                        <tr><td>Is Default View:</td><td><asp:CheckBox ID="CheckBoxViewDefault" runat="server" /></td></tr> 
                                        <tr><td colspan="2" align="center"><asp:Button ID="ButtonCreateView" runat="server" Text="Save Template As View" OnClick="SaveTemplateAsView" /></td></tr> 
                                     </table>   
                                </div>                                                  
                            </ItemTemplate> 
                        </telerik:RadToolBarButton> 
                    </Buttons> 
                </telerik:RadToolBarSplitButton> 
            </Items> 
        </telerik:RadToolBar> 

Thank you.
Yana
Telerik team
 answered on 27 Nov 2009
2 answers
208 views
Hi

I would like my combobox to display 10 items from a list of 100 items.
After 'onItemsRequested' I want it to only display rows 11 - 20.  But I am having trouble getting it to do this, it keeps displaying the first ten + the subsequent ten.
I have tried using
    uiCmboTier.Items.Clear();

but It still shows the previous data rows.

Any help would be more than appreciated.
I assume it should be able to do this ?  All the demos show the list growing and growing after each 'OnItemsRequested' even though they also use comboBox.Items.Clear();  ???

Thank you
Jonathan
Jonathan Annandale
Top achievements
Rank 1
 answered on 27 Nov 2009
0 answers
65 views

I'll grant you, wanting to upload a zero-length file is, well, an odd thing to want to do, but, it seems, in FF3.5 you can't.

I select the file OK, but when I click the button that causes a PostBack, and hence starts the Upload does nothing.

I have both client- and server-size validation on the form I use for this and I can see that the client-side validation functions fire but NO server-side code runs; not OnLoad or the server-side validation.

The same code run in IE8 /does/ upload the file.

As I say, wanting to upload a zero-length file seems like a waste of bandwidth to me, but it should work consistently, don't you think?

BTW, this code is running under Q1 2009.

-- 

Stuart

Stuart Hemming
Top achievements
Rank 2
 asked on 27 Nov 2009
4 answers
186 views
Hello,

I use a radtooltipmanager to replace the browser standard tooltip. It works well except in one case: I have a radgrid with reoredcolumnsonclient=true. If I swap two columns, the tooltip still displays the previous column value and not the new one.
I also did the test with Qtip and Jquery.tooltip, and the results is the same.

Is there a trick?

Best regards,

Laurent
Svetlina Anati
Telerik team
 answered on 27 Nov 2009
2 answers
57 views
Hi guys,

I am using the Tabstrip control with scrolling enabled but for some reason the scroll buttons are not visible when using the Sitefinity skin. You can click on them but no visible image is available. It works with other skins.

Any suggestions? 

Thanks.
Joseph
Top achievements
Rank 1
 answered on 27 Nov 2009
1 answer
186 views
I had need to give a month/year picker and I found this post:

Unfortunately, it doesn't play nicely if the user tries to modify the dates to be something other than the first of the month either by the "Today" button or by typing into the textbox. Attached is some slightly modified script where I've made this work for a "From" and "To" field where it also nicely handles a user modifying (whether on purpose or by accident) the day of the month. This script standardizes on the first of the month at 00:00:00.

Again, keep in mind that this script is for a slightly different page than that demo but it should be clear how to purge the script for the second field.

    //override the onload event handler to change the picker after the page is loaded 
    Sys.Application.add_load(setCalendarTable); 
 
    function setCalendarTable() { 
 
        var picker1 = $find("<%= startDateField.ClientID %>"); 
        var picker2 = $find("<%= stopDateField.ClientID %>"); 
        var calendar1 = picker1.get_calendar(); 
        var calendar2 = picker2.get_calendar(); 
        var fastNavigation1 = calendar1._getFastNavigation(); 
        var fastNavigation2 = calendar2._getFastNavigation(); 
 
        $clearHandlers(picker1.get_popupButton()); 
        $clearHandlers(picker2.get_popupButton()); 
        picker1.get_popupButton().href = "javascript:void(0);"
        picker2.get_popupButton().href = "javascript:void(0);"
        $addHandler(picker1.get_popupButton(), "click"function() { 
            var textbox = picker1.get_textBox(); 
            //adjust where to show the popup table  
            var x, y; 
            var adjustElement = textbox; 
            if (textbox.style.display == "none"
                adjustElement = picker1.get_popupImage(); 
 
            var pos = picker1.getElementPosition(adjustElement); 
            x = pos.x; 
            y = pos.y + adjustElement.offsetHeight; 
 
            var e = { 
                clientX: x, 
                clientY: y - document.documentElement.scrollTop 
            }; 
            //synchronize the input date if set with the picker one 
            var date = picker1.get_selectedDate(); 
            if (date) { 
                calendar1.get_focusedDate()[0] = date.getFullYear(); 
                calendar1.get_focusedDate()[1] = date.getMonth() + 1; 
                calendar1.get_focusedDate()[2] = 1; // hardcode this to the first of the month. 
            } 
 
            $get(calendar1._titleID).onclick(e); 
 
            return false
        }); 
        $addHandler(picker2.get_popupButton(), "click"function() { 
            var textbox = picker2.get_textBox(); 
            //adjust where to show the popup table  
            var x, y; 
            var adjustElement = textbox; 
            if (textbox.style.display == "none"
                adjustElement = picker2.get_popupImage(); 
 
            var pos = picker2.getElementPosition(adjustElement); 
            x = pos.x; 
            y = pos.y + adjustElement.offsetHeight; 
 
            var e = { 
                clientX: x, 
                clientY: y - document.documentElement.scrollTop 
            }; 
            //synchronize the input date if set with the picker one 
            var date = picker2.get_selectedDate(); 
            if (date) { 
                calendar2.get_focusedDate()[0] = date.getFullYear(); 
                calendar2.get_focusedDate()[1] = date.getMonth() + 1; 
                calendar2.get_focusedDate()[2] = 1; // hardcode this to the first of the month. 
            } 
 
            $get(calendar2._titleID).onclick(e); 
 
            return false
        }); 
        $addHandler(picker1.get_textBox(), "change"function() { 
            var textbox = picker1.get_textBox(); 
            if (textbox.value != '') { 
                var date = new Date(textbox.value); 
                date.setDate(1); 
                date.setHours(0, 0, 0, 0); 
                picker1.set_selectedDate(date); 
            } 
        }); 
        $addHandler(picker2.get_textBox(), "change"function() { 
            var textbox = picker2.get_textBox(); 
            if (textbox.value != '') { 
                var date = new Date(textbox.value); 
                date.setDate(1); 
                date.setHours(0, 0, 0, 0); 
                picker2.set_selectedDate(date); 
            } 
        }); 
 
        fastNavigation1.OnOK = 
            function() { 
                var date = new Date(fastNavigation1.Year, fastNavigation1.Month, 1); 
                picker1.get_dateInput().set_selectedDate(date); 
                fastNavigation1.Popup.Hide(); 
            } 
        fastNavigation2.OnOK = 
            function() { 
                var date = new Date(fastNavigation2.Year, fastNavigation2.Month, 1); 
                picker2.get_dateInput().set_selectedDate(date); 
                fastNavigation2.Popup.Hide(); 
            } 
 
 
        fastNavigation1.OnToday = 
            function() { 
                var date = new Date(); 
                date.setDate(1); 
                date.setHours(0, 0, 0, 0); 
                picker1.get_dateInput().set_selectedDate(date); 
                fastNavigation1.Popup.Hide(); 
            } 
        fastNavigation2.OnToday = 
            function() { 
                var date = new Date(); 
                date.setDate(1); 
                date.setHours(0, 0, 0, 0); 
                picker2.get_dateInput().set_selectedDate(date); 
                fastNavigation2.Popup.Hide(); 
            } 
    }    
 

-Shane
Yavor
Telerik team
 answered on 27 Nov 2009
1 answer
143 views

We are unable to edit content in IE8. 

·         Select Edit Content

·         Tool Bar appears

·         We are then unable to select any of the drop downs (Select, Style, Para)


We do get form.js errors
i.e  Invalid argument

·         RTE2PUEditor.aspx

·         Moss 2007 SP2

·         WSS 2.0

·         Windows Server 2003 SP2


Everything works as expected in IE7 and using IE7 compatibility mode.

Stanimir
Telerik team
 answered on 27 Nov 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?