+ Reply to Thread
Results 1 to 2 of 2

Excel Template modification using automation

  1. #1
    Terry Holland
    Guest

    Excel Template modification using automation

    I am using automation (from vb6 project) to open an excel template
    (test.xlt). I want to modify some cell values and then resave the template.
    I keep encountering a File Readonly error. Could someone post some sample
    code that would allow me to programmatically modify an excel template and
    then save template, overwriting old template


    tai

    Terry Holland



  2. #2
    Dave Peterson
    Guest

    Re: Excel Template modification using automation

    I think you may get various responses based on why the file was marked readonly.

    If it was on a server that the user (you) only had read access, too, I think
    you're out of luck.

    If it was marked Readonly (via windows explorer's properties), then you could
    use SetAttr (look at VBA's help) to change it.

    If it was opened readonly (a parm passed in workbooks.open), then don't use that
    parm.



    Terry Holland wrote:
    >
    > I am using automation (from vb6 project) to open an excel template
    > (test.xlt). I want to modify some cell values and then resave the template.
    > I keep encountering a File Readonly error. Could someone post some sample
    > code that would allow me to programmatically modify an excel template and
    > then save template, overwriting old template
    >
    > tai
    >
    > Terry Holland


    --

    Dave Peterson

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1