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
User0608User0608 

Id value is not valid for the Quote standard controller

Hello,

 

I am trying show the quote line items in my visualforce page, but my standard controller is Contract, and I have a relationship with Opportunity.


For access the Quote Line Items is Contract.Oportunidade__r.SyncedQuote.QuoteLineItems, but show this error: Aggregate Relationship is used in an unsupported complex expression containing 'SyncedQuote.quotelineitems' .


Then I created another page that get this id of SyncedQuote and show the line items...


This is my call to another page:

 

<apex:include pageName="quote_line_items">
<apex:param name="id" value="{!Contract.Oportunidade__r.SyncedQuoteId}"/>
</apex:include>

 

and this is the error: Id value is not valid for the Quote standard controller...

 

Someone can help me?
Thanks.

bob_buzzardbob_buzzard

According to the docs, apex:param isn't a valid child of apex:include.

 

--- snip ---

 

apex:param

 

 

A parameter for the parent component. The <apex:param> component can only be a child of the following components:

<apex:actionFunction>

<apex:actionSupport>

<apex:commandButton>

<apex:commandLink>

• <apex:outputLink>

• <apex:outputText>

• <flow:interview> 

 

--- snip ---

 

 

jvalotojvaloto

Thanks for reply,

but how can I call the other page?
With iframe doesn't show the other page when I put renderAs="pdf"..
How can I show the other page with renderAs="pdf"?

bob_buzzardbob_buzzard

I would expect the iframe to render as pdf if your browser has the capability to display PDF documents. I've used this to add PDF visualforce pages into dashboards.

jvalotojvaloto

My browser shows pdf, so that it shows all the main page, not only shows the page that I am calling.

 

What other way I can do this?

bob_buzzardbob_buzzard

Can you clarify what the problem actually is?

jvalotojvaloto

I want to show the QuoteLineItems in my visualforce page that have renderAs="pdf".
But when I try access the line items show this error:

Erro: Aggregate Relationship is used in an unsupported complex expression containing 'SyncedQuote.quotelineitems'

 

For access I use {!Contract.Oportunidade__r.SyncedQuote.QuoteLineItems} or {!Contract.Oportunidade__r.OpportunityLineItems} (is the same thing).


In this link you suggested to use iframe:

http://boards.developerforce.com/t5/Visualforce-Development/Aggregate-Relationship-is-used-in-an-unsupported-complex/td-p/275441

 

I can show the line items normally, but when I put renderAs="pdf" in the main page, the page of the line items is not shown.

 

My question is: how can I show the line items with renderAs="pdf" in my main page?

bob_buzzardbob_buzzard

Do you have the page that is included as an iframe rendering as pdf also?

jvalotojvaloto

I have tried with and without renderAs and not shown.

jvalotojvaloto

anyone else?