Showing posts with label 4.0.microsoft. Show all posts
Showing posts with label 4.0.microsoft. Show all posts

Friday, December 30, 2011

SQL SERVER – Reset sa Password

1.Open the SQL Server express management studio
2.Connect to SQL Server using windows authentication
3.Right click the server name and choose properties
4.Go to security tab. Change server authentication to “SQL Server and Windows Authentication mode”
5.Click OK and restart SQL Server
6.Go to SQL Server studio management express
7.Expand the server and choose security and expand logins
8.Right click on SA, from properties modify the password and confirm password

OR

To reset the sa password, you can make the following:
1. Login to the SQL Server box as the Administrator.
2. Run SQL Server Enterprise Manager.
3. Right-click the server name and choose ‘Edit SQL Server Registration properties’.
4. Choose ‘Use Windows authentication’ and click OK button.
5. Expand a server, expand a Security and click Logins.
6. Double-click the sa login and specify new password on the General tab. (enable Login to)

Or You Can Use

USE [master]
GO
ALTER LOGIN [sa] WITH DEFAULT_DATABASE=[master],
DEFAULT_LANGUAGE=[us_english], CHECK_EXPIRATION=ON, CHECK_POLICY=ON
GO
USE [master]
GO
ALTER LOGIN [sa] WITH PASSWORD=N’’ MUST_CHANGE
GO

or

From a command prompt
OSQL -S -E
1> EXEC sp_password NULL, ‘’, ‘sa’
2> GO

Sunday, October 23, 2011

Visual Studio 2010 Tips & Tricks for Developers

  1. Working in Full Screen Mode in Visual Studio

    1. Alt+Shift+Enter is the shortcut to enter to fullscreen mode in Visual Studio
    2. Its sometimes really helpful and more appealing for developers to work in full screen mode

    1. Editing


      1. For Copying a line in the IDE just go to the start of the line and press Ctrl+C,there is no need to select anything
      2. For Pasting a line just go to the start of the line and just press Ctrl+V
      3. For Deleting a line just go to the start of the line and press Ctrl+X, this is not actually delete but its similar to cut if you do Ctrl+X on current line and go to some other place in your code and do Ctrl+V then it will paste the same line there.
       
      1. Expanding and Collapsing the code units

        1. This nice little shortcuts has saved me a lot of time.Whenever i am working on a large piece of code i always get confused and make some changes in other Method or property because they were looking similar.
        2. But now with this shortcut i collapse one method as soon as it is finished.
        3. The shortcut is Ctrl+M+M.
        4. Just go to the beginning or end of the method or property or any code block and hit the shortcut it will expand or collapse the code block comparing to its present state.
        5. If you want to collapse all your code units or blocks to their definitions then the shortcut to achieve this is Ctrk+M+O or Ctrl+M Ctrl+O.This is also a very handy shortcut which helps a lot in development.
         
        1. Automatic Text Indentation and Formatting

          1. This shortcut helps me to write beautiful and decorative code which is easy to understand by any person.
          2. Shortcut is just press Ctrl+K+D.
          3. This works not only in C# and VB code behind but it works well in aspx pages.
          4. If you want to just format the selected piece of code then just press Ctrl+K+F