
Hi Team,
I'm unable to find the issue why i'm getting "Unterminated string constant" using Vbscript Activity.
Script Details :
----------------------------------------------------------------------------------------------------------------------------------------------------
Option Explicit
''On error resume Next
Dim timeStamp,d,m,y,GetCurrentDate,num,ObjFSO,objLog,ExcelObject,Arg_InputFilePath,Arg_LogFilePath,Arg_SaveAs,Machine_Hours_Src_WorkBook,Kk_Mchns_HoursCMpltd_Sheet,Kk_Mchns_WIpByIdentWo_Sheet
Dim objConnection,bBackground,Arg_WorkingDay_Num
Arg_InputFilePath = ("%strcmpltMHPFilePath%") ''Get The Input FIle NAme of Machine Hour pivots
Arg_LogFilePath = ("%strMachTrackerPath%") ''get The Log FIle Path
Arg_WorkingDay_Num = ("%strCurrentWorkingDay%") ''Get The Working Day Number
Arg_SaveAs = ("%strMachTrackerPath%") ''Save As path
----------------------------------------------------------------------------------------------------------------------------------------------------
reference : 2 attachments
I'm getting error at highlighted red color location/variables.
I have tracker the variables by keeping one message box (Please find the attached Screenshot). so variable values are printing in message box.
Still I'm getting the same issue.
Please help me to resolve the issue.
Thanks.
Issue resolved.
When we are passing variable from outside to Run Vbscript command, we need to make sure the variable is trimmed. Otherwise script will return "Error: Unterminated string constant".
Hope this information will help to all friends.