+ Reply to Thread
Results 1 to 2 of 2

At once Print Reports with different information AUTOMATICALLY.

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    09-18-2014
    Location
    Pakistan
    MS-Off Ver
    2013, 2016
    Posts
    283

    Question At once Print Reports with different information AUTOMATICALLY.

    Hi All!

    I am working in a college and I have to print many sheets daily in excel.
    But every time I print single sheet at once and then next and then next. All this manually.
    And every page has the information of single student.


    So I make a sample worksheet and need a macro

    I Need
    When I open user form and
    Type in Textbox1 = 2
    Type in Textbox1 = 8
    Then press command button

    It should print this page with roll number 2 to 8
    It should put 2 in Yellow box, update the data and print
    Then auto put 3 in yellow box and update the data and print
    Till 8 number it should print all the cards.

    Can anyone help me in this.

    I shall be very thankful to you.
    Attached Files Attached Files
    Last edited by AmirSoft; 01-29-2015 at 08:29 AM.

  2. #2
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: At once Print Reports with different information AUTOMATICALLY.

    Try this:
    Private Sub CommandButton1_Click()
        Dim l As Long
        On Error GoTo Terminate
        For l = TextBox1.Value To TextBox2.Value Step Sgn(TextBox2.Value - TextBox1.Value)
            With Sheet2
                .Range("B3").Value = l
                .PrintOut
            End With
        Next l
    Terminate:
        If Err.Number Then
            MsgBox "An error occured", vbExclamation + vbOKOnly, "Excel Forum"
            Err.Clear
        End If
    End Sub
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

+ 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. [SOLVED] Events triggered with print/print preview of reports
    By jik_ff in forum Access Tables & Databases
    Replies: 1
    Last Post: 01-11-2013, 06:00 PM
  2. Sorting bulk excel files and extracting information
    By babyfo in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-03-2012, 08:50 AM
  3. Replies: 0
    Last Post: 12-19-2011, 12:42 PM
  4. Save bulk letters and then print them off all together
    By aman1234 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-27-2010, 07:26 AM
  5. Replies: 1
    Last Post: 04-02-2010, 06:14 AM

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