# Excel cell

**URL:** <https://forum.uipath.com/t/excel-cell/703115>\
**Category:** Activities\
**Tags:** studio, excel, activities\
**Created:** [November 29, 2023, 3:15pm UTC](https://forum.uipath.com/t/excel-cell/703115 "2023-11-29T15:15:48Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pushpendra\_kowthavarapu](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pushpendra_kowthavarapu/32/473289_2.png) [@Pushpendra\_kowthavarapu](https://forum.uipath.com/u/Pushpendra_kowthavarapu)\
**Post date:** [November 29, 2023, 3:15pm UTC](https://forum.uipath.com/t/excel-cell/703115/1 "2023-11-29T15:15:48Z")

</div>

How to iterate the excel cell to write the data in each cell. Can someone help me with the syntax for this.

---

<div class="post-metadata">

**Author:** ![Gayathri\_Ramanathan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/gayathri_ramanathan/32/447592_2.png) [@Gayathri\_Ramanathan](https://forum.uipath.com/u/Gayathri_Ramanathan)\
**Post date:** [November 29, 2023, 4:02pm UTC](https://forum.uipath.com/t/excel-cell/703115/2 "2023-11-29T16:02:00Z")

</div>

1. Read the excel file usinh Read Range Activity and store it as a data table in the output
2. Use for each row activity to iterate through each row in the data table.
3. To write you can use Write Cell activity.

Please check and let me know if it works

@Pushpendra_kowthavarapu

---

<div class="post-metadata">

**Author:** ![Pushpendra\_kowthavarapu](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pushpendra_kowthavarapu/32/473289_2.png) [@Pushpendra\_kowthavarapu](https://forum.uipath.com/u/Pushpendra_kowthavarapu)\
**Post date:** [November 29, 2023, 5:10pm UTC](https://forum.uipath.com/t/excel-cell/703115/3 "2023-11-29T17:10:59Z")

</div>

What is the syntax do i need to write in cell .because I need to iterate below is the image reference

 ![17012778253712086145491943847837](https://global.discourse-cdn.com/uipath/original/4X/0/9/3/0939c7621c047a1ad12137cc326dbab08c477e2e.jpeg)

---

<div class="post-metadata">

**Author:** ![rikulsilva](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/rikulsilva/32/462189_2.png) [@rikulsilva](https://forum.uipath.com/u/rikulsilva)\
**Post date:** [November 29, 2023, 5:28pm UTC](https://forum.uipath.com/t/excel-cell/703115/4 "2023-11-29T17:28:47Z")

</div>

Hi @Pushpendra_kowthavarapu

Also, you can use Excel Scope activities

 ![image](https://global.discourse-cdn.com/uipath/original/4X/2/3/2/23216c65b6517a0e73ff6aa44ccfba09b6295e13.png)

---

<div class="post-metadata">

**Author:** ![Pushpendra\_kowthavarapu](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pushpendra_kowthavarapu/32/473289_2.png) [@Pushpendra\_kowthavarapu](https://forum.uipath.com/u/Pushpendra_kowthavarapu)\
**Post date:** [November 29, 2023, 5:33pm UTC](https://forum.uipath.com/t/excel-cell/703115/5 "2023-11-29T17:33:19Z")

</div>

If i check the auto increment, It works right?

---

<div class="post-metadata">

**Author:** ![rikulsilva](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/rikulsilva/32/462189_2.png) [@rikulsilva](https://forum.uipath.com/u/rikulsilva)\
**Post date:** [November 29, 2023, 5:39pm UTC](https://forum.uipath.com/t/excel-cell/703115/6 "2023-11-29T17:39:26Z")

</div>

Hi @Pushpendra_kowthavarapu

You can check the current row info using CurrentRow variable

The For Each Excel Row Activity doen’t produce a index variable

---

<div class="post-metadata">

**Author:** ![Gayathri\_Ramanathan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/gayathri_ramanathan/32/447592_2.png) [@Gayathri\_Ramanathan](https://forum.uipath.com/u/Gayathri_Ramanathan)\
**Post date:** [November 30, 2023, 1:40am UTC](https://forum.uipath.com/t/excel-cell/703115/7 "2023-11-30T01:40:02Z")

</div>

To make it simple, you can use a counter variable starting with 2, write cell and then increment the counter variable by 1.

@Pushpendra_kowthavarapu

---

<div class="post-metadata">

**Author:** ![Pushpendra\_kowthavarapu](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pushpendra_kowthavarapu/32/473289_2.png) [@Pushpendra\_kowthavarapu](https://forum.uipath.com/u/Pushpendra_kowthavarapu)\
**Post date:** [November 30, 2023, 3:52am UTC](https://forum.uipath.com/t/excel-cell/703115/8 "2023-11-30T03:52:28Z")

</div>

Could you help me with the intailizing the code.

---

<div class="post-metadata">

**Author:** ![Gayathri\_Ramanathan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/gayathri_ramanathan/32/447592_2.png) [@Gayathri\_Ramanathan](https://forum.uipath.com/u/Gayathri_Ramanathan)\
**Post date:** [November 30, 2023, 4:16am UTC](https://forum.uipath.com/t/excel-cell/703115/9 "2023-11-30T04:16:05Z")

</div>

Hi @Pushpendra_kowthavarapu

Please find the solution logic in the attachment. You can get the values of capital, weather and status and replace it in the write cell value parameter.

[TEST2.zip](https://forum.uipath.com/uploads/short-url/73kHqiipMnhul8Qhp8vopZNzn5L.zip) (8.4 KB)

Cheers

---

<div class="post-metadata">

**Author:** ![Pushpendra\_kowthavarapu](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pushpendra_kowthavarapu/32/473289_2.png) [@Pushpendra\_kowthavarapu](https://forum.uipath.com/u/Pushpendra_kowthavarapu)\
**Post date:** [November 30, 2023, 5:19am UTC](https://forum.uipath.com/t/excel-cell/703115/10 "2023-11-30T05:19:19Z")

</div>

The code you sent is working , but when i trying to do the same its not.

---

<div class="post-metadata">

**Author:** ![Gayathri\_Ramanathan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/gayathri_ramanathan/32/447592_2.png) [@Gayathri\_Ramanathan](https://forum.uipath.com/u/Gayathri_Ramanathan)\
**Post date:** [November 30, 2023, 5:21am UTC](https://forum.uipath.com/t/excel-cell/703115/11 "2023-11-30T05:21:30Z")

</div>

Could you please share your solution or snip ? @Pushpendra_kowthavarapu

---

<div class="post-metadata">

**Author:** ![Pushpendra\_kowthavarapu](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pushpendra_kowthavarapu/32/473289_2.png) [@Pushpendra\_kowthavarapu](https://forum.uipath.com/u/Pushpendra_kowthavarapu)\
**Post date:** [November 30, 2023, 5:29am UTC](https://forum.uipath.com/t/excel-cell/703115/12 "2023-11-30T05:29:39Z")

</div>

[Main.xaml](https://forum.uipath.com/uploads/short-url/kLdG5ELL8kMJOkaxkuzGZ7E2Fxb.xaml) (21.1 KB)

---

<div class="post-metadata">

**Author:** ![Gayathri\_Ramanathan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/gayathri_ramanathan/32/447592_2.png) [@Gayathri\_Ramanathan](https://forum.uipath.com/u/Gayathri_Ramanathan)\
**Post date:** [November 30, 2023, 6:32am UTC](https://forum.uipath.com/t/excel-cell/703115/13 "2023-11-30T06:32:06Z")

</div>

I am unable to open the file. Please share it as a zip with Project.json or let me know the issue that you are facing in detail so that I can help @Pushpendra_kowthavarapu

---

<div class="post-metadata">

**Author:** ![Gayathri\_Ramanathan](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/gayathri_ramanathan/32/447592_2.png) [@Gayathri\_Ramanathan](https://forum.uipath.com/u/Gayathri_Ramanathan)\
**Post date:** [November 30, 2023, 6:58am UTC](https://forum.uipath.com/t/excel-cell/703115/14 "2023-11-30T06:58:13Z")

</div>

@Pushpendra_kowthavarapu , just checked your code. Please give the index variable that you have created in the output of for each row in the Index parameter

 ![image](https://global.discourse-cdn.com/uipath/original/4X/8/b/9/8b9e038094de2f004cd2a7e8ded356f2d551e120.png)

 ![image](https://global.discourse-cdn.com/uipath/original/4X/9/6/6/966d4b2ef5ae36e9abd7155e40844274935a737e.png)

Cheers

---

<div class="post-metadata">

**Author:** ![Pushpendra\_kowthavarapu](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pushpendra_kowthavarapu/32/473289_2.png) [@Pushpendra\_kowthavarapu](https://forum.uipath.com/u/Pushpendra_kowthavarapu)\
**Post date:** [November 30, 2023, 7:35am UTC](https://forum.uipath.com/t/excel-cell/703115/15 "2023-11-30T07:35:28Z")

</div>

Thanks for the solution gayathri.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/system/32/182466_2.png) [@system](https://forum.uipath.com/u/system)\
**Post date:** [December 3, 2023, 7:35am UTC](https://forum.uipath.com/t/excel-cell/703115/16 "2023-12-03T07:35:36Z")

</div>

Closed on December 3, 2023, 7:35am UTC

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.
