File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes Peculiar problem facing in web application due to microsoft excel Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Peculiar problem facing in web application due to microsoft excel" Watch "Peculiar problem facing in web application due to microsoft excel" New topic
Author

Peculiar problem facing in web application due to microsoft excel

Periakaruppan Thiagarajan
Ranch Hand

Joined: Jul 26, 2005
Posts: 65
Hi,
We have devoloped a very huge web application for General Motors. The problem we are facing here, whenever we tried to copy either the label or value from the screen (struts with jsp) and paste it in microsoft excel, then try to access the application, the session is getting expired.
This happens only when we copy and paste the content in microsoft excel and not in any other editor like notepad etc.


Thanks,
Pk
Jan Groth
Ranch Hand

Joined: Feb 03, 2004
Posts: 456
are you saying:

- you have a webapplication with a user session.
- if you select and copy text in your browser, everything is okay
- if you paste it into notepad, you can continue surfing
- if you paste it into excel, your session expires

???

which browser? which os?

jan.
Periakaruppan Thiagarajan
Ranch Hand

Joined: Jul 26, 2005
Posts: 65
jan,

Whatever you have pointed out is correct. We are using Internet Explorer 6.0.2800.1106CO and the client side OS is Windows (any release)

Thanks,
PK
Peter Chase
Ranch Hand

Joined: Oct 30, 2001
Posts: 1970
Note: this is neither a Java question nor a beginner question. The Web pages may be generated by Java, but that's almost certainly got nothing to do with it.

If your stated observations are indeed correct, then what is happening might be due to the different types of data being posted to different applications.

When you Copy something onto the clipboard, the application from which you are copying (IE in your case) can decide to put more than one version of the data onto the clipboard. For instance, it could put plain text and HTML. More importantly, it could put some Microsoft special linking object (OLE or whatever's the current thing - I'm out of date on MS) on the clipboard that would call back to the originating application when pasted.

When you paste into Notepad, which is a dumb application, it can probably only accept the plain text version.

When you paste into Excel, which is a Microsoft application with all associated bells, whistles (and bugs?), it can probably accept all the different data types, including the special linking object perhaps. Therefore, pasting the data into Excel might cause calls to be made from Excel to IE, to get data or metadata. Maybe there's a bug in this process that causes the session to be expired.

If that's the case, you could work around it by using Paste Special, instead of Paste. When you do Paste Special, it gives you a menu of all the types of data on the clipboard. If you choose something simple like plain text or HTML, the problem might go away.
[ June 08, 2006: Message edited by: Peter Chase ]

Betty Rubble? Well, I would go with Betty... but I'd be thinking of Wilma.
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

Cutting and pasting anything from IE shouldn't have any effect on your session. Why should it? You are not making a request nor closing IE. Is this all you are doing? How do you open Excel - from inside the browser, or as a completely seperate application? When you say "then try to access the application" do you mean just by going back to the screen you have copied, or clicking a link in the content you have just pasted Excel? Tell us more detail, because what you have so far just doesn make sense.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Periakaruppan Thiagarajan
Ranch Hand

Joined: Jul 26, 2005
Posts: 65
Peter,

Many thanks.

I tried to paste the content using the option Paste Special by selecting plain text and it was working fine without any session expiry problem.

But, how to solve the issue by using paste option instead of paste special?. Why this is not happening in other web application like yahoo, google and etc.

Thanks,
Pk
Periakaruppan Thiagarajan
Ranch Hand

Joined: Jul 26, 2005
Posts: 65
Paul,

As per peter comments, it was working fine when we select paste special option instead of paste option.

for your question, we have open a excel as a seperate application and the only link to the web application is the content we have copied. Once pasted in excel, we went back to the screen we have copied and did some other operations like saving the details etc.

Thanks,
Pk
Periakaruppan Thiagarajan
Ranch Hand

Joined: Jul 26, 2005
Posts: 65
Please, can anybody help me on this.
Joanne Neal
Rancher

Joined: Aug 05, 2005
Posts: 3527
    
  15
As Peter said, this is unlikely to be a Java problem. You might have better luck on an Excel or IE forum.


Joanne
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Peculiar problem facing in web application due to microsoft excel