469,628 Members | 1,033 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,628 developers. It's quick & easy.

FileDownload with WebBrowser Control - disable the Save?

want to open a word document stored in my database.

What I do is save the document locally, and then open a new winform
that has the WebBrowser Control on it and navigate to that new file.

This allows the user to manipulate the file and save it. When they
close the WebBrowser, if the contents has changed I save it back to the
db, and delete the local file.

My problem is the "File Download" window that comes up. If the user
clicks Save or Cancel things don't work. I'd like to surpass this
screen altogether, but from what I've read, you can't avoid it.

Is there a way to disable the Save and Cancel buttons? Or at least the
Save button?

Thanks for any suggestions.

Jan 27 '06 #1
2 5844
Why don't you just use the shell function and let Windows determine the
proper program?
(e.g. Shell "cmd /c start YourFile.doc")

If the user has Word (or OpenOffice or WordViewer) installed, it will
open the document. This way you don't have to deal with any
"Save/Cancel" dialog.

I once posted a routine for that (in classic VB,
http://groups.google.com/group/micro...366585997c940f
)
You might want to use that as a reference.

Best Regards,

HKSHK

Jan 29 '06 #2
If you use the shell, would you have any way on knowing if the document
is still open or if it has been closed?.

I open the web browser as a showdialog, so the user can't do anything
else in my program, until they are done w/ the document changes and has
closed the document.

Thanks.

Feb 17 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

9 posts views Thread by ASP .NET Newbie | last post: by
reply views Thread by Jim | last post: by
2 posts views Thread by standish22 | last post: by
8 posts views Thread by Prosperz | last post: by
15 posts views Thread by Laurent Lequenne | last post: by
1 post views Thread by Marc Gravell | last post: by
reply views Thread by prefect | last post: by
reply views Thread by Sin Jeong-hun | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.