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

Offline issue

Hi All,

 

 I am creating an powerapps for offline. I have one button which takes some input from user and save into  JourneyCollection3. And send data to cds when the device has internet connection.

I am facing an issue for following flow- disconnects internet , open the offline app, take some data in offline mode from user and then come online and click on button which sends data to CDS. It throws an error saying "Value must be a data entity record"

But this is working- internet connection is present, opens an app, then disconnects internet , take some data in offline mode from user and then come online and click on button which sends data to CDS.

I have below code on app Onstart-
Set(varGIF,true);
//delete above

LoadData(
JourneyColletion,
"Saveitemstokeep",
true
);
LoadData(
JourneyColletion2,
"Saveitemstokeep2",
true
);
LoadData(
JourneyCollection3,
"Saveitemstokeep3",
true
);
//put code here
If(
Connection.Connected,//Route
ClearCollect(
RouteCollection,
Routes
);
SaveData(
RouteCollection,
"Saveitemstokeeproutelookup"
),
LoadData(
RouteCollection,
"Saveitemstokeeproutelookup",
true
);

);
If(
Connection.Connected,//Bus
ClearCollect(
BusCollection,
Buses
);
SaveData(
BusCollection,
"Saveitemstokeepbus"
),
LoadData(
BusCollection,
"Saveitemstokeepbus",
true
);

);
Set(varGIF,false)

 

Any help expert @WarrenBelz ?

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @Anonymous ,

I will give you one piece of advice which others may disagree with, but if you are trying to automate the on-line/off-line switch over, the sorts of issues you are facing will arise. Shane Young has a good video on his process.

I have a couple of off-line capable apps and all user uploads of offline data are manual, with the user checking they have good signal at the time.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

View solution in original post

1 REPLY 1
WarrenBelz
Super User
Super User

Hi @Anonymous ,

I will give you one piece of advice which others may disagree with, but if you are trying to automate the on-line/off-line switch over, the sorts of issues you are facing will arise. Shane Young has a good video on his process.

I have a couple of off-line capable apps and all user uploads of offline data are manual, with the user checking they have good signal at the time.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

View solution in original post

Helpful resources

Announcements
User Group Leader Meeting January 768x460.png

Calling all User Group Leaders!

Don't miss the User Group Leader meetings on January, 24th & 25th, 2022.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (1,885)