i'd like to pass the value get from crsytal report designer to main form. Below is my code:
Code in module
VB Code:
  1. Option Explicit
  2.  
  3. Public i As Integer
Code in Designer
VB Code:
  1. Option Explicit
  2.  
  3. Private Sub Section4_Format(ByVal pFormattingInfo As Object)
  4.     i = Field7.Value
  5. End Sub
Code in main form
VB Code:
  1. Private Sub Form_Load()
  2.     Load form2 'crystal report form
  3.     MsgBox i
  4.     unload form2
  5. End sub
I get 0 value, which should be 4 (records).
Anyone has idea what's wrong with my code?
Thanks!