VBAでWCFServiceを呼び出すためのさまざまなパラメーターを知りたいですか?私はこれを見つけました:
Dim addr As String
addr = "service:mexAddress=""net.http://y000zvk:7878/_vti_bin/Services/RetrieveList.svc/mex"","
addr = addr + "address=""net.http://y000zvk:7878/_vti_bin/Services/RetrieveList.svc/mex"","
addr = addr + "contract=""ServiceReference1.RetrieveList"", contractNamespace=""http://test.com"","
addr = addr + "binding=""basicHttpBinding"",bindingNamespace=""http://tempuri.org/"""
Dim service1 As Object
Set service1 = GetObject(addr)
MsgBox service1.GetSiteTitle()
しかし、私は、コントラクト、バインディング、バインディングの名前空間パラメーターで何をpuするかを本当に知りません。C#を使用してWCFサービスを作成しました。これは、app.configエンドポイントです。
<client>
<endpoint address="http://y000zvk:7878/_vti_bin/Services/RetrieveList.svc"
binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_RetrieveList"
contract="ServiceReference1.RetrieveList" name="BasicHttpBinding_RetrieveList" />
</client>
Webサービスを呼び出す方法について何かアイデアはありますか?デバッグモードの場合は、次のエラーが発生します。
スキーム'net.http'で使用できるバインディングがないため、MetadataExchangeClientインスタンスを初期化できませんでした。コンストラクターでBindingを指定するか、configurationNameを指定できます。パラメータ名:スキーム
よろしくお願いします