View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Michael Tomasura Michael Tomasura is offline
external usenet poster
 
Posts: 8
Default Help with programming question

Use a macro.

Sub Macro1()
x = 1
Do While Range("B" & x).Value < ""
Range("B" & x) = Abs(Range("B" & x))
x = x + 1
Loop
End Sub

A macro can be executed from another spreadsheet. You will need both sheets
open. The one with the macro and the one with the data.



--

"drummerboy827" wrote in message
...
allrihgt i have possibly a simple question and possibly not.

I've never programmed in visual basic but it seems quite simple. I'm
very fimilliar with c/c++ and i think i can get the hang of it quickly.
With that being said...

I have a program that saves about 10,000 pieces of data in cell b
starting from 1-n and it saves it as a csv file or soemthing that excel
can open. My question is how would i go about writing a script i can
run on the open sheet that will

1. Convert all numbers in the b cells to positive numbers

2. Add all of the numbers together

3. Display the numbers in another field or a script box or whatever u
would use.

Simply put, i just need to quickly compute seperate spread sheets with
the previous criteria. I just cant figure out how to make something i
can run on seperate sheets as opposed to the script being built into
the sheet.

Any ideas would be greatly appreciated,
~chris culp



------------------------------------------------
~~ Message posted from http://www.ExcelTip.com/
~~ View and post usenet messages directly from http://www.ExcelForum.com/