Created
July 7, 2011 12:41
Revisions
-
o-eight revised this gist
Jul 7, 2011 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,12 +1,12 @@ Partial Public Class MainPage Inherits UserControl 'WCFサービスのカスタムクラス用のメンバ変数宣言 Dim svc As ServiceReference1.Service1Client Public Sub New() InitializeComponent() 'カスタムクラスのインスタンス生成 svc = New ServiceReference1.Service1Client() 'DoWork呼び出し完了時のイベントハンドラを指定 AddHandler svc.DoWorkCompleted, AddressOf svc_DoWorkCompleted -
o-eight renamed this gist
Jul 7, 2011 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
o-eight created this gist
Jul 7, 2011 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,22 @@ Partial Public Class MainPage Inherits UserControl 'Declare Member-variant for Custom Class by WCF Service Dim svc As ServiceReference1.Service1Client Public Sub New() InitializeComponent() 'initialize Custom Class svc = New ServiceReference1.Service1Client() 'DoWork呼び出し完了時のイベントハンドラを指定 AddHandler svc.DoWorkCompleted, AddressOf svc_DoWorkCompleted End Sub Private Sub svc_DoWorkCompleted(sender As System.Object, e As ServiceReference1.DoWorkCompletedEventArgs) MessageBox.Show(e.Result) End Sub Private Sub button1_Click(sender As System.Object, e As System.Windows.RoutedEventArgs) Handles button1.Click svc.DoWorkAsync("Test Message") End Sub End Class