Hi Ulf,<div><br></div><div>it's solved. thank you!</div><div><br></div><div>Barco<br><br><div class="gmail_quote">On Wed, Dec 5, 2012 at 12:19 AM, Barco You <span dir="ltr"><<a href="mailto:barcojie@gmail.com" target="_blank">barcojie@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Thank you for replying. But I tried to use Pid ! Msg, but seemingly can not receive message as gproc:send(Key, Msg).  <div class="HOEnZb">
<div class="h5"><br><br><div class="gmail_quote">On Tue, Dec 4, 2012 at 9:31 PM, Ulf Wiger <span dir="ltr"><<a href="mailto:ulf@feuerlabs.com" target="_blank">ulf@feuerlabs.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div><br></div><div>The function gproc:send/2, when used on a non-unique key, in essence does this:</div>

<div><br></div><div><div>   lists:foreach(fun(Pid) -></div><div>                                        Pid ! Msg</div><div>                          end, gproc:lookup_pids(Key)),</div></div><div><br></div><div>So you can take that as a starting point, and add a clause that pattern-matches on the own pid, and then doesn't send a message in that case.</div>

<div><br></div><div>BR,</div><div>Ulf W</div><div><br></div><div><div><div>On 4 Dec 2012, at 13:21, Barco You wrote:</div><br></div><blockquote type="cite"><div><div><span>Dear All,</span></div><div>
<span><br></span></div>I use gproc:reg to register all the processes to a KEY and through<span></span> gproc:send(KEY, MSG) I can broadcast message to all the processes, including myself. But now I hope to send message to all the other processes except myself. How can I do it? Could you please illuminate ? Thank you.<div>


<span></span></div>
<br></div>
_______________________________________________<br>erlang-questions mailing list<br><a href="mailto:erlang-questions@erlang.org" target="_blank">erlang-questions@erlang.org</a><br><a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>

</blockquote></div><br><div>
<span style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;border-collapse:separate;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px"><div>

<div>Ulf Wiger, Co-founder & Developer Advocate, Feuerlabs Inc.</div><div><a href="http://feuerlabs.com" target="_blank">http://feuerlabs.com</a></div></div><div><br></div></span><br>
</div>
<br></div></blockquote></div><br>
</div></div></blockquote></div><br></div>