<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Dimas,<br>
  There are two parts to generating a template for a new component. <br>
<br>
  First, you create a new *.tmf (trnsys model file) in the Studio. You
enter a Type number and you define the inputs, outputs, and parameters.
Then you save the new component (at which point a new icon will appear
in the Simulation Studio direct access tree and the *.tmf and *.bmp
files will be saved to the ..\Trnsys17\Studio\Proformas\ directory.
This process only creates the proforma.<br>
<br>
  Second, open your proforma and select "Export As... Fortran" from the
File menu. At this point either a *.for file (if you are using
Trnsys16) or a *.f90 file (if you are using Trnsys170 will be generated
and the Studio will attempt to open your Fortran compiler. If it does
not succeed, open your compiler manually, create or import a workspace
project that is appropriate to your compiler (a *.dsw workspace if you
are using the Compaq compiler or a *.sln file if you are using the
Intel compiler). Edit the Fortran code to add your equations, compile,
then link.<br>
<br>
Best,<br>
 david<br>
<br>
<br>
On 10/12/2010 01:14, Dimas Firmanda Al Riza wrote:
<blockquote
 cite="mid:AANLkTimW5Jtrn5XEzhi1SNdMd7dPt4hJJgYeSkJgaGfc@mail.gmail.com"
 type="cite">God day to you!
  <div><br>
  </div>
  <div>I try to make a new component, </div>
  <div>after I exported to .for and make new folder (Mycomponent)</div>
  <div>why the folder does not appear in windows explorer, it is appear
only in Simulation Studio tree?</div>
  <div>I try to search .for file in the windows explorer, but even the
folder My component can't be found in TRNSYS directory</div>
  <div>Do you know about this?</div>
  <div><br>
  </div>
  <div>Thank you so much</div>
  <br>
  <div class="gmail_quote">On Tue, Oct 12, 2010 at 1:17 AM, David
BRADLEY <span dir="ltr"><<a moz-do-not-send="true"
 href="mailto:d.bradley@tess-inc.com">d.bradley@tess-inc.com</a>></span>
wrote:<br>
  <blockquote class="gmail_quote"
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
    <div bgcolor="#ffffff" text="#000000">Marion,<br>
 Check to make sure that the version of trnsys.h that you are using has
the TYPECK, getSimulationTimeStep, and getSimulationStartTime functions
exported properly for C++. I'm not familiar with the "send client
message" routine; make sure that you have added whatever library that
is part of to your Type as well.<br>
Regards,<br>
 David
    <div>
    <div class="h5"><br>
    <br>
    <br>
On 10/8/2010 16:03, Kerl, Marion (SCR US EXT) wrote:
    </div>
    </div>
    <blockquote type="cite">
      <div>
      <div class="h5">
      <p dir="LTR"><span lang="en-us"><font face="Calibri">Hey everyone,</font></span></p>
      <p dir="LTR"><span lang="en-us"><font face="Calibri">I</font></span><span
 lang="en-us"><font face="Calibri"> want to create my own new
component. I followed the manual and create a new component  in the
TRNSYS Studio.</font></span><span lang="en-us"> <font face="Calibri">Following
that,</font></span><span lang="en-us"> <font face="Calibri">I</font></span><span
 lang="en-us"><font face="Calibri"> exported the components via the</font></span><span
 lang="en-us"> <font face="Calibri">“</font></span><span lang="en-us"><font
 face="Calibri">Export to C++</font></span><span lang="en-us"><font
 face="Calibri">”</font></span><span lang="en-us"><font face="Calibri">.

      </font></span></p>
      <p dir="LTR"><span lang="en-us"><font face="Calibri">Then</font></span><span
 lang="en-us"> <font face="Calibri">I</font></span><span lang="en-us"><font
 face="Calibri"> created a project in Visual Studio and added the
exported cpp-file and the TRNSYS.h to my project</font></span><span
 lang="en-us"><font face="Calibri">.</font></span></p>
      <p dir="LTR"><span lang="en-us"><font face="Calibri">When</font></span><span
 lang="en-us"> <font face="Calibri">I</font></span><span lang="en-us"><font
 face="Calibri"> want to make a build of my project,</font></span><span
 lang="en-us"> <font face="Calibri">I</font></span><span lang="en-us"><font
 face="Calibri"> get these error messages:</font></span></p>
      <ul dir="LTR">
        <ul dir="LTR">
          <p dir="LTR"><span lang="en-us"></span><span lang="en-us"></span><span
 lang="en-us"><font face="Consolas" size="2">1>Link:</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1>    
Creating
library C:\TRNSYS16_1\Studio\Proformas\My
components\compTYP201\Debug\compTYP201.lib and object
C:\TRNSYS16_1\Studio\Proformas\My
components\compTYP201\Debug\compTYP201.exp</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1>Type201.obj
:
error LNK2019: unresolved external symbol "int __cdecl
sendclientmessage(int const *,int const *)"
(?sendclientmessage@@YAHPBH0@Z) referenced in function "int __cdecl
sendclienterror(int const *,int const *)" (?sendclienterror@@YAHPBH0@Z)</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1>Type201.obj
:
error LNK2019: unresolved external symbol
__imp__TRNSYSFUNCTIONS_mp_GETSIMULATIONTIMESTEP referenced in function
_TYPE201</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1>Type201.obj
:
error LNK2019: unresolved external symbol
__imp__TRNSYSFUNCTIONS_mp_GETSIMULATIONSTARTTIME referenced in function
_TYPE201</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1>Type201.obj
:
error LNK2019: unresolved external symbol __imp__TYPECK referenced in
function _TYPE201</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1>C:\TRNSYS16_1\Studio\Proformas\My
components\compTYP201\Debug\compTYP201.dll
: fatal error LNK1120: 4
unresolved externals</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1></font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1>Build
FAILED.</font></span></p>
          <p dir="LTR"><span lang="en-us"><font face="Consolas" size="2">1></font></span></p>
        </ul>
      </ul>
      <p dir="LTR"><span lang="en-us"></span></p>
      <p dir="LTR"><span lang="en-us"><font face="Calibri">What</font></span><span
 lang="en-us"><font face="Calibri">’</font></span><span lang="en-us"><font
 face="Calibri">s wrong? Are there any files in my project missing?</font></span></p>
      <p dir="LTR"><span lang="en-us"><font face="Calibri">Thank you in
advance.</font></span></p>
      <p dir="LTR"><span lang="en-us"><font face="Calibri">Regards,</font></span></p>
      <p dir="LTR"><span lang="en-us"><font face="Calibri">Marion</font></span><span
 lang="en-us"></span></p>
      <p dir="LTR"><span lang="en-us"></span></p>
      <p dir="LTR"><span lang="en-us"></span></p>
      </div>
      </div>
      <pre><fieldset></fieldset>
_______________________________________________
TRNSYS-users mailing list
<a moz-do-not-send="true" href="mailto:TRNSYS-users@cae.wisc.edu"
 target="_blank">TRNSYS-users@cae.wisc.edu</a>
<a moz-do-not-send="true"
 href="https://www-old.cae.wisc.edu/mailman/listinfo/trnsys-users"
 target="_blank">https://www-old.cae.wisc.edu/mailman/listinfo/trnsys-users</a>
  </pre>
    </blockquote>
    <br>
    <pre cols="72">-- 
***************************
David BRADLEY
Principal
Thermal Energy Systems Specialists, LLC
22 North Carroll Street - suite 370
Madison, WI  53703 USA

P:+1.608.274.2577
F:+1.608.278.1475
<a moz-do-not-send="true" href="mailto:d.bradley@tess-inc.com"
 target="_blank">d.bradley@tess-inc.com</a>

<a moz-do-not-send="true" href="http://www.tess-inc.com" target="_blank">http://www.tess-inc.com</a>
<a moz-do-not-send="true" href="http://www.trnsys.com" target="_blank">http://www.trnsys.com</a></pre>
    </div>
    <br>
_______________________________________________<br>
TRNSYS-users mailing list<br>
    <a moz-do-not-send="true" href="mailto:TRNSYS-users@cae.wisc.edu">TRNSYS-users@cae.wisc.edu</a><br>
    <a moz-do-not-send="true"
 href="https://www-old.cae.wisc.edu/mailman/listinfo/trnsys-users"
 target="_blank">https://www-old.cae.wisc.edu/mailman/listinfo/trnsys-users</a><br>
    <br>
  </blockquote>
  </div>
  <br>
  <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
TRNSYS-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:TRNSYS-users@cae.wisc.edu">TRNSYS-users@cae.wisc.edu</a>
<a class="moz-txt-link-freetext" href="https://www-old.cae.wisc.edu/mailman/listinfo/trnsys-users">https://www-old.cae.wisc.edu/mailman/listinfo/trnsys-users</a>
  </pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">-- 
***************************
David BRADLEY
Principal
Thermal Energy Systems Specialists, LLC
22 North Carroll Street - suite 370
Madison, WI  53703 USA

P:+1.608.274.2577
F:+1.608.278.1475
<a class="moz-txt-link-abbreviated" href="mailto:d.bradley@tess-inc.com">d.bradley@tess-inc.com</a>

<a class="moz-txt-link-freetext" href="http://www.tess-inc.com">http://www.tess-inc.com</a>
<a class="moz-txt-link-freetext" href="http://www.trnsys.com">http://www.trnsys.com</a></pre>
</body>
</html>