View Single Post
  #1 (permalink)  
Old August 19th, 2016, 10:25 AM
winkimjr2 winkimjr2 is offline
Friend of Wrox
Points: 465, Level: 7
Points: 465, Level: 7 Points: 465, Level: 7 Points: 465, Level: 7
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Apr 2013
Posts: 101
Thanks: 14
Thanked 0 Times in 0 Posts
Default How do I modify code for array to no array?

I would like to modify code that checks for batch citations using array. I want it to check for a single citation instead. This code uses a function GetCaseNumbersForCitation to check if a citation number exist in the database.

Here is the code to check if citation is a duplicate for batch citations.

I will not need the array because there is always going to be only one citation.

Here is the code I would like to modify

'Check if the citation is a duplicate
Hide   Copy Code
strCitationNumber = objXMLCitationNode.SelectSingleNode("msc:Citation/msc:CitationNumber/msc:ID", objXMLNameSpaceManager).InnerText
 strCitationNumbers = Msc.Integration.Mncis.Library.v4.Citation.GetCaseNumbersForCitation(strCitationNumber, False)
 If (strCitationNumbers(0) <> "No Matching Case") Then
 'add the error message
 CType(objXMLCitationNode, XmlElement).SetAttribute("validationError", "This is a duplicate citation.")
End If