On Wed, Oct 14, 2009 at 4:04 PM, mikea_59 <mikea...@yahoo.com> wrote:
>
> I haven't tried the servlet route yet. I've been doing something like
> this:
>
>      Window.open(GWT.getHostPageBaseURL() + "reports/" + (String)
> csvFile, "_blank", "");
>
> where
>
>      GWT.getHostPageBaseURL() + "reports/" + (String) csvFile
>
> gives me the URL of a .csv file that I want the user to be able to
> save to their local disk. It works in FF (it immediately displays the
> save dialog) but not in IE. IE shows a new page with the contents of
> the .csv file. I had to set a file association for Excel for .csv
> files, and then in the FF Tools->Options->Applications folder set
> Excel Files to "Always Ask", and it just works. Any ideas why this
> doesn't work for IE?

Are you setting the MIME type on the server? You can either create it
in your application or perhaps your server can set it via a
configuration value.

>
>
>
> On Oct 2, 7:29 am, ALEXEI BARBONI <alexeitel...@gmail.com> wrote:
>> Ok, I finished creating a servlet.
>>
>> I pass some parameters like path and name of the file, etc.. and get the
>> download
>>
>> And then I call Window.open at my GWT project
>>
>> Works ok...
>>
>> thanx
>>
>> 2009/10/1 ALEXEI BARBONI <alexeitel...@gmail.com>
>>
>>
>>
>> > Hi guys,
>>
>> > I still couldn't find the right way to create an hyperlink in my web app
>> > that makes a download of a file from the server to the client.
>>
>> > When you say "You have to create a GWT hyperlink and point it to the
>> > resource"
>>
>> > What method of the GWT Hyperlink do I use to point this hyperlink to the
>> > resource (the file to be downloaded in my server - I know the exactly
>> > location path + filename.)
>>
>> > I can't find the method that I can use to point to this file.
>>
>> > Can abybody give me a little help one more time?
>>
>> > thanks again
>>
>> > 2009/9/16 Ian Bambury <ianbamb...@gmail.com>
>>
>> > Please don't post the same question more than once - at least, not in the
>> >> same 5 minutes.
>> >> Ian
>>
>> >>http://examples.roughian.com
>>
>> >> 2009/9/16 sathya <sathyavik...@gmail.com>
>>
>> >>> I am having same problem in GWT 1.7.
>> >>> In my application, I need to download file from server to client. So I
>> >>> am directly using file path in window.open as shown below
>> >>> Window.open(“d:\result.xls”,"_self","");
>> >>> This opens in Firefox as expected however this doesn’t work with IE7.
>> >>> Please let me know if there is any workaround to do this.
>> >>> I need this very urgently. Please help me out in resolving this.
>>
>> >>> On Sep 3, 12:38 pm, chandrahas koyari <koy...@gmail.com> wrote:
>> >>> > Yes you have to create a GWT hyperlink and point it to the resource.
>>
>> >>> > On Sep 2, 6:28 pm, ALEXEI BARBONI <alexeitel...@gmail.com> wrote:
>>
>> >>> > > Hi chandrahas, thanks for the answer
>>
>> >>> > > I've been out from work last week.
>>
>> >>> > > Now I have to create a way to the user of my application make
>> >>> adownloadof
>> >>> > > afilethat is in the server.
>> >>> > > I know the exactly location of thefileand its name.
>>
>> >>> > > But I don't understand how to create a link (would be a GWT
>> >>> Hyperlink) that
>> >>> > > point to myfile. I think this way is easier than to create a servlet.
>>
>> >>> > > Could anybody give me a little help about?
>>
>> >>> > > thank you guys again
>>
>> >>> > > 2009/8/25 chandrahas koyari <koy...@gmail.com>
>>
>> >>> > > > There are two general methods to achieve it
>> >>> > > > 1. Create a link which directly point to that resource (file)
>> >>> > > > 2. Point to a Servlet which respond with afile(by using
>> >>> > > > getResourceAsFile() )
>>
>> >>> > > > On Aug 25, 2:50 am, Alexei Telles <alexeitel...@gmail.com> wrote:
>> >>> > > > > Hi...
>>
>> >>> > > > > I need to create a link in my web application where the user will
>> >>> > > > >downloadafilethat is in my server.
>>
>> >>> > > > > I was searching for something in the web, but I could not find
>> >>> > > > > something about.
>>
>> >>> > > > > Is there any GWT tool that allow me to develop a link in my
>> >>> > > > > application to make adownloadfrom the server to the client?
>>
>> >>> > > > > Or another way that you guys use to do?
>>
>> >>> > > > > Thanks again- Hide quoted text -
>>
>> >>> > - Show quoted text -- Hide quoted text -
>>
>> - Show quoted text -
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to