title: how to use multiple command in for loop
body: <p>My Current Code is:</p>
  <pre><code>    function OnClick(data){
      var files = data.func.sourcetab.selected_files;
      var cmd = data.func.command; cmd.ClearFiles();
      var re = new RegExp(&quot;(.*) - ([0-9]*) - (.*)(\.mp3|\.flac)&quot;);
  
  
      for(var i=0;i&lt;files.count;i++){
      //  DOpus.Output(&quot;File: [&quot; + files(i).name+&quot;]&quot;);
          var matches = String(files(i).name).match(re);
      //  if (!matches){ DOpus.Output(&quot;    skipped&quot;); continue; }
          var artist = matches[1];
          var track = matches[2];
          var title = matches[3];
          var cmdli = 'SetAttr META=&quot;artist:'+artist+'&quot; &quot;track:'+track+'&quot; &quot;title:'+title+'&quot; FILE=&quot;'+files(i).realpath+'&quot;';
          //DOpus.Output(&quot;    cmd: &quot; + cmdli);
          cmd.RunCommand(cmdli);
      //  cmd.RunCommand('Rename FROM=&quot;'+ files(i) +'&quot; TO=&quot;' + title + '&quot; IGNOREEXT');
      }
  
      for(var i=0;i&lt;files.count;i++){
          var matches = String(files(i).name).match(re);
          var title   = matches[3];
  cmd.RunCommand('Rename FROM=&quot;'+ files(i) +'&quot; TO=&quot;' + title + '&quot; IGNOREEXT');
      }
      }
  </code></pre>
  <p>Here I have used 2 for loop, the 2nd for loop used for run this command <code>cmd.RunCommand('Rename FROM=&quot;'+ files(i) +'&quot; TO=&quot;' + title + '&quot; IGNOREEXT');</code> Is there any way to run this command in my 1st for loop? If I can run this command in 1st for Loop then I don't need to write the 2nd for loop command.</p>