Friday, November 14, 2008

How do I find the extension of a file in Windows XP?

By default file extensions may not show in Windows Explorer. In case they are not showing follow the indicated procedure.

You may just know the file name in the Windows Explorer. Sometimes you need to know the correct extension. This is especially true when you rename a file. It is true that the icons may change and you may know the difference. But you may change the default of not showing extension to one showing extension by following the indicated steps:

In Windows Explorer open in C:\ drive

1.Click Tools | Folder Options...

2. In the Folder Options window change to the View Tab

3. Under Advanced settings: ,remove the check mark (default) for the radio button Hide extensions for known file types.

4. Click OK to the Folder Options window.

Now your files will be showing the extensions

Thursday, November 6, 2008

How do I set up a Data Connection in Visual Studio 2008?

It depends on where the data comes from, SQL Server, IBM DB2, MS Access etc.

Here is what you do for SQL Server 2008.

Step 1: Open Visual Studio 2008
            Click View | Server Explorer
            Click on Connection as shown.

The Add Connection window shows up

Step 2: Click on the Change...button

The Change Data Source window gets displayed.

Step 3: Highlight Microsoft SQL Server
            Click OK

Step 4: Click on the Refresh button
            Then click on the drop-down button
The SQL Servers on your machine should show up as in the figure
            Choose the SQL Server 2008 as shown by highlighting Hodentek2\SANGAM

Step 5: Assuming the SQL Server 2008 is to be Windows Authenticated
       Click on the drop-down handle for 'Select or enter a database name:"
       Select AdventureWorksDW2008 as shown


Step 6: Click on Test Connection button
You should get the following message

Step 7: Click OK to the message and close the Add Connection window.
You are done.

Now you will see your connection in the Data Connections folder in Server Explorer
Now you can access Tables, Views, Stored Procedures and Functions within the Visual Studio IDE

Well I have a number of other connections in my VS 2008 IDE.