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

Using javascript to return a calculated value from DOORS.

 Hi,


I am building a csv file searching for pairs (regex, DOORS module), without repetition, in a whole project (every module, every object). 
In the last paragraph of my template, I have defined an assigment to a variable as:

const regex = "/{{\w+;\w+}}/g";
var finalCSVfile = "";
while (myArray = Object_Text.toString().match(regex) != null) {
  temp = myArray[0] + ',' + Name;
  if (finalCSVfile.indexOf(temp) == -1) {
  finalCSVfile += temp + '\n';
    }
}

However, do not  know how to assign it to the RPE variable. 'return finalCSVfile;' fails.

Thanks for any help.


0 votes

Comments

Almost solved.


I included all the code between '{' and '}' brackets.
And included a 'RPEvariable = finalCSVfinal; ' line.



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
× 12,021
× 332
× 152

Question asked: Feb 14 '23, 9:35 a.m.

Question was seen: 783 times

Last updated: Feb 15 '23, 12:38 a.m.

Confirmation Cancel Confirm