0

I am facing below issue in .Net Core. I have added Microsoft.VisualBasic nuget package to .Net Core class library but still getting issue.

The type or namespace name 'FileIO' does not exist in the namespace 'Microsoft.VisualBasic' (are you missing an assembly reference?)

I didn't get above issue in .Net framework.

How to resolve above issue

Stephen Kennedy
  • 20,585
  • 22
  • 95
  • 108
  • Related topic : Visual Basic’s File IO Added to .NET Core https://www.infoq.com/news/2019/02/VB-File-IO-Core/ – Manak Jul 11 '19 at 09:44
  • As per given article, File IO supported in .Net Core 3.0 .Looks like .Net Core 3.0 is supported in VS 2019. How can I use .Net Core 3 in VS Enterprise 2017. – user2114257 Jul 11 '19 at 09:55
  • .Net Core 3 is in preview, RC planned in July, GA in September. How to use in VS2017: https://stackoverflow.com/questions/53641740/use-visual-studio-2017-with-net-core-sdk-3-0 – Asons Jul 11 '19 at 10:02
  • Possible duplicate of [Microsoft.VisualBasic.FileIO reference](https://stackoverflow.com/questions/58698869/microsoft-visualbasic-fileio-reference) – Stephen Kennedy Nov 05 '19 at 01:20

2 Answers2

1

I think there is no way to use Microsoft.VisualBasic.FileIO on .Net Core currently.

Maybe you can use some library like this, it would achieve the same results: https://github.com/bimonsubio1984/CommonCore/tree/master/Ported.VisualBasic

SomethingCool
  • 303
  • 2
  • 20
0

with the FileIO functionality there is the TextFieldParser. This is an RFC compliant CSV parser that can also handle fixed-width files.

0x53olution
  • 331
  • 3
  • 11