cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Regular Visitor

Connection.Connected takes too long

Hi all,

 

I have a form that submits data to a Sharepoint List, but I'm working to save the form as collection where there is no connection. The issue I found is that when I click on submit button with no internet connection from the devices, the app takes too long to 'realize' it is offline (even more than 1 minute). Also, the errors notifications looks too invasive. 

This is the code I have on the submit button:

If( 
Connection.Connected,
    SubmitForm(Form1); Navigate([@'Success Screen1'], ScreenTransition.Fade),
    Collect(Collection1, SubmitForm(Form1));
    SaveData(Collection1, "offlinesave");
    Navigate([@'Success Screen2'], ScreenTransition.Fade)
)

This is the error that appear all the time when I'm offline.

cropped-connection-issue.png

 

Does exists a way to make that connection verification faster? Is not the device since I tested it on two different android tablets, an iPad and an android smartphone, takes same time. 

 

Also, does exist a way to take these invasive errors away? 

Thanks!! 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User III
Super User III

@fmigg 

There is no real way to resolve alert errors like that from appearing.  The best course of action is to avoid hitting formulas where this might happen.

In your particular Formula, you are performing a SubmitForm if you have detected you are not connected.  This will cause the error you are seeing.

You might want to consider changing your Collect formula to:

   Collect(Collection1, Form1.Updates)

Otherwise, with the SubmitForm in there, it will try to connect and resolve to the server, which will result in an error message.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!

View solution in original post

1 REPLY 1
Super User III
Super User III

@fmigg 

There is no real way to resolve alert errors like that from appearing.  The best course of action is to avoid hitting formulas where this might happen.

In your particular Formula, you are performing a SubmitForm if you have detected you are not connected.  This will cause the error you are seeing.

You might want to consider changing your Collect formula to:

   Collect(Collection1, Form1.Updates)

Otherwise, with the SubmitForm in there, it will try to connect and resolve to the server, which will result in an error message.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!

View solution in original post

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (15,294)