cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
New Member

If statement with a Navigate(Thisitem Issue

 

 

Hi all, first post, just getting to grips with PowerApps.

 

I have a Gallery that i am using as a list of 'Links', some of the links are web URLs and therefore use the Launch function and some are Screens therefore need the Navigate function, I have connected to a SQL table see below and the field name is URL.

 

Capture1.PNG

 

I expected this to just work out the box, but doesnt seem that way. the code below is OnSelect on the NextArrow Icons shown below.

Capture2.PNG

 

Capture3.PNG

Thanks in Advance

Simon

 

3 REPLIES 3
Highlighted
Responsive Resident
Responsive Resident

Re: If statement with a Navigate(Thisitem Issue

Hi, Just check what value are you getting in Thisitem.URL (may be some encrypted values) also in Launch once try hardcoded url and check if its working e.g. Launch(https://www.google.com).

 

This may give you better direction. Please let me know if you have any further questions/doubts.

 

If this answer helps please mark it as verified.

 

Regards,

Pavan Kumar Garlapati

Highlighted
New Member

Re: If statement with a Navigate(Thisitem Issue

Hi, sorry if I wasnt clear.

 

The Launch is working fine, it picks the correct URL from the table and it opens fine, however this only works when I hardcode the Screename in the Navigate section (as the statement isnt accepted as correct when read from table) as below, what I have done is included the Screename in the table in the URL field

 

If("http" in ThisItem.URL, Launch(ThisItem.URL), Navigate(StaffSuggestion,ScreenTransition.Fade))

 

Regardless of the IF statement the function Navigate(ThisItem.URL,ScreenTransition.Fade) doesnt appear to work.

 

Highlighted
Responsive Resident
Responsive Resident

Re: If statement with a Navigate(Thisitem Issue

Hi,

 

I assume you have between 5 - 10 screens to navigate. Unfortunately Navigate function expects screen type of parameter. so in your case you can write within your if function.

 

Switch( ThisItem.URL, "Screen1",Navigate(Screen1, Fade), "Screen2",Navigate(Screen2, Fade), "Screen3",Navigate(Screen3, Fade), "Screen4",Navigate(Screen4, Fade) ).

 

 

Mark it as verified if it answers your question.

 

Regards,

Pavan Kumar Garlapati

Helpful resources

Announcements
Check this Out

Announcing

Class of 2020- Season 2

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

August 2020 Community Challenge: Can You Solve These?

August 2020 Community Challenge: Can You Solve These?

We're excited to announce our first cross-community 'Can You Solve These?' challenge!

secondImage

Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (8,818)