ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Form.Refresh doesn't work...help !! (https://www.excelbanter.com/excel-programming/289839-form-refresh-doesnt-work-help.html)

Tereba[_2_]

Form.Refresh doesn't work...help !!
 
Help !
I am using the Form.Refresh command and get an error message:

Compile error:
Method or data member not found

The sub is the following:

Private Sub ClrFormButton_Click()
Beep
Response = MsgBox("Are you sure you want to clear all informatio
from this form ?", vbYesNo + 48, "Clear Form")
If Response = vbYes Then ' User chose Yes.
Worksheets("data").Range("C34:C51").Delete
Form1.Refresh
DoEvents
Else
End If
End Sub

Where am I messing this up ?

Rgds
Tereba:confused

--
Message posted from http://www.ExcelForum.com


Chip Pearson

Form.Refresh doesn't work...help !!
 
Tereba,

Use the Repaint method. E.g.,

Form1.Repaint


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com



"Tereba " wrote in
message ...
Help !
I am using the Form.Refresh command and get an error message:

Compile error:
Method or data member not found

The sub is the following:

Private Sub ClrFormButton_Click()
Beep
Response = MsgBox("Are you sure you want to clear all

information
from this form ?", vbYesNo + 48, "Clear Form")
If Response = vbYes Then ' User chose Yes.
Worksheets("data").Range("C34:C51").Delete
Form1.Refresh
DoEvents
Else
End If
End Sub

Where am I messing this up ?

Rgds
Tereba:confused:


---
Message posted from http://www.ExcelForum.com/




Tereba[_3_]

Form.Refresh doesn't work...help !!
 
Hi Chip

Bingo !

Thank you for the suggestion.

Tereba :

--
Message posted from http://www.ExcelForum.com



All times are GMT +1. The time now is 11:57 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com