LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 72
Default VALIDATE WB NAME

I attemped to use the following code to force users to save the workbook
with a certain name.
It is not working, and produces ambiguous results. Any ideas.

Thanks in advance.

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Dim filename As String
filename = Application.GetSaveAsFilename
If Not UCase(filename) Like "*AIR CONTAINER*" Then
MsgBox "Save with correct name"
Cancel = True
Else
Cancel = False
End If

End Sub


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
validate wAYNE Excel Discussion (Misc queries) 1 March 1st 10 06:21 PM
validate kyoshirou Excel Discussion (Misc queries) 18 June 6th 07 01:08 AM
Looking up a name and then being able to validate it twynsys Excel Worksheet Functions 0 November 29th 06 02:48 PM
Looking up a name and then being able to validate it twynsys via OfficeKB.com Excel Worksheet Functions 0 November 21st 06 04:43 PM
How to validate edwardpestian Excel Worksheet Functions 4 June 9th 06 01:13 AM


All times are GMT +1. The time now is 05:36 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"