Date time orchestrator

how to convert from 10/30/1970 00:00:00 to dd/mm/yyyy

DateTime.Now.ToString(“dd/MM/yyyy”)

Hi @Arun.k
Just pass your variable here.

string.Format("{0}", System.DateTime.Now.ToString(“dd/MM/yyyy ”))

cheers :smiley:

Happy learning :smiley:

2 Likes

i am fetching data from orchestrator

1 Like

alright @Arun.k then pass the data that you fetch in orchestrator in that method.

cheers :smiley:

Happy learning :smiley:

2 Likes

after fetching i got in 10/30/1970 00:00:00
but i want only 10/30/1970 in dd/mm/yyyy format

yes then pass it to a variable and do the String.Format method @Arun.k

cheers :smiley:

Happy learning :smiley:

1 Like

give proper solution how to write it string.format

Hi @Arun.k

I already show how to do it just pass your variable

string.Format("{0}",VariableMo.ToString(“dd/MM/yyyy ”))

2 Likes

string.Format("{0}", System.DateTime.Now.ToString(“dd/MM/yyyy ”))
where i pass the variable in that expression

Hi @Arun.k

get the value from orchestrator.
store the value in a string variable “myvalue”.
Then create a datetime variable “mydate”.
use an assign activity
mydate = DateTime.ParseExact(myvalue,“dd/MM/yyyy”,System.Globalization.CultureInfo.InvariantCulture) .
Then mydate.ToShortDateString will give you the required output

Thanks,
Karthik

this expression showing error

how to remove 00:00:00 from 10/30/1970 00:00:00

how to use assign activity to get the value from queue
i used
i created a string variable myvalue and used assign activity. I put expresion intranscationitem.specificcontent(“BOB”).tostring
but after running it’s showing error