Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
excel freezing
i have a problem, My program keeps freezing, the screen is half
userform and half spreadsheet at the point of freezing, the code is as follow Private Sub CommandButton7_Click() Call mis If Worksheets("display").Range("b3").Value = "" Then MsgBox Title:="Reports program", PROMPT:="There Are No Records Returned, Please Return To The Menu" Exit Sub End If Worksheets("display").Range("a1") = "MIS Report" Unload Me End Sub the program calls mis the code for this is Sub mis() Dim region Dim webdata As Range Set webdata = Worksheets("mis").Range("a1:w3000") Application.ScreenUpdating = False region = Worksheets("codes").Range("b12") If region = ("No Filter Set") Then webdata.Copy Destination:=Sheets("display").Range("a2") Else webdata.AutoFilter Field:=2, Criteria1:=region webdata.Copy Destination:=Sheets("display").Range("a2") webdata.AutoFilter Field:=2 End If Worksheets("display").Select Call bestfit Application.ScreenUpdating = True End Sub It seems that the form is not unloading, the weird thing is that it was working fine, and just started to freeze hope someone can help |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
excel freezing
Try this:
Private Sub CommandButton7_Click() Call mis If Worksheets("display").Range("b3").Value = "" Then MsgBox Title:="Reports program", PROMPT:="There Are No Records Returned, Please Return To The Menu" Exit Sub End If Worksheets("display").Range("a1") = "MIS Report" Application.ScreenUpdating = True Unload Me DoEvents End Sub -- Regards, Tom Ogilvy wrote in message ups.com... i have a problem, My program keeps freezing, the screen is half userform and half spreadsheet at the point of freezing, the code is as follow Private Sub CommandButton7_Click() Call mis If Worksheets("display").Range("b3").Value = "" Then MsgBox Title:="Reports program", PROMPT:="There Are No Records Returned, Please Return To The Menu" Exit Sub End If Worksheets("display").Range("a1") = "MIS Report" Unload Me End Sub the program calls mis the code for this is Sub mis() Dim region Dim webdata As Range Set webdata = Worksheets("mis").Range("a1:w3000") Application.ScreenUpdating = False region = Worksheets("codes").Range("b12") If region = ("No Filter Set") Then webdata.Copy Destination:=Sheets("display").Range("a2") Else webdata.AutoFilter Field:=2, Criteria1:=region webdata.Copy Destination:=Sheets("display").Range("a2") webdata.AutoFilter Field:=2 End If Worksheets("display").Select Call bestfit Application.ScreenUpdating = True End Sub It seems that the form is not unloading, the weird thing is that it was working fine, and just started to freeze hope someone can help |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
excel freezing
Thanks, unfortunatley this did not help it just now seems to freezewith
just the form showing regards John |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel 2007 Freezing | Excel Discussion (Misc queries) | |||
Excel freezing up constantly | Excel Discussion (Misc queries) | |||
Help! Excel keeps freezing | Excel Discussion (Misc queries) | |||
Excel Freezing | Excel Discussion (Misc queries) | |||
excel freezing | Excel Programming |