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

Invalid argument type

Hi All,

I am creating app in offline mode. on App OnStartI have below code-
If(
!IsEmpty(JourneyColletion.cre08_name) && Connection.Connected && JourneyColletion.cre08_journeyenddateandtime<>Date(9999,09,09)+Time(00,00,00),
do this.....)
here I am having error in this- JourneyColletion.cre08_journeyenddateandtime<>Date(9999,09,09)+Time(00,00,00) as "Invalid argument type" 

I want to insert data when I am online and have some data and journey end date should not be equal to "9/9/9999 12:00 AM"

Any help is appreciated

1 ACCEPTED SOLUTION

Accepted Solutions
v-siky-msft
Community Support
Community Support

Hi @Anonymous ,

 

JourneyColletion.cre08_journeyenddateandtime means a single column table, but 'Date(9999,09,09)+Time(00,00,00)' mean a Date Time Value, so they are incompatible types.

If you want to check there is no date time value in journeyenddateandtime column equal to "9/9/9999 12:00 AM", please modify the code as follows.

If(
!IsEmpty(JourneyColletion.cre08_name) && Connection.Connected && Not((Date(9999,09,09)+Time(00,00,00)) in JourneyColletion.cre08_journeyenddateandtime),
do this.....)

Hope this helps.
Sik 

View solution in original post

1 REPLY 1
v-siky-msft
Community Support
Community Support

Hi @Anonymous ,

 

JourneyColletion.cre08_journeyenddateandtime means a single column table, but 'Date(9999,09,09)+Time(00,00,00)' mean a Date Time Value, so they are incompatible types.

If you want to check there is no date time value in journeyenddateandtime column equal to "9/9/9999 12:00 AM", please modify the code as follows.

If(
!IsEmpty(JourneyColletion.cre08_name) && Connection.Connected && Not((Date(9999,09,09)+Time(00,00,00)) in JourneyColletion.cre08_journeyenddateandtime),
do this.....)

Hope this helps.
Sik 

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (2,666)