I wrote a piece of code which reads an excel spreadsheet and filters a datatable to check a value after removing spaces from it (the purpose of which is due to potential double spacing).
The code is below and has always worked, but suddenly I am getting an error. I’ve even checked the data to ensure what I need is there (it is) and have ran old instances which I know for certain worked before, but no longer do:
oLatestReportDT.AsEnumerable().Where(Function(r) r(“CAP CODE”).ToString.Replace(" “,”“)= iCapCode.ToString.Replace(” “,”") AND CDbl(r(“Basic List Price”).ToString) = iListPrice).CopyToDataTable
Hey, I’m unable to as this contains sensitive information.
If you were to replicate a spreadsheet with the headers of CAP CODE and Basic List Price and gave them fields with ‘qwe rty’ and ‘12345’ then the scenario would be the same.