voyager

Absent Member.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2011-12-02
12:33
808 views
[Migrated content. Thread originally posted on 02 December 2011]
Hello,How could I write this sentence in Visual COBOL?
listView1.RetrieveVirtualItem += new RetrieveVirtualItemEventHandler(listView1_RetrieveVirtualItem);
Thank you
1 Solution
Accepted Solutions
Chris Glazier

Micro Focus Expert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2011-12-02
12:43
invoke listView1::add_RetrieveVirtualItem(new System.Windows.Forms.RetrieveVirtualItemEventHandler(self::listView1_RetrieveVirtualItem)
There is a demo program for Event Handlers in Visual COBOL.
Take a look at C:\Users\Public\Documents\Micro Focus\Visual COBOL 2010\Samples\COBOL for .NET\Events
or open up the Samples Browser in the Visual COBOL group and choose Events.
The sample for Delegates might also be useful...
2 Replies
Chris Glazier

Micro Focus Expert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2011-12-02
12:43
invoke listView1::add_RetrieveVirtualItem(new System.Windows.Forms.RetrieveVirtualItemEventHandler(self::listView1_RetrieveVirtualItem)
There is a demo program for Event Handlers in Visual COBOL.
Take a look at C:\Users\Public\Documents\Micro Focus\Visual COBOL 2010\Samples\COBOL for .NET\Events
or open up the Samples Browser in the Visual COBOL group and choose Events.
The sample for Delegates might also be useful...
voyager

Absent Member.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2011-12-02
12:45
Thanks, Just I have found this example too:
set MsgArrivedEvent to type Delegate::Combine
(
MsgArrivedEvent,
new MsgArrivedEventHandler(self::My_MsgArrivedEventCallback)
) as type MsgArrivedEventHandler