Hey guys,
I am working on a program to streamline our marketing process. I have attached 3 snippets: One of the user's form, one of the table that it is attached to, and the code that I can't get to work. Everything in the form is very basic and just directly linked to the table, except for the "Add to List" toggle switch. "No" (value of 2) is the default value for this button. Note the field on the form labeled "Ad Date" and a field in the table labeled "NextMailed."
The desired process is for a user to hit "Yes" on that toggle switch for the desired customers. When the switch is toggled to "Yes," the "AddToList" value in the table changes to 1, and the date that is in "Ad Date" on the form is inserted into the "NextMailed" field in the table. Another process later on will move that date from "NextMailed" to "LastMailed." Hitting the toggle switch back to "No" changes the AddToList value back to 2, and should clear out the NextMailed date.
Issues:
-Toggling back to No gives me a debug error, saying there is a syntax error with the UPDATE
-Toggling to Yes gives no error, but the NextMailed date is just a time. Returns 12:00:01 AM
Any help would be greatly appreciated!
The method behind my madness here was completely thought of in my head. So if there is a smarter way to accomplish this, I am all ears.