Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

XML - hasAttribute question
I use items1.hasAttribute("ID") to check of attribute ID exists in node
items1 before I get the attribute value. But, why i got this error message
"object doesn't support this properties or method - run time erro '438'" whe
n
it execute this at the if statement:

if items1.hasAttribute("ID")) then
'  do something here ....
Else
'
end if

Thanks for any help.

-sl
--
Thanks.

Report this thread to moderator Post Follow-up to this message
Old Post
sl
10-30-04 01:55 AM


Re: XML - hasAttribute question
What is item1? - Show the declaration.

--
Chris Hanscom - Microsoft MVP (VB)
http://www.veign.com
--

"sl" <sl@discussions.microsoft.com> wrote in message
news:F03CAE10-9758-4260-B524-A90EAECAA7FA@microsoft.com...
> I use items1.hasAttribute("ID") to check of attribute ID exists in node
> items1 before I get the attribute value. But, why i got this error message
> "object doesn't support this properties or method - run time erro '438'"
when
> it execute this at the if statement:
>
>  if items1.hasAttribute("ID")) then
>     '  do something here ....
>  Else
>    '
>  end if
>
> Thanks for any help.
>
> -sl
> --
> Thanks.



Report this thread to moderator Post Follow-up to this message
Old Post
Veign
10-30-04 01:55 AM


Re: XML - hasAttribute question
> I use items1.hasAttribute("ID") to check of attribute ID exists in node
> items1 before I get the attribute value. But, why i got this error message
> "object doesn't support this properties or method - run time erro '438'" w
hen
> it execute this at the if statement:
<code snipped>

Are you using VB.NET and the framework XML library or VB (Classic) and the M
SXML DOM?  I don't recall seeing the hasAttribute()
method on any MSXML interfaces and the only reference I can see to it in the
 MSDN is on XmlElement objects within the System.Xml
namespace.
If this is the case then you'll need to re-post to a .NET group such as those listed he
re: Http://EDais.mvps.org/DotNet/ if not then
post more of your code, in particular the declaration of "items1", how it's 
populated and which version of the XML library you are
using.
Hope this helps,

Mike


- Microsoft Visual Basic MVP -
E-Mail: EDais@mvps.org
WWW: Http://EDais.mvps.org/



Report this thread to moderator Post Follow-up to this message
Old Post
Mike D Sutton
10-30-04 01:55 PM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

Visual Basic archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 05:12 AM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.