Showing results for 
Search instead for 
Do you mean 
Community Home Request Access Read Blogs Share Your Ideas Search Community View My Settings
Reply
Nickel Contributor
Posts: 58
Registered: ‎05-05-2009

SalesLogix v7.2 - Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

Hi.

 

I have a problem with SalesLogix v7.2.0.1501. I implemented it, but when i open the Details tab of Account Entity the following message appears:

An error occurred executing active form script (AccountSmiley Very Happyetails). Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

 

Can anyone know help me.

 

Thanks in advance 

Gold Super Contributor
Posts: 3,087
Registered: ‎03-19-2009

Re: SalesLogix v7.2 - Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

KI - Digging back mentally... It has to deal with referencing a form that is not there....

 

It was fixed in SalesLogix updates... (believe it was an SP...) If you upgrade to the latest (7.5.1) you are covered - or you can log into Support.SalesLogix.com and look thru the HF and SP docs to see where it was first fixed.

--
RJ Ledger - rjledger@rjlSystems.net +1 603.369.3047 x101

".. Innovators in Mobility - Experts in Workflow Automation..."
http://www.rjlSystems.net - blog: www.rjlSystems.net/blog.html
Nickel Contributor
Posts: 58
Registered: ‎05-05-2009

Re: SalesLogix v7.2 - Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

Remember that issue is in SalesLogix 7.2 not 7.5

 

Adding, in my work we have installed and functionally (production enviroment) this version 7.2.0.1501 and not occurs this problem.

 

Regards 

Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: SalesLogix v7.2 - Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

[ Edited ]

Both the Account and Contact Details tab suffer the same problem. Adjust the scripts in both as follows. The green indicates the change.

 

ContactSmiley Very Happyetails

Sub AXFormChange(Sender)
    Dim objRS
    Dim strTimeZoneKey
    Dim strAddressID
    Dim iIndex
    Dim bFoundTimeZone
    gIgnoreTimeZoneChange = True
    bFoundTimeZone = False

    If Not (Application.MainViews.ActiveView Is Nothing) And _
           (UCase(Application.MainViews.ActiveView.Name) = UCase("System:Contact Details")) then

       strAddressID = Application.MainViews.ActiveView.DetailsView.Script.GetAddressID
       If strAddressID <> "" Then
         Set objRS = objSLXDB.GetNewRecordset
         objRS.Open "SELECT TIMEZONE FROM ADDRESS WHERE ADDRESSID = " & QuoteSQL(strAddressID), objSLXDB.Connection 'DNL
         If (Not objRS.EOF) And (Not objRS.BOF) Then
            strTimeZoneKey = CheckEmpty(objRS.Fields(0), "")
            If (strTimeZoneKey <> "") Then
               gTimeZone = strTimeZoneKey
               If strTimeZoneKey <> "" Then
                  If Application.BasicFunctions.TzIsValidTimeZoneKey(strTimeZoneKey) Then
                     iIndex = objSLXTZ.GetValueByKey(TZField_Index, strTimeZoneKey)
                     If IsNumeric(iIndex) Then
                        cboTimeZones.ItemIndex = iIndex +1
                        gTimeZone = strTimeZoneKey
                        bFoundTimeZone = True
                     End If
                  End If
               End If
            End If
         End If
         If (objRS.State = 1) Then
            objRS.Close
         End If
         Set objRS = Nothing
       End If
    End If
    If Not bFoundTimeZone Then
       cboTimeZones.ItemIndex = 0
       deCurrentDateTime.DateTime = Now()
    Else
       deCurrentDateTime.DateTime = objSLXTZ.CurrentDateTime(iIndex)
    End If
    gIgnoreTimeZoneChange = False
End Sub

 

Account: Details

