• DuFrey
  • NEWBIE
  • 25 Points
  • Member since 2008

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

Hi All,

 

 

I am creating a page. This page renders as PDF.

 

My requirement is I have two PageBlockTables and these PageBlockTables should always display

on a different page.

Even than my first PageBlockTable doesn't have data, the second PageBlockTable should display on second page.

 

 

Please suggest me, how should I need to design this requirement?

 

 

Thanks

Nitin Gupta

  • April 29, 2009
  • Like
  • 0
I am testing out mobile with a client using BlackBerrys and one of them is encounting a java exception error when attempting to edit a record. I have been unable to figure out how to duplicate this error message and no one else on the team encounters it either. I was wondering if any error messages are generated or logged anywhere (perhaps on the device itself?) when that happens to help with debugging.
  • March 19, 2009
  • Like
  • 0

The last two days I have received the message "Incompatible viewstate version detected!" when attempting to access different custom VF pages. I have never encountered it before and it doesn't cause any exceptions that I can log and I cannot seem to duplicate it either.

 

Curious if anyone has seen the same message or knows what it is referring to.

  • March 06, 2009
  • Like
  • 0

I have a custom button where I generate a VF page as a PDF with the renderAs="pdf" option by passing parameters via the query string like this:

 

/apex/QuotePDF?quoteid={!Quote__c.Id}&oppid={!Quote__c.OpportunityId__c}&ownerid={!Opportunity.OwnerId}

 

 Since the Spring 09 update, this has stopped working and gives a "Attempt to de-reference a null object" error. It appears that a value is not being populated but I am passing the VF page the necessary information needed to generate. I didn't see any mention of changes to renderAs for Spring 09. If I remove the renderAs="pdf" from the VF page, it displays without issues. Appreciate all ideas and insights.

 

  • February 10, 2009
  • Like
  • 0
I am using the • character entity which generates a bullet point in a Visualforce page which renders as a PDF. I am using like the following:

<div>&bull;<span class="tab"></span>&quot;<b>Content Site</b>&quot; means...

and I am get an the following warning: The entity "bull" was referenced, but not declared. I tried using &#149; and &#x2022; but those do not render correctly the bullet point in the PDF. I am unable to consistently generate the warning message either. I can generate the PDF 3 times and get the warning all three times or not at all without changing anything.

Any ideas what could be occurring?

Thanks.


  • November 25, 2008
  • Like
  • 0
I am generating a quote and rendering it as a PDF and also attempting to save it as an attachment in the quote with the following code:

Code:
public PageReference SaveContent() {   
     PageReference pdfPage = Page.QuotePDFPage;
     pdfPage.getParameters().put('quoteid',quoteId);
     pdfPage.getParameters().put('oppid',OppId);
pdfPage.getParameters().put('ownerid',OwnerId);
Blob pdfBlob = pdfPage.getContent();
Attachment a = new Attachment(ParentId = quoteId, Name = 'Quote.pdf', ContentType = 'pdf', Body = pdfBlob);
insert a;
return null;
}

When I generate a quote, an attachment is created but when I try to open it. I receive the error "Attempt to de-reference a null object".

I believe this is from not having all the correct object ids being passed. For the quotes when generated, I am passing the quote id, opportunity id, and user id.

I have tried several ways to attempt to pass the two additional ids using getParameters(), but none seem to work. How can I also pass these to the attachment? Do I also need to call the action from a different apex page then the one generating the quote?

  • October 07, 2008
  • Like
  • 0

I have a visualforce page sitting on the home page within an iframe.  I want the user to be able to click a link on that visualforce page and display the details page for the specific object (e.g. a Task).

 

When the user clicks the link the page refreshes but only within that iframe. How do I get the parent window (i.e. my main salesforce window) to refresh as if the page was being accessed normally?

 

Thanks in advance...

  • April 29, 2009
  • Like
  • 0

Hi All,

 

 

I am creating a page. This page renders as PDF.

 

My requirement is I have two PageBlockTables and these PageBlockTables should always display

on a different page.

Even than my first PageBlockTable doesn't have data, the second PageBlockTable should display on second page.

 

 

