Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Screen flashing
I have a macro that performs a certain set of tasks every second. Annoyingly
it also makes my screen flash every second, despite screen updating being set to false during activity. I'd be grateful for any observations anyone might have on this... Many thanks tp Sub TimerProc(ByVal hWnd As Long, ByVal uMsg As Long, _ ByVal nIDEvent As Long, ByVal dwTimer As Long) ' Application.ScreenUpdating = False 'On Error GoTo error_stop With Sheets("WMP").Range("BL4:bx64") .Replace What:="=", Replacement:="$$$=", LookAt:=xlPart, _ SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _ ReplaceFormat:=False End With With Sheets("Sheet1") Range("Y3:AA53").Select ActiveWorkbook.XmlMaps("java_Map").DataBinding.Ref resh End With With Sheets("WMP").Range("a5:m5") .Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove Application.CutCopyMode = False End With With Sheets("WMP").Range("a4:m4") .Copy End With With Sheets("WMP").Range("a5:m5") .PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False End With With Sheets("WMP").Range("BL4:bx64") .Replace What:="$$$=", Replacement:="=", LookAt:=xlPart, _ SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _ ReplaceFormat:=False End With If Sheets("WMP").Range("AM1") < Sheets("WMP").Range("AS1") Then With Sheets("WMP").Range("AS1") .Copy End With With Sheets("WMP").Range("AM1") .PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False End With End If Range("AQ1").Select Application.ScreenUpdating = True Exit Sub error_stop: Call EndTimer End Sub Sub StartTimer() TimerSeconds = 1 ' how often to "pop" the timer. TimerID = SetTimer(0&, 0&, TimerSeconds * 1000&, AddressOf TimerProc) End Sub Sub EndTimer() KillTimer 0&, TimerID End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to stop the screen from 'flashing' when copying and pasting | Excel Discussion (Misc queries) | |||
Screen "Flashing" on Window change | Excel Discussion (Misc queries) | |||
print box opens in right screen of dual screen setup why | Excel Discussion (Misc queries) | |||
Screen flashing why? | Excel Discussion (Misc queries) | |||
Need to convert point on screen to various screen resolutions | Excel Discussion (Misc queries) |