<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/245632</link>
    <title>MATLAB Central Newsreader - Matlab Compiler and paths</title>
    <description>Feed for thread: Matlab Compiler and paths</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2012 by MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Sun, 01 Mar 2009 18:40:19 -0500</pubDate>
      <title>Matlab Compiler and paths</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/245632#631719</link>
      <author>Bill </author>
      <description>All,&lt;br&gt;
&lt;br&gt;
After some success as a &quot;getting started&quot; person with the Matlab Compiler I have run into a snag when trying a &quot;real&quot; project:&lt;br&gt;
&lt;br&gt;
1. I did need to set some path values to get the top level script to execute properly, but indeed it does.&lt;br&gt;
&lt;br&gt;
2. I have built and packaged the project many times now and it &quot;almost&quot; runs.&lt;br&gt;
&lt;br&gt;
3. The problem is that an &quot;exist(filename)&quot; statement does not find the file when I run the &quot;.exe&quot; version of the project.&lt;br&gt;
&lt;br&gt;
4. The file does exist and, as an experiment, I added some code to prepend the path to the filename, and sure enough the &quot;.exe&quot; version did find the file when doing the &quot;exist&quot;&lt;br&gt;
&lt;br&gt;
5. Unfortunatley, there are several areas where the &quot;m&quot; code assumes that the Matlab path structure will supply the path to individual file names.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
It is almost as though the whole set of Matlab paths does not get included with the MCR.&lt;br&gt;
&lt;br&gt;
Any ideas?&lt;br&gt;
&lt;br&gt;
TIA,&lt;br&gt;
&lt;br&gt;
Bill</description>
    </item>
    <item>
      <pubDate>Sun, 01 Mar 2009 20:06:01 -0500</pubDate>
      <title>Re: Matlab Compiler and paths</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/245632#631726</link>
      <author>Bruno Luong</author>
      <description>&quot;Bill&quot; &amp;lt;john.doe.nospam@mathworks.com&amp;gt; wrote in message &amp;lt;goekqj$m4m$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; All,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; After some success as a &quot;getting started&quot; person with the Matlab Compiler I have run into a snag when trying a &quot;real&quot; project:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; 1. I did need to set some path values to get the top level script to execute properly, but indeed it does.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; 2. I have built and packaged the project many times now and it &quot;almost&quot; runs.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; 3. The problem is that an &quot;exist(filename)&quot; statement does not find the file when I run the &quot;.exe&quot; version of the project.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; 4. The file does exist and, as an experiment, I added some code to prepend the path to the filename, and sure enough the &quot;.exe&quot; version did find the file when doing the &quot;exist&quot;&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; 5. Unfortunatley, there are several areas where the &quot;m&quot; code assumes that the Matlab path structure will supply the path to individual file names.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; It is almost as though the whole set of Matlab paths does not get included with the MCR.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Any ideas?&lt;br&gt;
&lt;br&gt;
I have read through your five comments and I do quite understand what in there!&lt;br&gt;
&lt;br&gt;
Just one commen that might helpt: the default path when running an application in exe is the usually 2 level down from the location of the exe file. The folder is created to receive extracted encoded mfiles from the ctf.&lt;br&gt;
&lt;br&gt;
When this is clear, you will be ready to fix any path issues after compilation.&lt;br&gt;
&lt;br&gt;
It is also safer to use EXIST with second argument rather than single input.&lt;br&gt;
&lt;br&gt;
Bruno</description>
    </item>
    <item>
      <pubDate>Mon, 02 Mar 2009 14:21:07 -0500</pubDate>
      <title>Re: Matlab Compiler and paths</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/245632#631885</link>
      <author>Ashish Uthama</author>
      <description>On Sun, 01 Mar 2009 13:40:19 -0500, Bill &amp;lt;john.doe.nospam@mathworks.com&amp;gt;  &lt;br&gt;
