Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. How to consume WCF service throgh Visual Basic 6.0 application

How to consume WCF service throgh Visual Basic 6.0 application

Scheduled Pinned Locked Moved Visual Basic
csharpc++wcfhelp
10 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    amit k mistry
    wrote on last edited by
    #1

    Hi appreciate if someone can help me in this or who already passthrogh this situation ;) We have bunch of c++ and vb,asp classic and cobol application. They all need to consume WCF service . I have read related links as well as MSDN sample but not much strongly helpful.Can someone help me out ? app.config and proxyclient.cs is ready. But don't know excatly how to communicate ? Thanks!!

    N 1 Reply Last reply
    0
    • A amit k mistry

      Hi appreciate if someone can help me in this or who already passthrogh this situation ;) We have bunch of c++ and vb,asp classic and cobol application. They all need to consume WCF service . I have read related links as well as MSDN sample but not much strongly helpful.Can someone help me out ? app.config and proxyclient.cs is ready. But don't know excatly how to communicate ? Thanks!!

      N Offline
      N Offline
      nlarson11
      wrote on last edited by
      #2

      If you can use dotnet, make a com-wrapped dotnet dll that handles the wcf. Then use createobject from the vb6 application to the com-wrapped dll and your off and running.

      'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

      A 1 Reply Last reply
      0
      • N nlarson11

        If you can use dotnet, make a com-wrapped dotnet dll that handles the wcf. Then use createobject from the vb6 application to the com-wrapped dll and your off and running.

        'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

        A Offline
        A Offline
        amit k mistry
        wrote on last edited by
        #3

        Can you elborate the answer ?

        A 1 Reply Last reply
        0
        • A amit k mistry

          Can you elborate the answer ?

          A Offline
          A Offline
          amit k mistry
          wrote on last edited by
          #4

          You are talkin about this ??? http://support.microsoft.com/kb/817248[^]

          N 1 Reply Last reply
          0
          • A amit k mistry

            You are talkin about this ??? http://support.microsoft.com/kb/817248[^]

            N Offline
            N Offline
            nlarson11
            wrote on last edited by
            #5

            Correct.

            'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

            A 1 Reply Last reply
            0
            • N nlarson11

              Correct.

              'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

              A Offline
              A Offline
              amit k mistry
              wrote on last edited by
              #6

              Really not helpful Everytime I got message "entry point cound not found" when adding reference in my VB application and I didnt get any com class. :doh:

              N 1 Reply Last reply
              0
              • A amit k mistry

                Really not helpful Everytime I got message "entry point cound not found" when adding reference in my VB application and I didnt get any com class. :doh:

                N Offline
                N Offline
                nlarson11
                wrote on last edited by
                #7

                I have 4 com-wrapped dlls in my production environment so it works quite well. Let's see your class and makes sure it looks correct. There is also a setting in the project that you have set for com-interoptability.

                'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

                A 1 Reply Last reply
                0
                • N nlarson11

                  I have 4 com-wrapped dlls in my production environment so it works quite well. Let's see your class and makes sure it looks correct. There is also a setting in the project that you have set for com-interoptability.

                  'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

                  A Offline
                  A Offline
                  amit k mistry
                  wrote on last edited by
                  #8

                  actually I don't have idea about how can we add the .cs/.vb(which is created file by svcutil) and app.config file in COMClass ?

                  N 1 Reply Last reply
                  0
                  • A amit k mistry

                    actually I don't have idea about how can we add the .cs/.vb(which is created file by svcutil) and app.config file in COMClass ?

                    N Offline
                    N Offline
                    nlarson11
                    wrote on last edited by
                    #9

                    The article that you pointed out in an earlier answer shows you what you need to do to expose the dotnet class to com. This whole thing started because I thought you were familar with dotnet since you are going to have to write your own wcf code to talk to your services(svc files on the web server) anyway. If this is not true, your going to have to do some research on how to either bypass the need for dotnet on the UI side or research how to use dotnet and find a wcf example and adopt it to what you want to do.

                    'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

                    A 1 Reply Last reply
                    0
                    • N nlarson11

                      The article that you pointed out in an earlier answer shows you what you need to do to expose the dotnet class to com. This whole thing started because I thought you were familar with dotnet since you are going to have to write your own wcf code to talk to your services(svc files on the web server) anyway. If this is not true, your going to have to do some research on how to either bypass the need for dotnet on the UI side or research how to use dotnet and find a wcf example and adopt it to what you want to do.

                      'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous 'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous

                      A Offline
                      A Offline
                      amit k mistry
                      wrote on last edited by
                      #10

                      Hi, the COM wrapper has the clientproxy.cs, app.config (These 2 are from add service reference in vs 2008), COMClass.vb When I built, its create the tlb file in vs. 2008.but when I added this type library (.tlb) in visual basic 6.0 and ran it I got the Error <b>"Could not find the default endpoint element that references contract ' ‘in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element."</b> Here is the application I have created one COM wrapper in VS2008 and added wcf (Add service reference) service ,Did some necessary code to instantiate the object and call methods of WCF service And run it so I got one tlb file in my bin folder which I used in my VISUAL BASIC 6.0 application. I tried lots for dyanamic proxy and configuration with creating channel factory but not helpful .I will appreciate if someone can help me in.... Thanks

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups