If input stored in a string variable named str_input
Then
str_output = IF(String.IsNullorEmpty(str_input.ToString) OR str_input.ToString.Equals(“0”),string.Empty,Convert.ToDouble(str_input.ToString.Trim).ToString.TrimStart(“0”c).ToString)
Where str_output is a variable of type string
This will first check whether the input is zero or has no value in it.
If it has no value or it’s zero then it will give empty value to the output variable str_output
Or
It will convert the string to double first which will remove right side zeros and trimstart will remove left side zeroes
If first one is showing an error, you can import system.globalization OR Use the second code…Make sure output is double value. If you want it in string just use .tostring at the end…