I noticed that this question was unanswered,so I thought that I'd give you an idea, or at least the way that I found worked for the problem that I had.
What I wanted to do was to rename the Report files to preceed the filename with the number of Errors such as:
Process Alarm Test.html
rename the failed test with 2 errors to:
2-Process Alarm Test.html
For me it got a bit complicated in that I also wanted to make sure that each test was named for the test that was running. This required a series of things which in your case may also apply. My concern here is that your Report must be closed (completed) in order to move it.
1. Your top level Sequence should have the Model set to None. This allows each Subsequence call to create a Report, and therefor, when complete, it will close the file.
2. Each subsequence call from the Main sequence must be set to "Run in a New Execution", and the Settings tab must be set to Wait for Execution to complete "Before executing next step". You will also want to set your Model to either a specific Model, or the Process Model of the specified Client (file). I also found that I needed to add "RunState.Execution.TypeMask.Value to the Additional Execution Type Mask Settings to allow the "Break on failure in New Executions" to work correctly.
3. You'll then need to add a SequenceFilePostStep callback to the top level sequence. In this sequence you'll need to add a step that will rename (or in your case MOVE the file. But you'll also need a precondition set to
RunState.Caller.RunState.StepGroup == "Main"
so that it doesn't try to rename files from the Setup or Cleanup steps.
4. Then, somewhere in your subseqence test, you need to set a varaible (I used a StationGlobal, you could use a Parameter if you like) to indicate the report filename:
StationGlobals.sReportFileName =
RunState.Root.Locals.ReportFilePath
I've attached a file that hopefully will show you how I did most of this.
I'm sure that there are other ways of doing this, but because of some of my requirements, this was the solution that worked for me.
Mike