By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,478 Members | 1,604 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,478 IT Pros & Developers. It's quick & easy.

Field doesn't repaint

P: n/a
Hi,

In a form, when I change the LitterLine field, I programmatically
update the PupLine field, (as in the sample code below). However, the
PupLine field only gets updated the first time after the form is
opened. After that, if I keep the form opened and change LitterLine a
second time to something else, Pupline does get updated but not
repainted. When I move the form off screen and back, it gets repainted.
I tried Me.Repaint, but it didn't work. Is there other ways to get
around this problem? These two fields are both text fields.

Private Sub LitterLine_AfterUpdate()
Me![PupLine] = Me![LitterLine]
End Sub

Thanks,
Tony

Mar 9 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Br
Tony wrote:
Hi,

In a form, when I change the LitterLine field, I programmatically
update the PupLine field, (as in the sample code below). However, the
PupLine field only gets updated the first time after the form is
opened. After that, if I keep the form opened and change LitterLine a
second time to something else, Pupline does get updated but not
repainted. When I move the form off screen and back, it gets
repainted. I tried Me.Repaint, but it didn't work. Is there other
ways to get around this problem? These two fields are both text
fields.
You don't need to redraw the form, you need to refresh the data on the
form/field.

Try forms!myForm.Refresh or forms!myForm!MyField.Refresh
Private Sub LitterLine_AfterUpdate()
Me![PupLine] = Me![LitterLine]
End Sub

Thanks,
Tony


I don't recall having this problem when I've done similar things...
--
regards,

Br@dley
Mar 9 '06 #2

P: n/a
Hi Bradley,

I tried both Forms!Myform.Refresh and Forms!MyForm!Pupline.Refresh, but
both did not work. Forms!MyForm!Pupline.Refresh gave an error saying
"Object doesn't support this method or property." It seems that Pupline
field doesn't support any method, because when I type a period after
Pupline, the context menu only displays one choice as "Value". I wonder
why this is also. Any other suggestion?

Thanks,
Tony

Mar 9 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.