[CLOSED] DirectMethod Grid Editor error

  1. #1

    [CLOSED] DirectMethod Grid Editor error

    I'm trying to set up a Editable grid using the direct method copied from the sample site.
    The only diff is that I'm using a master page. I'm getting the error attached.
    Any ideas?

    Master Page:
    <%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Content.master.cs" Inherits="Aksia.Intranet.Content" %>
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" >
    <head runat="server">
        <asp:ContentPlaceHolder ID="head" runat="server">
    <body id="MasterPageBodyTag" runat="server">
        <form id="form1" runat="server">
          <ext:ResourceManager ID="ScriptManager1" runat="server"  HideInDesign="true" Theme="Access"  ScriptMode="Release" SourceFormatting="True">
            <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
           <asp:Label runat="server" ID="lblCache" ForeColor="White" Font-Size="XX-Small" />

    Code Behind
    using System;
    using Ext.Net;
    namespace Aksia.Intranet.Entities.AdminPages
        public partial class SoeIdEditor : System.Web.UI.Page
            protected void Page_Load(object sender, EventArgs e)
            public void AfterEdit(string id, string newValue)
                    //    int d = new Update("WorkflowProperty").Set("FieldValue").EqualTo(newValue).Where("WorkflowPropertyId").IsEqualTo(id).Execute();
                    // Send Message...
                    X.Msg.Alert("Saved", "Information has been saved");
                catch ( Exception er )
                    X.Msg.Alert("Error", er.ToString());
    .aspx code:

    <%@ Page Title="" Language="C#" MasterPageFile="~/Content.Master" AutoEventWireup="true"
        CodeBehind="SoeIdEditor.aspx.cs" Inherits="Aksia.Intranet.Entities.AdminPages.SoeIdEditor" %>
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    <asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
        <ext:XScript ID="XScript1" runat="server">
        <script type="text/javascript">
            var startEditing = function (e) {
                if (e.getKey() === e.ENTER) {
                    var grid = #{gridProperties},
                        record = grid.getSelectionModel().getSelected(),
                        index = grid.store.indexOf(record);
                    grid.startEditing(index, 1);
            var afterEdit = function (e) {
                try {
                    Properties of 'e' include:
                    e.grid - This grid
                    e.record - The record being edited
                    e.field - The field name being edited
                    e.value - The value being set
                    e.originalValue - The original value for the field, before the edit.
                    e.row - The grid row index
                    e.column - The grid column index
                    // Call DirectMethod
                       #{DirectMethods}.AfterEdit(e.record.data.WorkflowPropertyId,   e.value);
                catch (e) {
                    alert("err" + e);
        <ext:ResourceManagerProxy runat="server" RemoveViewState="true" ></ext:ResourceManagerProxy>
        <asp:SqlDataSource ID="DSProperties" runat="server" ConnectionString="<%$ ConnectionStrings:WarehouseConnectionString %>"
            SelectCommand="SELECT * FROM WORKFLOWPROPERTY WHERE WorkflowSoeId=@SoeId">
                <asp:QueryStringParameter QueryStringField="soeId" Name="SoeId" />
        <ext:GridPanel runat="server" ID="gridProperties" AutoHeight="true" TrackMouseOver="true"
                <ext:Store runat="server" ID="storeProperties" DataSourceID="DSProperties"  >
                        <ext:JsonReader IDProperty="WorkflowProperyId">
                                <ext:RecordField Name="WorkflowProperyId" Type="Int">
                                <ext:RecordField Name="FieldName" Type="String">
                                <ext:RecordField Name="FieldValue" Type="String">
                                <ext:RecordField Name="DueDate" Type="Date">
                <KeyDown Fn="startEditing" />
                <AfterEdit Fn="afterEdit" />
                <ext:RowSelectionModel runat="server" SingleSelect="true" />
            <ColumnModel runat="server">
                    <ext:Column Header="FieldName" DataIndex="FieldName">
                    <ext:Column Header="FieldValue" DataIndex="FieldValue">
                            <ext:TextField  runat="server" />
                    <ext:DateColumn Header="Date" DataIndex="DueDate">
                <ext:GroupingView runat="server">
  2. #2

    RE: [CLOSED] DirectMethod Grid Editor error


    Fixed. Please update from SVN

Similar Threads

  1. [CLOSED] DirectMethod in customcontrol error
    By Pablo_Azevedo in forum 1.x Legacy Premium Help
    Replies: 8
    Last Post: Jun 22, 2012, 8:56 PM
  2. Replies: 0
    Last Post: Sep 08, 2011, 9:59 AM
  3. Replies: 2
    Last Post: Jan 14, 2011, 5:51 PM
  4. [CLOSED] Error when processing DirectMethod on TreePanel
    By ewgoforth in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Nov 26, 2010, 8:41 AM
  5. [CLOSED] Dynamic Text Editor in grid error
    By CMA in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Nov 18, 2009, 8:19 AM

Posting Permissions