If it is not entering the
must be 0.
Use the debugger to examine the line
DataTable exceldt = tbds.Tables;
Does exceldt have a value? It will probably either be null or contain an empty table, so keep working your way up your code until you find the culprit.
The problem probably originates with a misspelling of either the filename or the sheet name. We cannot see your data so it is for you to debug to find out why.