Posts

Start working with CDS in Power Platform

To use the Common Data Service (CDS) in the Power Platform, follow these steps: Go to the Power Platform admin center ( https://admin.powerplatform.microsoft.com/ ) and sign in using your credentials. Click on the 'Environments' option in the left-hand menu and select the environment where you want to create the CDS. Click on the 'Settings' icon at the top right-hand corner of the screen and select 'Power Platform Admin Center'. In the Power Platform Admin Center, click on 'Common Data Service' in the left-hand menu. You can now create a new CDS database by clicking on the 'New' button. Choose a display name for the CDS database and click on the 'Create' button. Once the CDS database is created, you can start adding entities to it. Click on the 'Entities' option in the left-hand menu and then click on 'New Entity'. Fill in the entity details such as the entity name, display name, and description. You can then add attribute...

Create First canvas app in Power Apps

Steps to create your first canvas app in Power Apps: Go to the Power Apps website (https://powerapps.microsoft.com/) and sign in with your Microsoft account. If you don't have an account, you can create one for free. Click on the "Create" button in the left-hand menu and select "Canvas app". Choose a blank app or a pre-built template for your canvas app. If you choose a blank app, you will have to build the app from scratch. If you choose a template, you will have a pre-built app that you can customize. Give your app a name and select a screen size. You can choose from different sizes for phone, tablet, or computer screens. Once your app is created, you will see the Power Apps Studio. This is where you will build your app by adding screens, data sources, and controls. To add a new screen, click on the "Add screen" button in the left-hand menu and select the type of screen you want to add. To add a data source, click on the "Data sources" butt...

Initializing list and collection in c#.net

Sure, here's a brief overview of initializing a list and collection in C#: Initializing a List: A list is a collection that can be modified. Here's how you can initialize a list in C#: List<string> names = new List<string>(); // create an empty list names.Add("John"); // add items to the list names.Add("Mary"); Initializing a Collection: A collection is a grouping of objects of the same type. Here's how you can initialize a collection in C#: Collection<string> names = new Collection<string>(); // create an empty collection names.Add("John"); // add items to the collection names.Add("Mary"); Note that both lists and collections can be of different types, depending on what you need them for.  Also, there are other ways to initialize lists and collections in C#, but these are the most basic methods.

RichTextBox Field in power apps as Sharepoint online defalut forms.

Let's say you have some rich textbox columns in Sharepoint online, when we create a default canvas app the columns will show as a plain multiline text field. when we view this content in view mode the content of the Richtext field with HTML added to it.  So to correct this remove the multiline field and add a rich textbox  To replace a multiline text field with a Rich Text Box in Power Apps, you can follow these steps: Delete the multiline text field from the screen by selecting it and pressing the "Delete" key. Insert a new Rich Text Box control onto the screen by selecting it from the "Insert" menu. In the right-hand pane, under the "Data" tab, Change some properties as Default is set to Parent.default and DisplayMode as Parent.DisplayMode. These fields are needed to be set as the value sync automatically with the parent.  Configure the appearance of the Rich Text Box control, such as the font size and color, by selecting the control and using the fo...

Power Apps Choice Column Default Value with connector as Sharepoint

 To change the default choice-value in a Power Apps canvas app, you can follow these steps: Select the control that contains the choice field in which you want to change the default value. In the right-hand pane, under the "Data" tab, locate the "Default" property. Click on the "Default" property to open the formula bar. To change the default value of a choice field, you will need to provide the formula that specifies the value. For example, if you have a choice field with the options "Red," "Green," and "Blue," and you want to set the default value to "Green," you can enter the following formula:                     "Green" Alternatively, you can use the "First" or "Last" functions to set the default value to the first or last option in the list. For example:                     First([@Choices].Value)                ...

Understanding Power BI

 Power BI is a business analytics service developed by Microsoft that allows users to analyze data and share insights using interactive dashboards, reports, and data visualizations. The service is part of the Microsoft Power Platform, which also includes Power Apps and Power Automate. With Power BI, users can connect to a wide range of data sources, such as Excel spreadsheets, SQL databases, and cloud-based services such as Microsoft Azure and Dynamics 365. Once connected, Power BI provides a range of tools for creating interactive dashboards, reports, and data visualizations that can be shared with others. Power BI provides a user-friendly interface that allows users to easily create, modify, and share their data visualizations. The service includes a wide range of pre-built visualizations, such as charts, maps, and gauges, as well as custom visualizations developed by the Power BI community. Power BI also includes built-in AI capabilities, such as natural language query, which al...

Understanding Power Automate

 Power Automate is a cloud-based service developed by Microsoft that allows users to create automated workflows between different applications and services. The service was previously known as Microsoft Flow, but was rebranded as Power Automate as part of the Microsoft Power Platform. With Power Automate, users can create custom workflows that can integrate with various services, including Microsoft Office 365, Dynamics 365, SharePoint, OneDrive, and many others. These workflows can be triggered automatically based on certain events, such as receiving an email or a new file being added to a SharePoint document library. Power Automate provides a range of pre-built templates and connectors that can be used to create workflows quickly and easily. Users can also create their own custom workflows using a drag-and-drop interface, with no coding required. Workflows can include a wide range of actions, such as sending email notifications, creating new files or records, or updating data in ...

Understanding of Power Query

Power Query is a data transformation and cleaning tool developed by Microsoft, which is available as an add-in for Microsoft Excel and as part of the Microsoft Power BI suite. Power Query allows users to import, transform, and cleanse data from various sources in order to create clean, organized data tables that can be used for analysis and reporting. With Power Query, users can connect to a wide range of data sources, including databases, spreadsheets, text files, and web pages. Once connected, Power Query provides a range of tools for transforming the data, such as filtering, sorting, grouping, pivoting, and merging. Users can also create custom calculations and transformations using the M language, which is the scripting language used by Power Query. Power Query has a user-friendly interface that allows users to easily navigate through the various data transformation steps. It also provides a preview of the transformed data, allowing users to see the changes in real-time. Power Quer...

Understanding Power App

 Power Apps is a low-code platform developed by Microsoft that allows users to build custom applications without needing extensive coding knowledge. With Power Apps, users can create mobile and web applications that can integrate with various data sources such as Excel spreadsheets, SharePoint lists, or SQL databases. Power Apps provides a range of pre-built templates and connectors that can be used to create apps quickly and easily. The platform uses a drag-and-drop interface that allows users to add visual elements such as buttons, forms, and charts to their apps. Users can also customize the layout and functionality of these elements to fit their specific needs. Power Apps also provides built-in security and compliance features to ensure that data is protected and meets regulatory requirements. Users can control access to their apps and data sources using role-based security and multi-factor authentication. In addition to building custom applications, Power Apps can also be used...

Installing and using LESS.(PART- 3)

Hello readers, I am back here witht the lasst part of installation of the LESS. This lesson also includes the details about the different features of LESS. Now, In a moment we are about to start with part-3 Escaping Want to include the non valid css sytax or text that LESS doesn't recognize. LESS has a solution for that also.It may be some crazy Microsft Hack or may be some easter egg you want to place.You can use escaping To avoid throwing errors and breaking LESS. .class { filter: ~"progid:DXImageTransform.Microsoft.Alpha(opacity=20)"; } /* Will actually be outputted like this: */ .class { filter: progid:DXImageTransform.Microsoft.Alpha(opacity=20); } Importing Importing is pretty standard, too. The standard @import: 'classes.less' ; works just fine. If, however, you’re importing another LESS file, then the file extension is optional, so @import 'classes' ; would work as well. If you wa...

Installing and using LESS.(PART- 2)

Here we are about to understand the installation of the LESS. This lesson also includes the details about the different features of LESS. These all the details are divided into 3 different parts. Now, In a moment we are about to start with part-2 Operations This is about what you would expect: using fixed numbers or variables to perform mathematical operations in your styles. @base_margin: 10px; @double_margin: @base_margin * 2; @full_page: 960px; @half_page: @full_page / 2; @quarter_page: (@full_page / 2) / 2; For the record, I am aware that I could have also divided by four to get the @quarter_page variable, but I wanted to illustrate that the parentheses rule from the “order of operations” also applies. Parentheses are also required if you’re going to perform operations within compound properties; for example, border: (@width / 2) solid #000. Sass is a lot more versatile with numbers than...

Installing and using LESS.(PART- 1)

Image
Here we are about to understand the installation of the LESS. This lesson also includes details about the different features of LESS. All the details are divided into # different parts. Now, In a moment we are about to start with Part-1 Installation  Including LESS in something that you’re building is about as easy as it gets: Go get yourself a copy of less.js; Create a file to put your styles in, such as style. less; Add the following code to your HTML <head> ; <link rel="stylesheet/less" type="text/css" href="styles.less"> <script src="less.js" type="text/javascript"></script> Note the rel attribute of the link. You are required to append the /less to the end of the value for LESS to work. You are also required to include the script immediately after the link to the style sheet. If you’re using HTML5 syntax, remember to add  type="text/ and the type="text/javascript ". Ther...

Introduction to LESS.

Introduction To LESS I am using CSS from more then 5 years. When i started using LESS,it was a better way to write the CSS in the form of Code including variable, functions, and other programming contracts.The color palette providing a fixed boundary which helps me to prevent going crazy with colors and deviating my specified styling.  Some Features of Less are as Follows. 1. Mixins – Classes for classes. 2. Parametric mixins – Classes to which you can pass parameters, like functions. 3. Nested Rules – Classes within classes, which cut down on repetitive code. 4. Operations – Math within CSS. 5. Color functions – Edit your colors. 6. Namespaces – Groups of styles that can be called by references. 7. Scope – Make local changes to styles. 8. J avaScript evaluation – JavaScript expressions evaluated in CSS. If you want to read about LESS more  here(wikipedia)  or  here(lesscss.org) Other Blogs by ...

Difference between Less and CSS ?

Many of you may be familiar with the concepts of CSS. In CSS we can not write loops ,logic or many other programming constructs such if-else etc.Thus we can say css is a static language. On the other hand LESS or (SCSS) are CSS pre-processors. You can think of it as CSS with programming constructs, which help you in making your code modular and reusable. One possible use case is you can develop a theme system with LESS, its very easy by using variables for colors etc and changing the variable values to create a new theme for your webpage. Take a look at this example taken from Getting started | Less.js. @base: #f938ab; .box-shadow(@style, @c) when (iscolor(@c)) { -webkit-box-shadow: @style @c; box-shadow: @style @c; } .box-shadow(@style, @alpha: 50%) when (isnumber(@alpha)) { .box-shadow(@style, rgba(0, 0, 0, @alpha)); } .box { color: saturate(@base, 5%); border-color: lighten(@base, 30%); div { .box-shadow(0 0 5px, 30%) } } Compiles to .box { color...

Caching in MVC5 ?

Caching in MVC5 Caching is the most important aspect of high-performance web application.Caching is way of storing data when fetching of data is frequent hence praticlly imprving performnce of application. Advantages of Caching Reducing round trips Reducing Server database round trips Better Performance Lesser Network Traffic For Caching in MVC we use Output Cache Filter. Output Cache Filter This filter will allow us to cache the data for any action method for the specified time, by default the time limit is 60 seconds. This means when any cal is made the data will be cached for next 60 minute after that 60 seconds if there is any call the data will be cached again. Example of using Output Cache Filter [OutputCache(Duration=20, VaryByName="none")] public ActionResult Index() { ViewBag.Message=DateTime.Now.ToString(); return View(); } Here the code will cacche the index page for next 20 seconds. We can check the cache effect by placing the ViewBag.Me...

Initializing variable in c#.net ?

We are learning a new language daily so we need to remember how too initialize variables in c#.net so bookmark this and use it as your daily guidebook to initialize variable in c#.net. Initialize variables in C#.net Single Dimensional Array  Integers <code> int[] n1= new int[4]{2,3,1,4}; int[] n2= new int[]{1,2,3,4}; int[] n3= {1,2,3,4,}; </code> Strings <code> string[] s1= new string[4]{"tom","jerry","harry","ben"}; string[] s2= new string[]{"tom","jerry","harry","ben"}; string[] s3= {"tom","jerry","harry","ben"}; </code> Multi-dimensional array. Integer <code> int[,] n1 = new int[3, 2] { {1, 2}, {3, 4}, {5, 6} }; int[,] n2 = new int[,] { {1, 2}, {3, 4}, {5, 6} }; int[,] n3 = { {1, 2}, {3, 4}, {5, 6} }; </code> String <code> string[,] n1 = new string["...

Filters in MVC5?

Filters: Filters in mvc are a way to implement cross cutting concerns which means Functionaity that is used aross the application based on different layers. These fnctionality includes logging, exception handling, cacheing, Authorization, Authentication etc. These function are required to kept at single place so as to mkae changes easier.Advavntage that filters provide as they use common logic to implemented using cross cutting concerns that can be applied on different controllers and action methods. There are generally two types of filters that are Global filters and Controller filters.  We can create a Global filter by creating a class nad registering it as a global filter  <code> public class DemoGlobalFilterAttribute : ActionFilterAttribute    {        public override void OnActionExecuting(ActionExecutingContext context)        {            base.OnActionExecuti...

Attribute based routing in MVC 5 ?

Attribute Based Routing :Attribute based routing can defined as route configuration in the same place where action method is defined. This is way of setting the route configuration for every single action method in same section where action is defined for better usage and fast configuration. To enable Attribute based routing we need to add a small section into the RouteConfig.cs file, public static void RegisterRoutes(RouteCollection routes) { routes.MapMvcAttributeRoutes(); } Optional Parameter: We can specify the optional parameters in the URL in route attribute only using "?" character. [Route("Products/Electronics/{id?}")] public ActionResult GetElectronicItems(int? id) { ViewBag.Id = id; return View(); } Route Constraints :  Specify parameter constraints placing the constraint name after the parameter name separated by colon.Here the action methods needs a id of int type to be worked upon. [Route("Products/Electronics/{id:int}")...

Creating page for MVC in C#.net .

For this initially we need to have a model. Let the model be Cust for Customer public class Cust() { [DisplyName= "CustmerId"] public int Cust_Id{get ; set;} [DisplayName= "Cusotmer Name"] public string Cust_Name {get; set;} [DisplayName = "Cusomter Nick Name"] public string Cust_Nickname{get; set;} } Now we need to create a controller . Let the controller name Be Customer Initially we need to add the customer to the database To create any customer using this application we need to create two action methods, First will generate the html for the user to view the page to be created. Another, this methods will take the arguments from the UI(creation page) [HttpGet] public ActionResult Create() { return View(); } [HttpPost] public ActionResult Create(Cust NewCustomer) { //var date= DateTime.Today; // this may be anything you nee to pass on to next method // Do some thing on the code   return View("Cust"); //return...

Create a DataTable from a Class using reflection .

There are many solution to this problem, For this we use a technical process called Reflection. Reflection: To dynamically create an instance  of a type, bind the type to an existing  object ad invoke its methods or access its fields and properties. If you are using attributes in your code, reflection enables you to access them. 1. Use AsEnumerable()  method to support LINQ: private List<T> ConvertToList<T>(DataTable dt)     {         var columnNames = dt.Columns.Cast<DataColumn>()             .Select(c => c.ColumnName)             .ToList();         var properties = typeof(T).GetProperties();         return dt.AsEnumerable().Select(row =>             {                 var objT = Activator.CreateInstance<T>();         ...