Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Building a requirement attribute report through DXL

 Good Day,

I am running into syntax errors when trying to execute a DXL script in DOORS 9.6.2. The errors are occurring towards the script's end, centered around the If/Else/ElseIf) statements.   Here is the script.

// #include <"D:\BM\Rational\DOORS\9.6\Client\include\doors\"stdio.h>

// initalize variables
string NameItem()
string DealWithFormalModule()
string DealWithDescriptiveModule()
string DealWithLinkModule()

void RecurseFolder(Folder fld)
{   // Deal RECURSIVELY with sub-folders, and then all modules in this folder

    Skip skpItems = createString()
    Item itm
    string NameItem
    Folder fldNew
                  // Stage in Skip, key is name which is Alpha order
    for itm in fld do
    {  put (skpItems, fullName(itm), itm)
    }
                 // Recurse through sub-folders
    for itm in skpItems do
    {  if (type(itm) == "Folder" or type(itm) == "Project")
       {  NameItem = (string key skpItems)
          fldNew = folder(NameItem)
          RecurseFolder(fldNew)   // *** RECURSION ***
       }
    }
                // Now deal with modules in THIS folder
    for itm in skpItems do
    {  NameItem = (string key skpItems)
         if    (type(itm) == "Formal")      DealWithFormalModule(NameItem)
         elseif(type(itm) == "Descriptive") DealWithDescriptiveModule(NameItem)
         elseif(type(itm) == "Link")        DealWithLinkModule(NameItem)
         else{}   // Ignore Folder/Project
    }
    delete(skpItems)
} // end RecurseFolder()

 Folder fCurr = current
{  if     (!null project(fullName(fCurr))   // Folder IS a project; no need to prompt
     RecurseFolder(fCurr)
  elseif  (confirm("[Confirm] to do current Folder;\n[Cancel] to do current Project")) 
     RecurseFolder(fCurr) 
  else  RecurseFolder(folder(fullName(getParentProject(fCurr))) 
}

Cheers,
KWITS

0 votes


Be the first one to answer this question!

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 11,086

Question asked: Jun 22 '15, 1:57 p.m.

Question was seen: 7,331 times

Last updated: Jul 16 '15, 12:50 p.m.

Confirmation Cancel Confirm