N
nuti
hi,
iam trying to run a macro in the excel but its throwing error "object
required".
kindly help me out .
THE ERROR IS SHOWN FOR THE LAST LINE OF CODE.
-------------------------------------------------------------------------------------------------------
Dim objWSH As String, objFileSystem, objlogfile As String
Dim strWorkPath, lCountErrors, lCountWarnings, strLogFileName,
strLogDate As String
Dim strDHCPServer, strIPAddr, strMACAddr, strScope, strClientName,
strComment, strtype As String
Dim strOption, strOptionCode, strOptionValue, strDNSvalues As String
Dim fso, DHCPInputFile, strLine, varLine, posFirstParam, strFirstParam
As String
Dim strNewLine, posSecondParam, strSecondParam, strThirdParam As String
Dim strInputboxText, intInput, strInputFile, strRegion, strMsgboxText,
intMsgbox As String
Set objWSH = WScript.CreateObject("Wscript.shell")
Set objFileSystem = WScript.CreateObject("Scripting.FileSystemObject")
strWorkPath = objFileSystem.GetParentFolderName(WScript.ScriptFullName)
'Set working directory
'Logfile configuration
strLogDate = GetLogDate
strLogFileName = objWSH.ExpandEnvironmentStrings(strWorkPath & "\" &
strLogDate & ".log")
Set objlogfile = objFileSystem.CreateTextFile(strLogFileName, True)
-------------------------------------------------------------------------------------------------------
iam trying to run a macro in the excel but its throwing error "object
required".
kindly help me out .
THE ERROR IS SHOWN FOR THE LAST LINE OF CODE.
-------------------------------------------------------------------------------------------------------
Dim objWSH As String, objFileSystem, objlogfile As String
Dim strWorkPath, lCountErrors, lCountWarnings, strLogFileName,
strLogDate As String
Dim strDHCPServer, strIPAddr, strMACAddr, strScope, strClientName,
strComment, strtype As String
Dim strOption, strOptionCode, strOptionValue, strDNSvalues As String
Dim fso, DHCPInputFile, strLine, varLine, posFirstParam, strFirstParam
As String
Dim strNewLine, posSecondParam, strSecondParam, strThirdParam As String
Dim strInputboxText, intInput, strInputFile, strRegion, strMsgboxText,
intMsgbox As String
Set objWSH = WScript.CreateObject("Wscript.shell")
Set objFileSystem = WScript.CreateObject("Scripting.FileSystemObject")
strWorkPath = objFileSystem.GetParentFolderName(WScript.ScriptFullName)
'Set working directory
'Logfile configuration
strLogDate = GetLogDate
strLogFileName = objWSH.ExpandEnvironmentStrings(strWorkPath & "\" &
strLogDate & ".log")
Set objlogfile = objFileSystem.CreateTextFile(strLogFileName, True)
-------------------------------------------------------------------------------------------------------