ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Refresh Modified Query From Same Sheet (https://www.excelbanter.com/excel-programming/315634-refresh-modified-query-same-sheet.html)

Abdul[_6_]

Refresh Modified Query From Same Sheet
 
Hi All,

How can I refresh a (modified thru code based on value
from sheet1) query from another sheet from the workbook?

I want to have the code for .Connection = ???? to
represent activeworkbook sheeets("Temp 1")


With Sheets("TempData").Range("a1").QueryTable
.Connection = ????
.CommandText = myCmd
.Refresh BackgroundQuery:=False
End With


thanks All

Abdul


All times are GMT +1. The time now is 12:00 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com