Twitter API v1.1 with OAuth

Introduction The OAuth protocol enables websites or applications (Consumers) to access Protected Resources from a web service (Service Provider) via an API, without requiring Users to disclose their Service Provider credentials to the Consumers. More generally, OAuth creates a freely-implementable and generic methodology for API authentication. OAuth aims to unify the experience and implementation of… Read More Twitter API v1.1 with OAuth

Generate sql script using c# code

class Program { static void Main(string[] args) { string dbConnectionString = “Server=./sqlexpress;Database=mydata;User ID=sa;Password=test@111;Trusted_Connection=False;Encrypt=True;Connection Timeout=30;”; string databaseName = “mydata”; ScriptDatabase(dbConnectionString, databaseName); } public static string ScriptDatabase(string dbConnectionString, string databaseName) { SqlConnection conn = new SqlConnection(dbConnectionString); ServerConnection serverConn = new ServerConnection(conn); var server = new Server(serverConn); var database = server.Databases[databaseName]; var scripter = new Scripter(server); /* With… Read More Generate sql script using c# code

execute sql script c# code

public void Execute(string sqlfilePath) { string dbConnectionString = “”; try { using (StreamReader file = new StreamReader(filePath)) using (SqlConnection conn = new SqlConnection(dbConnectionString)) { StringBuilder sql = new StringBuilder(); string line; while ((line = file.ReadLine()) != null) { // replace GO with semi-colon if (line == “GO”) sql.Append(“;”); // remove inline comments else if (line.IndexOf(“–“)… Read More execute sql script c# code

create user to azure ad   services platforms author active-directory dotnet dstrockis Build a multi-tenant SaaS web application using Azure AD & OpenID Connect This sample shows how to build a multi-tenant .Net MVC web application that uses OpenID Connect to sign up and sign in users from any Azure Active Directory tenant, using the ASP.Net OpenID Connect OWIN… Read More create user to azure ad

global nuget directory

create nuget.config file <?xml version=”1.0″ encoding=”utf-8″?> <configuration> <config> <add key=”repositoryPath” value=”C:\Nuget Packages” /> </config> </configuration> copy this file to Solution Directory open notepad++ and find and replace text below find – ..\packages replace with – C:\Nuget Packages filters – *.csproj click find and replace button it will replace references . create folder C:\Nuget Packages Done! Build solution all nuget… Read More global nuget directory