• fromSEA
  • NEWBIE
  • 0 Points
  • Member since 2010

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 2
    Replies

I have query results coming as following: for contact 1 for three questions and answers.

 

for Contact 1

 Q1  - ans1

 Q2 - ans2

  Q3 - ans3

 

for Contact 2

 Q1  - ans1

 Q2 - ans2

  Q3 - ans3

I want to dislay the above results as following:

       Q1    Q2    Q3

C1   ans1 ans2 ans3

C3   ans1 ans2 ans3

 can someone please help me create a class in my controller that help create this display in my apex page? How to display column values as row hearders..

 

I really appreciate any suggestions?

 

 

I have query results coming as following: for contact 1 for three questions and answers.

 

for Contact 1

 Q1  - ans1

 Q2 - ans2

  Q3 - ans3

 

for Contact 2

 Q1  - ans1

 Q2 - ans2

  Q3 - ans3

I want to dislay the above results as following:

       Q1    Q2    Q3

C1   ans1 ans2 ans3

C3   ans1 ans2 ans3

 can someone please help me create a class in my controller that help create this display in my apex page? How to display column values as row hearders..

 

I really appreciate any suggestions?

 

 

Is it possible to iterate over a List of Maps? In the simplest form, a Map<String,String>... I want to be able to do the following in a visual force page (simplified):

 

VisualForce Page

<apex:repeat value="{!customMap}" var="map">
{!map.name} : {!map.custom}

</apex:repeat>

 

Controller

 

public someController
{
public List<Map<String,String>> customMap = null;

public getCustomMap()
{
if (customMap == null)
{
customMap = new List<Map<String,String>>();

customMap.add(new Map<String,String>{
'name' => 'Apple',
'custom' => 'Pie'
});

customMap.add(new Map<String,String>{
'name' => 'Banana',
'custom' => 'Cake'
});
}
return customMap;
}
}

 

 Would hopefully print something like...

 

 

Apple : Pie
Banana : Cake

 

 This is obviously not working for me, any suggestions or is this not possible right now?