Public Sub SaveRangeWeb() ActiveWorkbook.PublishObjects.Add _ SourceType:=xlSourceRange, _ Filename:=ActiveWorkbook.Path & "\Sample1.htm", _ Sheet:=ActiveSheet.name, _ Source:="$A$1:$B$11", _ HtmlType:=xlHtmlStatic ActiveWorkbook.PublishObjects(1).Publish (True) End Sub