# Get References From File

**URL:** https://forum.highend3d.com/t/get-references-from-file/1345
**Category:** Maya
**Tags:** mel
**Created:** [August 28, 2008, 10:25am UTC](https://forum.highend3d.com/t/get-references-from-file/1345 "2008-08-28T10:25:58Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![tostaky](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/t/cc9497/32.png) [@tostaky](https://forum.highend3d.com/u/tostaky)
#### Post date: [August 28, 2008, 10:25am UTC](https://forum.highend3d.com/t/get-references-from-file/1345/1 "2008-08-28T10:25:58Z")

</div>

Hi...

Can I get references path from maya file (after open it), if reference files dont exists?.

Thanks a lot.

---

<div class="post-metadata">

### Author: ![firebblade](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/f/dbc845/32.png) [@firebblade](https://forum.highend3d.com/u/firebblade)
#### Post date: [August 28, 2008, 10:41am UTC](https://forum.highend3d.com/t/get-references-from-file/1345/2 "2008-08-28T10:41:23Z")

</div>

do you mean : If you open a file which has a reference file that has been moved?and you want to find the  
folder that it was?   
 Could you rephrase that a little more analytically ?

---

<div class="post-metadata">

### Author: ![tostaky](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/t/cc9497/32.png) [@tostaky](https://forum.highend3d.com/u/tostaky)
#### Post date: [August 28, 2008, 10:53am UTC](https://forum.highend3d.com/t/get-references-from-file/1345/3 "2008-08-28T10:53:14Z")

</div>

1- I have two files: c:\temp\file1.mb and c:\temp\references\file2.mb

2- I create a reference in file1.mb to link with file2.mb and save file1.mb.

3- Then, I remove file2.mb from disk.

4- I need get path references (in this example "c:\temp\references\file2.mb") from file1.mb after open it. I open file1.mb and I need list (with mel or python) removed references from disk.

Thanks.

---

<div class="post-metadata">

### Author: ![firebblade](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/f/dbc845/32.png) [@firebblade](https://forum.highend3d.com/u/firebblade)
#### Post date: [August 28, 2008, 5:39pm UTC](https://forum.highend3d.com/t/get-references-from-file/1345/4 "2008-08-28T17:39:50Z")

</div>

when you open the file that contains the referenced files if they are missing   
it pop's up a window that says where the referenced files paths were and if you like

one mel string you can use is :

// retrieve a string array of all files referenced in the scene  
//  
 file -q -l;

---

<div class="post-metadata">

### Author: ![tostaky](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/t/cc9497/32.png) [@tostaky](https://forum.highend3d.com/u/tostaky)
#### Post date: [August 29, 2008, 7:22am UTC](https://forum.highend3d.com/t/get-references-from-file/1345/5 "2008-08-29T07:22:11Z")

</div>

If reference (file2.mb) dont exists in disk, "file -q -l" only return current file.

Thanks.

---

<div class="post-metadata">

### Author: ![joojaa](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/j/5daacb/32.png) [@joojaa](https://forum.highend3d.com/u/joojaa)
#### Post date: [August 29, 2008, 6:57pm UTC](https://forum.highend3d.com/t/get-references-from-file/1345/6 "2008-08-29T18:57:29Z")

</div>

If you run skip when you load the file it gets cleared (atlrsdt on my maya). So its no longer there.

You can however querry it ahed of time form commandline.
