Solved

problem in calling a javascript print function from a flash file.

Posted on 2004-03-22
12
207 Views
Last Modified: 2008-02-01
i'm having a print icon in the flash file. when the user clicks on it a javascript function is called where i print a frame.the problem is that in IE 6.0.2800 the flash file inserted in the HTML gets inverted, when we click the print icon. but there is no problem with the print functionality it is the flash file that gets inverted.so pls help me out .

it is working fine in the previous versions of I.E like I.E 5.5 etc.. only in IE 6.0.2800 the problem occurs

the code i use is

getURL("javascript:myfn()") // in the flash

in the html under javascript

function my()
{
     printFrame.focus();
     printFrame.print(); // where printframe is the frame that contains the content to be printed
}
0
Comment
Question by:arun_3k
  • 5
  • 4
  • 3
12 Comments
 
LVL 22

Expert Comment

by:rascalpants
ID: 10651864
why not just use Flash's inline print functionality?

here is a page that will help you figure this out...

http://www.macromedia.com/support/flash/action_scripts/actionscript_dictionary/actionscript_dictionary625.html


let me know if you need more help...

rp
0
 
LVL 5

Accepted Solution

by:
stef4s earned 70 total points
ID: 10656709
If you use the document.write method in javascript then make sure you call document.close(); before printing


printFrame.document.close();
printFrame.focus();
printFrame.print();
0
 

Author Comment

by:arun_3k
ID: 10657122
thanks stef4s partly soved now the flash file remains stable and it is not inverted but the thing is the color of the flash file is changed i.e color of the characters and other objects in the flash file are changed. anyhow great job done pls solve this problem too...
0
 
LVL 5

Expert Comment

by:stef4s
ID: 10657252
How have they changed colour?
0
 

Author Comment

by:arun_3k
ID: 10657305
everything is changed to blue color.
0
 
LVL 22

Expert Comment

by:rascalpants
ID: 10657706
so I am confused why you would not want to use the superior print functionality in Flash...  you have much better control, the quality is better, and from your problems above, it seems it would be much easier to implement...


the tool is there, why not use it?

rp
0
What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

 
LVL 5

Expert Comment

by:stef4s
ID: 10664857
please give us a link s we can see this colour change ourselves. What browser r u using?
0
 

Author Comment

by:arun_3k
ID: 10674664
in reply to stef4s : i'm using the I.E 6.0.2800.

in reply to rascalpants : i want to print a html frame not the frame in flash.this html frame contains a html page which contains the content to be printed.
0
 
LVL 5

Expert Comment

by:stef4s
ID: 10674761
arun_3k is it possible to post a link to your file so that I can see what happens?
0
 
LVL 22

Expert Comment

by:rascalpants
ID: 10823106
"in reply to rascalpants : i want to print a html frame not the frame in flash.this html frame contains a html page which contains the content to be printed."

I am not sure why this question was posted in the Flash Forum then...  what specific Flash problem was there and what was the solution?  

points to stef4... great, but this should not be PAQed in the Flash area...  people will later find this question thinking that they will get a Flash solution...  they will not...

rp
0
 
LVL 5

Expert Comment

by:stef4s
ID: 10830973
rascalpants, arun_3k thought it was a Flash Problem.

"problem is that in IE 6.0.2800 the flash file inserted in the HTML gets inverted".

Because Flash is embedded in HTML it is a valid question for both topics.
0
 
LVL 22

Expert Comment

by:rascalpants
ID: 10833102
I disagree....  but oh well...

rp
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
I have found that much of my time doing support ends up being a constant repetition of the same steps to different people.  Early on I stated using web pages with Frequently Asked Questions (FAQs) to alleviate most of the burden.  Sometimes this jus…
The goal of the tutorial is to teach the user how to how to record live broadcast.
The goal of the tutorial is to teach the user how to select which audio input to use. Once you have an audio input plugged into the laptop or computer, you will go into the audio input settings and choose which audio input you want to use.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now