I retrieved the paths from the root product per wfcWAssembly::ListComponentsByAssemblyRule.
Another question is, how can I get the file name, which is absent in the directory? In Creo, I can see it (in red) in the tree on the left side. If a drawing file is opened and its reference part is not in the directory, a message box is shown and says XXX.PRT is not in the directory. How can I get the info (XXX.PRT)?