Solved

Using VB in powerpoint

Posted on 2001-06-18
1
223 Views
Last Modified: 2010-05-18
I need to (within code in a powerpoint VB module) reference cells in an excel file.

What is the code that i need to do this?
Thanks

JS
0
Comment
Question by:jordo2798
1 Comment
 
LVL 2

Accepted Solution

by:
chandukb earned 100 total points
ID: 6203496
Yes, you can read data from xl.

reference excel object library in your project

Dim xl As Excel.Application

   If xl Is Nothing Then
       Set xl = CreateObject("Excel.Application")
       xl.DisplayAlerts = False
   End If

   xl.Workbooks.Open "your file name"
   xl.DisplayAlerts = True
   yourVariable = xl.sheets("sheet name").range("your column, row).value
   msgbox yourVariable
   Set xl = Nothing

Chandu


0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

705 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now