Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Excel VBA > Excel VBA
|
Excel VBA Discuss using VBA for Excel programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Excel VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 13th, 2004, 03:55 PM
Authorized User
 
Join Date: Jun 2003
Posts: 75
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The column that I needed the error message suppression for needs to be Text as the value can be "09" or "AB" etc.

I also don't think it's a good idea to turn the error messages off for the entire spreadsheet. In my situation the program is a one time deal. While testing, I'll comment out that line and when I do the final run I'll un-comment it out.

I'll do a bit more research on it. The macro recording suggestion helped a lot.

Thanks for all your comments.
 
Old August 13th, 2004, 04:20 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 150
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The recording tool is very useful.
I don't know why you use: Application.ErrorCheckingOptions.BackgroundCheckin g = False. Unless Excel2002 doesn't support my suggestion.

To test what happens when using: Application.ErrorCheckingOptions.NumberAsText = False try this on an empty sheet:

ColA - format it as text
ColB - format it as numbers

Enter 09 i a cell in col A to C and then run my suggestion. You'll see, that only colA is changing (the warning disappears). The two remaining colums are unchanged.

Therefore, you actually have full control over your data, whether disabling the NumberAsText or not.
 
Old August 13th, 2004, 04:36 PM
Authorized User
 
Join Date: Jun 2003
Posts: 75
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes, you are correct. I tried it using the NumberAsText = False and the warning message disappeared just for that column.

Thank you :-)





Similar Threads
Thread Thread Starter Forum Replies Last Post
Runtime Column Header Text vinod_yadav1919 BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7 1 November 29th, 2008 01:53 AM
To get text of ButtonField column in GridView nitinp ASP.NET 2.0 Professional 11 May 26th, 2007 12:55 PM
XML EXPLICIT with text column stevemeyns SQL Server 2005 1 February 7th, 2007 01:09 PM
how to capture the text in column khautinh C# 0 December 19th, 2003 01:38 PM
Write column heading to text file cat_trio Access VBA 0 November 13th, 2003 02:32 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.