Mirica_Victor
Registered User.
- Local time
- Today, 08:26
- Joined
- Oct 24, 2008
- Messages
- 11
Hy, I have a problem: on a open form event i have the folowing code:
In this format the if block is not run at all. It runs after I have put the code to be runned between Else and End if, only then the if block is executed and the dimensions of the mdb file is checked and the compact is conditionally executed. Anny ideeas why?
Code:
Private Sub Form_Open(Cancel As Integer)
Dim Dimensiune As Double
Dimensiune = FileLen("path_to_self_mdb_file") / 1024 / 1024
If Dimensiune > 500 Then
SendKeys "%tdc"
Else
End if
[Code to run]
End Sub
In this format the if block is not run at all. It runs after I have put the code to be runned between Else and End if, only then the if block is executed and the dimensions of the mdb file is checked and the compact is conditionally executed. Anny ideeas why?