Bug in 1.5.19.0 (EndPage method out of scope)

Hello,

I just upgraded to version 1.5.19.0 and now I get the error below.

Here is what I know…

I have a section (see way below) that I have determined causes the error to occur. If you look for the segment with text that starts “You don’t have to suffer through…” you will see a IsFirstParagraph=“false”. If I change that to IsFirstParagraph=“true” the problem goes away.

The following may also be of interest.
m_pdf.PageSetup.Margin.Top = 35;
m_pdf.PageSetup.Margin.Left = 35;
m_pdf.PageSetup.Margin.Right = 35;
m_pdf.PageSetup.Margin.Bottom = 35;
m_pdf.PageSetup.PageHeight = PageSize.LetterHeight;
m_pdf.PageSetup.PageWidth = PageSize.LetterWidth;
m_pdf.OpenType = OpenType.None;
m_pdf.DestinationType = DestinationType.FitPage;
m_pdf.IsSpaced = true;

David

THE ERROR

EndPage method out of scope.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ApplicationException: EndPage method out of scope.

Source Error:
Line 145:
Line 146: // Save
Line 147: m_pdf.Save(Response);
Line 148: //m_pdf.Save("", SaveType.OpenInBrowser, Response);
Line 149:

Source File: c:\development\visual studio\eladdenweb\website\admin\pdfreport.aspx.cs Line: 147

Stack Trace:
[ApplicationException: EndPage method out of scope.]
fg.f(bx A_0) +3822
e2.a(Pdf A_0, Section A_1, Table A_2, Row A_3, Cell A_4, Text A_5, String A_6, a A_7, ck A_8) +6734
cd.a(Pdf A_0, Section A_1, Table A_2, Row A_3, Cell A_4, Text A_5, a A_6, ck A_7, Boolean A_8) +1928
b9.a(Pdf A_0, Section A_1, a A_2) +779
bo.a(Pdf A_0) +319
am.a(ax A_0, Pdf A_1) +44
Aspose.Pdf.Pdf.Save(HttpResponse response) +45
VioCare.EladdenWeb.Reports.PDFReport.Page_Load(Object sender, EventArgs e) in c:\development\visual studio\eladdenweb\website\admin\pdfreport.aspx.cs:147
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573

THE SECTION CAUSING PROBLEM

Copyright 2002 - 2004, Viocare Technologies, Inc. [Page $p of $P]

Other Health Habits - Example

Regular exercise promotes physical strength, cardiovascular fitness, stronger bones and better weight control. At least 30 minutes of vigorous exercise 4 times a week maintains strength; higher levels of activity gives greater benefits.

The National Academy of Sciences recommends that children and adults participate in activities that consume at least 300 calories on most days of the week. The following activities give that level of fitness (note this is a draft, not verified):

Intensity and Duration of activities that use 1 calorie per pound

60 Minutes

Walking at 4 MPH

Bicycling on level ground

Recreational swimming

Raking leaves

Using handsaw and hammer

Carrying lumber

Brick laying

Painting wall w/roller

Sweeping with broom

Carrying 25 pounds on level

Vacuuming stairs

30 Minutes

Running at 10 MPH

Bicycling on hilly land

Swimming laps

Spading soft soil

Carrying shingles up ladder

Roofing at 5 blocks/hour

Leveling concrete

House painting with brush

Scrubbing floors by hand

Vigorously washing walls

15 Minutes

Running in a race

Basketball

Cross country skiing

Sawing with a hand saw

Working with a pitch fork (on farm)

Cutting tree branches

A word about smoking:

If you have tried to quit smoking and failed, don’t be discouraged. The average number of times that smokers quit smoking before they manage to “kick” the habit altogether is 11 times. Each time you make the effort to quit, you learn more about what makes smoking so hard to give up. Smoking cessation programs use several strategies to help smokers become abstainers. Gradual tapering use of cigarettes dampens withdrawal symptoms that lead to defeat. Programmed use of nicotine patches can help lower the strength of the addiction, making the final mile to abstinence more tolerable.

Other more direct methods include imagery. Imagine clean, clear lungs, no longer coated with tar. Imagine fresh spring breezes not tainted with smoke. Imagine fresh smelling clothes, rugs, upholstered furniture without the smell of old cigarettes. Imagine silky clean hair without a film of nicotine. Paste this paragraph somewhere so you can read it when the urge to smoke starts to overwhelm.

Some people find a substitute for smoking. Find something to put in your mouth that you don’t light and that doesn’t make you fat. Chewing gum gives the mouth an activity other than smoking. “Pretend” cigarettes made from china or plastic lets the hand put a safe alternative into the mouth. Chewing a toothpick may offer temporary relief.

You don’t have to suffer through the process of quitting alone. A smoking cessation program gives understanding and support while you struggle with the very difficult task of dropping a very dangerous habit. For information about a program near you call 1-800-xxx-xxxx or look on the internet at www.stopsmoking.com.

A word about drinking.

Alcohol, like cigarettes, can be addictive. While moderate amounts of wine and other alcoholic drinks may actually impart health benefits, more than 1 or 2 drinks per day can have a troubling effect. Distilled spirits gives calories with no other nutritional benefit. If alcohol becomes a problem, there are programs that can help. For information about a program near you call 1-800-xxx-xxxx or check the internet at www.stopdrinking.com.

(These messages will be given to people who report they smoke or consume more than two alcoholic beverages per day.)

Dear blankenbush,

Thanks for your consideration.

I am sorry for replying to you so late because I was on vacation. I will fix this bug and give a hot fix soon.


Dear blankenbush,

Thanks for your consideration.

Please download hot fix here.