Archive for May, 2015

SQL Server Authentication enabling using Microsoft SQL Server Management Studio

Hi all,

try this scenario to Enable SQL Server Authentication using MS SQL Server Management Studio

1. First, Login to the SQL Server Management Studio using Windows Authentication. Right-click on the database instance, and go to Properties.


2. Then on Properties page, click on Security and select SQL Server and Windows Authentication mode, and click on OK to close the Server Properties page.


3. Now you will get dialog box saying that you should restart your SQL Server to take the changes take effect. Is is not done yet, you have to done one more thing to enable the “sa” login.

4. Now expand Security folder and go to Logins. You can see the “sa” account is disabled when you install SQL Server using Windows Authentication mode.


5. Then right-click on the “sa” account and go to Login Properties. There you can set a password for the “sa” account.



6. Click on the Status page. There you can see the “sa” account is disabled by default. Click on the Enabled button to enable it. Then click on Ok to close the “sa” Login Properties.


Now “sa” account is enabled and you can login to the SQL instance using the “sa” account after restarting the SQL Server.

Note: SQL Server service needs to be restarted to make this change effective.

Categories: SQL Server

Validate MultiLine TextBox Length

Hi all,

try this example to Validate MultiLine TextBox Length

<%@ Page Language="C#"%>
<head runat="server">
<title>Multiline Textbox max length</title>
<form id="form1" runat="server">
<p>Text should be less then or equal to 25 chars</p>
<asp:TextBox runat="server" ID="MLTextBox"
TextMode="MultiLine" >
runat="server" Display="dynamic"
ErrorMessage="<p>only 25 chars please</p>">
<p />
<asp:Button runat="server" text="Submit"/>

Hope this helps

Good Luck.

Categories: ASP.Net