I'm trying to avoid "Add service reference" in my SL app because I want to use the EntityFrameWorks new self tracking entities. So I'm trying out ChannelFactory to create a channel and call my interface methods asyncronously from that.
It works, however I'm concerned about correctly closing/disposing ChannelFactory & the Channel. Is there an example anywhere of how this should be done when used asyncrosously in SL?
Does the ChannelFactory need to remain until you are finished w/ the channel it created? I think so because I got an error when I tried to dispose it before I used the channel.
Should I create the ChannelFactory & Channel as members of my UserControl and then somehow dispose of them when the UserControl is destoryed? I'm not sure how this would be done though.
I'd love to see an example.
If anyone can provide an example or point me to one I'd really appreciate it.
Thanks!