#1 21-05-2019 03:08 pm


Shipping Rules

Am using a lot of the shipping rules and works great.

But wondering if it is possible to edit the exported rules in any other program? And then import it back.

For example I want to send 500 particular items on one way. Currently I copy and paste the sku into the rule manually. But it is impossible to keep track or edit.



#2 21-05-2019 03:31 pm


Re: Shipping Rules

You can do it using import/export shipping rules in the dialog.

Although you may find it easier to use Scripting to provide the list of SKUs.

See under Script here: … rules.html

We can do the script for you, but it would be chargeable (probably 2-3hours).



#3 17-09-2019 12:48 pm

Simply NikNaks

Re: Shipping Rules

Have you got an example of a Script?

Similar to user above who wants to test different SKU, I want to make sure that for certain countries I always send tracked.
I realise I can do via a Script but the Help gives no example - it just basically says is is:
The value returned by the Collect_FieldValue(Record As RecordStruct) function

So - I have gone to Tools - Scripting. I then goto Code - Collect
But there is no option to add the Collect_FieldValue function

Even then - how do I create code for testing Country or SKU?. I just want a simple example to get me started



#4 17-09-2019 05:45 pm


Re: Shipping Rules

In your script:

Module Scripting
'In Records_ShipRule return a string that's used in shipping rules
Function Records_ShipRule(Record As RecordStruct) As String
 'Test for international deliveries
 If Record.Delivery.ISO2 <> "GB" Then
  For Each Item As ItemStruct In Record.Invoice.Items
   'Check SKUs
   If Item.SKU.Contains("mySKU1") Then
    Return "Tracked" 
   ElseIf Item.SKU.Contains("mySKU2") Then
    Return "TrackedSigned" 
   End If
  'Nothing found
  Return "NotFound"
 End If
End Function
End Module

Then to enable that code, make two Shipping Rules:

  • If [script] equals 'Tracked' ...

  • If [script] equals 'TrackedSigned'...


Board footer

Powered by FluxBB