ExcelBuffer.SelectSheetsNameStream(NVInStream) throwing error

Hi Expert,

I am trying to upload data from excel file and written below code

DialogCaption := ‘Select File to upload’;
UploadResult := UploadIntoStream(DialogCaption, ‘’, ‘’, Name, NVInStream);

If Name <> ‘’ then
Sheetname := Rec_ExcelBuffer.SelectSheetsNameStream(NVInStream)

The bold highlighted one throw below error. Can any one let me know what wrong with this? This code was working fine earlier. I am kind of clueless any suggestion please