Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
865
ultrawebgrid_Updaterow error
posted

Hi,

 I have added an updaterow method to my webgrid as it was instrcuted in this base knowledge http://devcenter.infragistics.com/Support/KnowledgeBaseArticle.aspx?ArticleID=9966 . When I run my application, it throws the following message:

Object reference not set to an instance of an object.

Can you help please? Here is my code:protected void UltraWebGrid1_UpdateRow(object sender, RowEventArgs e)

{

switch (e.Row.DataChanged)

{

case DataChanged.Modified:

// this.UpdateDataMap(e.Row);

DimensionBLL updatedatamap = new DimensionBLL();

updatedatamap.UpdateMddDataMap(Convert.ToInt32(e.Row.Cells.FromKey("LookupRDBID").Value),

e.Row.Cells.FromKey("MapTable").Value.ToString(),

e.Row.Cells.FromKey("MapField").Value.ToString(),

Convert.ToInt32(e.Row.Cells.FromKey("MapLen").Value),

e.Row.Cells.FromKey("WMDvalue").Value.ToString(),

Convert.ToInt32(e.Row.Cells.FromKey("Surveycode").Value), e.Row.Cells.FromKey("VariableName").Value.ToString(),

e.Row.Cells.FromKey("VariableText").Value.ToString(), e.Row.Cells.FromKey("ElementName").Value.ToString(),

Convert.ToInt32(e.Row.Cells.FromKey("VariableID").Value), Convert.ToInt32(e.Row.Cells.FromKey("Response").Value),

e.Row.Cells.FromKey("PTKVariable").Value.ToString(), e.Row.Cells.FromKey("CCP").Value.ToString(),

e.Row.Cells.FromKey("FixValue").Value.ToString(), Convert.ToDateTime(e.Row.Cells.FromKey("DateAdded").Value),

Convert.ToDateTime(e.Row.Cells.FromKey("DateModified").Value), Convert.ToDateTime(e.Row.Cells.FromKey("DateDeleted").Value),

Convert.ToBoolean(e.Row.Cells.FromKey("IsValid").Value), Convert.ToBoolean(e.Row.Cells.FromKey("Verified").Value),

Convert.ToBoolean(e.Row.Cells.FromKey("IsLock").Value), e.Row.Cells.FromKey("MDDFileName").Value.ToString());

break;

case DataChanged.Unchanged:

break;

}

}

Parents
  • 3475
    Offline posted

    I hit the error " 'Element' is null or not an object" on this same line of code. gs.Element is undefined. I have and an UltraWebTab that contains an UltraWebGrid that contain a WebCombo.  This error occurs when the UpdatePanel was added, with the panel it does not occur.   

    function igtbl_globalMouseMove(evnt)

    {

    if(!evnt)

    evnt=event;

     

    if(typeof(igtbl_gridState)!="undefined" && igtbl_gridState)

    {

    for(var gId in igtbl_gridState)

    {

    var gs = igtbl_gridState[gId];

    var scrElem = evnt.srcElement?evnt.srcElement:evnt.target;

    if(!ig_isAChildOfB(evnt.srcElement,gs.Element))

    {

    if (gs.Element.getAttribute("elementMode")=="resize")

Reply Children