Printing problems

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
songe
Posts: 6
Joined: Mon Oct 01, 2007 2:06 am

Printing problems

Post by songe » Thu Oct 04, 2007 3:12 am

Hi,
My name is songe. This is my first post. How are you doing?
I have a question. I'm currently transferring some old hypercard stacks into RunRev. For whatever reason though, the below handler gets to the "open printing" line and then the entire app stops working. If I push the cancel button that appears, the dialog will say "Cancelling" but actually never cancels. I end up having to quit the software and then restaring it to get back to work. Of course, nothing actually gets printed.
When I comment out everything but the revprintfield statement, it will print. I'd rather keep it to the original design though.
Any ideas?

----------
-- 9-27-2007
--
-- Done!
----------
on PRINTSOMETHING reader
put reader into cd fld "printField" of cd 1 of window "Things to Do"
open printing
revPrintField(the name of cd field "printField" of window "Things to Do")
revshowprintdialog false,false
close printing
end printsomething

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Thu Oct 04, 2007 9:36 am

Songe,

This should be:

Code: Select all

on PRINTSOMETHING reader
  put reader into cd fld "printField" of cd 1 of window "Things to Do"
  revshowprintdialog false,false
  revPrintField(the name of cd field "printField" of window "Things to Do")
end printsomething
Open printing (for dialog) is for printing cards, not for printing fields. Probably, Revolution is more picky at this point than HyperCard.

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

songe
Posts: 6
Joined: Mon Oct 01, 2007 2:06 am

Post by songe » Thu Oct 04, 2007 3:36 pm

Worked great. Thanks. I didn't know you could just put the revshowprintdialog thing before any print statement.
Thank You
Songe

Post Reply