Solved

Read only Excel Property Using Lotus Script

Posted on 2010-09-04
6
1,030 Views
Last Modified: 2013-12-18
Experts,

I am use Lotus Script to collect fields from selected and populate a specific Excel template. The report is meant to be a raw data export and I was hoping to add a read-only property to this file save entry. Can anyone help?
      
'identify and save the file
      x1App.ActiveWorkbook.SaveAs "H:\Data\"+ db.Title + " on " +RServer(0) + "_" + RDate +".xls"
      x1App.Application.ActiveWindow.Close (False)
      
      x1App.Application.Quit
      Set x1App=Nothing
0
Comment
Question by:mcjann
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
6 Comments
 
LVL 22

Expert Comment

by:mbonaci
ID: 33605452
All you can do to protect excel sheet is to use built-in protect worksheet option:

http://msdn.microsoft.com/en-us/library/dkcs53f3(VS.80).aspx
http://msdn.microsoft.com/en-us/library/aa174285(office.11).aspx


See here for previous Excel versions:
http://www.experts-exchange.com/Q_21622231.html
This is the correct link for Office 2003 (the one in the accepted comment doesn't work):
http://msdn.microsoft.com/en-us/library/aa204840(office.11).aspx
0
 
LVL 85

Accepted Solution

by:
Rory Archibald earned 500 total points
ID: 33611904
YOu can add a Read-only recommended property using the SaveAs method, or you can actually set the file attributes (it would be SetAttr in VBA).
0
 
LVL 22

Expert Comment

by:mbonaci
ID: 33936259
Since we haven't received any response, I'm not really sure if my answer is what he really wanted to do...
When I read it now, it seems that rorya was on the right track.
0
 
LVL 24

Expert Comment

by:broomee9
ID: 34026892
This question has been classified as abandoned and is being closed as part of the Cleanup Program.  See my comment at the end of the question for more details.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem "Can you help me recover my changes?  I double-clicked the attachment, made changes, and then hit Save before closing it.  But when I try to re-open it, my changes are missing!"    Solution This solution opens the Outlook Secure Temp Fold…
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question