LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default help with print button

I have an excel workbook which contains two sheets:

1. Inv
2. Sheet1

The Inv sheet contains these colums:

SEQ ITEM DESC BRAND NAME NAME WHOUSES

All the columns contain data.

The second sheet (Sheet1) contains the Inventory sheet that we want to use
for our Warehouse Inventory. This sheet contains all the columns like INV
sheet but on different places.

There are two cells on sheet1 SEQ=1. SEQ= is on one cell and number 1 is on
second cell. If we change the sequence number from 1 to 2 or 3 it will change
the ITEM CODE and ITEM DESCRIPTION on this sheet according to what is present
on the INV sheet.

The sheet1 contains a print button which will print the Inventory sheet
according to the ITEM NUMBER AND ITEM DESCRIPTION if we change the SEQ number.


The problem is that we want to print between two sequences. The print button
should print multiple sheets on continuous paper with different ITEM CODE AND
ITEM DESCRIPTION.

Like if we ask it to print between SEQ=1 TO SEQ=5. It should print multiple
sheets containing ITEM CODE=1 TO ITEM CODE=5 and ITEM DESCRIPTION=1 TO ITEM
DESCRIPTION=5.

The print button contains the following code:

Private Sub CommandButton1_Click()
Range("F1").Select
ActiveCell.FormulaR1C1 = Range("J1").Value - 2
Y = Range("J1").Value
Z = Range("J2").Value
For X = Y To Z
'Application.Run "MEDICAL.xls!Module1.Button2_Click"
'Exit For

Range("E1").Select
Selection.Copy
Range("F1").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Range("E1").Select
Application.CutCopyMode = False
ActiveCell.FormulaR1C1 = "=RC[1]+1"
Range("F1").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True

Next X


End Sub


can somebody help???

thankx!




 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Print Button Pass-the-Reality Excel Discussion (Misc queries) 1 March 31st 10 02:05 PM
print button macro & specific tabs to print Chuck[_3_] Excel Worksheet Functions 2 November 22nd 07 12:21 AM
Print Button Optitron Excel Programming 2 September 8th 05 03:14 PM
button to print rob New Users to Excel 2 January 13th 05 09:45 PM
overriding the print button and File/Print Pablo Excel Programming 3 September 11th 03 07:07 PM


All times are GMT +1. The time now is 09:36 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"