On Fri, 23 May 2008 17:09:08 +0300
"Dotan Cohen" <[EMAIL PROTECTED]> wrote:

> 2008/5/23 Jerry Feldman <[EMAIL PROTECTED]>:
> > On Fri, 23 May 2008 11:28:12 +0300
> > "Dotan Cohen" <[EMAIL PROTECTED]> wrote:
> >
> >> I have a calc sheet with a cell who's natural-number content must be
> >> incremented ++1 several times a day. Instead of retyping the new
> >> number over the old number, I would like to create a 'button' that
> >> increments the value by 1. I'm thinking that a clever if condition
> >> might help, but I'm not getting very far doing this alone. Pseudo
> >> JS-style code would look something like onmouseclick(++cell.value)
> >> however I cannot find anything like onmouseclick for Calc if
> >> conditions.
> >
> > While this may not be exactly what you want, how about in
> > tools/customize, create a button in the toolbar, and tie it to a macro.
> > Or, write a macro with a button in a cell. As I mentioned previously, I
> > am a relatively inexperienced spreadsheet person, but I think you can
> > get something doe very nicely.
> >
> 
> Actually, I did try playing with macros, but I could not find a way to
> increment a cell value with a macro either.

There is a lot of Excel examples out there. Take a look at the cell and
range functions. If you can get the cell value, just assign it to a
variable, then store it back into the cell. I'm about to leave work,
but I need to do some macro work on a sheet at work, so I'll try to
work on something either tonight or over the weekend. 



-- 
--
Jerry Feldman <[EMAIL PROTECTED]>
Boston Linux and Unix
PGP key id: 537C5846
PGP Key fingerprint: 3D1B 8377 A3C0 A5F2 ECBB  CA3B 4607 4319 537C 5846

Attachment: signature.asc
Description: PGP signature

Reply via email to