Tutorial by Examples: al

The below code will turn the table with an id of tableid into a DataTable, as well as return a DataTables API instance: $(document).ready(function() { $('#tableid').DataTable(); }); Compare this to the below code, which will turn the table into a DataTable but will not return a DataTables ...
' Sometimes we don't need to evaluate all the conditions in an if statement's boolean check. ' Let's suppose we have a list of strings: Dim MyCollection as List(Of String) = New List(of String)() ' We want to evaluate the first value inside our list: If MyCollection.Count > 0 And MyCo...
Creating an alert dialog AlertDialog.Builder builder = new AlertDialog.Builder(Context); builder.SetIcon(Resource.Drawable.Icon); builder.SetTitle(title); builder.SetMessage(message); builder.SetNeutralButton("Neutral", (evt, args) => { // code here for handling the Neutral...
CREATE UNIQUE INDEX idx_license_id ON Person(DrivingLicenseID) WHERE DrivingLicenseID IS NOT NULL GO This schema allows for a 0..1 relationship - people can have zero or one driving licenses and each license can only belong to one person
Demo HTML <script type="x-template" id="form-template"> <label>{{inputLabel}} :</label> <input type="text" v-model="name" /> </script> <div id="app"> <h2>{{appName}}</h2> <form-co...
In normal mode, we can increment the nearest number on the line at or after the cursor with <C-a> and decrement it with <C-x>. In the following examples, the cursor position is indicated by ^. Incrementing and decrementing numbers for i in range(11): ^ <C-x> decrements ...
Single JAR Sometimes you have a local JAR file you need to add as a dependency to your Gradle build. Here's how you can do this: dependencies { compile files('path/local_dependency.jar') } Where path is a directory path on your filesystem and local_dependency.jar is the name of your local...
Electron ports HTML web applications to native applications for a range of devices, including creating native desktop applications. It's also very easy to get started! To begin, we must have electron, nodejs, npm, git and meteor installed. Familiarity with these tools is vital for working with Mete...
Installing Angular Material npm npm install angular-material --save bower bower install angular-material --save jspm jspm install angular-material From Cloud cdnjs | jsdelivr | googlecdn Getting Started (blank shell) <html lang="en"> <head> <meta name...
Given that the function has a proper prototype, integers are widened for calls to functions according to the rules of integer conversion, C11 6.3.1.3. 6.3.1.3 Signed and unsigned integers When a value with integer type is converted to another integer type other than _Bool, if the value can be r...
Pointer conversions to void* are implicit, but any other pointer conversion must be explicit. While the compiler allows an explicit conversion from any pointer-to-data type to any other pointer-to-data type, accessing an object through a wrongly typed pointer is erroneous and leads to undefined beh...
This example wraps the asynchronous method oauth2.client.getToken(callback) from the package NPM package simple-oauth2into a Fiber so that the method may be called synchronously. const oauth2 = require('simple-oauth2')(credentials); const credentials = { clientID: '#####', clientSecret...
Two sequences whose corresponding elements are equal and which have the same number of elements are considered equal. SequenceEqual Determines whether two sequences are equal by comparing elements in a pair-wise manner. Method Syntax // SequenceEqual var numbers1 = new int[] { 1, 2, 3, 4,...
When you bind a service to your application credentials become available through the VCAP_SERVICES environment variable. This environment variable contains JSON containing the credentials for all bound services. Example VCAP_SERVICES environment variable { "push-reappt": [ { ...
String#replace can have a function as its second argument so you can provide a replacement based on some logic. "Some string Some".replace(/Some/g, (match, startIndex, wholeString) => { if(startIndex == 0){ return 'Start'; } else { return 'End'; } }); // will retur...
You can add your own validations adding new classes inheriting from ActiveModel::Validator or from ActiveModel::EachValidator. Both methods are similar but they work in a slightly different ways: ActiveModel::Validator and validates_with Implement the validate method which takes a record as an arg...
Use the UseCors() extension method on the IApplicationBuilder in the Configure method to apply the CORS policy to all requests. public void ConfigureServices(IServiceCollection services) { services.AddMvc(); services.AddCors(); } public void Configure(IApplicationBuilder app) { ...
To get SSIS working for a SQL Server 2005 environment Acquire SQL Server 2005 (x86 or 64 bit) images. Mount the second disk and launch the installation wizard "Next" your way through the dialogs until you see see this screen. Under Client Components, ensure Business Intelligence De...
You can also apply a mixin globally. Use caution! Once you apply a mixin globally, it will affect every Vue instance created afterwards. When used properly, this can be used to inject processing logic for custom options: // inject a handler for `myOption` custom option Vue.mixin({ created: func...
Add the following pom to the dependencies section of your gradle build file : project.dependencies { compile 'org.roboguice:roboguice:3.+' provided 'org.roboguice:roboblender:3.+' }

Page 64 of 269