Tutorial by Examples

In this article we will use a simple database called “Company” with two tables: [dbo].[Categories]([CategoryID], [CategoryName]) [dbo].[Products]([ProductID], [CategoryID], [ProductName]) 1-1 Generate Entity Framework code In this layer we generate the Entity Framework code (in project library) ...
In this layer we will write the application business. It is recommended for each presentation screen, you create the business interface and implementation class that contain all required functions for the screen. Below we will write the business for product screen as example /// <summary> ...
In this example we will use the Business layer in Presentation layer. And we will use MVC as example of Presentation layer (but you can use any other Presentation layer). We need first to register the IoC (we will use Unity, but you can use any IoC), then write our Presentation layer 3-1 Register ...
Graphically In XCode a simple NSTextView can be created by dragging and dropping one from the Object Library. This NSTextView sits inside an NSScrollView that is automatically set to expand vertically with the text view. Make sure when option(⌥)-dragging you make connections to the text view and...
The preferred and most common way of making an NSFont object is the following: Objective-C // Name is PostScript name of font; size is in points. NSFont *essayFont = [NSFont fontWithName:@"Times New Roman" size:12.0];
$username = 'user' $password= 'password' $DESTINATION = "D:\test\latest.tar.gz" $client = New-Object System.Net.WebClient $client.Credentials = new-object System.Net.NetworkCredential($username, $password) $lastModifiedResponse = $client.DownloadString('https://domain.org.com/artifact...
Here I am presenting how to create first basic program in Swift 3 language. First you need to have any basic programming language knowledge or not having then be ready to learn it from beginning. Requirements for developments: MAC OS - Version 10.11.6 or later for new Xcode 8.2 Xcode - Version ...
Here we are managing multiple collection there delegate methods with didselect events. extension ProductsVC: UICollectionViewDelegate, UICollectionViewDataSource{ // MARK: - UICollectionViewDataSource func collectionView(_ collectionView: UICollectionView, numberOfItemsI...
Every application needed to store User Session or User related details inside application in UserDefaults.So we made whole logic inside a Class for managing UserDefaults better way. Swift 3 import Foundation public struct Session { fileprivate static let defaults = UserDefaults.standard ...
Combining change of character case with Enumeration_IO and using a text buffer for the image. The first character is manipulated in place. with Ada.Text_IO; use Ada.Text_IO; with Ada.Characters.Handling; use Ada.Characters.Handling; procedure Main is type Fruit is (Banana, Pear, Orange, Me...
The component code is given as below. import { Component } from '@angular/core'; @Component({ selector: 'my-app', template: '<h1>{{title}}</h1>' }) export class MyAppComponent{ title = 'welcome'; } For angular testing, angular provide its testing utilities along with t...
1. Fetching the JSON response for last modified (latest) artifact latestArtifactUriResponse=curl -u username:password --silent https://hostname.com/artifactory/api/storage/<repo_name>/<folder_name>/?lastModified | grep uri | awk '{ print $3 }' | sed s/\"//g | sed s/,//g It will ...
The following server-side configuration allows CORS request to work along with Windows Authentication (no anonymous must be enabled in IIS). web.config - allow unauthenticated (anonymous) preflight requests (OPTIONS) <system.web> <authentication mode="Windows" /> &l...
The following example shows how to properly construct both GET and POST requests against Web API 2 (CORS must be configured server-side, if sent from another domain): <script type="text/javascript" src="https://code.jquery.com/jquery-3.1.1.js"></script> CORS with Wi...
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.6.1/angular.js"></script> CORS with Windows Authentication test (Angular) <script type="text/javascript"> var app = angular.module('myApp', []); app.c...
Operational System Setup (Linux-CentOS x64 or RedHat x64) 1-Increase the swap space to a minimum of 2 Gb 2-Space and CPU requirements: -Vertica requires at least 1 GB per CPU. -disk utilization per node should no more than sixty percent (60%). Disk space is temporarily required by certain query...
BEGINS - returns TRUE if one string begins with another string. string1 BEGINS string2 If string1 BEGINS with (or is equal to) string2 this will return true. Otherwise it will return false. If string two is empty ("") it will always return true. BEGINS is very useful in queries wher...
There are standard functions built in for comparing equality, inequality etc. NameSymbolAlternativeExampleEqual=EQi = jNot equal<>NEi <> jLess than<LTi < jless than or equal<=LEi <= jGreater than>=GTi > jGreater than or equal≥=GEi >= j The symbol can be exchanged w...
RANDOM - generates a random number RANDOM(low, high) Generates a pseudo random integer between low and high // Example that generates 20 random numbers between 1 and 20 (1 and 20 included) DEFINE VARIABLE i AS INTEGER NO-UNDO. DO i = 1 TO 20. DISPLAY i RANDOM(1, 20). PAUSE. ...
Python includes a profiler called cProfile. This is generally preferred over using timeit. It breaks down your entire script and for each method in your script it tells you: ncalls: The number of times a method was called tottime: Total time spent in the given function (excluding time made in c...

Page 1116 of 1336