Kotlin Tutorial: Basics learning on operators and types | Kotlin programming language | Part 1

Introduction In this Kotlin Tutorial: Basics learning on operators and types, you will learn about operators and types in the Kotlin programming language. In this part, we will explore numeric operators, usage of variables, types, and learn about strings. You will get the full benefits when you go through the tutorial in sequence. Reference on […]

Kotlin Tutorial: Getting Started

Introduction Kotlin tutorial getting started using REPL (Read-Eval-Print Loop) teaches you Kotlin Programming language with simple examples. You will learn the advantage of programming in Kotlin and install the IDE to practice. This Kotlin tutorial is mainly for the programmers who already know an object-oriented language and want to learn more about Kotlin. If you […]

Implement a simple timer using CountDownTimer in Android using Kotlin or Java

In this post, I will be covering how to Implement a simple timer using CountDownTimer in Android using Kotlin or Java. Android provides a utility class called CountDownTimer that you use to implement the timer. Schedule a countdown until a time in the future, with regular notifications on intervals that are set. Implementing CountDownTimer in Kotlin Android […]

How to resolve Cannot access a disposed object in Dotnet Core when injecting DbContext

Accessing DbContext after it is disposed will cause a “Cannot access a disposed object in dotnet Core when injecting DbContext” error. Entity Framework (EF) Core is a lightweight, open-source. EF Core can serve as an object-relational mapper (O/RM). A DbContext instance represents a session with the database and can be used to query and save […]

Implement background tasks using IHostedService and access scoped service using IServiceScopeFactory

It is easy to implement Background tasks and scheduled work using IHostedService and the BackgroundService class. Sometimes it is required certain work to be offloaded when a Web API request is processed. That work could be accessing database records and update some information on some tables based on existing data. In this post, I’m going […]