TraceInfo and full path to file

I'm trying to get the full path (including the filename) of a trace in a window using the following code:
Function traces()
    String wins
    Prompt wins, "Make selection", popup WinList("*",";","WIN:1")
    DoPrompt "Make selection", wins
   
    print wins  // prints "Graph0"

    String info
    info = TraceInfo(wins,"",0)
    print info // for XWAVEDF, it simply returns "root"
End


However, I'm simply getting "root" for WAVEDF. Why doesn't this return this full path to the file that this trace came from? Can I get the full path to the file using TraceInfo, including the filename itself? Thanks very much.

Kevin
The reason I'm asking about this is because I have a function that overlays all the traces in all open windows and puts them into 1 window. However, I want to be able to get information about each of these traces. How do I get this overlay function to get String variables that are created by another function? Should I be using global variables here? Thanks.
Kevin
Note that the keyword is "XWAVEDF" not "XWAVE"; TraceInfo is returning the path to the data folder (in your case, the root data folder), so the x wave name would be something you append to it. That's in the XWAVE:myXWave; part.

--Jim Prouty
Software Engineer, WaveMetrics, Inc.