Jump to content

common

Recommended Posts

Hi Guys,

 

I am working on 2 pages.

 

One page has a list of accounts with a form and this is submitted to second page. The second page displays html of documents(like invoices and so on.) that need to be printed. The system I work in is a couple of pages in framesets.

 

Now I want to have the html in the second page printed without showing the second page. So in other words: When the submit button is clicked I need the print box popup and when print is clicked the second page needs to be printed.

 

Now what I have done, is to add a another frame to the frameset with a with of 0, so it will not be visible in the browser.

And after the second page loads, I use the

window.print()

function to bring up the print box.

 

My problem is, that this only works when I open the second page in a new window. And nothing happens when I open the second page in the additional frame. Now I havn't tried thisyet, but belives if I use

parent.[framename].print()

it will work for the frame.

 

I want it work in both when opening the page in a new window and when I open it in the Additional frames.

 

Does anyone know how I can do this?

 

Thanks in advance

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.