Pavankumar
Pavankumar

Reputation: 1

Verify phone number using PhoneNumbers.dll with C#, Visual studio 2010

I am trying to verify phone number using PhoneNumbers.dll(File version 8.9.0.0) for twillio SMS API with C# (Visual studio 2010)

Lines of Code used in application:

private static PhoneNumberUtil phoneUtil = PhoneNumberUtil.GetInstance();
private static List<string> supportedRegions = phoneUtil.GetSupportedRegions().ToList<string>();

After application build, facing below error

The type 'System.Object' is defined in an assembly that is not referenced. You must add a reference to assembly 'netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'.

enter image description here

In case same dll used in .Net 2015 no error results with build successed. Please suggest to over come system.object error in .net 2010

Upvotes: 0

Views: 2039

Answers (1)

TheGeneral
TheGeneral

Reputation: 81573

Im not sure why .net standard is not working for you

however if you really need to you can go to an early version of libphonenumber-csharp

https://www.nuget.org/packages/libphonenumber-csharp/7.7.4

Upvotes: 0

Related Questions