Communicating Between Multiple Projects

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Veleek

    #1

    Communicating Between Multiple Projects

    An alternate title for this might be "Creating my own set of core
    classes".

    Just a quick overview. In order to learn C#, Sockets, Multithreading
    and whatever else I can, I am attempting to create MSN Messenger (My
    Sucky New Messenger), ie. a simple IM program as it is a interesting
    way to incorporate all of the project. This will utilize a server
    which all the useres will connect to in order to determine who is
    online. After users have connected they will be able to open up
    seperate windows in order to chat with other users. The person running
    the server will also be able to open up chat windows with the users.

    Now my question is this: Both the client and server have the ability to
    chat, so for consistancy, I would like it to just use the same window
    form. Plus I will be passing user and messages back and forth and
    would like to pass objects instead of just using strings.

    How can I create a series of common classes and structures (including
    my 'Chat' window) that I can share among each of the applications. Is
    this as simple as creating a new project in the same solution? This is
    what I have done for creating the main Client/Server portions. If so,
    how can I start BOTH applications at the same time through VC#?

    I was having problems deciding which board this message would be better
    suited for

  • Veleek

    #2
    Re: Communicating Between Multiple Projects

    Sorry, Accidental post there. Just let me complete this.

    I was having problems deciding which board this message would be better
    suited for, a language one or a VisualStudio one as it's kinda sitting
    right on the edge.

    I would appreciate any help or suggestions. Thanks.

    Comment

    • Nicholas Paldino [.NET/C# MVP]

      #3
      Re: Communicating Between Multiple Projects

      Veleek,

      For something like this, you want to create a library project. You can
      put your common functionality in this project and then you can add a
      reference to the output (or the project itself) as well. Then, you can
      share the functionality between any other projects you have.

      Also, as a side note, there are API's in windows that allow you to
      handle messaging functionality pretty easily (which MSN messenger is based
      on). You would have to access this functionality through COM interop. The
      reference for the APIs are at (watch for line wrap):

      http://msdn.microsoft.com/library/de...nger_entry.asp

      Hope this helps.


      --
      - Nicholas Paldino [.NET/C# MVP]
      - mvp@spam.guard. caspershouse.co m

      "Veleek" <veleek@gmail.c om> wrote in message
      news:1137831689 .239761.219120@ z14g2000cwz.goo glegroups.com.. .[color=blue]
      > An alternate title for this might be "Creating my own set of core
      > classes".
      >
      > Just a quick overview. In order to learn C#, Sockets, Multithreading
      > and whatever else I can, I am attempting to create MSN Messenger (My
      > Sucky New Messenger), ie. a simple IM program as it is a interesting
      > way to incorporate all of the project. This will utilize a server
      > which all the useres will connect to in order to determine who is
      > online. After users have connected they will be able to open up
      > seperate windows in order to chat with other users. The person running
      > the server will also be able to open up chat windows with the users.
      >
      > Now my question is this: Both the client and server have the ability to
      > chat, so for consistancy, I would like it to just use the same window
      > form. Plus I will be passing user and messages back and forth and
      > would like to pass objects instead of just using strings.
      >
      > How can I create a series of common classes and structures (including
      > my 'Chat' window) that I can share among each of the applications. Is
      > this as simple as creating a new project in the same solution? This is
      > what I have done for creating the main Client/Server portions. If so,
      > how can I start BOTH applications at the same time through VC#?
      >
      > I was having problems deciding which board this message would be better
      > suited for
      >[/color]


      Comment

      Working...