Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
147 views
Hi telerik team,

Are there any approaches for this case?

Thanks so much!
Shinu
Top achievements
Rank 2
 answered on 13 Jun 2012
2 answers
109 views
Hi Telerik,

I have a dynamically created floating RadDock called "FormAreaDock" that I use to act like a box - sort of a placeholder - for other dynamically floating RadDocks.

I am purposely not using RadDockZones because as far as I know, zones cannot be moved anywhere I want to move it.

I have been able to move the "FormAreaDock" to virtually any position and any other floating RadDocks that are within the bounds of the "FormAreaDock" also move along with it.

My problem is that it only works when I'm running the program in my development machine. Once I publish (deploy) it, it refuses to work as it should and I am getting the following error message:

Webpage error details
  
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; InfoPath.2; .NET4.0C; .NET4.0E)
Timestamp: Thu, 7 Jun 2012 23:19:50 UTC
  
  
Message: Sys.WebForms.PageRequestManagerServerErrorException: Invalid JSON primitive: {"Top":346,"Left":969,"DockZoneID":"","Collapsed":false,"Pinned":false,"Resizable":true,"Closed":false,"Width":"701px","Height":"904px","ExpandedHeight":0,"Index":-1}.
Line: 6
Char: 84093
Code: 0
URI: http://xm-wvl-02:4201/Telerik.Web.UI.WebResource.axd?_TSM_HiddenField_=AppContent_ctlAdminTemplatesFreeStyleEdit_RadScriptManager1_TSM&compress=1&_TSM_CombinedScripts_=%3b%3bSystem.Web.Extensions%2c+Version%3d4.0.0.0%2c+Culture%3dneutral%2c+PublicKeyToken%3d31bf3856ad364e35%3aen-US%3a1f68db6e-ab92-4c56-8744-13e09bf43565%3aea597d4b%3ab25378d2%3bTelerik.Web.UI%2c+Version%3d2011.3.1305.40%2c+Culture%3dneutral%2c+PublicKeyToken%3d121fae78165ba3d4%3aen-US%3a8cba3cb6-b29d-4c9f-be22-7b43626a420a%3a16e4e7cd%3aed16cbdc%3af7645509%3a24ee1bba%3af46195d3%3a854aa0a7%3a874f8ea2%3a5a6d9d23%3a7c926187%3a8674cba1%3ab7778d6c%3ac08e9f8a%3aa51ee93e%3a59462f1%3a5f39f986%3a1e771326%3aaa288e2d

So, my questions are:

1. Why do I not get that error in my development machine?
2. What factors should I take into consideration to avoid an INVALID JSON error?
3. Is there a better way of doing what I'm trying to achieve?

Thank you.
Virgil Rodriguez
Top achievements
Rank 1
 answered on 12 Jun 2012
1 answer
698 views
I have a radgrid with all rows in edit mode.
A update button is outside the grid.
<telerik:RadGrid ID="radgridFeeCalc" runat="server" ShowStatusBar="true"
                                    AutoGenerateColumns="False" PageSize="5" AllowPaging="True" AllowSorting="True"
                                    AllowMultiRowSelection="False" AllowAutomaticUpdates="false"
                                    GridLines="None" AllowAutomaticDeletes="false" AllowAutomaticInserts="false"
                                    OnItemDataBound="radgridFeeCalc_ItemDataBound"
                                    >
                                    <PagerStyle Mode="NextPrevAndNumeric"></PagerStyle>
                                    <MasterTableView DataKeyNames="SEQ_NUM, DST_ID"
                                    AllowMultiColumnSorting="True" ShowFooter="True"
                                    CommandItemDisplay="Top" Name="Address" AllowFilteringByColumn="False" TableLayout="Auto" >
                                        <CommandItemSettings ShowAddNewRecordButton="false" ShowRefreshButton="false" />
                                        <Columns>                                           
                                             
                                            <telerik:GridBoundColumn SortExpression="SEQ_NUM" HeaderText="Sequence" HeaderButtonType="TextButton"
                                                DataField="SEQ_NUM" UniqueName="sEQ_NUM" ReadOnly="true">
                                            </telerik:GridBoundColumn>
                                             
                                            <telerik:GridBoundColumn SortExpression="DESCR" HeaderText="Description" HeaderButtonType="TextButton"
                                                DataField="DESCR" UniqueName="dESCR" ReadOnly="true">
                                            </telerik:GridBoundColumn>
 
                                            <telerik:GridTemplateColumn HeaderText="Calc Amount" DataField="VAL" UniqueName="vAL" >
                                                <EditItemTemplate>
                                                    <asp:TextBox ID="VAL" runat="server" Text='<%# Bind("VAL") %>'></asp:TextBox>
                                                </EditItemTemplate>
                                                <ItemTemplate >
                                                    <asp:TextBox ID="view_VAL" runat="server" Text='<%# Bind("VAL") %>'></asp:TextBox>
                                                </ItemTemplate>
                                            </telerik:GridTemplateColumn>
 
                                            <telerik:GridBoundColumn SortExpression="DST_ID" HeaderText="Distribution Id" HeaderButtonType="TextButton"
                                                DataField="DST_ID" UniqueName="dST_ID" ReadOnly="true">
                                            </telerik:GridBoundColumn>
                                        </Columns>
                                    </MasterTableView>
                                </telerik:RadGrid>
 
                                <telerik:RadButton ID="btnUpdate" runat="server" Text="Update" onclick="btnUpdate_Click"></telerik:RadButton>