wrote:&lt;br&gt;
&lt;br&gt;
&amp;gt; All,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; After some success as a &quot;getting started&quot; person with the Matlab  &lt;br&gt;
&amp;gt; Compiler I have run into a snag when trying a &quot;real&quot; project:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 1. I did need to set some path values to get the top level script to  &lt;br&gt;
&amp;gt; execute properly, but indeed it does.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 2. I have built and packaged the project many times now and it &quot;almost&quot;  &lt;br&gt;
&amp;gt; runs.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 3. The problem is that an &quot;exist(filename)&quot; statement does not find the  &lt;br&gt;
&amp;gt; file when I run the &quot;.exe&quot; version of the project.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 4. The file does exist and, as an experiment, I added some code to  &lt;br&gt;
&amp;gt; prepend the path to the filename, and sure enough the &quot;.exe&quot; version did  &lt;br&gt;
&amp;gt; find the file when doing the &quot;exist&quot;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 5. Unfortunatley, there are several areas where the &quot;m&quot; code assumes  &lt;br&gt;
&amp;gt; that the Matlab path structure will supply the path to individual file  &lt;br&gt;
&amp;gt; names.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; It is almost as though the whole set of Matlab paths does not get  &lt;br&gt;
&amp;gt; included with the MCR.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Any ideas?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; TIA,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Bill&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Have you included the file ('filename' in exist(filename)) in the project?</description>
    </item>
    <item>
      <pubDate>Wed, 04 Mar 2009 15:32:02 -0500</pubDate>
      <title>Re: Matlab Compiler and paths</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/245632#632474</link>
      <author>Bill </author>
      <description>Ashish,&lt;br&gt;
&lt;br&gt;
The answer is NO. I'll bet that is the problem! I'll post a message if that is the case.&lt;br&gt;
&lt;br&gt;
Thanks for the tip,&lt;br&gt;
&lt;br&gt;
Bill</description>
    </item>
    <item>
      <pubDate>Wed, 04 Mar 2009 16:38:01 -0500</pubDate>
      <title>Re: Matlab Compiler and paths</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/245632#632501</link>
      <author>Emanuele </author>
      <description>Hi Bill, i have a problem ti run the .exe file.&lt;br&gt;
&lt;br&gt;
What is the right path to run the .exe file&lt;br&gt;
&lt;br&gt;
I have tried with&lt;br&gt;
matlabroot\bin\win32\file.exe&lt;br&gt;
Is right??&lt;br&gt;
&lt;br&gt;
Thanks all in advance&lt;br&gt;
&lt;br&gt;
Emanuele</description>
    </item>
    <item>
      <pubDate>Wed, 04 Mar 2009 16:58:02 -0500</pubDate>
      <title>Re: Matlab Compiler and paths</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/245632#632507</link>
      <author>Bill </author>
      <description>2 Things:&lt;br&gt;
&lt;br&gt;
1. Ashish was correct, when I added all of the files that were referenced by the application, it ran correctly. A downside is that this added 16 Mbytes to my application size. This is what I want if I am deploying to a different computer, but not really what I want if those files already exist on my PC (or even the target PC). Oh well, all is OK for now.&lt;br&gt;
&lt;br&gt;
2. Emanuele, you wrote the following:&lt;br&gt;
&lt;br&gt;
&quot;i have a problem ti run the .exe file. What is the right path to run the .exe file&lt;br&gt;
I have tried with matlabroot\bin\win32\file.exe&lt;br&gt;
Is right??&quot;&lt;br&gt;
&lt;br&gt;
Keeping in mind that I am a novice a this, as near as I can tell, the .exe file can be anywhere. In my case, I want it on a network drive, and it seemed to work fine from there for my application.&lt;br&gt;
&lt;br&gt;
That being said, I would think there is some sort of &quot;default pathing&quot; that would permit the user to arrange the Matlab application .exe in the same folder as any data files and that those data files would be found on a &quot;relative path&quot; basis.&lt;br&gt;
&lt;br&gt;
Bill</description>
    </item>
  </channel>
</rss>

