How do I: Populate a drop-down

The schema.xml will look like:

 <Field Name=”NomStatus” ID=”{6f37ad73-3881-4411-bb98-b2f4dd0273b0}” DisplayName=”Status” Format=”Dropdown” Type=”Choice”>
        <CHOICES>
          <CHOICE>Pending Approval</CHOICE>
          <CHOICE>Approved</CHOICE>
          <CHOICE>Rejected</CHOICE>
        </CHOICES>
      </Field>

The elements.xml will look like:

<Field Name=”NomStatus”>Approved</Field>

Adding Date to element.xml

elements.xml

    <Data>
      <Rows>
        <Row>
          <Field Name=”DOB”>2015-12-01</Field>        
        </Row>
      </Rows>
    </Data>

schema.xml

<Field Name=”DOB” ID=”{3441d411-3bcf-4587-af39-2ae2f6414223}” DisplayName=”DOB” Type=”DateTime” Format=”DateOnly” />

Preventing the deletion of a folder in SharePoint 2010 using C# and Visual Studio

This project has custom C# code that prevents the deletion of a folder from a SharePoint 2010 list. This project also redirects the user to a custom error page if the “Expires” field is left blank. It was created in Visual Studio 2008. This is deployed as a farm solution.

EventReciever1 is for the prevented deletion of the folder
EventReciever2 is for the prevention of an empty expireation date
I tried to contain the the event that prevents and empty expiration date in the same event that prevents folder deletion but could not. So that is why I created EventReciever2 and it worked fine.

Download package here