Posts by excel_321

    I have a VBA code which opens up a dialog box in which to save my excel sheet. It is working well except one part. When the dialog box opens, it automatically opens in the folder I want to save my file in however if I click ok, it comes up with the following message:


    "Path does not exist. Check the path and try again"


    This error message disappears IF I select the folder again manually and then proceeds to save. I don't want to see the error message especially as the dialog box opens up to save in the correct folder in the first instance. How do i prevent having to select manually. The part of the code in which the problem lies is this:


    Re: VBA Code to convert and save as pdf


    sorry the code I currently have is this one not the one above:


    Re: VBA Code to convert and save as pdf


    More specifically the code I have is as follows:



    This saves the filename as the active sheet followed by date and time. I would like the filename to be whatever is in the contents of cell B52. This is the only amendment to the code I require. The rest is working like a gem.

    Re: VBA Code to convert and save as pdf


    I want to convert a protected sheet to pdf, so when I hit the command button it should open a directory box giving me the option to select a folder to save in. The file name should be the contents of cell B52.

    Can someone help me with a VBA code I need. I want to convert a protected sheet to pdf, so when I hit the command button it should open a directory box giving me the option to select a folder to save in. The file name should be the contents of cell B52.


    Thank you for your help

    Hi,


    How can I horizontally lookup text from a table (using index match) with 2 conditions.


    This is my data set


    [TABLE="width: 497"]

    [tr]


    [td]

    Name

    [/td]


    [td][/td]


    [td]

    Mexico

    [/td]


    [td]

    UK

    [/td]


    [td]

    USA

    [/td]


    [td]

    France

    [/td]


    [/tr]


    [tr]


    [td]

    Andy

    [/td]


    [td][/td]


    [td]

    R

    [/td]


    [td]

    R

    [/td]


    [td]

    G

    [/td]


    [td]

    A

    [/td]


    [/tr]


    [tr]


    [td]

    Sarah

    [/td]


    [td][/td]


    [td]

    R

    [/td]


    [td]

    R

    [/td]


    [td]

    G

    [/td]


    [td]

    R

    [/td]


    [/tr]


    [tr]


    [td]

    James

    [/td]


    [td][/td]


    [td]

    A

    [/td]


    [td]

    A

    [/td]


    [td]

    A

    [/td]


    [td]

    G

    [/td]


    [/tr]


    [tr]


    [td]

    John

    [/td]


    [td][/td]


    [td]

    R

    [/td]


    [td]

    G

    [/td]


    [td]

    G

    [/td]


    [td]

    A

    [/td]


    [/tr]


    [/TABLE]



    I want to pick out the letter from the table based on Name and Country. Eg., James / UK would return "A".


    Many thanks

    Re: Saving a series of PDFs by macro


    What needs to be added to this code in order to save with a file name which consists of the contents of two cells? For example I want to save it by the name which is on the drop down list and also the contents of m68

    Re: Saving a series of PDFs by macro


    the following is my new code but the HideNames macro still not working!


    Re: Saving a series of PDFs by macro


    The final thing looks like this:


    Re: Saving a series of PDFs by macro


    Everything is now working except my hidenames macro! My code for it is as follows and I have substituted it with your:


    Code
    Sub HideNames()      'your routine
    End Sub


    Re: Saving a series of PDFs by macro


    Apologies for my ignorance, what do you mean by:

    "replace my HideNames Sub with yours"


    I wasn't sure what to do here. Do I replace HideNames with the actual code for the HideNames macro or is it something else?

    Re: Saving a series of PDFs by macro


    Whoa this is taking shape! It does save the PDF documents now. There are two issues however,


    1) It does not apply the HIDENAMES macro for some reason
    2) My raw data is on the tab called "class data". The drop down box is also on this sheet. The actual file which needs to be saved is on a tab called "report A4". At the moment the above code is saving the files off "class data".


    How do we solve these two conundrums. I must say I am appreciative of your help. This will make life very easy for me!