Click here to Skip to main content
15,896,514 members

Comments by jeAntoni (Top 6 by date)

jeAntoni 3-Sep-17 2:57am View    
Thanks lot for the alert - very helpful.
As you said I see no replies on my Question.

And if possible can you please suggest me a best grid to use in my MVC app (free downloadable).
jeAntoni 30-Aug-17 19:57pm View    
Thanks. I just did it - created the discussion
jeAntoni 22-Aug-17 13:52pm View    
This works fine. Somehow I had missed an assignment in between, and thus was seeing the right output.

ResultantList = ListOne.Where(s => ListTwo.Any(l => (l.ID == s.ID && s.Value> l.Value))) .ToList();
jeAntoni 30-Jan-17 0:14am View    
Thanks Jochen. I have updated my Question.

As per your answer I understand that the control goes to the caller as there is an await. I also note that the control keeps going and coming back to ReceiveAsync - but only for some time.

Plesae guide me on - why does it break out and not return back to the ReceiveAsync method (as it does for first some number of times)? It should actually keep receiving data as I see the message is being send from IoT Hub continuosly with no break.
Kindly give me some idea on how to take this forward.
jeAntoni 27-Jan-17 0:22am View    
I tried including try catch block
i.e placing the code statements - while(true) part - of the method ReceiveMessagesFromDeviceAsync in try catch block as below.
I have confirmed that it never hits the statements marked below as ====>
STT-A or STT-B or STT-E or STT_END_OF_METHOD
It loops inside while for some number of times (i.e receives data from IoT Hub)
and at one point of time at the statement STT- IoT_DATA it comes out of the method and returns to the calling method - i.e to the method SetHubs() I have mentioned in my query\comment
(This proceeds to display the page)

try{
          if (ct.IsCancellationRequested) 
                break; // STT-A
          EventData eventData = await eventHubReceiver.ReceiveAsync(); // STT- IoT_DATA
          if (eventData == null) 
                 continue;//STT-B
          string data = Encoding.UTF8.GetString(eventData.GetBytes());
}
catch(Expecption exp){
string e =exp.message(); //STT-E
}
} //STT-END_OF_METHOD

Am I missing something like the partition limit or so. If so please guide me how to do or make the required settings to make this work.

## Note : The same code works fine in a Console App.