Retrieving and Deserializing JSON in Your Xamarin.Forms App

Поділитися
Вставка
  • Опубліковано 12 жов 2024

КОМЕНТАРІ • 86

  • @jfversluis
    @jfversluis  2 роки тому

    Want to learn more about uploading data to a REST API? Check out this video right here: ua-cam.com/video/KPDGtLeNClQ/v-deo.html

  • @robertbrown7478
    @robertbrown7478 3 роки тому +1

    Awesome tutorial! I love how you tied it in with the Collection View and that you didn't edit out the mistakes so we know what the potential pitfalls are. Thanks so much!!!

    • @jfversluis
      @jfversluis  3 роки тому +1

      Thank you Robert! Yeah, unless it's a major catastrofe I'll just let it in so you can also learn from my mistakes :)
      I think it's important to realize no one is perfect and hopefully when someone runs into the same thing they now learned 2 things from this video!

  • @marox88
    @marox88 3 роки тому +1

    Thank You for remembering and made what I was asking for :)) Gerald You are FANTASTIC!! :) And please make this DataTemplate :D

    • @jfversluis
      @jfversluis  3 роки тому

      Of course I did! 😌 DataTemplates is also on the list!

  • @onlysexist
    @onlysexist 2 роки тому

    Excellent, just excellent. More than Exccellent my friend. This is what i was looking for. From Dominican Republic: Excellent

    • @jfversluis
      @jfversluis  2 роки тому

      That is amazing to hear, thank you so much!

  • @YoUserExp
    @YoUserExp 3 роки тому

    Great stuff! Nice work on the stream yesterday talking about the community toolkit as well. Thank you for all of the information. If possible I'd like to ask for a video implementing MQTT communication if you are in need of video ideas.

    • @jfversluis
      @jfversluis  3 роки тому

      Thank you Jeremy! It was so much fun to do!
      MQTT in itself or specific to Xamarin? Not something I'm very familiar with so wouldn't hold my breath, but who knows! I appreciate the suggestion :)

    • @YoUserExp
      @YoUserExp 3 роки тому +1

      @@jfversluis Thanks for the reply. I was thinking of Xamarin specifically. I currently use websockets but it seems to be a little overkill for my use case. Also, In the toolkit do you think we'll ever have a semi official Bluetooth library. If not is there one you recommend?

    • @jfversluis
      @jfversluis  3 роки тому

      Not in the foreseeable future I think. Do you know about Shiny?

    • @YoUserExp
      @YoUserExp 3 роки тому

      @@jfversluis I had looked into it but it was only in prerelease when I was originally developing my app. Have you had a good experience with it?

  • @levkilic
    @levkilic 3 роки тому

    Thank you Gerald for this great video! You explained the topic in a simple way, not lost in details.

    • @jfversluis
      @jfversluis  3 роки тому

      That’s great to hear, thank you Levent!

  • @androidsavior
    @androidsavior 3 роки тому

    This is great ! , keep it up man

  • @Elsa-jw3xe
    @Elsa-jw3xe 3 роки тому +1

    Great video Gerald. Could you perhaps make a video how to work with libraries?

    • @jfversluis
      @jfversluis  3 роки тому

      A library to work with libraries? 😉 I assume you mean video! But what do you want to know about working with libraries?

    • @Elsa-jw3xe
      @Elsa-jw3xe 3 роки тому

      @@jfversluis lol yes, i was too quick... But would be nice if you could do a video about that. Been thinking myself about a login which i could use in several projects and then only change the layout. But perhaps thats too much to ask haha.

  • @chrisdroney8141
    @chrisdroney8141 3 роки тому +1

    Hey, thanks for the tutorial! It hasn't been very easy for me to find good tutorials for the xamarin.forms framework. The sample code repo link seems to be dead, is there any chance you've renamed that project since uploading?

    • @jfversluis
      @jfversluis  3 роки тому +1

      You'll never believe it... I forgot to set the repo to public and no one ever noticed :D
      Made it public now! Hope it helps!

    • @chrisdroney8141
      @chrisdroney8141 3 роки тому

      @@jfversluis Thanks, I appreciate it!

  • @25kyro
    @25kyro 3 роки тому

    Awesome! But noticed you said I want to keep it simple without Data Binding, but could you show us how to do with Binding also!

    • @jfversluis
      @jfversluis  3 роки тому

      Sure thing! What is it you'd like to see exactly?

  • @lemoncrazedcamel
    @lemoncrazedcamel 3 роки тому

    A great note for anyone on windows, you can use the special paste functionality of vs2019 to create the serializable class instead of using a website

    • @jfversluis
      @jfversluis  3 роки тому

      Absolutely! Didn't I mention that in the video?! Did I forget? Because it's such a good feature! I should record productivity tips :D
      Thanks for adding this!

    • @lemoncrazedcamel
      @lemoncrazedcamel 3 роки тому +1

      @@jfversluis I think you did I just jumped the gun on my comment! :D and a productivity tools and tips video would be great!

    • @jfversluis
      @jfversluis  3 роки тому +1

      No worries! Better one time too many!
      I’ll think about those productivity ones... it’s a bit of a blind spot probably because I use a lot of them without even noticing anymore 😄

  • @Tamer_Ali
    @Tamer_Ali 3 роки тому

    Hi Gerald,
    Awesome video tutorial
    I hope you talk about how to use Localization in Xamarin Forms and how to change the app / page / control flow direction RTL/LTR based on localization.
    Thanks

    • @jfversluis
      @jfversluis  3 роки тому +1

      Great suggestion! Thank you for watching!

  • @chosenvan
    @chosenvan 2 роки тому

    Thank you very much.. I needed this.. solved all my problems ;)

    • @jfversluis
      @jfversluis  2 роки тому +1

      Thank is great! Thank you so much for letting me know :D

  • @cissemy
    @cissemy 3 роки тому +1

    Great course.
    How can I add pagination and filter my collectionview ?
    Thanks

    • @jfversluis
      @jfversluis  3 роки тому

      Here is at least a tutorial on how to add pagination: doumer.me/infinite-scroll-with-the-xamarin-forms-collection-view/

    • @cissemy
      @cissemy 3 роки тому

      @@jfversluis
      Thanks

  • @codigoadictivo
    @codigoadictivo 3 роки тому

    Coool, nice video 👍🏽

  • @AMIRKHAN-dm2fm
    @AMIRKHAN-dm2fm 3 роки тому

    great
    i am waiting for app center tutorials😉
    and please try to make tutorial series on MVVM and clean architecture or best practices.

    • @jfversluis
      @jfversluis  3 роки тому +1

      Working on it!

    • @AMIRKHAN-dm2fm
      @AMIRKHAN-dm2fm 3 роки тому

      @@jfversluis Thanks😊

    • @jfversluis
      @jfversluis  3 роки тому +1

      What do you want to know about MVVM?

    • @AMIRKHAN-dm2fm
      @AMIRKHAN-dm2fm 3 роки тому

      @@jfversluis sir all advance concepts.

    • @jfversluis
      @jfversluis  3 роки тому

      Can you make that more concrete? What is advanced for one person might now be advanced for another :)

  • @dancluderay1304
    @dancluderay1304 3 роки тому

    Would be great to see a video on Bluetooth beacons and triggering events

    • @jfversluis
      @jfversluis  3 роки тому

      If only Apple would release those AirTags :D

  • @abdelrahmanalasal6801
    @abdelrahmanalasal6801 2 роки тому

    Thanks Gerald

  • @bastiantokusumajaya4337
    @bastiantokusumajaya4337 2 роки тому

    Hello, can i ask, i have already searched around your channel and can't find the video u mentioned about sending data to rest api, which i needed, can you please give me the link for that video you mention in the beginning of this video?

    • @jfversluis
      @jfversluis  2 роки тому

      Whoops sorry about that, I was referring to this one: ua-cam.com/video/KPDGtLeNClQ/v-deo.html

  • @mo7amedh.m264
    @mo7amedh.m264 3 роки тому

    You really really really the best 👏

  • @jaskodemic9705
    @jaskodemic9705 3 роки тому +1

    Thanks for that but can u explain how u get the data if json hava child ?

    • @jfversluis
      @jfversluis  3 роки тому +1

      If you paste that into QuickType it will also do that for you. Basically just create another object and add that as a property :) I can do another video on that

    • @annbrady2310
      @annbrady2310 3 роки тому +1

      @@jfversluis A video on this would be greatly appreciated.

    • @jfversluis
      @jfversluis  3 роки тому

      What is de trouble you’re having with it?

  • @dancluderay1304
    @dancluderay1304 3 роки тому

    Very good

    • @jfversluis
      @jfversluis  3 роки тому

      Thank you Dan! And thank you for being a member! Very much appreciated!

  • @divangerber7897
    @divangerber7897 3 роки тому

    Wait, how did you get a response in postman on /weatherforecast without running the application in Visual Studio First? I get a Error: connect ECONNREFUSED "IP adress" ..

    • @jfversluis
      @jfversluis  3 роки тому +1

      Sorry if I made it seem like it isn’t running. It definitely has to run or be hosted somewhere for this to work :)

    • @divangerber7897
      @divangerber7897 3 роки тому

      @@jfversluis Ok so I am implementing what I learn from your uploads, how do I host my api (to a sql express database) so that remote devices can do CRUD operations to and from the database through the XAMARIN.Forms Cross-platform app?

  • @tomoorizardo745
    @tomoorizardo745 3 роки тому

    bro please make one with images + json data. for example a product with image using webapi Or a user with profile picture that is uploaded to a webapi.

    • @jfversluis
      @jfversluis  3 роки тому +1

      It’s probably easier to do that separately. If you look at apps they mostly let you add all the “text data” like you profile info first, and you tap on your profile image to set that separately.
      Even if that’s not what you want, make the UI so that it looks as one but do two calls in the background one for the data and one for the image.
      I’ll see if I can get to a video that combines it, hopefully this helps in the meantime

    • @tomoorizardo745
      @tomoorizardo745 3 роки тому

      @@jfversluis thank you so much bro

  • @jordanreighn3143
    @jordanreighn3143 3 роки тому

    I get a Unexpected character encountered while parsing value. What could this mean?

    • @jfversluis
      @jfversluis  3 роки тому

      You’re probably getting HTML back instead of JSON so something about the request or response isn’t right. Try with a tool like postman

  • @dhirenpathak
    @dhirenpathak 2 роки тому

    please also put Web API Consume in MAUI Blazor App

    • @jfversluis
      @jfversluis  2 роки тому

      That’s in there but should be no different than doing it in any other type of app :)

  • @keimmeraltuve8452
    @keimmeraltuve8452 3 роки тому

    I cant retrieve from a json link because the method get does not return anithing, the api has an .json file what should i do in that situation?

    • @jfversluis
      @jfversluis  3 роки тому

      Not sure what you mean. You mean it wants do download a .json file rather than sending you the JSON content directly? Read the file in memory and deserialize from there :)

    • @keimmeraltuve8452
      @keimmeraltuve8452 3 роки тому

      @@jfversluis sorry, english is not my main language, but thanks for the explanation, I figured it out, great video thanks for the explanation

  • @hossamal-deenhamedal-sayyd9166
    @hossamal-deenhamedal-sayyd9166 3 роки тому

    How to Make This Function And Get The Response And displayed in collection View In Fresh MVVM ?

    • @jfversluis
      @jfversluis  2 роки тому

      FreshMvvm shouldn't matter in this case. Just make sure to put the data in a ObservableCollection and use that as the source for your CollectionView with databinding

  • @LobsterHarry
    @LobsterHarry 3 роки тому

    That was a little too Quick & Dirty in my Opinion. Fortunately I knew everything already ! ;-)

    • @jfversluis
      @jfversluis  3 роки тому

      Oh no! Why’s that? You feel it’s going to fast for people to follow? Or you mean you’d like to see it done a bit more the right way than just creating an HttpClient all the time?

  • @_samirdahal
    @_samirdahal 3 роки тому

    What if we have different naming convention in our json object and c# class properties? Can it still able to deserialize it?
    app.quicktype.io/ this was a pro tip. Thanks!

    • @jfversluis
      @jfversluis  3 роки тому +1

      Great! Glad you learned something! If it’s different you can use the JsonProperty attribute on your properties. See for example: www.jerriepelser.com/blog/deserialize-different-json-object-same-class/

    • @_samirdahal
      @_samirdahal 3 роки тому +1

      @@jfversluis Thanks! I got it.