Forum Articles
  Welcome back Join CF
You are here You are here: Home | Forum | For you Windows XP 64 Bitters out there...

You are currently viewing our boards as a guest which gives you limited access to view most of the discussions, articles and other free features. By joining our Virgin Media community you will have full access to all discussions, be able to view and post threads, communicate privately with other members (PM), respond to polls, upload your own images/photos, and access many other special features. Registration is fast, simple and absolutely free so please join our community today.


Welcome to Cable Forum
Go Back   Cable Forum > Computers & IT > General IT Discussion
Register FAQ Community Calendar

Excel and VBA, how to protect?
Reply
 
Thread Tools
Old 23-05-2005, 12:25   #1
Strzelecki
Inactive
 
Join Date: Jan 2004
Location: Essex
Age: 43
Services: 80/20Mbps FTTC on Freeola
Posts: 871
Strzelecki has reached the bronze age
Strzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze age
Excel and VBA, how to protect?

The company my Dad works for have had some stuff done in Excel which includes macros and VB code that has been written by them. The macros are password protected so people can't steal them (supposedly) but now they want to give the program out to a few customers. They've asked me if it's possible to give a good level of protection to their program and also if the program can have a usage timeout (stops working after 30 days) that can be set by them before they give it to the customer. I don't know why they've done it in Excel as the security in there is always crackable and they don't have time to let me rewrite the whole thing in VB or something. They will be giving the program to customers on CD. Anyone have any ideas? I've looked at the standard workbook passwords and VB password stuff and also creating a dll but it doean't seem very good. As for the CD protection timeout that probably can be done but with 3rd party software.
Strzelecki is offline   Reply With Quote
Advertisement
Old 23-05-2005, 13:09   #2
Richard M
Inactive
 
Join Date: Jun 2003
Location: Los Angeles, CA
Age: 47
Posts: 6,343
Richard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze array
Richard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze arrayRichard M has a bronze array
Re: Excel and VBA, how to protect?

The problem here is that VB script is always uncompiled so anyone can view the source.
You could do something like:
Quote:
Dim StopWorking
StopWorking = "01/06/2005"
Dated = Datetime.Now()
If StopWorking <= Dated Then
Response.Write "Trial Expired!"
End If
Or something like that anyway (VB skills are not that good) but even then you'd still be able to look at the code and change the date.
Richard M is offline   Reply With Quote
Old 23-05-2005, 14:59   #3
Raistlin
Inactive
 
Join Date: Feb 2004
Location: There's no place like 127.0.0.1
Services: Depends on the person and the price they're offering
Posts: 12,384
Raistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered stars
Raistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered stars
Re: Excel and VBA, how to protect?

You could look at the Autoexec automation for Excel.

You can include a module called (I think) Autoexec in the VBA for the worksheet. This runs as soon as the worksheet opens. Then use the code above (or an approximation of it to suit your needs) to test the date. If the date is out of the allowed bounds you simply close the sheet.

Hopefully your clients won't necessarily be able to bypass this very easily.
Raistlin is offline   Reply With Quote
Old 23-05-2005, 20:09   #4
Strzelecki
Inactive
 
Join Date: Jan 2004
Location: Essex
Age: 43
Services: 80/20Mbps FTTC on Freeola
Posts: 871
Strzelecki has reached the bronze age
Strzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze ageStrzelecki has reached the bronze age
Re: Excel and VBA, how to protect?

Ah thanks for the suggestions so far, sorry I didn't reply sooner, had to go to work! Just had it emailed to me, 14 worksheets and 31 Macros so I don't think this is a quick job. I'll try autoexec first though!
Strzelecki is offline   Reply With Quote
Old 23-05-2005, 20:56   #5
Raistlin
Inactive
 
Join Date: Feb 2004
Location: There's no place like 127.0.0.1
Services: Depends on the person and the price they're offering
Posts: 12,384
Raistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered stars
Raistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered starsRaistlin is seeing silvered stars
Re: Excel and VBA, how to protect?

What do these spreadsheets do?
Raistlin is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 23:41.


Server: lithium.zmnt.uk
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
All Posts and Content are © Cable Forum