function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
RudiHulsbosRudiHulsbos 

Visualforce page to display multiple object data

Hi All,

 

We need to display data related to Contacts from multiple custom objects combined into one row. We used to use a matrix type excel spreadsheet to display some nice graphs and colored indicators. We have now created custom objects (between 5 and 10, might add more later) related to Contacts, all linked by a master detail relationship.

 

e.g.

Contacts Object           Feedback Object      Surveys Object

Name1, Phone, Email      Date, Comments        Survey Name, Type, Date

Name2, Phone, Email      Date, Comments        Survey Name, Type, Date 

Name3, Phone, Email      Date, Comments        Survey Name, Type, Date 

 

and so on.....

 

What would be the best way to go about accomplishing this type of visualforce page?

 

I am going through the discussion boards reading up a lot, but though i would get some expert advice :)

 

Thanks,

 

Rudi 

bob_buzzardbob_buzzard

You will need to use wrapper classes that contain all of the objects related to a contact, plus the contact itself.

 

You can then back a datatable/pageblocktable/repeat component with a list of the wrapper classes and use merge fields to access details from each of the wrapped classes.

 

If you search the VF boards for wrapper class, you should find some examples.