Help! Need Loop for Printing Bingo Cards

djicenine

New Member
Joined
Mar 16, 2016
Messages
10
Hi All!

I'm really hoping someone can help me with this! I have a bingo card spreadsheet that I use for music bingo. It works like this: I paste in a list of 75 songs into sheet 1, hit F9 to refresh, and a bingo card on sheet 2 gets randomly populated with 25 of the songs. I then hit Control-P to print the card.

My problem is I need to prepare several games per night, and each game needs to have 50-75 unique bingo cards generated. Right now, I am physically pressing F9 to refresh, then control-p to bring up the printer dialog box, then pressing enter to print. This is extremely tedious and time consuming, as you might imagine.

I would like to create a macro that would bring up a dialog box that asks me how many bingo cards I would like to print, then when I hit enter, runs a loop that will refresh the page, then print for however many times I told it to.

I would be psyched if someone could point me in the right direction on this!

Thank you very much!
Patrick
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
What about something like the following:

Code:
[COLOR=#011993][FONT=Menlo]Sub[/FONT][/COLOR][COLOR=#000000][FONT=Menlo] BingoPrint()[/FONT][/COLOR][FONT=Menlo]
[/FONT]
[COLOR=#008F00][FONT=Menlo]' Refresh page and print x number of times[/FONT][/COLOR]
[FONT=Menlo]
[/FONT]
[COLOR=#000000][FONT=Menlo]Application.ScreenUpdating = [COLOR=#011993]False[/COLOR][/FONT][/COLOR]
[FONT=Menlo]
[/FONT]
[COLOR=#000000][FONT=Menlo]x = InputBox("How many sheets do you require printing?")[/FONT][/COLOR]
[FONT=Menlo]
[/FONT]
[COLOR=#000000][FONT=Menlo][COLOR=#011993]For[/COLOR] Card = 1 [COLOR=#011993]To[/COLOR] x[/FONT][/COLOR]
[FONT=Menlo]
[/FONT]
[COLOR=#000000][FONT=Menlo]    Calculate[/FONT][/COLOR]
[COLOR=#008F00][FONT=Menlo][COLOR=#000000]               [/COLOR]'Amend the range to reflect your bingo card[/FONT][/COLOR]
[COLOR=#000000][FONT=Menlo]        Range("A2:G24").PrintOut[/FONT][/COLOR]
[FONT=Menlo]
[/FONT]
[COLOR=#000000][FONT=Menlo][COLOR=#011993]Next[/COLOR] Card[/FONT][/COLOR]
[FONT=Menlo]
[/FONT]
[COLOR=#000000][FONT=Menlo]Application.ScreenUpdating = True[/FONT][/COLOR]
[FONT=Menlo]
[/FONT]
[COLOR=#011993][FONT=Menlo]End[COLOR=#000000] [/COLOR]Sub[/FONT][/COLOR]

I have tested this and it works fine on the Mac.

HTH,

Coops
 
Upvote 0
Beaten 2 it
 
Last edited:
Upvote 0
Coops!

Simply put, you are the Greatest Person on Earth right now! It worked! You are the best! Thank you so much!

Patrick
 
Upvote 0
Most welcome, enjoy your newly found free time
 
Upvote 0

Forum statistics

Threads
1,224,825
Messages
6,181,191
Members
453,021
Latest member
pingpong7117

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top