0

I'm trying to insert data in a peer, but it doesn't work.

I leave below the code that I'm using:

PeerNameRegistration pnReg = new PeerNameRegistration();
pnReg.PeerName = peerName;
pnReg.Start();
pnReg.Port = 80;
pnReg.Comment = txtName.Text;
pnReg.Data = System.Text.Encoding.UTF8.GetBytes("Data");
pnReg.Stop(); (?)

When I check the peers, I can see 4 nodes, but none of them has data or comment.

mcarton
  • 27,633
  • 5
  • 85
  • 95
Alberto Vona
  • 55
  • 2
  • 9

1 Answers1

0

You have to specify proprties' values before calling the Start() method. If you want to change a property's value after the registration of peer, you can use Update() method.

thirdDeveloper
  • 855
  • 1
  • 10
  • 30