If Statement help required

G Marshall

Board Regular
Joined
Dec 31, 2002
Messages
134
I have an input form “OilOrders” linked to a table “OrdersInvoices” Three input fields on the form are “InvoiceNumber” , “Date” and SiteName”. I want to create an event procedure on the field “SiteName” that produces a message box with a warning if there is already a duplicate “InvoiceNumber”, “Date” and SiteName” already in the table “OrderInvoices”.
Now it is possible that there could be a duplicate entry in these fields, I only want to warn the user and ask if they wish to continue.
Could someone point me in the right direction as to what code I will need.
Any help appreciated.


Gerald
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December

Forum statistics

Threads
1,221,849
Messages
6,162,425
Members
451,765
Latest member
craigvan888

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top