Posts

Create PopUp in .Net MAUI

Image
Popup in .net Maui Please, support my blog by clicking on our sponsors ad! Popups are an integral part of user interface design, allowing developers to convey information and interact with users in a more engaging manner. In .NET MAUI, there are three main types of popups available: DisplayAlert, DisplayPrompt, and Plugin.Maui.Popup. In this blog post, we will dive into each of these popup types, explore their functionalities, and provide code examples to demonstrate their usage. DisplayAlert: Simple and Informative Popups DisplayAlert is a built-in feature in .NET MAUI that provides a straightforward way to display alert popups to users. These popups typically present important messages, notifications, or warnings that require user acknowledgement. Here's an example of how to use DisplayAlert in your .NET MAUI application: DisplayAlert("Display Alert", "Welcome to DotNet Maui", "OK","Cancel",FlowDirection.RightToLeft); In the co

Animation in .net MAUI

Image
 Animation will add more good looking UI of the mobile application. Let's see how to add animation using lottie file. Lottie is a mobile library for andriod and IOS that prases Adobe After Effects animations exported as JSON. Lottie Animation in .NetMaui You can go through the lottie website. This lottie provide pently of cool animation and also you can create own animation. Please, support my blog by clicking on our sponsors ad! Let's get started First add install "SkiaSharp.Extended.UI.MAUI" in your project using nugget manager. This nugget is prerelease so please check "Include Prerelease". Lottie animation in .net Maui Next step is to Bootstrap Skiasharp plugin in MAUIProgram file and add UseSkiaSharp() to the app builder.  Below is the code: public static class MauiProgram { public static MauiApp CreateMauiApp() { var builder = MauiApp.CreateBuilder(); builder

XAML Files

Image
 XAML stands for E x tensible A pplication M arkup L anguage. When project is created you can see the maui project structure In this project, there are xaml file(App.xaml,AppShell.xaml,MainPage.xaml) each of this page support xaml language and when you expand it, each will have associated cs file.      In each contentpage of Maui Project, you observe some code at starting of the page xmlns is used for binding namespace. "http://schemas.microsoft.com/dotnet/2021/maui" is an namespace which is version identifier which contain certain information If you remove this line then it will throw error. blue lines says that there is an error. this is because namespace has been removed  The xmlns:x attribute indicates an additional XAML namespace, which maps the XAML language namespace.It define some xaml element. Using x we can use some element like x:class,x:name etc. x:class define the name of the class the use in code behind. Hope this is helpful to you. please share your fee

Introduction to .NET MAUI: Building Cross-Platform Applications with .NET and C#

Image
 .NET MAUI stands for .NET Multi-platform App UI, which is a UI framework that allows developers to create cross-platform applications for iOS, Android, Windows, and macOS using .NET and C# programming language. It is an evolution of the Xamarin.Forms framework and is built on top of .NET 6 Introduction: In today's world, businesses need to create applications that run on multiple platforms to reach a wider audience. However, building applications for different platforms can be a time-consuming and complicated process. This is where .NET MAUI comes in. .NET MAUI allows developers to create cross-platform applications for iOS, Android, Windows, and macOS using .NET and C# programming language. What is .NET MAUI? .NET MAUI is a UI framework that enables developers to create cross-platform applications using a single codebase. It is built on top of .NET 6 and is an evolution of the Xamarin.Forms framework. With .NET MAUI, developers can create native applications that run on multiple

Exploring Xamarin Forms: Enhancing Your App's UI with Images

Image
In Xamarin.Forms, the Image control is used to display an image in your application's user interface. The Image control can display images from a variety of sources, including resources, files, and URLs. The Image control supports several properties that can be used to control the way the image is displayed, such as Aspect, HeightRequest, and WidthRequest. You can also use data binding to dynamically set the Source property of the Image control. Please, support my blog by clicking on our sponsors ad! Please watch the video to understand image briefly Here's an example of how to use the Image control in your Xamarin.Forms application: Add the Image control to your XAML page: <Image Source="myImage.png" /> Set the Source property of the Image control to the path of the image you want to display. You can use a local file path or a URL: // Local file path <Image Source = "myImage.png" /> // URL <Image S

Find out how to implement appshell in xamarin forms

Image
Xamarin.Forms 4.0 introduced the amazing feature called Xamarins.Forms Shell. It has reduced complexity of creating mobile apps. Please, support my blog by clicking on our sponsors ad! It is used for Navigation,URI base routing, integrated search handling. Before Appshell there was independent feature: MasterDetailPage TabbedPage NavigationPage but Appshell has combine this and make easy creating apps. > You can add xaml file in your project and named it as AppShell.xaml and Update it like below code: AppShell.Xaml <?xml version="1.0" encoding="utf-8" ?> <Shell xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" x:Class="XamarinCourse.AppShell"> </Shell> AppShell.Xaml.cs public partial class AppShell : Shell { public AppShell() { InitializeComponent(); } } You can call this class

Map in xamarin form

Image
  Maps in xamarin forms Please, support my blog by clicking on our sponsors ad! First Add Nugget in all projects Xamarin.Forms.Map Lets Configure in IOS project to show map in iphone  In AppDelegate.cs file, Initialize the map below "global::Xamarin.Forms.Forms.Init();" line in "FinishedLaunching" method FormsMaps.Init(); Add following key in info.plist for permission <key>NSLocationWhenInUseUsageDescription </key> <string>Allow map to access to your location while you use the app.</string> <key>NSLocationAlwaysAndWhenInUseUsageDescription</key> <string>Always Allow map to access to your location</string> <key>NSLocationUsageDescription</key> <string>We would like to show you a map</string> <key>NSLocationAlwaysUsageDescription</key> <string>We would like to show you a map</string> Now Let's configure for android proj