Adding to exisiting VBA

Outlook

New member
Local time
Today, 03:57
Joined
Jul 15, 2013
Messages
4
Hi,

Hoping this is the right section for the thread.

I have exisiting visual basic code that takes the results of a query and copies it to a specific tab within an excel workbook.

Private Sub Image58_Click()
Call SendTQ2XLWbSheet("File Progression - Stratford", "Pipeline", "O:\Public\Public-Lettings\Lettings Documents\Rolling Running Lettings Transactions.xls")
End Sub

I now need to add some code to it so that the excel database is filtered, however the next time it runs, the data must still be on the same rows which it isn't if the data is filtered.

Consequently I thought I could add code in to un-filter it before the copying of data, and the re-filter after the copying of data.

However nothing I write works - any suggestions?

Hannah.
 
Try posting you database with some sample data, and also show which result you want to get by a print screen, (zip the database).
 
The code that I created which you are using would not be able to do what you want it to do. What you would need to do is iterate through the individual records and find the row it needs to be on. Without seeing your spreadsheet and database we can't know how it would know which record goes with which row, etc.
 

Users who are viewing this thread

Back
Top Bottom