View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
Don Guillett Don Guillett is offline
external usenet poster
 
Posts: 10,124
Default how does a macro use an inputbox ?

I repeat, you are probably making this harder than it needs to be. Care to
post your code?

--
Don Guillett
SalesAid Software

"Roger" wrote in message
...
That's the problem, the spreadsheet (or code) doesn't know which line is
the last line +1 for the totals so up to now I have been setting the macro
to put the totals on line 650 irrespective of the number of rows in the
table, and then (afterwards) manually deleting the blank rows before I
print the table. I know how to count the rows, and how to input the number
using InputBox, but I don't know how to use it in a line of code which
needs to refer to a particular cell or several columns (but not all in the
line)

thanks ... Roger

"Don Guillett" wrote in message
...
Why would you do it that way? If you have a line that creates the totals
then excel will already know the row.. Perhaps you should copy/paste your
code here for improvements.

look in vba help for inputbox

--
Don Guillett
SalesAid Software

"Roger" wrote in message
...
I have a table which varies in length from 2 rows to 650 rows. There are
always 14 columns. I have a macro which formats the columns and adds a
total line to the last line of the table + 1. The columns have different
formats, so they need to be formatted one by one so using the macro is
quicker and easier. If I use RowNr = InputBox ("input the row number for
the totals) in the macro I can get the RowNr into the code, but how can I
use it, Rownr, to define a particular row or cell, please ?

Roger