+ Start a Discussion

Is it possible to create a polymorphic Lookup field via the Metadata API?

Hi All,


I am trying to figure out if it's possible to create a polymorphic Lookup custom field (like the WhatId field in Task, where the Id value can point to different types of objects). It looks like it is not possible to modify a Lookup field's metadata directly.


Before I expend the time to create a .NET soap client (to run during setup of my custom app), can anyone advise me if it is possible to do this through the Metadata API? Can I pass a string array to the referenceTo field of a Field object... something like that?


Thanks for any help,




To my knowledge you can't create a polymorphic lookup field by any means.