473,386 Members | 1,958 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Error: Overload resolution failed

Hi,

I get an overload resolution failed error (Overload resolution failed because no accessible 'New' can be called without a narrowing conversion), and I can't seem to find a lot of relevant information by googling the web.
Function GetFromXml(Id As String, Node As String)
Dim NodeValue As String
Dim xpathDoc As XPathDocument
Dim xmlNav As XPathNavigator
Dim xmlNI As XPathNodeIterator
xpathDoc = New XPathDocument(Getpath() & ArticlesXmlFile)
'------- ^^^^^^^^^^^^^^^ ERROR IN LINE ABOVE'
xmlNav = xpathDoc.CreateNavigator()
xmlNI = xmlNav.Select("/articles/article[id=" & Id & "]/" & Node)
While (xmlNI.MoveNext())
'Response.Write(xmlNI.Current.Name + " : " + xmlNI.Current.Value & "<br>")
NodeValue = xmlNI.Current.Value
End While
Return NodeValue
End Function

The GetPath() function just returns the path under the current - the path it returns is checked & is correct (the function gets used in other places without error), only when i call it in this "xpathDoc = New XPathDocument()" part.
If i enter the path manually (XPathDocument(PATH_HERE)) everything works find.

Any idea what causes this? The complete error message is listed below:
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: BC30519: Overload resolution failed because no accessible 'New' can be called without a narrowing conversion:

Source Error:


Line 122: Dim xmlNav As XPathNavigator
Line 123: Dim xmlNI As XPathNodeIterator
Line 124: xpathDoc = New XPathDocument(GetPath() & ConfigurationSettings.AppSettings("xmlArticlesLoca tion"))
Line 125: xmlNav = xpathDoc.CreateNavigator()
Line 126: xmlNI = xmlNav.Select("/articles/article/id")

Thanks in advance,
Tim De Vogel
S-Data NV
Nov 17 '05 #1
0 2560

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: AIM | last post by:
Error in msvc in building inheritance.obj to build hello.pyd Hello, I am trying to build the boost 1.31.0 sample extension hello.cpp. I can not compile the file inheritance.cpp because the two...
5
by: Gang Zhang | last post by:
Hi, I have 2 overloaded functions as below: myfunc(byval val as Decimal) as string myfunc(byval val as String) as string When calling the function with a single like: dim num1 as single...
4
by: Josh Golden | last post by:
i have a solution with 2 projects in it, project a and b. project a will be a dll, but for now exists in the solution. projectB references projectA. projectA has a dataset with one datatable in...
1
by: steve | last post by:
I am trying to create an XSLT Transform but keep getting the same problem. Overload resolution failed because no accessible 'Transform' can be called with these arguments. I create a reference...
6
by: multisync | last post by:
I'm getting the following error: Overload resolution failed because no accessible 'Add' can be called with these arguments: 'Public Sub Add(item As System.Web.UI.WebControls.ListItem)': Value of...
2
by: jason | last post by:
Since going to framework 2.0 from 1.1, I'm getting error: Overload resolution failed because no accessible 'New' can be called without a narrowing conversion: On line: Dim LogInfo As New...
0
by: ccante3070 | last post by:
What does this error message mean? program is vb.net 2003 Overload resolutionj failed because no accessible "Run" can be called with these arguments. 'Public Shared Sub Run (context As System....
11
by: jakester | last post by:
I am using Visual C++ 2007 to build the code below. I keep getting linkage error. Could someone please tell me what I am doing wrong? The code works until I start using namespace for my objects. ...
5
by: jknupp | last post by:
In the following program, if the call to bar does not specify the type as <int>, gcc gives the error "no matching function for call to ‘bar(A&, <unresolved overloaded function type>)’". Since bar...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.