Tutorial by Examples: ti

Install the NLog.Config package. (NuGet 3 users should install NLog and add the config manually.) Write to logger: using NLog; public class MyClass { private static Logger logger = LogManager.GetCurrentClassLogger(); public void MyMethod1() { logger.Trace("Sample trace mess...
layout.scss nav { ul { margin: 0; padding: 0; list-style: none; li { margin: 0 5px; } } } output nav ul { margin: 0; padding: 0; list-style: none; } nav ul li { margin: 0 5px; }
The following should be added to your global .gitconfig file [merge] tool = kdiff3 [mergetool "kdiff3"] path = D:/Program Files (x86)/KDiff3/kdiff3.exe keepBackup = false keepbackup = false trustExitCode = false Remember to set the path property to point to th...
[diff] tool = kdiff3 guitool = kdiff3 [difftool "kdiff3"] path = D:/Program Files (x86)/KDiff3/kdiff3.exe cmd = \"D:/Program Files (x86)/KDiff3/kdiff3.exe\" \"$LOCAL\" \"$REMOTE\"
[merge] tool = intellij [mergetool "intellij"] cmd = cmd \"/C D:\\workspace\\tools\\symlink\\idea\\bin\\idea.bat merge $(cd $(dirname "$LOCAL") && pwd)/$(basename "$LOCAL") $(cd $(dirname "$REMOTE") && pwd)/$(basename "$REM...
[diff] tool = intellij guitool = intellij [difftool "intellij"] path = D:/Program Files (x86)/JetBrains/IntelliJ IDEA 2016.2/bin/idea.bat cmd = cmd \"/C D:\\workspace\\tools\\symlink\\idea\\bin\\idea.bat diff $(cd $(dirname "$LOCAL") && pwd)/$(ba...
Options are used for adding capabilities such as "User-Agent". Example in C#: var options = new PhantomJSOptions(); options.AddAdditionalCapability("phantomjs.page.settings.userAgent", "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0&qu...
GNU awk supports a sub-string extraction function to return a fixed length character sequence from a main string. The syntax is *substr(string, start [, length ])* where, string is source string and start marks the start of the sub-string position you want the extraction to be done for an optio...
To Convert you date in dd/MM/yyyy format into milliseconds you call this function with data as String public long getMilliFromDate(String dateFormat) { Date date = new Date(); SimpleDateFormat formatter = new SimpleDateFormat("dd/MM/yyyy"); try { date = formatter.p...
In the manifest we have fours dangerous runtime permissions from two groups. <!-- Required to read and write to shredPref file. --> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> <uses-permission android:name="android.permission.READ_EXTE...
This is an actual useful strategy to differentiate member data from parameters... Lets take this example : // Dog Class Example #include <iostream> #include <string> using std::cout; using std::endl; /* * @class Dog * @member name * Dog's name * @function bark * ...
Since Sphinx is available on the Python Package Index, it can be installed using pip: pip install Sphinx or you can also install using easy_install easy_install -U sphinx Then you can check that it has been correctly installed by executing the following command: > sphinx-quickstart --ver...
Variables can be used in string interpolation. This allows you to dynamically generate selectors, properties and values. And the syntax for doing so a variable is #{$variable}. $className: widget; $content: 'a widget'; $prop: content; .#{$className}-class { #{content}: 'This is #{$content}'...
Some CSS properties belong to a namespace, for instance border-right belongs to the border namespace. To write less, we can utilize property nesting, and skip these prefixes, even on multiple levels. If we needed to create a border on the right and left of a class named .borders we could write this...
SELECT EncryptByPassphrase('MyPassPhrase', 'This text will get encrypted') This will also encrypt but then by passphrase instead of asymmetric(certificate) key or by an explicit symmetric key.
inline int add(int x, int y);
Detailed instructions on getting acumatica set up or installed.
Graph Theory is the study of graphs, which are mathematical structures used to model pairwise relations between objects. Did you know, almost all the problems of planet Earth can be converted into problems of Roads and Cities, and solved? Graph Theory was invented many years ago, even before the in...
SQL Server and SQLite allow to create indexes that contain not only a subset of columns, but also a subset of rows. Consider a constant growing amount of orders with order_state_id equal to finished (2), and a stable amount of orders with order_state_id equal to started (1). If your business make ...
Attributes can be useful for denoting metadata on enums. Getting the value of this can be slow, so it is important to cache results. private static Dictionary<object, object> attributeCache = new Dictionary<object, object>(); public static T GetAttribute<T, V>(this V va...

Page 358 of 505