+ Reply to Thread
Results 1 to 4 of 4

Macro completes 1st step not 2nd. Also run time error

  1. #1
    Registered User
    Join Date
    03-22-2017
    Location
    England
    MS-Off Ver
    2016
    Posts
    3

    Macro completes 1st step not 2nd. Also run time error

    Hey guys when running the following macro i can get a document to print but when it comes to case 7 I can only get the DR Label to print. I cant get the Lining HBJ to print am i missing something that would print both pages? It works fine with any of the cases before hand but any with 2 pages to print it will only print the 1st page.

    Also after I run the macro it comes up with ("Run-time error '13': Type mismatch) but the macro still works fine is their anyway to solve this?

    I'm sure its simple but im still learning this is only my 3rd macro and I don't spend much time on them so I'm a noob.

    Please Login or Register  to view this content.
    Moderator's note: Please take the time to review our rules. There aren't many, and they are all important. Rule #3 requires code tags. I have added them for you this time because you are a new member. --6StringJazzer

    Thanks for the help in advance.
    Last edited by 6StringJazzer; 03-22-2017 at 11:20 AM.

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2411
    Posts
    26,673

    Re: Macro completes 1st step not 2nd. Also run time error

    Where did you get this syntax? That syntax is "clever" side-effect syntax, and it could be messing up assignment of the printer or something. Use something more straightforward.

    Change all of your code like this:

    Please Login or Register  to view this content.
    That will probably solve some problems but I am still not sure why you are getting 1 page when you expect 2. I would probably have to see your file for that. Can you attach it? Under the text box where you type your reply click the Go Advanced button. On the next screen scroll down and click on Manage Attachments, which will show a pop-up window to Select and Upload a file. Then close the window.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    03-22-2017
    Location
    England
    MS-Off Ver
    2016
    Posts
    3

    Re: Macro completes 1st step not 2nd. Also run time error

    Hey 6Stringjazzer

    Please see attached I've attached before I've made the update or do you want me to make the update. I will make the update now let me know if you want me to re upload. Thanks mate.
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    03-22-2017
    Location
    England
    MS-Off Ver
    2016
    Posts
    3

    Re: Macro completes 1st step not 2nd. Also run time error

    I just made the change and it no longer works weirdly.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 2
    Last Post: 01-11-2017, 12:24 AM
  2. [SOLVED] Runtime Error 9, open debug and macro completes
    By Aaron092 in forum Excel Programming / VBA / Macros
    Replies: 42
    Last Post: 11-03-2014, 10:09 AM
  3. why is this code returning error AFTER it completes
    By Muzza86 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 04-24-2014, 09:30 AM
  4. [SOLVED] preventing simple zoom macro from running step by step
    By reece1984 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-11-2012, 06:13 AM
  5. I need a drop down list that auto completes and filters at the same time
    By TranceDiablo in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-01-2011, 09:06 AM
  6. On error, go back a step in macro
    By girthhart in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 10-07-2008, 12:04 PM
  7. Still adding to Complex Macro...1 step at a time.
    By oberon.black in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-04-2005, 01:05 PM

Tags for this Thread

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