Habe die TLB.Pas mal angefügt
Nachtrag: IN VB6 geht's so...
Code:
Public WithEvents objCoffeeBarServant As CoffeeBar.CoffeeBarController
Public iCoffeeBarServant As CoffeeBar.ICoffeeBarController
...
Public Sub Form_Load()
Set objCoffeeBarServant = New CoffeeBarController
Set iCoffeeBarServant = objCoffeeBarServant
...
iCoffeeBarServant.AddBean ("Nicaragua")
...
iCoffeeBarServant.OpenCoffeeBar
End Sub
...
Private Sub objCoffeeBarServant_Brewed(ByVal ticket As String)
Dim orderedCupOfCoffee As ICup
Set orderedCupOfCoffee = iCoffeeBarServant.GetOrderedCup(ticket)
Text1.Text = orderedCupOfCoffee.Taste
Text2.Text = iCoffeeBarServant.ServedCoffees
End Sub