cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Convert Datetime using "convert time zone" action

Hi all,

 

I am able to convert the time from 10/08/2019 to

 2019-10-07T11:00:00.0000000Z

I want my final output to be

2019-10-07T11:00:00.0000

So basically removing the last 4 characters.

 

How would I do that?

 

Thank you 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Anonymous 

 

dynamiccontentreference - that is a dummy text I added for you to replace it with the field which stores the actual value 

 

so remove this from the expression and then swicth to dynamic content (WHILE IN EXPRESSION WINDOW - dynamic content is right to the left of it as a tab) and select the field which has the date value you want the last 4 chars to be replaced

 

--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

 

View solution in original post

9 REPLIES 9
RezaDorrani
Dual Super User II
Dual Super User II

Hi @Anonymous 

 

Use expressions

 

replace(dynamiccontentdatevalue,'000Z','')
 
or
 
substring(dynamiccontentdatevalue,0,sub(length(dynamiccontentdatevalue),4))
 
--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
Anonymous
Not applicable

Hi Rich,

 

Where do I add that? Sorry I am new to Flow...Flowchart.PNG

Do I need a new action between "Convert time zone" and "Filter Array 3"?

 

Best

 

@Anonymous 

 

Depends on where you want it

 

In apply to each (last action) if you need it in that loop

 

then use

 

replace(item()?['internal name of field'],'000Z','')

Anonymous
Not applicable

I want to use the shorted datetime here:

Capture.PNG

@Anonymous 

 

Then add the expression there

 

click on the box - go to expression panel and enter it there

 

replace(dynamiccontentreference,'000Z','')

Anonymous
Not applicable

It says expression is invalid. 

I am sorry about this...I am not too familiar with Flow...

@Anonymous 

 

Share screenshot of expression

 

Anonymous
Not applicable

error.PNG

Hi @Anonymous 

 

dynamiccontentreference - that is a dummy text I added for you to replace it with the field which stores the actual value 

 

so remove this from the expression and then swicth to dynamic content (WHILE IN EXPRESSION WINDOW - dynamic content is right to the left of it as a tab) and select the field which has the date value you want the last 4 chars to be replaced

 

--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

 

View solution in original post

Helpful resources

Announcements
MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

Top Solution Authors
Users online (53,568)