We have an issue on when to assess tax on freight. We have 2 types of customers, our corp owned and franchisees. All customers are in every US states. We just want to assess freight tax on our franchisees. Currently the setting is nontaxable on freight.
My solution is to create a VBA on the sales order entry window. Once lose focus on the freight field, the VBA will update the non-taxable to based on customer freight taxable option if it's a franchisee. I'm stuck on the technical names of the fields, so can anyone help with the object names for the sales tax detail window and the freight taxable drop down list? Or if there's a written code that i could use, that would be awesome!
Thanks in advance
Hung
*This post is locked for comments
I think i'm close. I created a macro to run when the freight field lose focus. The macros opens the sales tax schedule window, change the freight taxable from "non-taxable" to "'based on customer", click ok, then click recalculates when asked "this change will affect the current tax calculation".
It works but the one hiccup is when the user makes a change on the freight again. I get this error message, "No modal dialog appeared. (Line #8)" . Any ideas on how to bypass this error message?
Here's my code, be gentle I'm not a programmer.
Private Sub Freight_AfterUserChanged()
If (CInt(CustomerID) > 2000 And CInt(CustomerID) < 9999) Then
'run frt taxable macro
SendKeys "+{F1}"
Else
End If
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,151 Super User 2024 Season 2
Martin Dráb 229,993 Most Valuable Professional
nmaenpaa 101,156