Task httpclient -> call just one time ?

cristopheB 551 Reputation points
2021-07-26T15:37:44.39+00:00

Hello,
I have an app under xamarin android who call a controller in http and get some information ..
All works fine BUT sometimes we notice we have the same call in the same hour / sec

For to resume, inside the controller i have a log who trace the begin of the call and the end of the call
And i don't know why but sometimes for the same device , the call http is like DUPLICATE multiple time ...

Any idea about how to solve this ?

thanks

Xamarin
Xamarin
A Microsoft open-source app platform for building Android and iOS apps with .NET and C#.
5,349 questions
{count} votes

1 answer

Sort by: Most helpful
  1. cristopheB 551 Reputation points
    2021-08-05T14:12:20.31+00:00

    IHello @JarvanZhang

    I"ve find :)
    In fact, it's an pagerAdater who load multiple fragment and the life cycle for all was not good ..

    as this, we spend some in multiple time in the call http

    thanks for your help


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.