Book a Demo

Author Topic: the return value of GetByName  (Read 5912 times)

happygzl

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
the return value of GetByName
« on: January 11, 2008, 01:06:16 am »
If the element is  absent ,then what is the return value in VB6 ??

eg:
Dim docObject As EA.Element      
Set docObject = package.Elements.GetByName("Artifact1")
If docObject <>""
« Last Edit: January 13, 2008, 05:24:51 pm by happygzl »

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: the return value of GetByName
« Reply #1 on: January 11, 2008, 03:50:30 am »
Shouldn't that be:
If not docObject is Nothing

happygzl

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: the return value of GetByName
« Reply #2 on: January 13, 2008, 05:50:17 pm »
it is ok .thanks.