How to write Data back to sage100 / mas90 using BOI?

SOLVED

Hello,

I am new to sage100 BOI and i am  trying to understand the workflow of BOI,

i am able to read data of a customer from sage but when i am trying to change a value i am getting error's 

This is a sample code that i tried:

'*************************************************************************************************************************************************************************************

Public Function change()
Dim ch = oScript.NewObject("AR_Customer_bus", oSS)
Dim al1 As String =""
Dim al2 As String =""
ch.nGetResultSets("AddressLine1$" , "AddressLine2$", al1, al2," CustomerNo$=" & Chr(34) & "ABF" & Chr(34), "", "")
cuslis = (Split(Mid(al1, 3, Len(al1) - 3), Chr(138)))
ch.nSetValue("AddressLine1$","test")

If Not (CBool(ch.nWRITE())) Then MsgBox(ch.sLastErrorMsg)
End Function

I am getting the following error