Solved

Excel complaining about the Format command

Posted on 2011-03-21
2
371 Views
Last Modified: 2012-08-14
I am trying out a spreadsheet on a totally different computer.  It has a VBA subroutine that is complaining with a compiler error about the Format() function is not found.  Yet when I create a brand new spreadsheet and create a VBA subroutine the Format command shows up in the Intellisense and it works when I run it.  I am using Excel version 2002.  Thanks
0
Comment
Question by:techhound
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 14

Accepted Solution

by:
pteranodon72 earned 500 total points
ID: 35183917
That is the symptom of having a bad reference declaration in your project. One bad reference throws off code that is unrelated to the problem library. In the erroring file, go to the code module and look at the references declared. Are any of them listed as missing? Clear that one (or those ones), close and save, and then add them back in (but only if they are necessary). Please write back if you have not added / removed References before and I can be more specific.

Hope this helps,
pT72
0
 
LVL 6

Expert Comment

by:FernandoFernandes
ID: 35192417
a way to work around it, is using the full name of the function... like:

vba.format(blah blah blah)

instead of only

format(blah blah blah)
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.
This Micro Tutorial will demonstrate how to create pivot charts out of a data set. I also added a drop-down menu which allows to choose from different categories in the data set and the chart will automatically update.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question