Customer delivery addresses
  • Nat
    Customer delivery addresses

    by Nat » Wed Apr 12, 2006 11:59 am

    How would I setup my customer screen using the screen builder to copy the customer's address into the customer's delivery address automatically, if the delivery address is not filled in by the operator?
  • COBS Tech Support
    Posts:683
    Joined:Fri Sep 09, 2005 8:23 am

    by COBS Tech Support » Wed Apr 12, 2006 12:02 pm

    Here is a script that copies the customer address to the delivery address. Add this to the bottom of the Screen Script inside the Screen Builder, when the customer screen is open.

    If Mode = 3
    If IsEmpty(SCRRead("CUSDNAME") + SCRRead("CUSDADD") + SCRRead("CUSDADD2") + SCRRead("CUSDSUB"))
    SCRWrite("CUSDNAME", SCRRead("CUSNAME"))
    SCRWrite("CUSDADD", SCRRead("CUSADDR"))
    SCRWrite("CUSDADD2", SCRRead("CUSADDR2"))
    SCRWrite("CUSDSUB", SCRRead("CUSSUB"))
    SCRWrite("CUSDPOST", SCRRead("CUSPOST"))
    SCRWrite("CUSDSTATE", SCRRead("CUSSTATE"))
    Endif
    Endif

    The above script checks to see if the delivery name + delivery address + 1st and 2nd address lines + the delivery suburb are blank.

    If all these fields are blank, the customer address is copied into the delivery address. Otherwise it's left untouched. Obviously this can be changed to suite the requirements of the business.

Who is online

Users browsing this forum: No registered users and 5 guests