Skip to content
  • Home
  • About
    • Our Partners & Clients
  • Products & Services
  • Contact Us
  • Blog
    • Coding Tips
    • Design
    • Free Resources
  • Search
Origine IT
Origine IT
Break the rules, Simplify
  • Home
  • About
    • Our Partners & Clients
  • Products & Services
  • Contact Us
  • Blog
    • Coding Tips
    • Design
    • Free Resources
  • Search
Category: Coding
Home Case Studies Archive for category "Coding"

Category: Coding

MSSQL – split value in single column into multiple rows

Problem i have a supplier table that stores supplier email, and the column can store 1 or more email address separated by carriage return character. …

Read more"MSSQL – split value in single column into multiple rows"

MSSQL – Restore a database backup to new database (new name) from TSQL

1. make sure you have exclusive access to the database, means the database is not being used or there are pending transaction USE master GO …

Read more"MSSQL – Restore a database backup to new database (new name) from TSQL"

Copy and Paste screenshot to div using javascript

    <html> <head> <script language=”javascript” src=”scripts/jquery-3.0.0.min.js”></script> <script> $(document).ready(function(e) { $(“#textareaid”).bind(“paste”, function(e){ var items = (e.clipboardData || e.originalEvent.clipboardData).items; console.log(JSON.stringify(items)); // will give you the mime …

Read more"Copy and Paste screenshot to div using javascript"

Javascript Regular Expression

In javascript, we can use regular expression to test if a given string contain the numbers, alphabet, or special characters. for example, var re1 = …

Read more"Javascript Regular Expression"

How to convert json string to Dictonary List in C# ?

To convert a JSON string into a Dictionary list, string jsonstring = “[{\”no\”:\”1\”}, {\”no\”:\”2\”}]”; List<Dictionary<string, object>> items = new System.Web.Script.Serialization.JavaScriptSerializer().Deserialize<List<Dictionary<string, object>>>(jsonstrig); foreach(Dictionary<string, object> item in …

Read more"How to convert json string to Dictonary List in C# ?"

How to send email with attachment in C# via Office365.com ?

This aspx code sends email with attachment   <%@ Page Language=”C#” AutoEventWireup=”true” debug = “true” %> <%@ Import namespace=”System.IO” %> <%@ Import namespace=”System.Net” %> <%@ …

Read more"How to send email with attachment in C# via Office365.com ?"

How to connect to MSSQL in C# ?

This aspx code connects to MSSQSL and retrieve data from “product” table.   <%@ Page Language=”C#” AutoEventWireup=”true”%> <%@ Import namespace=”System.IO” %> <%@ Import namespace=”System.Collections” %> …

Read more"How to connect to MSSQL in C# ?"

How to generate a random number in C#

This sample code generate 30,000 random 5-character-alphanumeric code in C#. The codes are stored in Hashset to be used for duplicate check.   Random random …

Read more"How to generate a random number in C#"

How to generate QR Code in c# ?

This sample code generate a QR code in C#, and display the QR code on web page Download the library from https://github.com/codebude/QRCoder/ * QRCoder is …

Read more"How to generate QR Code in c# ?"
2021 © Origine IT
Back to Top