Advanced VB.NET Programming - Serializing Objects with JSON

Поділитися
Вставка
  • Опубліковано 14 січ 2025

КОМЕНТАРІ • 37

  • @dford0001
    @dford0001 Рік тому

    Thank you for your time in putting together these videos. They have helped tremendously! I hope to see more!

  • @faithakanga
    @faithakanga 2 роки тому +2

    Thanks for the lessons. Please make more videos about the advance programming

  • @redouanesaadouni6861
    @redouanesaadouni6861 2 роки тому +2

    We need like this video, please continue

  • @kevnar
    @kevnar 3 роки тому +3

    Perfect! Exactly what I needed for my project. You even helped me avoid the pitfall of using the deprecated serialization methods. I was planning to do that.
    I'm assuming sub-classes of objects are automatically included in the JSON serialization, so I only have to save the parent object and everything associated with it gets saved as a package. That saves a heck of a lot of trouble. The objects in my project are monstrous trees of subclasses and sub-subclasses. I'll let you know how it all works out.

    • @ComputerScienceLessons
      @ComputerScienceLessons  3 роки тому +2

      You're most welcome (and thanks for the idea kevnar). If you serialize an object created from a sub, sub sub class, inheritance will take care of everything for you. E.G. I created an object from an Employee class, whose parent was the Person class, I then serialized the employee object. If I had a Manager class (a type of employee), which inherited from the Employee class (a type of person), which inherited from the Person class, then I would serialize the manager object. Do let me know how it works out. :)KD

  • @rushabhbajaj310
    @rushabhbajaj310 2 роки тому +3

    Bro , Dont Stop Uploading this Playlist , its really helpful , I have seen all videos from all your vb.net playlists , I want to learn more , at least tell me where i can keep learning about vb.net , any site , yt channel will be fine

  • @jtlunsford780
    @jtlunsford780 Рік тому +1

    Never heard of it. Now I know how and what it's used for. And with some research, I think I can implement it if I ever need to. Thanks so much for the great vids and your expertise...JT

  • @davidm9442
    @davidm9442 Рік тому +2

    Thank you so much good sir!

  • @renatzkigab2616
    @renatzkigab2616 2 роки тому +2

    Please do more on advance topic and perhaps get into the database programming. Thanks it's a great vid.

    • @ComputerScienceLessons
      @ComputerScienceLessons  2 роки тому +2

      I plan to. You might find my videos on developing a theatre booking system useful. :)KD

  • @CienaGoat
    @CienaGoat 3 роки тому +4

    How were you able to stop it from serializing the salary by just returning either true or false with this function you made? I don't see it being used anywhere outside of the declaration. 21:10

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

      It comes down to the fact that the function has the name 'ShouldSerializeSalary', I guess that's what the JsonSerializer's Serialize method is looking out for. Love the channel BTW (subbed). Keep it coming :)KD

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

      @@ComputerScienceLessons Oh ok I gotcha! So it's just like kind of the standard syntax to use in this scenario. It's like a function definition but not at the same time.

  • @Dotto19
    @Dotto19 3 роки тому +4

    This is amazing and well executed. Very easy to understand. Thank you. . Do you have a video that explains the OOP using windows form please?

    • @ComputerScienceLessons
      @ComputerScienceLessons  3 роки тому +3

      Thank you. This series of videos covers OOP in Visual Basic .NET
      ua-cam.com/play/PLTd6ceoshprcFCsO49h2870tVzEeFpeWk.html
      :)KD

    • @Dotto19
      @Dotto19 3 роки тому +4

      @@ComputerScienceLessons Thank you and God bless you 🙏🏾🙏🏾

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

      @@ComputerScienceLessons This is one of the most helpful video I’ve ever watched . Do you do C# as well?

  • @george27121984
    @george27121984 3 роки тому +3

    Bravo

  • @TheInfinitum00
    @TheInfinitum00 3 місяці тому +1

    Hello Mr Drumm. First of all thank you for this great course. I finished the beginner and intermediate levels and I'll start Advanced series. I wonder, by any chance, did you include Database interaction with DB in this advanced course?

    • @ComputerScienceLessons
      @ComputerScienceLessons  3 місяці тому +1

      Hi. You are very welcome. I've made a series about building a theatre booking system in VB.NET. This includes some DB interaction using ADO.NET ua-cam.com/play/PLTd6ceoshprfziF0lglNcyKqqfzcXT-K8.html
      :)KD

    • @TheInfinitum00
      @TheInfinitum00 3 місяці тому

      @@ComputerScienceLessons Thank you!

  • @ryancameron6837
    @ryancameron6837 2 роки тому +2

    I'm still a little lost on why you'd need serialization when you can just use StreamWriter and Reader? Is it to organize data more effeciently?

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

      Good question. The simple answer is that you could. Arguably JSON serialisation is well supported (by lots of different systems and programming languages), you could also argue that it's fashionable! The format of a JSON file relates well to the structure of an object (but you could of course do something similar with a text file, or XML). If you want to store object data more permanently, you should use a database.
      There is a discussion of the pros and cons of serialisation here:
      softwareengineering.stackexchange.com/questions/191269/java-serialization-advantages-and-disadvantages-use-or-avoid
      :)KD

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

      @@ComputerScienceLessons Thank you so much! This helps a lot! Do you perhaps have a video link to a tutorial on storing information in databases?

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

    Thank you very much Sir for all the effort you put in that channel.
    I would like to ask, how the "ShouldSerializeSalary" method influences the serialization process. Who is calling that method and how it achieves the result.
    I am not aware of VB.NET but rather of C#. In C# we would have some attributes to mark the property that should not get serialized. The "ShouldSerializeSalary" method looks like "magic" to me

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

      Yea. Great effort, but efforts should be made to deprecate VB.NET altogether. Horrible abomination.

  • @matm4413
    @matm4413 3 роки тому +2

    nice

  • @chrisdaum1394
    @chrisdaum1394 Рік тому

    Thank you for your efforts, I learned a lot watching your tutorials.
    With this one I have one problem...
    The JSON file is lacking the square brackets at the beginning/end of the file and the commas between the datablocks.
    I couldn´t figure out how to insert these via JsonWriter.Indentation Chars.
    You might call me stupid, so please if there´s an easy solution give me a hint... 🙂
    thanks!!

  • @mohammedal-mudhafar4602
    @mohammedal-mudhafar4602 Рік тому +2

    MsgBox("Thank you so much :)_")

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

    Nice tutorial good Job. My Human Intelligence recognised 99% at least one clown and liar in the image.