|
-
Jun 7th, 2007, 08:35 AM
#1
Thread Starter
Junior Member
Open Excel workbooks without showing them
I suppose it's a really simple task, but I tried to search and could't find in help.
I'm in VBA PPT and I want to open a workbook to get data from it, and then close it.
Code:
Set wbExcel = appExcel.Workbooks.Open(path)
Here's what I have to open the workbook, but the problem is that I don't want to see the message telling me to enable macros and the Excel workbook, I want it to run in background.
I read somewhere about WithWindow:=msoFalse but that didn't work since it's a workbook.
-
Jun 7th, 2007, 08:58 AM
#2
Re: Open Excel workbooks without showing them
try:
appExcel.Workbooks.Application.Visible = True
should make the Excel application unvisible to the user!
You're welcome to rate this post!
If your problem is solved, please use the Mark thread as resolved button
Wait, I'm too old to hurry!
-
Jun 7th, 2007, 10:39 AM
#3
Thread Starter
Junior Member
Re: Open Excel workbooks without showing them
 Originally Posted by opus
try:
appExcel.Workbooks.Application.Visible = True
should make the Excel application unvisible to the user!
It nearly works perfectly, it blocks the screen but I still see the Excel window and the "Enable Macros" msgbox
-
Jun 7th, 2007, 12:49 PM
#4
Fanatic Member
Re: Open Excel workbooks without showing them
Try this before you open the workbook:
Code:
appExcel.DisplayAlerts = False
-
Jun 8th, 2007, 02:10 AM
#5
Re: Open Excel workbooks without showing them
Using ADO in PowerPoint you can open and retrieve data from Excel without using Excel COM.
My FAQ example of reading the sheet names with ADO:
http://vbforums.com/showthread.php?t=442232
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|