Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 02-24-2012, 09:55 PM   #1
josiah29
Registered User
 
Join Date: Feb 2012
Posts: 33
Angry Unbalanced Layer Operators?

Hey,

I am working with PDF and I have a class full of function that I can call to and put in my desired parameters.

Everything is working fine but I can't get it to work to make a new page...

It works if you define the function right in the class and call to it as such

protected var p_pdfDocument: PdfDocument;

p_pdfDocument.newPage();

but when I try to make a custom function to call to in the custom class and call to it I get an error

Error: Unbalanced layer operators.

Any body know how to solve this??

Thanks!
josiah29 is offline   Reply With Quote
Old 02-24-2012, 09:58 PM   #2
josiah29
Registered User
 
Join Date: Feb 2012
Posts: 33
Default

And if anything can anybody at least explain what Unbalanced layer operators means so I can try to solve this problem because I don't even know where to start due to the fact that I don't know what is causing it to throw this error.

Thanks Again!
josiah29 is offline   Reply With Quote
Old 02-25-2012, 10:04 AM   #3
wvxvw
Holosuit User
 
wvxvw's Avatar
 
Join Date: Oct 2006
Location: Tel Aviv
Posts: 4,301
Send a message via ICQ to wvxvw
Default

You probably need to look into documentation to the library you are using. They might have a forum of their own, or a mailing list or some other way to contact the developers. The error text isn't any of the built-in Flash errors - that's something the developers of the library decided to add, and as it usually happens with error messages, they are cryptic and uninformative

To help others to at least recognize your problem, you could at least tell what library are you using - generating PDF files isn't anything very common to do in AS and very few people may know what library you are talking about.
__________________
The .NET open source editor for Flash and web developers
*This would be my contribution to the project*
couchsurfing if you need it
wvxvw is offline   Reply With Quote
Old 02-25-2012, 02:58 PM   #4
ASWC
Super Moderator
 
ASWC's Avatar
 
Join Date: Dec 2007
Location: Greenville, SC
Posts: 6,528
Default

For your level of programming I recommend using AlivePDF instead which has been around for a longer time and has a more developed documentation and examples and support.
__________________
aswebcreations
Super Duper!
ASWC is offline   Reply With Quote
Old 02-27-2012, 03:48 PM   #5
josiah29
Registered User
 
Join Date: Feb 2012
Posts: 33
Default

Thanks For your replies guys!

I am using Pure PDF and it is actually a project for my job, one of the clients wants a PDF file generated after somebody finishes their course and we are just exploring different options on how to do it so I have been put in charge of building it in Pure PDF.

I think that it is just having a fit about the way I am calling to the newpage() function so I am going to try moving things around a little bit and see if I can get it to work.

Thanks Again!
Josiah
josiah29 is offline   Reply With Quote
Old 02-27-2012, 06:25 PM   #6
josiah29
Registered User
 
Join Date: Feb 2012
Posts: 33
Default

I finally figured it out!

The problem is I had a function that looked like this

XTC_$PDF_newPage():void
{
p_pdfDocument.newPage();
}

and It didn't like that fact that I was calling to the newPage function inside of another function so all I had to do was put a variable = the p_pdfDocument variable in my class and in the part of the code where I wanted to start a new page just do this

var var_pdfDoc = p_pdfPackage.p_pdfDocument;

var_pdfDoc.newPage();

and It worked like a charm!
Thanks for you recommendations guys

and ASWC i'm sorry for being a jerk to you on one of my other posts you were just trying to help me and I was being rude I was just frustrated trying to figure out my problem and I didn't want more problems pointed out but I know I need to take advice as help not as criticism so thanks for your help!
josiah29 is offline   Reply With Quote
Old 02-27-2012, 07:31 PM   #7
ASWC
Super Moderator
 
ASWC's Avatar
 
Join Date: Dec 2007
Location: Greenville, SC
Posts: 6,528
Default

np Glad you found the solution.
__________________
aswebcreations
Super Duper!
ASWC is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:54 AM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.