tags:

views:

634

answers:

1

I've created a custom field type based on SPFieldLookup. When I use SharePoint's "Export to Spreadsheet" function, however, it's not rendered correctly.

For normal lookup fields, only the Lookup Value is rendered. For my custom field, the string representation of the lookup value is used (i.e., "1;#My Lookup Value").

Is there a way to change the custom lookup field so that it will render only the Lookup Value when exported to a spreadsheet?

A: 

I'm not sure if its possible to do what you want.

Here's a note from the SPFieldLookup documentation on MSDN:

Notes to Inheritors: In Windows SharePoint Services 3.0, columns based on custom field types do not appear in Datasheet view and are not included when you export a list to a Microsoft Excel spreadsheet.

Maybe you can look into the DisplayPattern element in your fldtypes_XXX.xml

Jason