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. C#
  4. Calling a Method in C#

Calling a Method in C#

Scheduled Pinned Locked Moved C#
csharp
4 Posts 3 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.
  • S Offline
    S Offline
    sivainfo
    wrote on last edited by
    #1

    I have declared object in C#. And I want to use a method(logon) for that object in the next statement. Is there any way in C# to do like that. If I try to use it shows "Object does not contain definition for this method". I have tried in VB.net. It is working fine. siva siva

    S 1 Reply Last reply
    0
    • S sivainfo

      I have declared object in C#. And I want to use a method(logon) for that object in the next statement. Is there any way in C# to do like that. If I try to use it shows "Object does not contain definition for this method". I have tried in VB.net. It is working fine. siva siva

      S Offline
      S Offline
      Seishin
      wrote on last edited by
      #2

      MyClass obj = new MyClass(); obj.Method(param); if this doesn't help then show us the code...

      life is study!!!

      S 1 Reply Last reply
      0
      • S Seishin

        MyClass obj = new MyClass(); obj.Method(param); if this doesn't help then show us the code...

        life is study!!!

        S Offline
        S Offline
        sivainfo
        wrote on last edited by
        #3

        object objsession = Glue.newInstance("ClassName") when this method is executed, it creates an object objsession. But there is a method called logon after the session is created. objsession.logon(username,password) This doesnot work. But in VB.net it works. Is there any solution?

        M 1 Reply Last reply
        0
        • S sivainfo

          object objsession = Glue.newInstance("ClassName") when this method is executed, it creates an object objsession. But there is a method called logon after the session is created. objsession.logon(username,password) This doesnot work. But in VB.net it works. Is there any solution?

          M Offline
          M Offline
          Matglas
          wrote on last edited by
          #4

          C# is case sensative. Make sure logon is Logon when the method had capital letters.

          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