How to remove last char from a range in one go without loops

Hello Friends,

I want to remove “$” sign in one go without any loops.
I tried below formula in write cell activity but showing error:-

It shows wrong format.

Can we have any other approaches?

Hi @Jeeru_venkat_Rao ,

Can you please check below screenshot its working for me,

Use this below code in write cell activity,


Hope this may help you :slight_smile:


Thanks @Manish540

Issue resolved.

Hi @Jeeru_venkat_Rao ,

If you found my answer useful to you please mark it as solution. I guess you marked wrong reply as solution.

Thank you :slight_smile:

One more thing I want to ask.

Assume if we are getting this data from any Datatable not in excel so, If we want to remove $ sign and want in int format hence we can do the sum. How we can do that?

Hi @Jeeru_venkat_Rao ,

Use this below code to sum the column values,
sumOfValues(Variable type is Double) = dt.AsEnumerable().Sum(Function(x) CDbl(x("Values").ToString.Trim.Replace("$","")))

sumOfValues(Variable type is Integer) = dt.AsEnumerable().Sum(Function(x) CInt(x("Values").ToString.Trim.Replace("$","")))

Hope this helps :slight_smile:

You are awesome bro,

This is what I am looking for.

Thank you so much for your quick reply.

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