Password protect Excel 2007 from Java

Password protect Excel 2007 from Java

Page 1 of 1

5 Replies - 4683 Views - Last Post: 31 March 2010 - 10:21 AM Rate Topic: -----

#1 shrimon  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 31-March 10

Password protect Excel 2007 from Java

Posted 31 March 2010 - 08:24 AM

Hi,

I want to create password protected Excel 2007 files from java code.
Is there any third party jar that i can use for this purpose?
I tried to use JExcel api but it looks like Office 2007 is not supported by them.
Any help is greatly appreciated.
Thanks in advance.

Thanks,
Shrimon
Is This A Good Question/Topic? 0
  • +

Replies To: Password protect Excel 2007 from Java

#2 NeoTifa  Icon User is offline

  • Whorediot
  • member icon





Reputation: 2670
  • View blog
  • Posts: 15,712
  • Joined: 24-September 08

Re: Password protect Excel 2007 from Java

Posted 31 March 2010 - 08:29 AM

Well, manipulating Excel files in Java is hard as there's an external library involved or they know the format to read the files. Are you having a specific problem with people jacking your files up with Java? Plus I think there are options to protect your files in the Office menus. Let me check...
Was This Post Helpful? 0
  • +
  • -

#3 shrimon  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 31-March 10

Re: Password protect Excel 2007 from Java

Posted 31 March 2010 - 08:34 AM

Thanks NeoTifa !!!
I have this requirement where i need to generate password protected excel files.
I was able to generate password protected pdf files but looks like the business team wants to have excel files.

Thanks,
Shrimon
Was This Post Helpful? 0
  • +
  • -

#4 NeoTifa  Icon User is offline

  • Whorediot
  • member icon





Reputation: 2670
  • View blog
  • Posts: 15,712
  • Joined: 24-September 08

Re: Password protect Excel 2007 from Java

Posted 31 March 2010 - 08:58 AM

Just a quick glance in the menu, there are 2 options that look like they might work. There are encrypted and protected files. I think encrypted files require a certain security certificate to decode, or at least I think that's how our office has them set up. You can also restrict the users able to see them and alter the credentials. They are under the prepare option under the application menu. ^__^ Hope that helps you out a little.

I would also try using some vba to write a program to ask for a specific password first, or check the users id, for validation before opening. Another source you might find useful is MSDN http://msdn.microsof...us/default.aspx I use this a lot for Excel help.

This post has been edited by NeoTifa: 31 March 2010 - 09:01 AM

Was This Post Helpful? 1
  • +
  • -

#5 shrimon  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 31-March 10

Re: Password protect Excel 2007 from Java

Posted 31 March 2010 - 09:46 AM

I am generating these files from a Servlet.


Thanks,
Shrimon
Was This Post Helpful? 0
  • +
  • -

#6 NeoTifa  Icon User is offline

  • Whorediot
  • member icon





Reputation: 2670
  • View blog
  • Posts: 15,712
  • Joined: 24-September 08

Re: Password protect Excel 2007 from Java

Posted 31 March 2010 - 10:21 AM

Okay, so you're doing this via web then? I'm not too familiar with servlets. Can you explain the process?
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1