Hi all, I am trying to add a button to my webpage that opens the save as dialog box, and allows the users to save the page (it is a form) as a word doc... I used this code which does work, but only allows to save as a txt or html file... Is there any way to make it so that they can save it as a .doc file to be able to edit it later?
[HTML]<input type="button" value="Save Form" onClick="javascript: document.execCommand('SaveAs','1','EvalForm');"/>[/HTML]
4 8800
Hi all, I am trying to add a button to my webpage that opens the save as dialog box, and allows the users to save the page (it is a form) as a word doc... I used this code which does work, but only allows to save as a txt or html file... Is there any way to make it so that they can save it as a .doc file to be able to edit it later?
Code: ( text )
1.
<input type="button" value="Save Form" onClick="javascript: document.execCommand('SaveAs','1','EvalForm');"/>
Hi all, I am trying to add a button to my webpage that opens the save as dialog box, and allows the users to save the page (it is a form) as a word doc... I used this code which does work, but only allows to save as a txt or html file... Is there any way to make it so that they can save it as a .doc file to be able to edit it later?
Code: ( text )
1.
<input type="button" value="Save Form" onClick="javascript: document.execCommand('SaveAs','1','EvalForm');"/>
Moved to Javascript forum
Being non-standard code, it'd difficult to say for certain, but I think you'll probably have to do something server-side and let the user download it instead. That's actually better, because it would work in more browsers rather than just IE.
I've merged the threads and changed the thread title.
Sign in to post your reply or Sign up for a free account.
Similar topics
by: lir |
last post by:
Hi,
I am trying to save a fram in a page using the execCommand("saveas")
the html is save currectly but I can not save the gif on that page.
How can I save the fram with the gif via...
|
by: Martin Dale |
last post by:
Dear all,
Is there any way to activate the Save As command from Javascript. I
would like to have a "Save as" button on a page which has been
dynamically created (client side using...
|
by: 00steve |
last post by:
Hi,
I was wondering if anyone knew how to go about having a "save as HTML"
option incorporated within a page. (I know the option is available
from the file menu from within IE, but a client has...
|
by: SAL |
last post by:
Below is my javaScript function that I am having trouble with. When I set
the bUserInterface parameter to FALSE in the follow statement,
"document.execCommand("CreateLink","false", oSource)", the...
|
by: Thomas Magma |
last post by:
I have a simple JavaScript application that will generate some text type
data for the end user. Is it possible to have a button that will allow them
to save this information to a text file?
...
|
by: =?Utf-8?B?YXNkZg==?= |
last post by:
Hello. I am making a web application with c# and am using this code:
Response.ContentType = "application/x-excel";
Response.AddHeader("Content-Disposition", "attachment;filename=" +...
|
by: ppardi |
last post by:
I'm developing an addin for Word 2007 and I need to determine whether a user
saves a Word 2007 document in an older format (97-2003) after a save as is
done. The scenario is that the user starts...
|
by: guilherme21922 |
last post by:
I want to on a click button save a file:
The file is in D:\FilesExport\Custumers.txt.
I tried to do this but nothinh happens!
...
|
by: ejrfigueiredo |
last post by:
Hi,
Is there a way to get a script function to save a page without the
execCommand (which works on IE but doesn't on Firefox).
Below there's the code I'm using, I took it from a template page...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
| |