I am trying to import a csv file into my blob field and i have a field named as file name is there any way get the file name of the file that we are importing ,
Hi, You can try the following methods. If you are importing an Excel file, you can also get the Sheet Name.
FileMgt: Codeunit "File Management";
FileName := FileMgt.GetFileName(FromFile);
TempExcelBuffer: Record "Excel Buffer" temporary;
SheetName := TempExcelBuffer.SelectSheetsNameStream(IStream);
Hope this helps.
Thanks.
ZHU
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,219 Super User 2024 Season 2
Martin Dráb 230,056 Most Valuable Professional
nmaenpaa 101,156