Public Class Parser Public Event OnReplaceWithThisContent(ByVal e as MyEventArgs) Public Overridable Function ReplaceWithThisContent() As Boolean Dim loMyEventArg as MyEventArgs = new MyEventArgs RaiseEvent OnReplaceWithThisContent(loMyEventArg) IF loMyEventArg.pmks_nodefault = true Return(loMyEventArg.pmks_returnvalue) Else Return True End if End Function End Class Public Class myEventArgs pmks_nodefault = false pmks_returnvalue as Object = false End ClassStep 2.
Public Class ViewPagePage Inherits Framework.Framework.ViewPage Public Overrides Function GetPage() As Boolean Dim loParser As Framework.Framework.Parser = New Framework.Framework.Parser(oProcess) AddHandler loParser.OnReplaceWithThisContent, AddressOf MyOnReplaceWithThisContent ' Parse for table loParser.cTable = "Company" loParser.cContent = lcNotes loParser.oOriginator = Me If Not loParser.ParseForTable() Then Return False End If Return True End Function Private Sub MyOnReplaceWithThisContent(ByVal e as MyEventArgs) e.pmks_nodefault = true e.pmks_returnvalue = false End SubIn This case.. when you run loParser.ParseForTable - at first it RaiseEvent OnReplaceWithThisContent with
> Public Class Parser > > Public Overridable Function ReplaceWithThisContent() As Boolean > Return True > End Function > > End Class >>
> Public Overrides Function ReplaceWithThisContent() As Boolean > Return True > End Function >>
>Public Class ViewPagePage > > Inherits Framework.Framework.ViewPage > > Public Overrides Function GetPage() As Boolean > Dim loParser As Framework.Framework.Parser = New Framework.Framework.Parser(oProcess) > > ' Parse for table > loParser.cTable = "Company" > loParser.cContent = lcNotes > loParser.oOriginator = Me > If Not loParser.ParseForTable() Then > Return False > End If > > Return True > End Function >>