Wednesday, November 3, 2010

You can validate default selected index value of the drop down by using require field validator. As the validation process is executed at client side it reduce extra post back of your page. To do this you have to just out the require filed validator on page and set the default values of it such as ErrorMessage, ControlToValidate. To validate the default value of drop down you have to set the "InitialValue" property of validator to default value of it. here is the sample code

For those of you who don’t know, MySQL is an open-source DataBase server. Being that it’s open-source, it’s also free. That’s about as low-cost as you can get. Of course, you may ask ‘Why use MySQL’? Did you read the previous sentences?? It’s free, as well as being a fairly robust database server!To be able to use MySQL, there are a couple of downloads that must be done:MySQL ItselfMySQL ODBC DriverThe Database Server (MySQL), itself can be downloaded here:http://dev.mysql.com/downloads/mysql/4.0.html

The biggest hurdle in using MySQL, is the setup – much like many other users of MSDE have found out. Without a user interface, it’s quite cumbersome, requiring a command prompt to do all the work. Here’s the best page I’ve found so far to take you, step-by-step through this process:

Now, once this is all set up – guess what – you have no data. If you want, the above installation page will also help you get started creating databases, tables and fields for your sample data. But, if you want a much quicker way to populate your database server, so you can get started, AugustWind Software has user interface for MySQL called Data Management Toolkit.Check it out here

6. In Solution Explorer, right-click the DeletingEventHandler node, and then click Properties.

7. In the Properties dialog box, click the Signing tab, select Sign the asembly, select Choose a strong name key file, and then click .

8. In the Create Strong Name Key dialog box, type DeletingEventHandler.snk in the Key file name box, optionally specify a password for the key, and then click OK.

9. Build the project.

10. Find the \DeletingEventHandler\bin\Debug folder in the Visual Studio Projects folder, and drag the DeletingEventHandler.dll file to Local_Drive:\WINDOWS\assembly to place theDLL in the global assembly cache.

2. Create a Feature.xml file in this folder like the following that identifies the Feature and its element manifest file and sets the Feature scope to Web site.Xml

GUID">xmlns="http://schemas.microsoft.com/sharepoint/">

3. To replace the GUID placeholder in the previous Id attribute, generate a GUID by running guidgen.exe located in Local_Drive:\Program Files\Microsoft Visual Studio 8.

4. Create an Elements.xml file in the DeletingEventHandler folder that identifies the assembly, class, and method to implement as the event handler. This example applies the event handler to all announcements lists of a site, as specified by the ListTemplateId attribute. For the IDs of other default Windows SharePoint Services list template types, see the Type attribute description of the ListTemplate element.Xml

5. To get the Public Key Token of the assembly, in Windows Explorer find the DeletingEventHandler.dll file in the Local_Drive:\WINDOWS\assembly, right-click the file, click Properties, and on the General tab of the Properties dialog box, select and copy the token.

6. At a command prompt, navigate to \Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN on the local drive, and type each of the following commands to install the Feature in the deployment, activate the Feature on a specified subsite, and reset Microsoft Internet Information Services (IIS) so that the changes take effect:

About Me

I am SharePoint Analyst having more than 8 years of experience in microsoft technology such as asp.net c#, MVC, WSS, MOSS2007, SharePoint 2010, SharePoint 2013. I am here with sharing solutions for the problems that I have faced during development. Hope this might be helpful to all of you and save your time.
Happy Coding...!