+ Reply to Thread
Results 1 to 8 of 8

Modify Checkbox Value on Save As Box

  1. #1
    Registered User
    Join Date
    10-20-2010
    Location
    Norwich, England
    MS-Off Ver
    Excel 2003
    Posts
    6

    Modify Checkbox Value on Save As Box

    Good Morning,

    I posted yesterday with a query on how to stop files automatically opening when they are printed to a file (http://www.excelforum.com/excel-prog...d-to-file.html).

    I managed to resolve this by finding out there was a checkbox in the "Save As" box that pops up when you choose "Print to File". Now while I can go through all the workbooks that I need to print, and save them with this checkbox unchecked it would be much neater if there was a way to do this through the same macro that I use for printing out all the sheets in the workbook.

    So my question is, can this checkbox be manipulated through VBA or will I just have to bite the bullet and go through all the workbooks manually ensuring that this checkbox is unchecked. (If there is a way of turning this off altogether through excel itself then that would be a solution but I don't believe that there is)

    I have been scouring Google for the last day or so and have so far come up with nothing so any pointers/hints to get me going in the right direction would be very much appreciated.

    Below is my code just in case anyone wants it :-

    Please Login or Register  to view this content.
    Thanks in advance,

    Ben

  2. #2
    Valued Forum Contributor blane245's Avatar
    Join Date
    02-20-2009
    Location
    Melbourne, FL
    MS-Off Ver
    Excel 2010
    Posts
    649

    Re: Modify Checkbox Value on Save As Box

    I haven't been able to find this "Save As" checkbox that you refer to. When I manually select "Print to File", I get a pop up asking for a file name, but no checkboxes on it. What version of Excel are you using?
    Bob
    Click my star if my answer helped you. Mark the thread as [SOLVED] if it has been.

  3. #3
    Registered User
    Join Date
    10-20-2010
    Location
    Norwich, England
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Modify Checkbox Value on Save As Box

    I'm using Excel 2003 Professional. I think the checkbox only appears if you print to the "Microsoft Document Image Writer".

    Sorry for not clarifying that in the original post as that is the printer I am sending the data too as I need to convert it to a .tif.

  4. #4
    Valued Forum Contributor blane245's Avatar
    Join Date
    02-20-2009
    Location
    Melbourne, FL
    MS-Off Ver
    Excel 2010
    Posts
    649

    Re: Modify Checkbox Value on Save As Box

    That is what I am doing. Could you send a screen print of the window containing the button you are referring to. That may help me find it.

  5. #5
    Registered User
    Join Date
    10-20-2010
    Location
    Norwich, England
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Modify Checkbox Value on Save As Box

    Hmm, very strange that I am getting it and you aren't. Attached is the screenshot of the save as dialog box.

    The checkbox I am referring to is the "View Document Image" one at the bottom of the window. Have just reread my original post for a 3rd time and have realised that I didnt actually put the name of the checkbox on there so my apologies again for that (thanks for being patient and still trying to help out!)

    If this box is checked then the document will automatically open once it has been printed to a file - if it is unchecked then the document does not automatically open. I need to force this checkbox to be unchecked through code if possible to save me having to go through every workbook and manually do it.

    Thanks again!

    Ben
    Attached Images Attached Images

  6. #6
    Valued Forum Contributor blane245's Avatar
    Join Date
    02-20-2009
    Location
    Melbourne, FL
    MS-Off Ver
    Excel 2010
    Posts
    649

    Re: Modify Checkbox Value on Save As Box

    I don't get the Save As dialog. What I get is different and is attached. Let's make sure we are on the same page. I select File->Print. I select the Microsoft Office Document Image Writer and then check Print to File.

    I suspect that we have different versions of the image writer. My is version 11.03.8166.02. I got it from the print Properties... dialog

    PrintToFile.JPG

  7. #7
    Registered User
    Join Date
    10-20-2010
    Location
    Norwich, England
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Modify Checkbox Value on Save As Box

    Aha. I see why we are getting different results now. I am not ticking the "Print to File" checkbox on the print dialog as when you print to the "Microsoft Document Image Writer" it goes to a file anyway. Try leaving this box unticked and (hopefully) you will get the same save as dialog box as I get.

    I can also confirm that I am using version 11.03.8166.02 of the Microsoft Document Image Writer though.

  8. #8
    Valued Forum Contributor blane245's Avatar
    Join Date
    02-20-2009
    Location
    Melbourne, FL
    MS-Off Ver
    Excel 2010
    Posts
    649

    Re: Modify Checkbox Value on Save As Box

    After all of this confusion on my part, I now see what your problem is, but now I am getting a different behavior. When I use the PrToFile argument, it seems to ignore it and use the OpenFileDialog (with the View Document Image checkbox) rather than the Print to File dialog. If I leave off the PrToFile parameter, then I get the Print to File Dialog. Very strange.

    In any case, I have tried recording macros under various situation and have not been able to see that the View Document Image checkbox is accessible to VBA thorugh through that dialog. I have not been able to locate the View Document Image attribute within the workbook properties, but it has got to be there somewhere, just not accessible to VBA.

    I will keep looking...

+ 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