<html>
<head>
<link href="mmres://user_interface_reference.css" rel="stylesheet" type="text/css">
<title>GETPROFILESTRING</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
   <div id="Description">
   <table cellpadding="0" cellspacing="0" border="0" width="100%" class="main">
      <tr> 
         <td valign="top" class="name">GETPROFILESTRING</td>
         <td valign="top" nowrap class="compatibility">&nbsp;</td>
      </tr>
      <tr>
         <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
      </tr>


    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Description</span>
<p>
Gets an initialization file entry. 
</p>

<p>
An initialization file assigns values to configuration variables, also known as entries, that are set when the system boots, the operating system comes up, or an application starts. An initialization file has the suffix INI; for example, boot.ini, Win32.ini. 
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Returns</span>
<p>
An entry in an initialization file, as a string. If there is no value, returns an empty string.
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Category</span>
<p>
System functions
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Function syntax</span><pre>GetProfileString(<i>ini</i>Path, section, entry)
</pre>    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">See also</span>
<p>
GetProfileSections, GetProfileString, SetProfileString
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Parameters</span>
<p>

</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Example</span><pre>&lt;h3&gt;GetProfileString Example&lt;/h3&gt;
Uses GetProfileString to get the value of timeout in an initialization file. 
Enter
the full path of your initialization file, and submit the form.
&lt;!--- If the form was submitted, it gets the initialization path and timeout 
value specified in the form ---&gt;
&lt;cfif Isdefined(&quot;Form.Submit&quot;)&gt;
   &lt;cfset IniPath = FORM.iniPath&gt;
   &lt;cfset Section = &quot;boot loader&quot;&gt;
   &lt;cfset timeout = GetProfileString(IniPath, Section, &quot;timeout&quot;)&gt;
   &lt;h4&gt;Boot Loader&lt;/h4&gt;
   &lt;!--- If no entry in an initialization file, nothing displays ---&gt;
   &lt;p&gt;Timeout is set to: &lt;cfoutput&gt;#timeout#&lt;/cfoutput&gt;.&lt;/p&gt;
&lt;/cfif&gt;
&lt;form action = &quot;getprofilestring.cfm&quot;&gt;
&lt;table cellspacing = &quot;2&quot; cellpadding = &quot;2&quot; border = &quot;0&quot;&gt;
   &lt;tr&gt;
       &lt;td&gt;Full Path of Init File&lt;/td&gt;
       &lt;td&gt;&lt;input type = &quot;Text&quot; name = &quot;IniPath&quot; value = &quot;C:\myboot.ini&quot;&gt;
      &lt;/td&gt;
   &lt;/tr&gt;
   &lt;tr&gt;
    &lt;td&gt;&lt;input type = &quot;Submit&quot; name = &quot;Submit&quot; value = &quot;Submit&quot;&gt;&lt;/td&gt;
    &lt;td&gt;&lt;/td&gt;
   &lt;/tr&gt;&lt;/table&gt;
&lt;/form&gt;
</pre>
         </td>
      </tr>
   </table>
   </div>
<div id="INIPATH">
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tr>  
<td valign="top" class="name">INIPATH</td>
  <td valign="top" nowrap class="compatibility">&nbsp;</td>
  </tr>
  <tr>
  <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
  </tr>


<p>Absolute path (drive, directory, filename, extension) of initialization file; for example, C:\boot.ini</p>

  </td>
  </tr>
  </table>
</div>
<div id="SECTION">
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tr>  
<td valign="top" class="name">SECTION</td>
  <td valign="top" nowrap class="compatibility">&nbsp;</td>
  </tr>
  <tr>
  <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
  </tr>


<p>Section of initialization file from which to extract information</p>

  </td>
  </tr>
  </table>
</div>
<div id="ENTRY">
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tr>  
<td valign="top" class="name">ENTRY</td>
  <td valign="top" nowrap class="compatibility">&nbsp;</td>
  </tr>
  <tr>
  <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
  </tr>


<p>Name of value to get</p>

  </td>
  </tr>
  </table>
</div>

  </body>
</html>
