Filter List lookup but exclude self


Badge +8

Greetings:

 

I have an application in which one or more documents are submitted to a document library by email, for which a workflow parses the email subject line for a common property called the TicketNumber.  All of the documents submitted in that email therefore have the same ticket number. but no other properties are defined except the usual ones like the document name and creation date, etc. None of the custom fields are defined yet, but I have a form for just that purpose.

 

When I open a form on one of the documents I need  to also refer to the other documents that came in under the same TicketNumber.  That's easy enough using a List Lookup filtered by a form control connected to that property, but what I am struggling with is a way to exclude from that list the document whose form I have just opened. In other words, If I have three documents, A, B, and C, all with TicketNumber 123456, and I open the form for document A, I want my lookup to show only documents B and C.  Using a List Lookup filtered by the TicketNumber I always get documents A,B, and C. I have tried using custom Javascript that works fine to remove a value from a choice control but it does not seem to work with List Lookup controls. I have also tried filtering on an arbitrary value instead of the value of a form control, and using calculated fields for the item. Nothing seems to work.  Is there any way to do this?

 

Thanks!


0 replies

Be the first to reply!

Reply