Help fixing "type not recognized" error in VB.net

  • Thread starter Thread starter KRC
  • Start date Start date
K

KRC

I am using an external object called WebZinc to help parse web pages
in VB.net. I am trying to use a particular method following the
example in the help reference but am unable to get VB.net to recognize
it. The code example is:

Dim containsWordA As Boolean = New TextProcessor("my string containing
words").ContainsWord("containing")

where TextProcessor is the object and ContainsWord is the method.
VB.net underlines the TextProcessor statement and indicates type not
recognized.I have included the Webzinc Namespace in the Objects
Directory and have used the Imports statement to reference the
namespace. When I browse the Object Directory, the Webzinc objects are
are visible. Other objects work fine. I suspect I have some sort of an
initialization problem.

I'm a newbie, so I suspect a simple mistake. I would appreciate any
thoughts.
Thanks.
 
Hi KRC,

The chance that you get an answer that helps you in this is in this
newsgroup very low.

I think that you can ask it better on the place where you got your WebZinc
object.

You can also try it in this newsgroup because that has more special to do
with aspnet problems.

Aspnet
<
Web interface:
<http://msdn.microsoft.com/newsgroups/default.asp?url=/newsgroups/loadframes
..asp?icp=msdn&slcid=us&newsgroup=microsoft.public.dotnet.framework.aspnet>

I hope this helps a little bit?

Cor
 
Hi, Try this:

Dim containsWordA As Boolean = (New TextProcessor("my string containing
words")).ContainsWord("containing")

i.e. the addition of parentheses around the type initialization

--
HTH,
-- Tom Spink, Über Geek

Woe be the day VBC.EXE says, "OrElse what?"

Please respond to the newsgroup,
so all can benefit
 
Thanks to all for the suggestions. With some experimentation, I solved the
problem. Solution: I needed to reference the namespace in the statement,
e.g. Whitecliff.WebZinc.TextProcessor(etc.). I assumed it had already been
defined, but I guess I was wrong.
 
Back
Top