Q
Problem solve Get help with specific problems with your technologies, process and projects.

Retrieving Excel data for an application

Development expert Greg Low offers an approach for querying an MS Excel database.

I am developing an application to make maintenance records more useful. The application must be able to accept queries and display the result in numeric form of on a chart. Can you provide a sample code snippet in VBA for querying an MS Excel database?
Sorry, I'm not 100% sure what you're after here. In general, the best approach is to set up Excel to get External data from MSQuery, have it put the data into a table and then have a chart object based upon the tabular data. You can do this (depending upon the Excel version), by choosing "Get External Data" from the "Tools" menu. It is often possible to do this without even writing code, simply by using the query designer tool.
This was last published in December 2005

Dig Deeper on .NET Development for SQL Server

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.

-ADS BY GOOGLE

SearchBusinessAnalytics

SearchDataCenter

SearchDataManagement

SearchAWS

SearchOracle

SearchContentManagement

SearchWindowsServer

Close