G
Guest
I want to make a calculation between 2 records, for example:
My original table looks like:
Itemnumber date quantity
1 01-11-05 10
1 05-11-05 -8
1 07-11-05 -3
2 01-11-05 5
2 05-11-05 -6
The final result should be:
Itemnumber date quantity total available
1 01-11-05 10 10
1 05-11-05 -8 2
1 07-11-05 -3 -1
2 01-11-05 5 5
2 05-11-05 -6 -1
Because I don't think this is possible in Access, I export my original table
to Excel and calculate the last column. Afterwards I import the table (with
the last column) back to Acess.
I want that this calculation goes automatically.
The first thing I tried was to make a macro in Access with the function
"send keys".
So I open the excelsheet and send keys to calculate the last column.
For the first record this was no problem. But I can't find the right keys to
send to excel to copy the formula downwards.
Does anyone know this keys??
The second thing I tried was to make a macro in excel and tried to send the
keys Ctrl + Z to run the macro.
This din't work uptill now.
Does anyone know how I must send Ctrl + Z to excel?
Finally: Is there perhaps a solution in Access??
Jan van Hooff
My original table looks like:
Itemnumber date quantity
1 01-11-05 10
1 05-11-05 -8
1 07-11-05 -3
2 01-11-05 5
2 05-11-05 -6
The final result should be:
Itemnumber date quantity total available
1 01-11-05 10 10
1 05-11-05 -8 2
1 07-11-05 -3 -1
2 01-11-05 5 5
2 05-11-05 -6 -1
Because I don't think this is possible in Access, I export my original table
to Excel and calculate the last column. Afterwards I import the table (with
the last column) back to Acess.
I want that this calculation goes automatically.
The first thing I tried was to make a macro in Access with the function
"send keys".
So I open the excelsheet and send keys to calculate the last column.
For the first record this was no problem. But I can't find the right keys to
send to excel to copy the formula downwards.
Does anyone know this keys??
The second thing I tried was to make a macro in excel and tried to send the
keys Ctrl + Z to run the macro.
This din't work uptill now.
Does anyone know how I must send Ctrl + Z to excel?
Finally: Is there perhaps a solution in Access??
Jan van Hooff