-
changing file paths
I am programming the experiment on my office computer, but will be running the experiment on our lab computers. Thus the path names will be different on the lab computers then on my office computer. Is there a way to globally change the path names? For example, on my office computer, the path might be "C:\Documents and Settings\Dgprocess\Desktop\Study", but on the lab computers it would be "C:\Documents and Settings\Lab\Desktop\Study." It is a large and complex study, and changing all the paths by hand would take considerable time.
-
Hm. Due to the need for filepaths that are relative, a feature was added into the Experiment Editor which specifies shorter filenames for files that are found within the same directory or in subdirectories that the experiment file is located in.
For more information, see the following link: [url]http://www.empirisoft.com/medialab/help/specifying_file_paths.htm[/url]
If these paths have already been created and specified - it might be a bit of work to actually go through and change them all. Around how many filenames do you believe need to be altered?
-
Thanks newell. I actually figured this out by reading the help file (duh). However, since the program was originally written (by my former grad student) with files in lots of separate folders, I had to put all the files in one folder and am now in the process of manually changing all the paths. I don't think the experiment is written as succinctly as it could be- there are 64 different .que files that need to have path files changed (and each one has about 7 variables).
-
By the way, I'm using v2006, which I don't think supports relative paths for subdirectories.
-
Hm - If needed, I can create a small tool for you tonight to do this process for you.
-
Wow- that would be fabulous! Its a bit tedious doing this by hand.... Do you need me to send you anything?
-
Hm - that's ok. I'll have the tool ready sometime later tonight.
-
Thanks.
Although I'm having a related problem- I started changing the paths, and now the experiment can't find the files at all. I moved all the files into one folder, and manually changed the paths for one condition (1A)- and tried to run that condition, but for every outside file, the program gives me the error that it can't find the file. I double and triple-checked that all the paths are correct. And each individual questionnaire runs fine when run as a stand-alone questionnaire. But when I run the whole experiment, when it calls up the files within the questionnaires, it suddenly can't find the files.
Weird.
Thanks for your help with this.
Oh, by the way... the ctl+alt+right arrow shortcut that's programmed to quit the experiment doesn't work on my computer... the same keys are used to change the orientation of the screen.
-
1 Attachment(s)
Ok - let's see here...
I've completed and attached a tool that should hopefully make your task a lot easier. Essentially, it's a 'Find & Replace' tool. It works by simply taking input for the string you want it to find, input for the string you want the found text to be replaced with, and the directory where you want files with a [B].que[/B] or [B].exp[/B] extension to be altered. The software recursively sorts through each subdirectory within the folder you denote. This means that choosing say the directory C:\ as your base folder would be a bad idea - as the software would sort through every folder on the drive, and search through any files with an extension of .exp and .que . Rather, select the folder that contains the files with text you want altered (ie. C:\MediaLab\Samples\Sample1).
First, download and install the .Net 2.0 Framework: [URL="http://www.microsoft.com/downloads/details.aspx?FamilyID=0856EACB-4362-4B0D-8EDD-AAB15C5E04F5&displaylang=en"]http://www.microsoft.com/downloads/d...displaylang=en[/URL]
Next, download the attached .Zip and run the .EXE .
[SIZE=1][B]Que Files Replace:[/B]
- Question Wording / File Name
- Name
- BackImage
- BackSound
- BackVideo
- Parameters
- Filename
- OmitConditions[/SIZE]
[SIZE=1][B]Exp Files Replace:[/B]
- File Name
- BackImage
- BackSound
- BackVideo
- Parameters[/SIZE]
[B]Warning:[/B] Searching for simple text to replace may lead to replacements to occur that you did not intend to happen. For example, requesting that all instances of the word 'and' are replaced with 'C:\MediaLab\Samples\Sample1', could cause for many more replacements to take place than you may have wanted.
[B]Warning:[/B] The software will search through ANY folder that is contained within the Data Location. For instance, if you choose to use the folder "C:\Program Files" - it will search through EVERY folder within the Program Files directly, opening and altering any .que/.exp file it can find. Make sure you only select the specified data folder for the experiment that contains the .que/.exp files you want to edit.
[B]Warning:[/B] Make sure you don't have any of the files open before executing the 'Process' button.
Here's an example of the input I've used:
Find: [I]find this text[/I]
Replace: [I]replace it with this text[/I]
Directory: [I]C:\MediaLab\Samples\Sample1[/I]
[IMG]http://www.empirisoft.com/Download/ReplacementEditor.png[/IMG]
The above input will replace any occurrences of the text '[I]find this text[/I]' with the text '[I]replace it with this text[/I]' in each .que and .exp file that it can find within the directory: [I]C:\MediaLab\Samples\Sample1[/I] .
It should also be noted that it is -highly- suggested that you back up your files before executing this code. Please ask any questions you may have before using the software (if you have any).
---
In regards to the monitor issue, see the following thread: [URL]http://www.empirisoft.com/support/showthread.php?t=389[/URL]