You need to sign in to do that
Don't have an account?
DMRae
Visualforce Page: List showing matching records / Text field
Hey there,
I'm new at Visualforce and like to create my first page.
Imagine the following setup:
You have a custom object called Event. An Event may be a congress or a trade fair. Within the object you have the text field "City__c".
Now you're working on a Lead from Dallas. Means: The standard field "City" equals "Dallas". Wouldn't it be great now to see all events taking in place in Dallas? I'd like to built a Visualforce Page list, that shows all Event records where the Lead field "City" is matching the Event field "City__c". I'm happy with 3 - 4 columns in the list.
Any idea how to build this? Feel free to provide me with sample code that is applicable for my project.
Kind regards,
David
I'm new at Visualforce and like to create my first page.
Imagine the following setup:
You have a custom object called Event. An Event may be a congress or a trade fair. Within the object you have the text field "City__c".
Now you're working on a Lead from Dallas. Means: The standard field "City" equals "Dallas". Wouldn't it be great now to see all events taking in place in Dallas? I'd like to built a Visualforce Page list, that shows all Event records where the Lead field "City" is matching the Event field "City__c". I'm happy with 3 - 4 columns in the list.
Any idea how to build this? Feel free to provide me with sample code that is applicable for my project.
Kind regards,
David
thanks for your quick reply. You're right! With a custom report I'd be able to match those two object types. But how can I bring the magic of custom reports to the Lead layout? It's easy to add the report to the layout. But the real magic is, that only records will show up that meet the matching criteria "City". Imagine the records have no relationship yet. Tell me, if I'm on the wrong track. If I'd be using Campaigns, I guess it would mean that there must be an existing relationship established by a lookup field.
Looking forward to your ideas!
"Events" are examplary for a variety of objects that I'd like to display in that way. The slogan is "Showing records that have something in common with the record I'm working with right now". It also goes for "Use Cases". Example: The rep works on a Lead with the industry "Fashion". In a list he sees all Fashion use cases at a glance within the Lead record he's working with. Of course you can realize it with a Related List. But it would mean that you have to establish a relationship for each record. So for me, a Visualforce Page sounded like the last choice. What do you think?