Solved

Auto printing from a submit button

Posted on 2004-04-06
6
286 Views
Last Modified: 2013-12-24
Using Frontpage 2000,  Have created a form that is connected to an Access 2000 Database. When the submit button is clicked it sends the data to my access database.

I need it to also print a copy of this form automatically to the users default printer... Is this possible ?

Just3082
0
Comment
Question by:just3082
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 12

Expert Comment

by:rcmb
ID: 10767165
Place this code at the top of your results page

<Script Language = "Javascript">
window.print()
</script>

This will open the print dialogue box and allow the user to print the page.

RCMB

0
 

Author Comment

by:just3082
ID: 10767343
I do not have a results page.  Only my main form page and a confirmation page.

Just3082
0
 
LVL 12

Accepted Solution

by:
rcmb earned 250 total points
ID: 10767420
Edit the line where the submit button is to read like the following:

<input type="submit" value="Submit Comments" onclick="window.print()">

You just need to add the onclick portion. This will click the form with all of the data in it. If you have any text area boxes, make sure they are big enough to view all data.

RCMB
0
Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

 
LVL 12

Expert Comment

by:rcmb
ID: 10767476
Note - If you are using the fp generated form there is really no way to modify the results. If you have built a confirmation page then use my first comment at the top of the confirmation page.

RCMB
0
 

Author Comment

by:just3082
ID: 10767885
The onlick worked great... The only problem is that all of my fields have validation rules, therefore if they skip a control and press the submit button they will receive the validation error as well as a print box....

But I'm ok with this unless there is a way to remedy it...

Just3082
0
 
LVL 12

Expert Comment

by:rcmb
ID: 10769187
The best way to remedy this is to have your page submit to a confirmation page and place the first code I gave you at the top of the page. You can create your own page and have it display the form results.

What are you doing with the form? If the information is being recorded in a database then have the form submit to an ASP page and then have the page display and print the results.

RCMB
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Writing .htaccess to redirect only the index page 3 100
importing  maven Project 5 328
Can't connect to Hosgator with Filezilla 8 76
Advanced Visual HTML Editor 2 94
This article provides a case study on how our local youth baseball league deployed a new website, including the platform selection, implementation and benefits to the league.
When setting up new project requests for our site, one of the most powerful tools our team has available to use is Axure (http://www.axure.com/). It’s a tool for creating software and web prototypes that can function and interact as if it were the a…
The purpose of this video is to demonstrate how to properly insert a Vimeo Video into a WordPress site or Blog. This will be demonstrated using a Windows 8 PC. Go to your WordPress login page. This will look like the following: mywebsite.com/wp…
The purpose of this video is to demonstrate how to integrate Mailchimp with Facebook. This will be demonstrated using a Windows 8 PC. Mailchimp and Facebook will be used. Log into your Mailchimp account. : Click on your name. Go to Account Setti…

730 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