View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Hemant_india[_2_] Hemant_india[_2_] is offline
external usenet poster
 
Posts: 107
Default Reference cell in previous worksheet to then add +1 for serial

thames
write a small routine
something like this
sub x()
dim asheet ,bsheet dim x
x= thisworkbook.worksheets.count
for n= 1 to x
worksheet(n).activate
'your print command here
asheet= worksheet(n).range(f,10) =====change
next n
the code is not complete
but u will get an idea

--
hemu


"Thames" wrote:

Thank you for your response. I do understand what you are saying. Pasted
below is my response to another reply:

I am trying to find if there is a value/function that references a cell on
a previous worksheet. In other words, if assuming there is a value (say
232)in Worksheet 1, Cell F23, that I wish to appear in Worksheet 2 as the
value 233, I know how to program WORKSHEET1!F23+1, but if I wanted to copy
that formula across a 50 sheet workbook, do I need to type in each Worksheet#
on each page, or is there a value that equals a reference to the previous
worksheet, i.e: (PreviousWorkSheet#!F23+1)

"John Bundy" wrote:

You sure can, without knowing the cell or its contents, i can't be exact but
if the last cell is on sheet1 column A cell 10 then wherever you want the
answer:
=Sheet1!A10+1

change Sheet1! to the sheets name and A10 to the cell that its in.
--
-John Northwest11
Please rate when your question is answered to help us and others know what
is helpful.


"Thames" wrote:

I want to print a serial number on previously printed gift cards. The gift
cards are printed 2-up on 8.5x11 stock. I thought I could create a 50 sheet
workbook and print 100 cards at a time by printing the workbook, using my
card stock in my printer tray. Am wondering if there is a way to reference
the cell in the preceeding worksheet, then add a +1 value.