libphonenumber PhoneNumbers错误 [英] libphonenumber PhoneNumbers error
本文介绍了libphonenumber PhoneNumbers错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
Dim phoneUtil = PhoneNumbers.PhoneNumberUtil.GetInstance()
Dim a = phoneUtil.getNumberType("96170274754")
我一直收到以下错误:
I keep getting the below error:
Error 4 'GetNumberType' is ambiguous because multiple kinds of members with this name exist in class 'PhoneNumbers.PhoneNumberUtil'. C:\Users\elj\Desktop\NumberBook\NbChat\Classes\NumberBook.vb 1403 17 NbChat (NbChat\NbChat)
我该如何解决这个问题?
how can i fix this?
推荐答案
这应该可以帮到你 - http://msdn.microsoft.com/en-us/library/ms235408%28v=vs.90%29.aspx [ ^ ]。
This should help you - http://msdn.microsoft.com/en-us/library/ms235408%28v=vs.90%29.aspx[^].
从我在源代码 [ ^ ],getNunberType
方法参数应该是b相反,当您传递字符串时,请输入PhoneNumber
对象。因此,为了使用它,您应该首先找到从字符串中获取PhoneNumber
对象的方法。
From what I see in the source code[^], thegetNunberType
method parameter should be aPhoneNumber
object while you are passing a string, instead. So, in order to uset it, you should first find a way to obtain aPhoneNumber
object from your string.
这篇关于libphonenumber PhoneNumbers错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文