Our vBulletin migration is complete.
Welcome vBulletin users! All content and user information from the Micro Focus Forums (vBulletin) site has been migrated to this site. READ MORE.
sousou
New Member.
137 views

Find duplicate value

Jump to solution

Hi everybody.

I'm trying to create a script detecting if a value is duplicate or not. It means  when I create a defect, I would like to chek if value of one field is already existing in other defect

My code for the moment : 

Set tdc = TDConnection
Set reqF = tdc.ReqFactory
Set reqFilter = reqF.Filter
reqFilter.Filter("BG_USER_01") =Bug_Fields("BG_USER_01").Value
reqFilter.Order("BG_USER_01") = 1
Set reqL = reqFilter.NewList

 

Message=MsgBox("test",Styl,MSG_TITRE_016)   

 

'If reqL.Count > 0 Then 'Première utilisation
Styl=vbCritical
Msg="ERROR.....'
Message=MsgBox(Msg,Styl,MSG_TITRE_016)
'Bug_Fields("BG_USER_01").Value=""
end if

 

It seems to have a problem in 

Set reqL = reqFilter.NewList because line 

Message=MsgBox("test",Styl,MSG_TITRE_016)   is not executed.

But I'm not able to find why......

 

Thanks for your help 🙂

0 Likes
1 Solution

Accepted Solutions
Chris_Grz Outstanding Contributor.
Outstanding Contributor.

Re: Find duplicate value

Jump to solution

Things would be better if you use BugFactory instead of ReqFactory.

0 Likes
2 Replies
Chris_Grz Outstanding Contributor.
Outstanding Contributor.

Re: Find duplicate value

Jump to solution

Things would be better if you use BugFactory instead of ReqFactory.

0 Likes
sousou
New Member.

Re: Find duplicate value

Jump to solution

sure..... thanks a lot

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.