Tuesday, 13 March 2018

How to use AngularJS filters in html controls

Description : in this post how to convert datem currency, lowercase and uppercase in angular js simple pass filter from filter list

Filters List :

- currency : format number in currency format
- date : format date to formated date
- lowercase : fromat string to lowercase
- uppercase : format string to uppercase

How to create table using SQL CREATE TABLE

Description : CREATE TABLE statement use for create a table in your existsing SQL database

Syntax :

CREATE TABLE YourTableName (
    TableColumn1 DataType,
    TableColumn2 DataType,
    TableColumn3 DataType,
)

Example :

CREATE TABLE Employee (
    EmployeeID Int,
    EmployeeName Varchar(50),
    City Varchar(50),
    PhoneNo Varchar(50)
)

Syntax : Syntax for how to create table using another table of database

CREATE TABLE YourTableName AS
SELECT Column1,
Column2 FROM CreatedTableName

How to DROP Database using SQL DROP DATABASE

Description : SQL DROP DATABASE statement drop existing database from your SQL

Syntax :

DROP DATABASE YourDatabaseName

Example :

DROP DATABASE EmployeeDB

How to create database in SQL using CREATE DATABASE Statement

Description : SQL CREATE DATABASE statement use for create Database in SQL

Syntax :

CREATE DATABASE YourDatabaseName

Example :

CREATE DATABASE EmployeeDB

How to fix VS2017 missing XAML tools build error

Error :

The "Microsoft.Build.Tasks.Xaml.PartialClassGenerationTask" task could not be loaded from the assembly C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\amd64\XamlBuildTask.dll. Could not load file or assembly 'file:///C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\amd64\XamlBuildTask.dll' or one of its dependencies. The system cannot find the file specified. Confirm that the <UsingTask> declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements Microsoft.Build.Framework.ITask

To solve this issue just open visual studio installer and go to Individual Components tab and select "Windows Workflow Foundation"


Thursday, 1 March 2018

How to call function after complete page load in javascript

Description : in this post how to call function after complete page load in aspx, html, cshtml page just add below code in script

Write below code and add your function in setInterval

<script>
        document.addEventListener("DOMContentLoaded", function () {
            setInterval(calculateTotalFees(), 0);
        }, false);
</script>

How to upercase / lowercase text in SQL query

Description : in this post how to get result of state name in upper case  or in lower case

Query Syntax for upper case text return in result

- SELECT UPPER(sta_StateName) AS State FROM StateMaster

Result :

DISTRICT OF COLUMBIA
TEXAS
NEW MEXICO

Query Syntax for lower case text return in result

- SELECT LOWER(sta_StateName) AS State FROM StateMaster

Result :

district of columbia
texas
new mexico

Screen Shot :