# Copy a text parameter to a number parameter

**URL:** <https://forum.dynamobim.com/t/copy-a-text-parameter-to-a-number-parameter/23320>\
**Category:** Revit\
**Created:** [July 3, 2018, 10:29am UTC](https://forum.dynamobim.com/t/copy-a-text-parameter-to-a-number-parameter/23320 "2018-07-03T10:29:01Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![p.sandford](https://avatars.discourse-cdn.com/v4/letter/p/f08c70/32.png) [@p.sandford](https://forum.dynamobim.com/u/p.sandford)\
**Post date:** [July 3, 2018, 10:29am UTC](https://forum.dynamobim.com/t/copy-a-text-parameter-to-a-number-parameter/23320/1 "2018-07-03T10:29:01Z")

</div>

![Snip%201](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/c/d/cdeca4823c72682e172a9a9a7c5060e1ee3649ac.JPG)

Hello all, I have been dabbling with Dynamo for a little while with not much success but hopefully have a real need for it now (well hopefully it’ll be able to help me).

I created a project parameter as text and for various reasons I now need to run a forumla to add two numbers together but as it’s text you can’t. I have achieved the image attached but cannot get it to write to the new parameter. Is there a way to copy between parameters of different types?

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![m.rijsmus](https://avatars.discourse-cdn.com/v4/letter/m/6f9a4e/32.png) [@m.rijsmus](https://forum.dynamobim.com/u/m.rijsmus)\
**Post date:** [July 3, 2018, 10:33am UTC](https://forum.dynamobim.com/t/copy-a-text-parameter-to-a-number-parameter/23320/2 "2018-07-03T10:33:23Z")

</div>

![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/f/9/f91e67e169d6c35b4733e6afe4c13d01ae8cbe63.png)

---

<div class="post-metadata">

**Author:** ![p.sandford](https://avatars.discourse-cdn.com/v4/letter/p/f08c70/32.png) [@p.sandford](https://forum.dynamobim.com/u/p.sandford)\
**Post date:** [July 3, 2018, 11:49am UTC](https://forum.dynamobim.com/t/copy-a-text-parameter-to-a-number-parameter/23320/3 "2018-07-03T11:49:49Z")

</div>

Hi m.rijsmus,

Thanks for the response, as mentioned I’m pretty new to this so I’m not sure where what you have detailed would fit into my process, any assistance would be gratefully received.

Thanks

---

<div class="post-metadata">

**Author:** ![M.Perez](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/m.perez/32/49821_2.png) [@M.Perez](https://forum.dynamobim.com/u/M.Perez)\
**Post date:** [July 3, 2018, 11:59am UTC](https://forum.dynamobim.com/t/copy-a-text-parameter-to-a-number-parameter/23320/4 "2018-07-03T11:59:34Z")

</div>

If your problem is that you can not write the value because it is a String and not a Number just place it in between. After Element.GetParameterValueByName and before Element.SetParameterByName

---

<div class="post-metadata">

**Author:** ![m.rijsmus](https://avatars.discourse-cdn.com/v4/letter/m/6f9a4e/32.png) [@m.rijsmus](https://forum.dynamobim.com/u/m.rijsmus)\
**Post date:** [July 3, 2018, 12:04pm UTC](https://forum.dynamobim.com/t/copy-a-text-parameter-to-a-number-parameter/23320/5 "2018-07-03T12:04:19Z")

</div>

![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/0/a/0a6ab29b6da1104532267810c773a3a83c755e05.png)