Please suggest me, how should I need to design this requirement?

 

 

Thanks

Nitin Gupta

  • April 29, 2009
  • Like
  • 0

I have a non-sobject field called "InvoiceDates" in my controller extension. On the VF page there is both an InputTextarea and an outputtext for the same field. The idea is the inputtextarea is pre-populated, but editable by the user. When the user updates that field and clicks a refresh button, they can see a "preview" of the document that will be created.

 

So far things work great for the inputtext area. I placed \n in the string which provides my line breaks. However when I go to output the value it shows up on a single line.

 

Part of method defining string

string vDate = string.valueof(StartDate.Month() +'/'+ StartDate.Day()+'/'+ StartDate.Year()); String Term = 'Term ' + string.valueof(i+2) + ': '; InvoiceDates = InvoiceDates + Term + Vdate + '\n';

VF Page area

 

(this works)

<apex:inputtextarea value="{!InvoiceDates}" id="InvoiceDates" style="width:300px;height:150px"/>

(Output not displaying with line breaks) <apex:outputtext value="{!InvoiceDates}" /> (Also tried) {!InvoiceDates}

 

the component references says outputtext "escape the rendered text if it contains sensitive HTML and XML characters" I'm assuming that using outputtext would "strip" my \n, so I tried just placing the string without an outputtext - but get the same data string line.

 

The only way I have been able to work around this is to create a list<string> instead of a concatenated String. This works on the display, but doesn't work for the user Inputtextarea well. Any suggestions on how I can get my output to include the \n ?

The last two days I have received the message "Incompatible viewstate version detected!" when attempting to access different custom VF pages. I have never encountered it before and it doesn't cause any exceptions that I can log and I cannot seem to duplicate it either.

 

Curious if anyone has seen the same message or knows what it is referring to.

  • March 06, 2009
  • Like
  • 0

I have a custom button where I generate a VF page as a PDF with the renderAs="pdf" option by passing parameters via the query string like this:

 

/apex/QuotePDF?quoteid={!Quote__c.Id}&oppid={!Quote__c.OpportunityId__c}&ownerid={!Opportunity.OwnerId}

 

 Since the Spring 09 update, this has stopped working and gives a "Attempt to de-reference a null object" error. It appears that a value is not being populated but I am passing the VF page the necessary information needed to generate. I didn't see any mention of changes to renderAs for Spring 09. If I remove the renderAs="pdf" from the VF page, it displays without issues. Appreciate all ideas and insights.

 

  • February 10, 2009
  • Like
  • 0
I am using the &bull; character entity which generates a bullet point in a Visualforce page which renders as a PDF. I am using like the following:

<div>&bull;<span class="tab"></span>&quot;<b>Content Site</b>&quot; means...

and I am get an the following warning: The entity "bull" was referenced, but not declared. I tried using &#149; and &#x2022; but those do not render correctly the bullet point in the PDF. I am unable to consistently generate the warning message either. I can generate the PDF 3 times and get the warning all three times or not at all without changing anything.

Any ideas what could be occurring?

Thanks.


  • November 25, 2008
  • Like
  • 0
I am generating a quote and rendering it as a PDF and also attempting to save it as an attachment in the quote with the following code:

Code:
public PageReference SaveContent() {   
     PageReference pdfPage = Page.QuotePDFPage;
     pdfPage.getParameters().put('quoteid',quoteId);
     pdfPage.getParameters().put('oppid',OppId);
pdfPage.getParameters().put('ownerid',OwnerId);
Blob pdfBlob = pdfPage.getContent();
Attachment a = new Attachment(ParentId = quoteId, Name = 'Quote.pdf', ContentType = 'pdf', Body = pdfBlob);
insert a;
return null;
}

When I generate a quote, an attachment is created but when I try to open it. I receive the error "Attempt to de-reference a null object".

I believe this is from not having all the correct object ids being passed. For the quotes when generated, I am passing the quote id, opportunity id, and user id.

I have tried several ways to attempt to pass the two additional ids using getParameters(), but none seem to work. How can I also pass these to the attachment? Do I also need to call the action from a different apex page then the one generating the quote?

  • October 07, 2008
  • Like
  • 0