# \#assign

**URL:** https://forum.uipath.com/tag/assign/1611.md

[Latest](https://forum.uipath.com/latest.md) · [Categories](https://forum.uipath.com/categories.md) · [Tags](https://forum.uipath.com/tags.md)

---

## [String directory bug](https://forum.uipath.com/t/string-directory-bug/4951490)

<div class="topic-metadata">

**Author:** [@aqiffm](https://forum.uipath.com/u/aqiffm)\
**Replies:** 8\
**Last updated:** [August 26, 2025, 7:34am UTC](https://forum.uipath.com/t/string-directory-bug/4951490 "2025-08-26T07:34:03Z")

</div>

I have string for a directory bug which is really weird. Below is the sample of the bug Actual string is a path directory that I am not willing to show

---

## [Extract substring within Brackets](https://forum.uipath.com/t/extract-substring-within-brackets/2865999)

<div class="topic-metadata">

**Author:** [@Yugal\_Raju](https://forum.uipath.com/u/Yugal_Raju)\
**Replies:** 3\
**Last updated:** [June 26, 2025, 3:04pm UTC](https://forum.uipath.com/t/extract-substring-within-brackets/2865999 "2025-06-26T15:04:33Z")

</div>

Hello , I have string variable ; 1/6( 12) , But I only require 12 from with the bracket , please help me split and get the required substring. Thank you

---

## [UiPath Solution: Remove Duplciates from String and sort them](https://forum.uipath.com/t/uipath-solution-remove-duplciates-from-string-and-sort-them/2820237)

<div class="topic-metadata">

**Author:** [@pavithra\_pavi](https://forum.uipath.com/u/pavithra_pavi)\
**Replies:** 2\
**Last updated:** [May 15, 2025, 2:50pm UTC](https://forum.uipath.com/t/uipath-solution-remove-duplciates-from-string-and-sort-them/2820237 "2025-05-15T14:50:55Z")

</div>

This video demonstrates how to efficiently remove duplicate values from a string and sort them alphabetically using UiPath. The step-by-step tutorial covers the use of string manipulation and LINQ methods to achieve the …

---

## [Zendesk Tickets - get field names + data](https://forum.uipath.com/t/zendesk-tickets-get-field-names-data/772420)

<div class="topic-metadata">

**Author:** [@sam.willson](https://forum.uipath.com/u/sam.willson)\
**Replies:** 1\
**Last updated:** [October 11, 2024, 2:00pm UTC](https://forum.uipath.com/t/zendesk-tickets-get-field-names-data/772420 "2024-10-11T14:00:40Z")

</div>

Hey everyone, I’m wondering if anyone may be able to help. I’m in the process of iterating through a selection of Zendesk tickets (which I’ve gathered using the “Search” activity). Would anyone know how to gather data …

---

## [Error while running the bot, kindly help](https://forum.uipath.com/t/error-while-running-the-bot-kindly-help/768711)

<div class="topic-metadata">

**Author:** [@Milan\_Vora](https://forum.uipath.com/u/Milan_Vora)\
**Replies:** 5\
**Last updated:** [September 24, 2024, 6:54am UTC](https://forum.uipath.com/t/error-while-running-the-bot-kindly-help/768711 "2024-09-24T06:54:32Z")

</div>

Please help, I am getting this below mentioned error. 24.10.4-beta.17693+Branch.release-v24.10.4.Sha.23194d406b66452fd1dd41226b57a4ce8b842719.23194d406b66452fd1dd41226b57a4ce8b842719 Source: Assign: Find Unique Branch …

---

## [How to Assign Last Label Name to Variable or "null" if Empty in UiPath](https://forum.uipath.com/t/how-to-assign-last-label-name-to-variable-or-null-if-empty-in-uipath/735780)

<div class="topic-metadata">

**Author:** [@samantha\_shah](https://forum.uipath.com/u/samantha_shah)\
**Replies:** 9\
**Last updated:** [April 19, 2024, 7:24pm UTC](https://forum.uipath.com/t/how-to-assign-last-label-name-to-variable-or-null-if-empty-in-uipath/735780 "2024-04-19T19:24:32Z")

</div>

Hello UiPath Community, I am working on a project involving email communication analysis, where I extract labels from a stream of emails, process them, and queue different data types. I need to assign the last label’s n…

---

## [How to Assign and Read a Text File?](https://forum.uipath.com/t/how-to-assign-and-read-a-text-file/735647)

<div class="topic-metadata">

**Author:** [@Jackson\_Hew](https://forum.uipath.com/u/Jackson_Hew)\
**Replies:** 11\
**Last updated:** [April 19, 2024, 10:04am UTC](https://forum.uipath.com/t/how-to-assign-and-read-a-text-file/735647 "2024-04-19T10:04:53Z")

</div>

Hi, I wish to read a text file and write into a CSV file. I have manage to do the flow within the image below and it works fine. But this method of reading and writing into a specific CSV is hardcoded. I want to le…

---

## [Assign: The datetime represented by the string '31/12/2023 11:50:00' is not supported in the calendar System.Globalization.Gregorian.Calendar](https://forum.uipath.com/t/assign-the-datetime-represented-by-the-string-31-12-2023-1100-is-not-supported-in-the-calendar-system-globalization-gregorian-calendar/726568)

<div class="topic-metadata">

**Author:** [@Chen0000](https://forum.uipath.com/u/Chen0000)\
**Replies:** 5\
**Last updated:** [March 14, 2024, 5:54am UTC](https://forum.uipath.com/t/assign-the-datetime-represented-by-the-string-31-12-2023-1100-is-not-supported-in-the-calendar-system-globalization-gregorian-calendar/726568 "2024-03-14T05:54:31Z")

</div>

Hello Community I have a excel file with 2 columns, ID and test\_datetime. The format for the test\_datetime column is Custom dd/mm/yyyy hh:mm:ss and I cannot change this. I did a read range activity into a datatable. For…

---

## [Can not assign 'strNewCol' to '\_dtaBase\_out.Columns(strOriginalCol).ColumnName'](https://forum.uipath.com/t/can-not-assign-strnewcol-to-dtabase-out-columns-stroriginalcol-columnname/723986)

<div class="topic-metadata">

**Author:** [@k58\_Vu\_Minh\_Nguyet](https://forum.uipath.com/u/k58_Vu_Minh_Nguyet)\
**Replies:** 3\
**Last updated:** [March 4, 2024, 2:28am UTC](https://forum.uipath.com/t/can-not-assign-strnewcol-to-dtabase-out-columns-stroriginalcol-columnname/723986 "2024-03-04T02:28:24Z")

</div>

I run it perfectly in other project. But this time it came across error: Can not assign ‘strNewCol’ to ‘\_dtaBase\_out.Columns(strOriginalCol).ColumnName’.

---

## [How to add numbert to string with decimal](https://forum.uipath.com/t/how-to-add-numbert-to-string-with-decimal/723095)

<div class="topic-metadata">

**Author:** [@AaronMark](https://forum.uipath.com/u/AaronMark)\
**Replies:** 8\
**Last updated:** [February 28, 2024, 10:33am UTC](https://forum.uipath.com/t/how-to-add-numbert-to-string-with-decimal/723095 "2024-02-28T10:33:01Z")

</div>

Hi everyone, while browsing a web tab, I need to collect an amount from a page. This amount is collected as a “string”, and contains decimals. ex: €35.00 I need to add €15 to this string, to use it later. I removed …

---

## [Extracting Text From Email Body (After Keyword) - Multi Line](https://forum.uipath.com/t/extracting-text-from-email-body-after-keyword-multi-line/714430)

<div class="topic-metadata">

**Author:** [@sam.willson](https://forum.uipath.com/u/sam.willson)\
**Replies:** 6\
**Last updated:** [January 23, 2024, 5:16pm UTC](https://forum.uipath.com/t/extracting-text-from-email-body-after-keyword-multi-line/714430 "2024-01-23T17:16:49Z")

</div>

Hi there, I’m currently having issues extracting multi-line text from an email body, after a key word (including that key word). E.g, my email looks like so: Client No: 1234 Client Name: Mr Smith Client Response: -…

---

## [Assignの値が上手く取れない](https://forum.uipath.com/t/assign/708494)

<div class="topic-metadata">

**Author:** [@anon81414615](https://forum.uipath.com/u/anon81414615)\
**Replies:** 4\
**Last updated:** [December 27, 2023, 1:56am UTC](https://forum.uipath.com/t/assign/708494 "2023-12-27T01:56:06Z")

</div>

お世話になっております。 売上関係の報告するためのロボットを作成したのですが、 一部、値がきちんと取得できない不具合が発生しています。 自分でも設定を確認しているのですが、原因が分からず困っています。 不具合が発生しているフローの一部は以下のようになっています。 Assign transactionIDsAsString ＝ String.Join(“, “, uniqueTransactionIDs) ↓ Assign …

---

## [Error BC30182: Type Expected while creating DataTable](https://forum.uipath.com/t/error-bc30182-type-expected-while-creating-datatable/651683)

<div class="topic-metadata">

**Author:** [@JavRip](https://forum.uipath.com/u/JavRip)\
**Replies:** 4\
**Last updated:** [October 20, 2023, 12:07pm UTC](https://forum.uipath.com/t/error-bc30182-type-expected-while-creating-datatable/651683 "2023-10-20T12:07:00Z")

</div>

Hi there, I’m doing the “Generate Yearly Report” assignment from the UiPath Academy. While trying to merge all the monthly reports (csv files) I get an error all the time. I’m trying to create a new datatable with an a…

---

## [Convert ANY document into Excel](https://forum.uipath.com/t/convert-any-document-into-excel/580949)

<div class="topic-metadata">

**Author:** [@pavithra\_pavi](https://forum.uipath.com/u/pavithra_pavi)\
**Replies:** 0\
**Last updated:** [September 8, 2023, 2:49pm UTC](https://forum.uipath.com/t/convert-any-document-into-excel/580949 "2023-09-08T14:49:52Z")

</div>

Hi All, Check out my latest video on How to convert any type of document format into EXCEL. The video navigates on explaining how to write VBA how to invoke VBA in UiPath How to pass parameters to VBA script LINK :…

---

## [Insert an Asset Value into an Assign](https://forum.uipath.com/t/insert-an-asset-value-into-an-assign/573787)

<div class="topic-metadata">

**Author:** [@sam.willson](https://forum.uipath.com/u/sam.willson)\
**Replies:** 2\
**Last updated:** [August 18, 2023, 8:52am UTC](https://forum.uipath.com/t/insert-an-asset-value-into-an-assign/573787 "2023-08-18T08:52:04Z")

</div>

Hi all, I’m just wondering if anyone knows if it’s possible to insert an Asset value/variable into an Assign? E.g my current assign is as follows: DataTable2 = DataTable1.AsEnumerable().Take(500).CopyToDataTable Howe…

---

## [How to TryCatch System.FormatException for Assign: String date format](https://forum.uipath.com/t/how-to-trycatch-system-formatexception-for-assign-string-date-format/553672)

<div class="topic-metadata">

**Author:** [@Nyx](https://forum.uipath.com/u/Nyx)\
**Replies:** 6\
**Last updated:** [June 13, 2023, 2:23pm UTC](https://forum.uipath.com/t/how-to-trycatch-system-formatexception-for-assign-string-date-format/553672 "2023-06-13T14:23:08Z")

</div>

I have tried the below TryCatch but it still gives me the same error

---

## [How to initialize a queuing element without using the orchestrator component and create fields and assign a value](https://forum.uipath.com/t/how-to-initialize-a-queuing-element-without-using-the-orchestrator-component-and-create-fields-and-assign-a-value/545210)

<div class="topic-metadata">

**Author:** [@pavithra\_pavi](https://forum.uipath.com/u/pavithra_pavi)\
**Replies:** 0\
**Last updated:** [May 16, 2023, 7:15am UTC](https://forum.uipath.com/t/how-to-initialize-a-queuing-element-without-using-the-orchestrator-component-and-create-fields-and-assign-a-value/545210 "2023-05-16T07:15:00Z")

</div>

Hello Everyone, Im back with a more interesting topic and problem walkthrough on UiPath is “How to initialize a queuing element without using the orchestrator component and create fields and assign a value” topic cover…

---

## [Input string was not in a correct format -Get text activity](https://forum.uipath.com/t/input-string-was-not-in-a-correct-format-get-text-activity/544728)

<div class="topic-metadata">

**Author:** [@Paddi](https://forum.uipath.com/u/Paddi)\
**Replies:** 6\
**Last updated:** [May 15, 2023, 3:08am UTC](https://forum.uipath.com/t/input-string-was-not-in-a-correct-format-get-text-activity/544728 "2023-05-15T03:08:41Z")

</div>

Hi all, I’m trying to get text from the website and use the page number as a counter in the loop. And the error ‘Input string was not in a correct format’ would sometimes occurs which I’m confused cause it does not occu…

---

## [How to get the date of the previous business day?](https://forum.uipath.com/t/how-to-get-the-date-of-the-previous-business-day/539158)

<div class="topic-metadata">

**Author:** [@Betul\_Dundar](https://forum.uipath.com/u/Betul_Dundar)\
**Replies:** 4\
**Last updated:** [April 26, 2023, 6:56am UTC](https://forum.uipath.com/t/how-to-get-the-date-of-the-previous-business-day/539158 "2023-04-26T06:56:47Z")

</div>

I have a string variable named ‘str\_date’ which contains a date and time in the format of ‘20.12.2022 15:04:25’. How can I add 1 month to this date, and get the date of the previous business day? Can you provide a single…

---

## ["Assign" keeps showing the name doesn't exist](https://forum.uipath.com/t/assign-keeps-showing-the-name-doesnt-exist/533223)

<div class="topic-metadata">

**Author:** [@108305006](https://forum.uipath.com/u/108305006)\
**Replies:** 15\
**Last updated:** [April 7, 2023, 2:16am UTC](https://forum.uipath.com/t/assign-keeps-showing-the-name-doesnt-exist/533223 "2023-04-07T02:16:39Z")

</div>

I want to convert Total(data table) to NumbersS(String variable) & HospitalS(String variable) to process the following sequence ( replace text in Word document using variable. There are two words I need to replace and t…

---

## [Round off not giving the expected result](https://forum.uipath.com/t/round-off-not-giving-the-expected-result/524869)

<div class="topic-metadata">

**Author:** [@raja.raviraj](https://forum.uipath.com/u/raja.raviraj)\
**Replies:** 6\
**Last updated:** [March 10, 2023, 11:55am UTC](https://forum.uipath.com/t/round-off-not-giving-the-expected-result/524869 "2023-03-10T11:55:32Z")

</div>

Hi All, I would like to round off any number to 3 decimal places . I tried below methods but not giving the expected results, sample = 14.23448 Method1 : CDbl(sampl).ToString(“#.###”) gives 14.234 but the expected re…

---

## [Merging two if statements within an assign](https://forum.uipath.com/t/merging-two-if-statements-within-an-assign/523456)

<div class="topic-metadata">

**Author:** [@duaine.b](https://forum.uipath.com/u/duaine.b)\
**Replies:** 3\
**Last updated:** [March 6, 2023, 12:25pm UTC](https://forum.uipath.com/t/merging-two-if-statements-within-an-assign/523456 "2023-03-06T12:25:17Z")

</div>

I have two if in two different assign, if there a way to merge the two statements into one? out\_arrayCRNumber = If(jObjCompanyInfo.ContainsKey(“CRNNumber”), out\_arrayCRNumber.Concat({jObjCompanyInfo(“CRONumber”).ToStrin…

---

## [Get Characters before and after a specific keyword in a notepad](https://forum.uipath.com/t/get-characters-before-and-after-a-specific-keyword-in-a-notepad/494737)

<div class="topic-metadata">

**Author:** [@Techno1](https://forum.uipath.com/u/Techno1)\
**Replies:** 14\
**Last updated:** [December 8, 2022, 8:40am UTC](https://forum.uipath.com/t/get-characters-before-and-after-a-specific-keyword-in-a-notepad/494737 "2022-12-08T08:40:37Z")

</div>

Hi Team, I have a keyword in a notepad file which is extracted as a variable. Suppose in the below document, I extracted the keyword “government”, and I save it into a string variable. I need to get 100 characters b…

---

## [Multiple '' Assign' expression for datetime value](https://forum.uipath.com/t/multiple-assign-expression-for-datetime-value/496453)

<div class="topic-metadata">

**Author:** [@sirwa](https://forum.uipath.com/u/sirwa)\
**Replies:** 5\
**Last updated:** [December 6, 2022, 5:29am UTC](https://forum.uipath.com/t/multiple-assign-expression-for-datetime-value/496453 "2022-12-06T05:29:34Z")

</div>

Hi, I am trying to achieve the following expression for a value that has been exported from Excel. This value could have been 9-12-2022 or 09-12-2022. The first input would trigger an error for the following expression…

---

## [Assign Integer Value to XML](https://forum.uipath.com/t/assign-integer-value-to-xml/495614)

<div class="topic-metadata">

**Author:** [@ram\_dhas](https://forum.uipath.com/u/ram_dhas)\
**Replies:** 12\
**Last updated:** [December 2, 2022, 3:36pm UTC](https://forum.uipath.com/t/assign-integer-value-to-xml/495614 "2022-12-02T15:36:44Z")

</div>

Hi, I need to assign a value to an XML file before I can use the file as input for further processing. I tired to achieve this using Replace functionality. However, it works only for String Variables and in my case it i…

---

## [String Extract Error](https://forum.uipath.com/t/string-extract-error/484292)

<div class="topic-metadata">

**Author:** [@d.ulutas](https://forum.uipath.com/u/d.ulutas)\
**Replies:** 6\
**Last updated:** [October 25, 2022, 4:24pm UTC](https://forum.uipath.com/t/string-extract-error/484292 "2022-10-25T16:24:57Z")

</div>

Hello there, i have one file path; “C:\\Users\\UiPath\\Desktop\\Home24\\559690.PDF” “559690.PDF” may vary Example; “C:\\Users\\UiPath\\Desktop\\Home24\\232131690.PDF” How can I get only the pdf name anyway?

---

## [How implement 'For Each' loop inside an Assign Activity](https://forum.uipath.com/t/how-implement-for-each-loop-inside-an-assign-activity/475129)

<div class="topic-metadata">

**Author:** [@Leonardo\_Andrade](https://forum.uipath.com/u/Leonardo_Andrade)\
**Replies:** 4\
**Last updated:** [September 22, 2022, 3:13pm UTC](https://forum.uipath.com/t/how-implement-for-each-loop-inside-an-assign-activity/475129 "2022-09-22T15:13:13Z")

</div>

Hello guys, I want to implement an For-Each loop inside an Assign Activity, but I don’t know how to do it. Can someone help me, please?

---

## [How to sum each data and get avg?](https://forum.uipath.com/t/how-to-sum-each-data-and-get-avg/458696)

<div class="topic-metadata">

**Author:** [@yigit.aybey](https://forum.uipath.com/u/yigit.aybey)\
**Replies:** 7\
**Last updated:** [July 22, 2022, 10:49am UTC](https://forum.uipath.com/t/how-to-sum-each-data-and-get-avg/458696 "2022-07-22T10:49:08Z")

</div>

Hell guys, i need some help. I’m new at this platform. I do not know linq and V.B .NET(a little know). This is my excel datas and it’s got more than 200 datas. I need to get the AVG of each “City/Town” Price in dif…

---

## [Assign Error Message!](https://forum.uipath.com/t/assign-error-message/458439)

<div class="topic-metadata">

**Author:** [@yigit.aybey](https://forum.uipath.com/u/yigit.aybey)\
**Replies:** 4\
**Last updated:** [July 21, 2022, 1:39pm UTC](https://forum.uipath.com/t/assign-error-message/458439 "2022-07-21T13:39:19Z")

</div>

Hi all, i’m getting this error message in assign “Assign: Exception has been thrown by the target of an invocation.” Why am i getting this error or what should i change in the code or where? What is the solution? NOT …

---

## [Speration Different Datas in Excel](https://forum.uipath.com/t/speration-different-datas-in-excel/446926)

<div class="topic-metadata">

**Author:** [@yigit.aybey](https://forum.uipath.com/u/yigit.aybey)\
**Replies:** 1\
**Last updated:** [June 19, 2022, 3:48am UTC](https://forum.uipath.com/t/speration-different-datas-in-excel/446926 "2022-06-19T03:48:55Z")

</div>

Hi guys, My excel files and there is more values how it looks. and it should be like this (It is done by manually): How can i do that? I did smt but it doesn’t work. What i’ve done already First i did read r…

[Next page](https://forum.uipath.com/tag/assign/1611.md?match_all_tags=true&page=1&tags%5B%5D=assign)
