![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Board Regular
Join Date: Apr 2002
Location: Indianapolis
Posts: 80
|
I have a couple of questions this morning and would greatly appreciate any help.
1) The following code gives the user prompt "are you sure..blah,blah". Is there a way to disable that prompt so my users don't have to respond? Sub Delete_Bad_Sheets() Sheets("input").Delete Sheets("Information").Delete Sheets("1st pass").Delete Sheets("Detail 1").Delete Sheets("GLAdmin").Delete End Sub 2)I've utilized code from the archives to save the file using cell contents... I'm getting an error. I looked at this a lot last night and can't figure out what's wrong. Any suggestions? Sub saveme() ActiveWorkbook.SaveAs Filename:="G:POL_ADMINPolicy Value ResearchT-Recs Detail for Apr-02 recs" & Format(Sheets("Detail").Range("a1"), "0") & ".xls" End Sub Thanks for any help. Can't wait til I can help answer instead of always asking. BTW, on this board, should I post each question individually? Always like to follow the rules.... Lisa |
|
|
|
|
|
#2 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: Auckland, New Zealand
Posts: 4,209
|
Quote:
Sub Delete_Bad_Sheets() Application.DisplayAlerts=false Sheets("input").Delete Sheets("Information").Delete Sheets("1st pass").Delete Sheets("Detail 1").Delete Sheets("GLAdmin").Delete Application.displayalerts=True End Sub 2) What Error are you getting |
|
|
|
|
|
|
#3 |
|
Board Regular
Join Date: Apr 2002
Location: Indianapolis
Posts: 80
|
Ivan -
Your answer to #1 works great! Thanks. I have an issue with #2 that happens before the actual save routine. Couldn't see that last night! Basically that cell is referencing one of the sheets I delete. Duh!! Thanks again Lisa |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|