VBA程序出现sub或者function未定义

日期:2018-03-07 15:04:22 人气:1

VBA程序出现sub或者function未定义

SUBSTITUTE和rept是工作表函数,需要用WORKSHEETFUNCTION来调用。 Sub test() Dim I, j, K As Long Dim a, b As String Dim useSheet As Excel.Worksheet Set useSheet = ThisWorkbook.Worksheets("Sheet1")a = useSheet.Cells(1, 1).Valueb = Trim(Right(Application.WorksheetF
    A+
热门评论