How do I get all values from all rows from the grid in an external button "btnUpdate".
I have the following code and can get the datakeyvalues but cannot get the textbox value as the "VAL" textbox is not found.
protected void btnUpdate_Click(object sender, EventArgs e)
        {
            foreach (GridEditFormItem editedItem in radgridFeeCalc.MasterTableView.GetItems(GridItemType.EditFormItem))
            {
                string keyId1 = editedItem.OwnerTableView.DataKeyValues[editedItem.ItemIndex]["SEQ_NUM"].ToString();
                string keyId2 = editedItem.OwnerTableView.DataKeyValues[editedItem.ItemIndex]["DST_ID"].ToString();
 
                TextBox combo = ((GridEditFormItem)editedItem).EditFormCell.FindControl("VAL") as TextBox;
                string str1 = combo.Text;
            }
        }

Jayesh Goyani
Top achievements
Rank 2
 answered on 12 Jun 2012
5 answers
181 views
Background:

I have implemented RadScheduler (Q3 ASP.NET AJAX) into a custom MOSS web part. The scheduler is bound to a SharePoint Datasource on the page. The ds is attached to a standard SP task list. I have bound the scheduler start time field to the start date and the scheduler end time field to the due date.

Problem:

I am getting the following error: System.Exception: Appointment is invalid: Start time must be before the End time. at Telerik.Web.UI.Appointment.Validate()

In looking through my task list data, I see that some tasks are scheduled to start and end on the same day. I also see that I have tasks that do not have either a start date or a due date.

I assume my error is being generated from these inconsistencies.

Proposed Resolution:

I think I would need to verify each appointment, but I am unsure as to the best way to handle the exceptions. I am thinking the AppointmentDataBound event could be used to verify each appointment. I could check to make sure all fields exist and make sure the due date is after the start date. Would using this event work? 

Question:

Can the scheduler handle using dates only without a time field? I would like to have all appointments register as full day appointments. If the start date was 5/1 and the due date was 5/2, can the sceduler evaluate this? Also, if the start date and due date were the same, can the scheduler evaluate this? Or do I need to add custom handling in the AppointmentDataBound event for these scenarios?

Thanks.
Peter
Telerik team
 answered on 12 Jun 2012
0 answers
57 views
Sorry guys for the trouble. I solved it. It was my CssClass. Removing that does the trick.

Thanks,
-Sree
Sreekanth
Top achievements
Rank 1
 asked on 12 Jun 2012
1 answer
138 views
The OnKeyPress event will fire on a RadGrid but NOT when you are in Edit Mode using EditMode="EditForms". 

How do I capture KeyPress event in a RadGrid while in Edit Mode?
Eyup
Telerik team
 answered on 12 Jun 2012
1 answer
165 views
Hi All, 

I m using radgrid's google like filtering feature.

Also i m having two checkbox columns which are dynamically created.

Now, if i check a checkbox and filter the values the checkbox's status is lost. It becomes unchecked.

How can i persist the checkbox's checked status after filtering?
Eyup
Telerik team
 answered on 12 Jun 2012
2 answers
134 views
Hello all :)

I add an ajax loading panel and ajax panel to my page, but when I run the page I got this message

The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).


what can I do to avoid it ? 

thanks all : )
Eyup
Telerik team
 answered on 12 Jun 2012
1 answer
85 views
Hi,

my Rad Grid has two types of edit. One type of edit works fine. other type is select and display child records, and click on edit, I can the error - column name is neither a column nor relation. Exception is as follows.

There was a problem extracting DataKeyValues from the DataSource. Please ensure that DataKeyNames are specified correctly and all fields specified exist in the DataSource

Please help...
Eyup
Telerik team
 answered on 12 Jun 2012
7 answers
220 views
Hi Team,
I am facing one issue, While adding any HTML or XML tag in my telerik:RadComboBox 
 it is giving a javascript error as :
Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 500
This error is only coming when I put < with some alphabets ex: "<aa","<a" or "<TEST>".
Even it is working proper when I put "aa>" or "<>".

I have followed the solution suggested as in thread:
http://www.telerik.com/community/forums/aspnet/combobox/combobox-crashes-opon-entering-html-tags.aspx 

As my error is coming on Client side so I have used htmlEncode method also as:
$('<div/>').text(value).html();
Still I am facing the same issue.
Please give suggestion to resolve this issue.


Ivana
Telerik team
 answered on 12 Jun 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?