# Variables in INI file

**URL:** https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102
**Category:** Discussion
**Created:** [February 6, 2009, 9:24am UTC](https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102 "2009-02-06T09:24:43Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [February 6, 2009, 9:24am UTC](https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102/1 "2009-02-06T09:24:43Z")

</div>

Is there a way to have a "dynamic" INI file so I can use %VARIABLE% instead of VALUE, for example

NEW\_VAR=%VARIABLE%

&nbsp;

I am using the Set Variable Action to set&nbsp;variable %VIEW%, then I use %VIEW% in the INI file, but the value of %VIEW% isn't put in the variables loaded from the INI file.

The errors I get are like: Can't find path M:\%VIEW%\etc... (I would expect the path to be M:\myView\etc...)

&nbsp;

Does anyone have a solution for this?

&nbsp;

Regards,

Magnus G

---

<div class="post-metadata">

### Author: ![richardfloor](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/r/41988e/32.png) [@richardfloor](https://www.finalbuilder.com/forums/u/richardfloor)
#### Post date: [February 11, 2009, 7:48am UTC](https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102/2 "2009-02-11T07:48:30Z")

</div>

Hi Magnus,   
  
 The thing you want to do is possible. I use it too. I have a ini file and in the file i have a line like   
  
 Opl\_Build\_DcpOutputDir=%EMC%%Opl\_Path\_Extension%\output\dcp   
  
 The variables in %EMC%%Opl\_Path\_Extension% are always changed to the values that are set in other places or also come from the ini file. In the action to set the variable i have the option “Epand Expression” checked.   
  
 I hope this answer helps.

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [February 11, 2009, 9:36am UTC](https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102/3 "2009-02-11T09:36:47Z")

</div>

Hi Magnas/Richard   
  
 Only the entry name and section names are expanded… the actual values read in are not. This build has a new property to support doing just that :   
  
 [https://www.finalbuilder.com/downloads/finalbuilder/620/FB620\_1314.exe](https://www.finalbuilder.com/downloads/finalbuilder/620/FB620_1314.exe)

---

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [February 18, 2009, 8:15am UTC](https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102/4 "2009-02-18T08:15:44Z")

</div>

Hi Richard and Vincent.

Thank you for your help and support.

I have downloaded the new version but I really don't understand what to look for. Where do I find this new property? And how do I do to make it work? Is it a new Action?

&nbsp;

Regards,

Magnus

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [February 20, 2009, 12:36pm UTC](https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102/5 "2009-02-20T12:36:12Z")

</div>

Hi Magnus

The new property is on the Read Ini Action :

![readini.jpg](https://www.finalbuilder.com/forums/uploads/default/original/1X/9d71b42151e2073b61ee6f862c27e066c996f29b.jpeg)

---

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [February 20, 2009, 9:05am UTC](https://www.finalbuilder.com/forums/t/variables-in-ini-file/1102/6 "2009-02-20T09:05:30Z")

</div>

Ok, thank you. I was using the "Load Variables from INI" action. That's why I couldn't find it :)

Does the "Read INI File" action only read one variable at the time or could it be used to load all variables at the same time?

/Magnus
