MsExcel. DisplayAlerts:=false;
MsExcel. Range [' A1 ', 'I200]. Locked:=True;
MsExcel. Range [' A1 ', 'I200] FormulaHidden:=True;
MsExcel. ActiveSheet. Protect (Password:='yjs', DrawingObjects:=True, Contents:=True, Scenarious:=True).
MsExcel. ActiveWorkbook. Save;
MsExcel. Workbooks [1]. The Close (True, mypath + 'table \ \ budget implementation adjustment. XLS ", false);
MsExcel. Quit;
MsExcel:=the Unassigned;
Olecontainer1. CreateLinkToFile (str1, false);
Comment out the line 2 and 4 normal, perform an error in the fourth row,
CodePudding user response:
MsExcel:=the Unassigned; This will remove