Saturday, February 27, 2010

Which is better for performance, Sunbroutine Or Function in VB.NET?

Many VB.NET developer are confused about the difference between the Function and Subroutine in VB.NET.
Here is a nice article from CodeProject, explains the differences between them and when to use each one of them Click Here

Friday, February 26, 2010

Have you ever used a Virtual Database?

During the last decades, The concept of Virtualization covered most of the fields/ elements  of the IT field, starting from virtual hardware devices, operation systems and software simulation.
But, Have you ever used a VIRTUAL DATABASE?

I found a nice article demonstrating a Virtual Database tool. The company called Idera produced a tool that attach a backup file to the SQL Server and it appears as a normal database. You can run queries, run any third Party tools directly against this database.You can do all these steps in less than 3 minutes.

But, Why I need to use a tool like this?
The big advantage of a tool like this is Save your time (Time is money).
If you are working in a project and you have a production database backup, with a size 15 GB, and you want to synchronize the latest changes from the development instance.
Here is the traditional steps to do this.
1- Create a new database.
2- Restore the production database backup on the new database.
3- Synchronize the changes between the two databases.
4- Save the synchronization SQL Script.

But with a third party tool like this:
1- Attach the backup file directly to the SQL server.
2- Synchronize the changes between the two databases.
3- Save the SQL Script.

You could say, I only saved one step out of 4.
I can tell you, from my experience, the longest step in all these 4 steps is step number 2.
So you removed the longest step, which usually takes about 10 minutes and my be more for the large size databases.
 There are many tools in the market doing this job. One of the greatest companies is Red Gate.
I am using the tools from Red Gate since 2 years, which solve all my hard SQL situations easily and in short time.

Any comments would be appreciated.

Friday, February 19, 2010

How to debug Dll deployed to the GAC remotely

Remote debugging is a very nice tool from Microsoft, especially if you have an error in a machine other than your development one, and you want to know what's the problem.
Firstly: Here are the steps to configure it from MSDN team Click Here.
These steps working fine with the mentioned example in the video.
But, How to use it if you have a SharePoint solution deployed to the GAC?
I spent 2 hours trying to let it work, but the point is,  remote debugging doesn't work if you don't have the "pdb" file in the same path with the "dll", so you have to copy the  "pdb" file to the same path with the "dll" one (If the soultion name is mysolution so, mysolution.pdb and mysolution.dll are the files in your debug folder from Visual Studio).
So, Here is one of the secrets of the GAC folder.
1- Open this Path %windir%\assembly this is the Assembly folder.


2- Now, Open the following Path %windir%\assembly\GAC_MSIL



3- You will find that for each dll deployed in the GAC, there is a folder with the same name.
4- Open mysolution folder
5- You will find that inside this folder, there is a folder for each version.
6- Open the version folder, and copy the mysolution.pdb and mysolution.dll to that location.
7- Start remote debugging and have fun :-)
I tried these steps and it's working fine with me.

You are welcome to post Comment Or Questions.

Sunday, February 14, 2010

SharePoint Interview Questions

A nice series of articles by Isha Attlee about SharePoint Interview Questions, for people who are working in SharePoint Development, Testing and Administration.
I found it useful for me, and it added to me many new tips.
For more information Click Here

Monday, February 8, 2010

Virtual Machines for SP Enviroment

If you have a laptop and you want to play around with the new features of SharePoint 2010, what are you going to do?
A nice article demonestrates the diffrenet possibilities to do this Click Here

Sunday, February 7, 2010

PDFMyURL Saves Web Sites as PDF Files [PDF]

PDFMyURL Saves Web Sites as PDF Files [PDF]
 
Saving something as a PDF file is a great way to preserve it for future reference or for sharing with others, without risking the site changing before you look at it again. PDFMyURL makes it easy to convert sites to PDF.
Point PDFMyURL at a website URL and it will convert the site into a PDF document. Not only can you do a simple conversion just by plugging in a URL but you can also modify the PDF with a wide variety of flags see the advanced menu for a full list that let you set the page orientation and size, header information, print orientation, and more. PDFMyURL also has a bookmarklet you can drag to your toolbar for easy access to the PDF creation service.

PDFMyURL is a free service and doesn't watermark or otherwise alter the site you are converting to PDF. Have a favorite tool for PDF conversion or a bookmarklet that makes life easier? Let's hear about it in the comments.

How to Reference a JavaScript file from a Content Page

A nice article descripes how to reference a JavaScript file from a content page instead of putting it in the master page, while you don't need it in all the pages.
For more Information Click Here