我正忙着通过vba添加到单元格的超链接。我想我有预先要求添加超链接。虽然我无法让它工作。
通过浏览论坛等等,我能够创建这个代码,但无论我怎么努力,我都无法让它发挥作用。代码在Object required
行
.Hyperlink
With ActiveWorksheet
.Hyperlink.Add Anchor:=ActiveWorksheet.Cells(i, 2)
Address = Cells(SerialNumberLocation, 2)
TextToDisplay = AlternateEngineNumber
End With
有没有人有关于改进代码的任何提示?
将ActiveWorkSheets
更改为ActiveSheets
并将.Hyperlink
移至Hyperlink
我仍然会收到相同的错误,代码为nwo,如
With ActiveSheet
Hyperlink.Add Anchor:=ActiveSheet.Cells(i, 2)_
Address = Cells(SerialNumberLocation, 2)_
TextToDisplay = AlternateEngineNumber
End With
谢谢