# Synchronize between CSV files and dynamo

**URL:** <https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372>\
**Category:** Revit\
**Tags:** revit, dynamo\
**Created:** [February 5, 2020, 1:19pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372 "2020-02-05T13:19:50Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![MAIA17112](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@MAIA17112](https://forum.dynamobim.com/u/MAIA17112)\
**Post date:** [February 5, 2020, 1:19pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/1 "2020-02-05T13:19:50Z")

</div>

Hi, I have a problem when I import data from CSV file and then when I make any updates in it it 's not updating on dynamo directly which means I need to import it again to read updates. How I can make synchronize between files and dynamo. I used dynamo 2.3 and Revit 2019.

---

<div class="post-metadata">

**Author:** ![a.koltakovADRC7](https://avatars.discourse-cdn.com/v4/letter/a/54ee81/32.png) [@a.koltakovADRC7](https://forum.dynamobim.com/u/a.koltakovADRC7)\
**Post date:** [February 5, 2020, 3:05pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/2 "2020-02-05T15:05:48Z")

</div>

your must keep data from file in families and in file data at the same time.  
What is primary: datas in file or datas in revit? i have a solution for sync key shchedule with excel data. But there is a big problem: what is primary? If I make changes in file and revit project at the same time.  
Alternatively, you can transfer data from a file to the Extensible Storage field in family and store data there.  
Your task has no easy solution

---

<div class="post-metadata">

**Author:** ![LievX](https://avatars.discourse-cdn.com/v4/letter/l/7ea924/32.png) [@LievX](https://forum.dynamobim.com/u/LievX)\
**Post date:** [February 5, 2020, 5:54pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/3 "2020-02-05T17:54:26Z")

</div>

what I do with CSV files in dynamo is: I freeze a node to prevent any changes to be done, then I change the bool value in the “transpose” option of the “Import CSV” node, then, unfreeze, change again the boolean option and run the graph… I don’t know why csv is not updated automatically, but it’s no need to load the file again

---

<div class="post-metadata">

**Author:** ![Michael\_Kirschner2](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/michael_kirschner2/32/75576_2.png) [@Michael\_Kirschner2](https://forum.dynamobim.com/u/Michael_Kirschner2)\
**Post date:** [February 5, 2020, 9:41pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/4 "2020-02-05T21:41:11Z")

</div>

If you use the File.FromPath node this creates a watcher which will update the graph whenever the file changes on disk.  
[https://dictionary.dynamobim.com/#/Core/File/Action/File.FromPath](https://dictionary.dynamobim.com/#/Core/File/Action/File.FromPath)

---

<div class="post-metadata">

**Author:** ![MAIA17112](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@MAIA17112](https://forum.dynamobim.com/u/MAIA17112)\
**Post date:** [February 6, 2020, 1:17pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/5 "2020-02-06T13:17:30Z")

</div>

maybe I need a python script to solve it

---

<div class="post-metadata">

**Author:** ![Brendan\_Cassidy](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/brendan_cassidy/32/7685_2.png) [@Brendan\_Cassidy](https://forum.dynamobim.com/u/Brendan_Cassidy)\
**Post date:** [February 6, 2020, 2:10pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/6 "2020-02-06T14:10:36Z")

</div>

You could use a path through node with your file path as the element to be sent through and a date/time input as the other input selection.

This will then force it to re send your path and make the other nodes update.

---

<div class="post-metadata">

**Author:** ![MAIA17112](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@MAIA17112](https://forum.dynamobim.com/u/MAIA17112)\
**Post date:** [February 7, 2020, 11:16am UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/7 "2020-02-07T11:16:24Z")

</div>

> [@Brendan\_Cassidy](#):
>
> file path as the element

how I can use file path as the element?

---

<div class="post-metadata">

**Author:** ![Deniz\_Maral](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/deniz_maral/32/80323_2.png) [@Deniz\_Maral](https://forum.dynamobim.com/u/Deniz_Maral)\
**Post date:** [February 7, 2020, 11:24am UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/8 "2020-02-07T11:24:23Z")

</div>

File path \> File.FromPath

---

<div class="post-metadata">

**Author:** ![MAIA17112](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@MAIA17112](https://forum.dynamobim.com/u/MAIA17112)\
**Post date:** [February 7, 2020, 12:07pm UTC](https://forum.dynamobim.com/t/synchronize-between-csv-files-and-dynamo/46372/9 "2020-02-07T12:07:12Z")

</div>

yes deniz I know but I think this problem in dynamo 2.3 when I try 1.3 every think was okay, but in 2.3 version I need to load file txt or excel and etc… to refresh data. Now I am trying to refresh it by python but I have errors in python code.

# Enable Python support and load DesignScript library

import clr  
clr.AddReference(‘ProtoGeometry’)  
from Autodesk.DesignScript.Geometry import \*  
import time,datetime

# The inputs to this node will be stored as a list in the IN variables.

dataEnteringNode = IN  
tex=IN[0]  
time=[1]

# Place your code below this line

f=open(tex, “r”)  
if f.mode == ‘r’:  
contents =f.read()  
print(contents)  
ts = time.time()  
timestamp = datetime.datetime.fromtimestamp(ts).strftime(’%Y-%m-%d %H:%M:%S’)  
precursor ="[" timestamp "] --\> "

# Assign your output to the OUT variable.

OUT = contents

just I try to refresh time of saving file by python can you help me in this?
