i am currently trying to run a web crawler through the terminal. it compiles fine and the debug does not find any errors, however i get the following error which i do not understand.
any ideas on how to get rid of this error would be much appreciated
Unhandled Exception: System.ArgumentOutOfRangeException: startIndex + length > this.length
Parameter name: length
at System.String.Substring (Int32 startIndex, Int32 length) [0x00000]
at OpenWebSpiderCS.mysql.executeSQLQuery (System.String SQL) [0x00000]
at OpenWebSpiderCS.db.startIndexThisSite (OpenWebSpiderCS.page p) [0x00000]
at OpenWebSpiderCS.ows.startCrawling () [0x00000]
at OpenWebSpiderCS.mainClass.Main (System.String[] args) [0x00000]
thank you
This exception tells that when you use Substring function you send startIndex and Length to it. And parameters you sent are invalid because startIndex+Length is more that the length of the whole string.
Just revise your code or check before