Click here to Skip to main content
15,888,242 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
what is the code of the function or functions to receive notification regarding network architecture ?

What I have tried:

a simple try
a most simple code
C#
class school 
{
    public string name {get;set;}
    public int nos_class{get;set}
}
class a
{
    school ss=new school();
    ss.nos_class=12;
    public static void student(out school s,in school ss)
    {
        s=new student();
        s.name="vvvv";
        System.out.println(s.name+"   "+ ss.nos_class);
    }
    main()
    {
        school a=new school
        {
            name ="cccc";  //is changed in code 
         nos_class=14;     //is not changed 
        }
        student (school,school);
    }
}

if this code is changed with the member functions of the namespace system.net.sockets then i will get the notifications from the clients ( little bit change or otherwise the knowledge is same )
Posted
Updated 14-Feb-21 4:34am
v2
Comments
Richard MacCutchan 14-Feb-21 11:00am    
That code has nothing to do with network architecture, but shows that you still have not taken any of the advice you have been offered.

As you can see in this rather old, but still valid CodeProject article: Introduction to TCP client server in C#[^]
you can use TcpClient() to send notifications to the server.
Instead of using a Main() method, use another method name e.g. SendNotification().
 
Share this answer
 
v2
We are more than willing to help those that are stuck: but that doesn't mean that we are here to do it all for you! We can't do all the work, you are either getting paid for this, or it's part of your grades and it wouldn't be at all fair for us to do it all for you.

So we need you to do the work, and we will help you when you get stuck. That doesn't mean we will give you a step by step solution you can hand in!
Start by explaining where you are at the moment, and what the next step in the process is. Then tell us what you have tried to get that next step working, and what happened when you did.
And what you have posted at the moment does none of what you want - so we can't see that you have tried to do anything for yourself, let alone where you might have gone wrong!

If you are having problems getting started at all, then this may help: How to Write Code to Solve a Problem, A Beginner's Guide[^]
 
Share this answer
 
Comments
Member 12712527 14-Feb-21 10:11am    
i will surely listen to you sir and do as much as my knowledge and intelligence could help me . but you have to promise me that you will not stop helping me
RickZeeland 14-Feb-21 10:22am    
That sounds like Client-Servant architecture to me :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900