The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
|
|
Error calling Method AXFORMChange
Posted: 10 Oct 08 6:32 AM
|
We just performed a test upgrade on our saleslogix database from version 6.1 to version 7.2. On checking the test upgrade the following error message occurs on one of our customised add/edit plugin. The form in question does have a fair amount of scripting.
Error Calling Method AXFORMChange Error in IDispatch.Invoke():0x80020101
Can anyone help? |
|
|
|
Re: Error calling Method AXFORMChange
Posted: 11 Oct 08 2:33 AM
|
These are annoying in the fact that they simply mean an error occurs ! Unfortunately, it's going to be down to code and an error in that code. Maybe put it somewhere we can see it. But, difficult to track down without seeing it. |
|
|
| |
| |
|
Re: Error calling Method AXFORMChange
Posted: 13 Oct 08 11:03 AM
|
VERSION 7.2 CODE
Sub AXFormChange(Sender) '******************************************************************************* ' Description: Used in all Client Services forms ' Purpose : Enables/Disables fields as necesary depending on state of order '******************************************************************************
Dim strMode dim vbNewLine dim strAdvBooked dim strExBooked dim strCSApproved
dim oCon dim oRS dim strSQL
vbNewLine = Chr(13) & Chr(10) strMode = Application.GlobalInfo.Item("strMODE") 'msgbox "mode = " & strMode
IF strMode = "EDIT" THEN 'Trying to edit an existing order - disable certain fields cboSubType.Enabled = False deStart.Enabled = False deStart.AllowNull = True 'avoids issue where user forced to enter a value in a R/O field 'deExpiry.Enabled = False 'dont disable expiry date field txtAmount.Enabled = False ELSE 'Trying to add a new order - disable certain fields cboSubType.Enabled = True deStart.Enabled = True deStart.AllowNull = False 'avoids issue where user forced to enter a value in a R/O field 'deExpiry.Enabled = True 'dont disable expiry date field txtAmount.Enabled = True
GenerateSubNumber pklStatus.Text = "Active"
'SET UP THE COMBO BOXES FOR THE SUB FAMILY Set oCon = Application.GetNewConnection strSQL = "SELECT SHORT_NAME, BIP_TENDERMATCH_PROPSID FROM BIP_TENDERMATCH_PROPS " & _ "WHERE FAMILY = '" & Application.GlobalInfo.Item("BIP_TENDERMATCH_FAMILY") & "'" Set oRS = oCon.Execute(strSQL)
cboSubType.Items.Clear cboTendermatchID.Items.Clear cboTendermatchID.Text = ""
While Not oRS.EOF cboSubType.Items.Add(oRs.Fields("SHORT_NAME").Value) cboTendermatchID.Items.Add(oRs.Fields("BIP_TENDERMATCH_PROPSID").Value) oRS.MoveNext WEnd
oRS.Close oCon.Close Set oRS = Nothing Set oCon = Nothing
END IF
Application.GlobalInfo.Item("strMODE") = ""
IF chkAllowEdit.Checked = True OR Application.BasicFunctions.CurrentUserID = "ADMIN" THEN pnlMain.Enabled = True ELSE pnlMain.Enabled = False END IF
End Sub
************************************************************************************************** VERSION 6.2 CODE
Sub AXFormChange(Sender) '******************************************************************************* ' Description: Used in all Client Services forms ' Purpose : Enables/Disables fields as necesary depending on state of order '******************************************************************************
Dim strMode dim vbNewLine dim strAdvBooked dim strExBooked dim strCSApproved
dim oCon dim oRS dim strSQL
vbNewLine = Chr(13) & Chr(10) strMode = Application.GlobalInfo.Item("strMODE") 'msgbox "mode = " & strMode
IF strMode = "EDIT" THEN 'Trying to edit an existing order - disable certain fields cboSubType.Enabled = False deStart.Enabled = False deStart.AllowNull = True 'avoids issue where user forced to enter a value in a R/O field 'deExpiry.Enabled = False 'dont disable expiry date field txtAmount.Enabled = False ELSE 'Trying to add a new order - disable certain fields cboSubType.Enabled = True deStart.Enabled = True deStart.AllowNull = False 'avoids issue where user forced to enter a value in a R/O field 'deExpiry.Enabled = True 'dont disable expiry date field txtAmount.Enabled = True
GenerateSubNumber pklStatus.Text = "Active"
'SET UP THE COMBO BOXES FOR THE SUB FAMILY Set oCon = Application.GetNewConnection strSQL = "SELECT SHORT_NAME, BIP_TENDERMATCH_PROPSID FROM BIP_TENDERMATCH_PROPS " & _ "WHERE FAMILY = '" & Application.GlobalInfo.Item("BIP_TENDERMATCH_FAMILY") & "'" Set oRS = oCon.Execute(strSQL)
cboSubType.Items.Clear cboTendermatchID.Items.Clear cboTendermatchID.Text = ""
While Not oRS.EOF cboSubType.Items.Add(oRs.Fields("SHORT_NAME").Value) cboTendermatchID.Items.Add(oRs.Fields("BIP_TENDERMATCH_PROPSID").Value) oRS.MoveNext WEnd
oRS.Close oCon.Close Set oRS = Nothing Set oCon = Nothing
END IF
Application.GlobalInfo.Item("strMODE") = ""
IF chkAllowEdit.Checked = True OR Application.BasicFunctions.CurrentUserID = "ADMIN" THEN pnlMain.Enabled = True ELSE pnlMain.Enabled = False END IF
End Sub |
|
|
|
Re: Error calling Method AXFORMChange
Posted: 13 Oct 08 11:20 AM
|
Start debugging. Use MSGBOX or application.debug.writeline (with DBGView er) and find out where the error is occuring.
GenerateSubNumber code needs to be debugged aw well.
|
|
|
|