Sub AXFormChange(Sender)
    Dim objRS
    Dim strTimeZoneKey
    Dim strAddressID
    Dim iIndex
    Dim bFoundTimeZone
    lveLeadSource.Text = txtLeadSourceDesc.Text
    gIgnoreTimeZoneChange = True
    bFoundTimeZone = False
    If Not (Application.MainViews.ActiveView Is Nothing) And _
           (UCase(Application.MainViews.ActiveView.Name) = UCase("System:Account Details")) then
       strAddressID = Application.MainViews.ActiveView.DetailsView.Script.GetAddressID
       If strAddressID <> "" Then
         Set objRS = objSLXDB.GetNewRecordset
         objRS.Open "SELECT TIMEZONE FROM ADDRESS WHERE ADDRESSID = " & QuoteSQL(strAddressID), objSLXDB.Connection 'DNL
         If (Not objRS.EOF) And (Not objRS.BOF) Then
            strTimeZoneKey = CheckEmpty(objRS.Fields(0), "")
            If (strTimeZoneKey <> "") Then
               gTimeZone = strTimeZoneKey
               If strTimeZoneKey <> "" Then
                  If Application.BasicFunctions.TzIsValidTimeZoneKey(strTimeZoneKey) Then
                     iIndex = objSLXTZ.GetValueByKey(TZField_Index, strTimeZoneKey)
                     If IsNumeric(iIndex) Then
                        cboTimeZones.ItemIndex = iIndex +1
                        gTimeZone = strTimeZoneKey
                        bFoundTimeZone = True
                     End If
                   End If
                End If
             End If
         End If
         If (objRS.State = 1) Then
          objRS.Close
         End If
         Set objRS = Nothing
       End If
    End If
    If Not bFoundTimeZone Then
       cboTimeZones.ItemIndex = 0
       deCurrentDateTime.DateTime = Now()
    Else
       deCurrentDateTime.DateTime = objSLXTZ.CurrentDateTime(iIndex)
    End If
    gIgnoreTimeZoneChange = False

    If dteLastHistory.Text <> "" then
       txtDaysValue.Text = Application.Translator.Localize("Last 'Touched' ") & DateDiff("d", dteLastHistory.DateTime, now) & Application.Translator.Localize(" days ago")
    Else
       txtDaysValue.Text = Application.Translator.Localize("Last 'Touched' 0 days ago")
    End If
End Sub

 

Also, you need to change the form as well and remove the txtLastHistory object and replace it with a new DateTimeEdit control named as dteLastHistory - set it to readonly and bind the DateTime property to ACCOUNT:LastHistoryDate. Then make it readonly and set the colour to btnFace (to make it seem like the rest). There's a subtle difference to the object and script that makes this fail if not changed!

 

BTW Don't forget the [double] kudos if it works !!

Message Edited by MikeSpragg on 22-10-2009 07:47 PM
Gold Super Contributor
Posts: 3,087
Registered: ‎03-19-2009

Re: SalesLogix v7.2 - Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

Of course it works ;-)
--
RJ Ledger - rjledger@rjlSystems.net +1 603.369.3047 x101

".. Innovators in Mobility - Experts in Workflow Automation..."
http://www.rjlSystems.net - blog: www.rjlSystems.net/blog.html
Nickel Contributor
Posts: 58
Registered: ‎05-05-2009

Re: SalesLogix v7.2 - Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

Hi Mike!!!

 

Thanks for your help.

 

Your help works fine in Contact: Details, but in Account: Details not work. The error message continue appearing.

 

- I put the green code (see above code).

- Put the End If of green If at the end of Sub. See bellow

    End If

 End Sub

 

- Remove txtLasHistory textbox and put the dteLastHistory datetime control. Set the properties name, color, readonly, datetime of dteLastHistory.

 

I miss something?

 

Regards

Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: SalesLogix v7.2 - Object doesn't support this property or method: 'GetAddressID' at line 43, char 5

Probably easiest if you load up a 7.5 onto a VMWare and then compare the 2 - it does work - but you do need to change the DateTimeEdit control (from a text control) as discussed.