Save this web page with value of the active cell in sheet2
Thanks Tim
Works a treat
All the best
Dave
"Tim Williams" <timjwilliams at gmail dot com wrote in message
...
Untested:
With ActiveWorkbook.PublishObjects.Add(xlSourceRange, _
"C:\Test\" & Sheet2.Range("B1").Value, _
"sheet1", "$A$5:$Q$70", xlHtmlStatic, "Book1_16704", "")
I'm using the sheet2 codename - if you want to use the tab name it would
be
Activeworkbook.sheets("Sheet2").Range("B1").value
Tim
"DaveM" wrote in message
. uk...
Hi
Sub SaveTempletAsWebpage()
Range("A5:Q70").Select
With ActiveWorkbook.PublishObjects.Add(xlSourceRange, _
"C:\Test\Page.htm" _
, "sheet1", "$A$5:$Q$70", xlHtmlStatic, "Book1_16704", "" _
)
.Publish (True)
.AutoRepublish = False
End With
ChDir _
"C:\Test"
End Sub
I would like to save this web page with value of the active cell in
sheet2 which is B1
Thanks in advance
Dave
|