Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Okay, here is the problem. The code below crashes out at the
Windows(UFFN).Activate part. I think that the code is assigning False to the UF instead of assigning the input from the selection window. Is there some other way to make sure that the then statement runs when the click Cancel. While I'm thinking about it, is there some way to make sure the write restriction password dialog box doesn't appear? Dim UF As Variant Dim UFFN As Variant UF = Application.GetOpenFilename(Title:="This Weeks Projections for Angie") If UF < False Then Workbooks.Open Filename:=UF Set wbUF = Workbooks.Open(Filename:=UF, WriteResPassword:="sue") UFFN = wbUF.Name Windows(UFFN).Activate Sheets("Angie").Select Sheets("Angie").Copy After:=Workbooks("Projection Summary.xls").Sheets("Summary") Windows(UFFN).Activate ActiveWindow.Close Windows("Projection Summary").Activate Else MsgBox "No projection forms selected for Angie. You must add them manually later." *** Sent via Devdex http://www.devdex.com *** Don't just participate in USENET...get rewarded for it! |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Loading problems | Excel Discussion (Misc queries) | |||
Problems with Fuction Loading | Excel Worksheet Functions | |||
File Loading Problem | Excel Programming | |||
Loading an Excel file | Excel Programming | |||
Problems Loading Analysis ToolPak when automating from Visual Basic | Excel Programming |