cancel
Showing results for 
Search instead for 
Did you mean: 

VBA event

Former Member
0 Kudos

Hi,

If I send data to the database with the setting 'manual calculation' in Excel the time is much faster than with 'Automatic calculation'.

My problem is: I need the automatic calculation when the users enter data (because of EV_SUM). Is there an VBA event I can trigger before I send data to the database?

Thanks,

Lars

Edited by: Platon BPC on Sep 9, 2010 12:13 PM

Accepted Solutions (1)

Accepted Solutions (1)

steelblu
Explorer
0 Kudos

You may want below code.

BEFORE_SEND

You use this function to execute a custom operation before the system sends data.

Syntax

BEFORE_SEND(Argument As String)

MsgBox Argument

BEFORE_SEND = True

End FunctionEnd of the code.

AFTER_SEND

You use this function to execute a custom operation after the system sends data.

Syntax

AFTER_SEND(Argument As String)

MsgBox Argument

AFTER_SEND = True

End Function

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

The EVSUM function is part of the Excel sheet/workbook and therefore I think it not an option to include the code in VBA.

I'm looking for an event like workbook_open() I can trigger before and after sending data to the database.

If I have this I can use xlCalculationAutomatic and xlCalculationManual respectively.

/Lars

Former Member
0 Kudos

Application.Calculation = xlCalculationAutomatic

Write the EVSuM code.

Application.Calculation = xlCalculationManual