Click to See Complete Forum and Search --> : Outlook Forms


e8370
October 10th, 2001, 08:10 AM
Hi All,
Hope you can help out a beginner. I have done enough VB and VBA programming to do all the basic stuff, but I can't figure out the way the VBScript in Outlook 98 works.
I have created a form in a task. The form holds a combobox and a textbox. The goal is to automatically fill in the description in the textbox, when the user selects an item in the combobox.
This is (part of) the code I'm trying to use:

Sub Item_Open
set MyPage = Item.GetInspector.ModifiedFormPages("VerwerkingsBlokken")
End Sub





Sub ComboBox1_Click
MyPage("VerwerkingsBlokken").Controls("txtOms01").Value = OmsBlok(MyPage.ComboBox1.Value)
End Sub





Function OmsBlok(Blok)
Select Case Blok
Case "NVCONX01"
OmsBlok = "Conversietraject WAO/ZW"
Case else
OmsBlok = ""
End Select
End Function




What is going wrong? When I try to do this in an MS Access form, everything works fine...