473,387 Members | 1,771 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

i'm stuck!

Hi guys, I desperately need a program that will open a password protected excel file and then save it as a none password protected file.

Problem is perl is not letting me do that so I've turned to VB. I don't know ANY VB so haven't got a clue where to start and haven't got time to learn it...

Anyone know where there may be code for this/similar code. Or does anyone want to write some code? ;-)

Thanks, A helpless noob.
Dec 29 '06 #1
3 1182
Killer42
8,435 Expert 8TB
Hi guys, I desperately need a program that will open a password protected excel file and then save it as a none password protected file.

Problem is perl is not letting me do that so I've turned to VB. I don't know ANY VB so haven't got a clue where to start and haven't got time to learn it...

Anyone know where there may be code for this/similar code. Or does anyone want to write some code? ;)
Quick question - do you mean that you want it to work without knowing the password? Or will you splly the password? I'm no expert on this, but I'd say it's likely to make a big difference.

Also, what version of VB?

(Note, it might be easier to throw the program together using the VBA editor built into Excel.)
Dec 31 '06 #2
Well I know the password, I just need to be able to open the excel file, copy all the data to a new excel file and then save it (hence having an identical file that isn't password protected) Then I'll use perl to play with the excel file.

My main problem is that there is no way to open a file in perl that is password protected, so I have to open it in VB (whichever version) and then save a non-password protected file. Bit long winded but I don't know any other way!
Jan 2 '07 #3
Killer42
8,435 Expert 8TB
Well I know the password, I just need to be able to open the excel file, copy all the data to a new excel file and then save it (hence having an identical file that isn't password protected) Then I'll use perl to play with the excel file.

My main problem is that there is no way to open a file in perl that is password protected, so I have to open it in VB (whichever version) and then save a non-password protected file. Bit long winded but I don't know any other way!
So would it be enough to simply open the spreadsheet and save it (perhaps under a new name) without the password? Or do you actually need to copy the data to another spreadsheet? The open/save seems likely to be simpler.

Here's a sample macro I recorded in Excel, saving a spreadsheet without password...
Expand|Select|Wrap|Line Numbers
  1. Sub SaveUnprotected()
  2.   ActiveWorkbook.SaveAs Filename:= _
  3.     "C:\Documents and Settings\<username>\My Documents\rrrr.xls", FileFormat:=xlNormal _
  4.     , Password:="", WriteResPassword:="", ReadOnlyRecommended:=False, _
  5.     CreateBackup:=False
  6. End Sub
Is this any help?
Jan 2 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: No | last post by:
I purchased a program ( So I thought) that turned out to be just a bunch of php scripts put together. I am getting terrible support from the author but I am biting my tongue because I don't want...
1
by: ron | last post by:
have been stuck on this for several days now. I am trying to create a reverse polish calculator and I'm stuck at an intermediate stage. This is what I know I have to do (just not sure how to do it...
2
by: Vladimir | last post by:
I'm running ASP on IIS 5.1 on Windows XP, the same thing works on Windows 98 with PWS. The function below stuck the IIS - draws only frame with nothing inside and wait for infinite. All other...
3
by: Yeren | last post by:
We run a website with pages that are created using ASP. The website is used by different people from different networks. For some people, the pages are stuck. It looks like the were able to open...
2
by: Bryan Field-Elliot | last post by:
We have a running server (v7.3) which, over time, seems to accumulate a bunch of "stuck" PostgreSQL instances which appear to be dead inside of a transaction. For example, "ps" reveals many of...
8
by: MLH | last post by:
I use a mouse-down procedure to trap right mouse clicks and CTRL-Right mouse clicks. Running the procedure must put honey or some other sticky substance into my keyboard because subsequent...
4
by: Astronomically Confused | last post by:
using System; using System.Collections; using System.IO; using System.Net; using System.Net.Sockets; using System.Threading; class HttpProcessor { private Socket s;
4
by: =?Utf-8?B?TWF1cg==?= | last post by:
My cd is stuck in the drive. I can open the drawer O K but the c d will not come out Help me please -- Maur
0
by: =?Utf-8?B?QmlsbEI=?= | last post by:
This is a tough one... My Windows Service app periodically performs some processing on new entries to a SQL Server database table. It uses a simple System.Timer to call the Elapsed event...
7
by: alphasahoo | last post by:
Hi I am working on a program which writes the output a SQL select statements from number of source tables first to a load matrix and then writes to a load.dat file. But while writing to the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
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,...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.