Tuesday, 28 June 2016

printing up Arrow and down arrow

Printing up  Arrow and down arrow

Pring Up arrow
System.Text.RegularExpressions.Regex.Unescape("\u2191")
Printing Down arrow
System.Text.RegularExpressions.Regex.Unescape("\u2193")

Friday, 22 April 2016

Configuring Sql Session State


Open a command prompt and locate the following path: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 based on your OS version and .NET version
Use the following statement:
Using default ASPState database and SQL security

aspnet_regsql -S serverName -U UserName -P Password -ssadd -sstype p

Using default ASPState database and windows security

aspnet_regsql -S serverName -E -ssadd -sstype p

Using custom database and SQL security

aspnet_regsql -d TableName -S serverName -U UserName -P Password 
-ssadd -sstype c

t - Stores session data in the SQL Server tempdb database. This is the default. If you store session data in the tempdb database, the session data is lost if SQL Server is restarted.
p - Stores session data in the ASPState database instead of in the tempdb database.
c - Stores session data in a custom database. If you specify the c option, you must also include the name of the custom database using the -d option.
In your configuration file:

Using default SQL security:

<sessionstate mode="SQLServer" timeout="20" allowcustomsqldatabase="true"sqlconnectionstring="Data Source=Server;User ID=UserID;Password=Password;"       cookieless="false">

Using default windows security:

<sessionstate mode="SQLServer" timeout="20" allowcustomsqldatabase="true"  sqlconnectionstring="Data Source=Server;Integrated-Security=SSPI;" cookieless="false">

Custom database name:

<sessionstate mode="SQLServer" timeout="20" allowcustomsqldatabase="true"sqlconnectionstring="Data Source=Server;Initial Catalog=tablename;User ID=UserID;Password=Password;" cookieless="false">

Wednesday, 13 April 2016

Insert Sql Query formula for Excel


Insert Sql Query formula  for Excel

="Insert into ##temp_ITContractsCountry (TaoxnomyId,Location) VALUES ("& A2 & ","& CONCATENATE("'",B2,"'") &");"

Friday, 13 November 2015

Learn English From This Links

grammer.ccc.comment.edu
www.ucl.ac.uk/internet-grammar
hypergrammar/arts
pardueowl-
britishcouncilgrammar(learnenglish)
BBcLearningEnglish
StockexchangeEnglish
English-Test.net

Monday, 26 October 2015

Server Error in '/' Application.


A storage mechanism has already been configured for this application

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: SharpArch.Core.PreconditionException: A storage mechanism has already been configured for this application




Solution

I got Same Issue   solved by resetting the iis using following command

                                    Try to run iisreset command

in command prompt

Wednesday, 21 October 2015

Crud Operations or(Scaffold ) On MVC using Nhibernate

Crud Operations or(Scaffold ) On MVC  using Nhibernate

CREATE TABLE [dbo].[Employee](
      [Id] [int] IDENTITY(1,1) NOT NULL,
      [Name] [nvarchar](255) NULL,
      [PhoneNumber] [nvarchar](255) NULL,
      [Designation] [nvarchar](255) NULL,
      [Email] [nvarchar](255) NULL,
      [DeptNo] [int] NULL,
PRIMARY KEY CLUSTERED
(
      [Id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]
GO
/****** Object:  Table [dbo].[Department]    Script Date: 10/21/2015 17:29:26 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE TABLE [dbo].[Department](
      [DeptNo] [int] IDENTITY(1,1) NOT NULL,
      [DeptName] [nvarchar](255) NULL,
      [Location] [nvarchar](255) NULL,
PRIMARY KEY CLUSTERED
(
      [DeptNo] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY]

GO

Sunday, 31 May 2015

Signal R



Signal r is a new developer’s API provided for ASP.NET web applications, used to add "real time" web functionality to ASP.NET applications. "Real Time" web functionality is the ability to have server code to push contents to connected clients.
SignalR supports "server push" or "broadcasting" functionality. It handles connection management automatically. In classic HTTP connections for client-server communication connection is re-established for each request, but SignalR provides persistent connection between the client and the server.SignalR is an open-source API, and is accessible through GitHub.
Where to use:

·         Chat room applications
·         Real-time monitoring applications
·         Job progress updates
·         Gaming applications

What technologies does SignalR use to transfer data?

·         Using WebSockets if it is available
·         Otherwise, using other technologies, e.g. long polling,Server Sent Events ,Forever Frames

What kind of data does SignalR support to transfer?

  • Non-compressed JSON text or plain textIf you want to transfer compressed JSON or BSON or your binary data, you have to encodeusing Base64) or to
  • Implement IJsonSerializer by your own logic on the server side and implement the same logic on the client side. Note that TextReader and TextWriter are used inside SignalR. That means you have to convert your data to text before transferring anyway.

API Details:

SignalR provides two models for communication:
1.    Persistent Connections
The Persistent Connection API gives developer direct access to the low level communication protocol that SignalR exposes. This API uses the format of the actual message sent that needs to be specified and if the developer prefers to work with messaging and dispatching model rather than a remote invocation.
2.    Hubs:
It's a High Level API written over PersistentConnection. This API allows the client and server to call methods on each other directly. Hubs also allow you to pass strongly typed parameters to methods, enabling model binding.


Figure: chat application process

Web Sockets:

They allow a long-held single TCP socket connection to be established between the client and server which allows for bi-directional, full duplex, messages to be instantly distributed with little overhead resulting in a very low latency(no delay) connection.
Both the WebSocket API and the WebSocket protocol are standardised which means the web now has an agreed standard for realtime communication between Internet clients and servers.

References:



http://www.codeproject.com/Articles/524066/SignalR-Simple-Chat-Application-in-Csharp




http://ruwandotnet.wordpress.com/2012/03/17/74/

Search Keyword