This is funny. I have a button on a form where one of many lines of code is a very simple "me.[Status ID] = 4" It always worked in the past, but I modified some code before it and now whenever it gets to that line I get the error: "You cant assign a value to this object" . None of the modified code before that have nothing to do with that [Status ID] field.
Now the weird thing is that if I click debug when I receive that error, then click continue (F5) or step into (F8) it runs that line perfectly fine and sets the [Status ID] to "4" like it is suppose to.
Technically I have a solution, but any suggestions on why it is happening?
My solution is, I changed it from what it was:
me.[Status ID] = 4
To:
On Error Resume Next
Me.[Status ID] = 4
Me.[Status ID] = 4
And that works.
Now the weird thing is that if I click debug when I receive that error, then click continue (F5) or step into (F8) it runs that line perfectly fine and sets the [Status ID] to "4" like it is suppose to.
Technically I have a solution, but any suggestions on why it is happening?
My solution is, I changed it from what it was:
me.[Status ID] = 4
To:
On Error Resume Next
Me.[Status ID] = 4
Me.[Status ID] = 4
And that works.