I have a bit of code that checks a number of fields in an excel sheet before finally saving it and creating a pdf of the file.
I've had to amend the code slightly today in order to cater for a new clients requirements.
However, when running the scripts, it stops after changing a cell value. doesn't throw me an error, just stops.
if I hit the button to run the code again it does not have to change the cell value so continues to complete the process.
if I go into the VBA editor and run the script line by line it works fine including changing the cell value.
the bit that's causing me an issue is this:
Dim seriallength As Integer
seriallength = Range("AU19").Value
ActiveSheet.Range("B15").Value = "VARIOUS DETAILED BELOW"
Application.Wait (Now + TimeValue("0:00:2"))
If seriallength <> "0" Then
As you can see I've tried adding in a wait timer to see if the cell update is causing the issue, but am now at a loss.
Thanks for any help!