Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 11-23-2017, 10:18 AM
ramzan11b ramzan11b is offline Macro for automatically refreshing Data connection on Closed excel workbook. Windows 7 64bit Macro for automatically refreshing Data connection on Closed excel workbook. Office 2013
Novice
Macro for automatically refreshing Data connection on Closed excel workbook.
 
Join Date: Nov 2017
Posts: 1
ramzan11b is on a distinguished road
Default Macro for automatically refreshing Data connection on Closed excel workbook.

Hy all.
I need some help.
I will be very grateful and will pray-full for any help.
I don't know about using macros in excel.

I am using excel 2013. I have a workbook which has connections to SQL Server for power query and pivot tables.
I want that the data connections in work book may be refreshed at specific time intervals and workbook may be saved.
Can some one please guide me for adding and enabling macro for this purpose.


I am completely raw in adding macro. So please someone guide me completely with some example.
I will be very much grateful for this help.
Reply With Quote
  #2  
Old 11-24-2017, 08:55 AM
ArviLaanemets ArviLaanemets is offline Macro for automatically refreshing Data connection on Closed excel workbook. Windows 8 Macro for automatically refreshing Data connection on Closed excel workbook. Office 2016
Expert
 
Join Date: May 2017
Posts: 873
ArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud of
Default

Create a vb-script which opens your Excel workbook (maybe without displaying it at all), refreshes the query, and then saves and closes the workbook. And then run this script by Windows scheduled task.

Btw. Why you need to automate this at all? When someone uses the workbook to see the data, then you can set the query to SQL Server to be refreshed on open. When you query the data in Excel workbook, then why not query the data from SQL Server directly?
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Macro for automatically refreshing Data connection on Closed excel workbook. need vba code export data to closed workbook sheets manilara Excel Programming 1 02-12-2016 08:20 PM
OL2010: Your IMAP server closed connection markg2 Outlook 0 12-17-2015 08:08 AM
Your IMAP server closed the connection emueyes Outlook 0 07-14-2013 11:38 PM
Macro for automatically refreshing Data connection on Closed excel workbook. macro to transfer data from one workbook to another workbook virsojour Excel Programming 5 02-01-2011 08:58 PM
Macro for automatically refreshing Data connection on Closed excel workbook. Refreshing Data in Excel jamal420 Office 3 06-13-2005 03:45 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 06:52 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft