longestdrive
Programmer
Hi all
I'm gradually getting through my project thanks to your help. I now have a working export from ms project to excel.
I had trouble setting the range object and should have specified the sheet object before the range. but that's ok now.
My problem now is setting range to equal two sets of cells within the sheet.
Here's the bare bones code:
xlrange is a range object
xlsheet is a dim object
tsv.count is a column count
This code results in a complete block, rather than two distinct areas.
I'm struggling with getting to grips with range, offset, cells etc. How can I set the range object to non contigous areas?
Thank you
LD
I'm gradually getting through my project thanks to your help. I now have a working export from ms project to excel.
I had trouble setting the range object and should have specified the sheet object before the range. but that's ok now.
My problem now is setting range to equal two sets of cells within the sheet.
Here's the bare bones code:
Code:
Set xlRange = xlSheet.Range(xlSheet.Range(xlSheet.Cells(1, 3), xlSheet.Cells(1, TSV.Count)), xlSheet.Range(xlSheet.Cells(sumHrsRow, TSV.Count + 1), xlSheet.Cells(sumHrsRow, TSV.Count + 2)))
xlrange is a range object
xlsheet is a dim object
tsv.count is a column count
This code results in a complete block, rather than two distinct areas.
I'm struggling with getting to grips with range, offset, cells etc. How can I set the range object to non contigous areas?
Thank you
LD