Hi All,
 
In a feature event receiver I am trying to create some views for a
particular list as per this code:
 
----
//Ordered by Reference number
SPViewCollection views = spLibrary.Views;
StringCollection libViewFields = new StringCollection();

libViewFields.Add("File_x0020_Type");
libViewFields.Add("Reference_x0020_Number");
libViewFields.Add("Modified");
libViewFields.Add("Item_x0020_Author");
libViewFields.Add("Item_x0020_Title");
libViewFields.Add("FileLeafRef");
libViewFields.Add("Group1");
 
qry = "<OrderBy><FieldRef Name='Reference_x0020_Number' Ascending='True'
/></OrderBy>";
libViews.Add("Ordered by Reference Number", libViewFields, qry, 100,
true, false);
 
spLibrary.Update();
----
 
This is all working fine, but I would really like to add the "File Type"
column so that it shows an icon for the file type, and the name
(FileLeafRef) column so that it has the dropdown edit menu.  Anybody
have any idea how to create these view fields programatically
 
Many thanks
 
Nigel Witherdin
Senior Support Analyst
Eversheds
 
Direct Dial: +44 (0) 84 549 754 17
Mobile: +44 (0) 7738 553256
 
www.eversheds.com



****** This email is sent for and on behalf of Eversheds LLP ******

This email is sent for and on behalf of Eversheds LLP which is a limited 
liability partnership, registered in England and Wales, registered number 
OC304065. Registered office One Wood Street, London. EC2V 7WS.  Registered VAT 
number GB820704559. A list of the members' names and their professional 
qualifications is available for inspection at the above office. Regulated by 
the Solicitors Regulation Authority (see www.sra.org.uk). 

Confidentiality:  This email and its attachments are intended for the above 
named only and may be confidential.  If they have come to you in error you must 
take no action based on them, nor must you copy or show them to anyone; please 
reply to this email and highlight the error.

************* [ www.eversheds.com ] *************



------------------------------------------------------------------- OzMOSS.com 
- to unsubscribe from this list, send a message back to the list with 
'unsubscribe' as the subject.

Powered by mailenable.com

Reply via email to