Hi All
I need help with a code for a DLookupFunction. I will try to attach my simple database
The database has 2 parts to it.
The first part
One part is for inputting the delivery charges for a postcode prefixes for Freight Companies (in my example it is ADD and FR). You can see in the form, “FolServiceMain1” that for each post code prefix for a particular freight company, the delivery cost charged will depend on
a) Whether the Service is for “Next Day” or “Economy”
b) The number of pallets delivered
I have a query (QPostCodeCharges) that I would like to use for my second part.
The second part
This part deals with the creation of the delivery note for each customer, by inputting the information into FolCustDN
Once inputted, the user will press the button “Get Cost”. I need help with a DLookup VBA for this part. I would like the programme to compare the prefix in the field Cust_DelPCode and according to that value, pick up the value for the field Cust_estimated_delivery_cost from QPostCodeCharges where there is a match for:
a) The post code prefix
b) The Service Type (Economy or Next day)
c) No of pallets
If no match is found, I need a message saying “No match Found”
The post code field in the form does not have the prefix in isolation and so the VBA will need to compare the first few letter to seek the match
Please help
Rob
I need help with a code for a DLookupFunction. I will try to attach my simple database
The database has 2 parts to it.
The first part
One part is for inputting the delivery charges for a postcode prefixes for Freight Companies (in my example it is ADD and FR). You can see in the form, “FolServiceMain1” that for each post code prefix for a particular freight company, the delivery cost charged will depend on
a) Whether the Service is for “Next Day” or “Economy”
b) The number of pallets delivered
I have a query (QPostCodeCharges) that I would like to use for my second part.
The second part
This part deals with the creation of the delivery note for each customer, by inputting the information into FolCustDN
Once inputted, the user will press the button “Get Cost”. I need help with a DLookup VBA for this part. I would like the programme to compare the prefix in the field Cust_DelPCode and according to that value, pick up the value for the field Cust_estimated_delivery_cost from QPostCodeCharges where there is a match for:
a) The post code prefix
b) The Service Type (Economy or Next day)
c) No of pallets
If no match is found, I need a message saying “No match Found”
The post code field in the form does not have the prefix in isolation and so the VBA will need to compare the first few letter to seek the match
Please help
Rob