How to update customer details by his Id using sdk ?

LoadbyName  is the only method I can find in SDK. Can anyone tell me how to get customer details by his Id and then update. ?

Parents
  • I used the following filters:

    Dim CustomerList = Me.company.Factories.CustomerFactory.List()
    Dim filter = PropertyFilterExpression.Equal(PropertyFilterExpression.Property("Customer.ID"),
             PropertyFilterExpression.Constant(ID))
    ' Use LoadModifier to filter
    Dim modifier = LoadModifiers.Create()
    modifier.Filters = filter
    ' load customer based on filter expression And set as data source
    CustomerList.Load(modifier)
    selectedCustomer = CustomerList.First()

    The ID is the id of the customer and the selectedCustomer will hold the customer with all of its properties.  This is in VB but the logic is the same for C#.  Me.company has to be filled by selecting the company and you also have to be authorised.

    Savin after changing the properties can be bone by selectedCustomer.Save()

Reply
  • I used the following filters:

    Dim CustomerList = Me.company.Factories.CustomerFactory.List()
    Dim filter = PropertyFilterExpression.Equal(PropertyFilterExpression.Property("Customer.ID"),
             PropertyFilterExpression.Constant(ID))
    ' Use LoadModifier to filter
    Dim modifier = LoadModifiers.Create()
    modifier.Filters = filter
    ' load customer based on filter expression And set as data source
    CustomerList.Load(modifier)
    selectedCustomer = CustomerList.First()

    The ID is the id of the customer and the selectedCustomer will hold the customer with all of its properties.  This is in VB but the logic is the same for C#.  Me.company has to be filled by selecting the company and you also have to be authorised.

    Savin after changing the properties can be bone by selectedCustomer.Save()

Children
No Data