working on this in C# Win Forms.

how do set a variable and after run the command copy ?
as the code is now, the Process1.startInfo.Arguments = "/k **SET** etc. etc." is overwritting by the "/k **COPY** etc. etc." command and there for not executed.

```
    public void OutputBtn_Process_Click(object sender, EventArgs e)
    {
        foreach (FileInfo fi in listBox1.Items)
        {
            Process process1 = new Process();
            process1.StartInfo.Arguments ="/k Set filename ="+fi.Name;
            process1.StartInfo.UseShellExecute = false;
            process1.StartInfo.Arguments = "/k copy /b %filename% test.txt";
            //process1.StartInfo.LoadUserProfile = true;
            process1.StartInfo.FileName = "cmd.exe";
            process1.StartInfo.WorkingDirectory = Path.GetDirectoryName(fi.FullName);
            process1.Start();
        }
    }

```