cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
sikelsh
Level: Powered On

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
PavanKumar
Level 8

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

sikelsh
Level: Powered On

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.

 

PavanKumar
Level 8

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
firstImage

PowerApps Monthly Community Call!

Join us next Wednesday for our Demo Extravaganza, October 16, 2019 8am PDT.

firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

SecondImage

Power Platform Summit North America

Register by September 5 to save $200

Top Kudoed Authors
Users Online
Currently online: 217 members 4,895 guests
Please welcome our newest community members: