Thread View: comp.sys.next.programmer
1 messages
1 total messages
Started by Vern Stant
Tue, 01 Sep 1992 23:43
Speaker/Listener Help (Please!)
Author: Vern Stant
Date: Tue, 01 Sep 1992 23:43
Date: Tue, 01 Sep 1992 23:43
42 lines
1954 bytes
1954 bytes
I am (desperately) trying to get 2 apps to communicate by speaker/listener.
Presently, I have both the speaker and listener in 1 app. Neither the speaker
nor listener is set to being the App's. kText is an otherwise functional text
object. They are inited like this:
myListener = [[Listener alloc] init];
[myListener setDelegate: kText];
[myListener checkInAs:"vern_w_in"];
[myListener setPriority:NX_MODALRESPTHRESHOLD];
[myListener addPort];
mySpeaker = [[Speaker alloc] init];
thePort = NXPortFromName("vern_w_in", NULL);
if (thePort != PORT_NULL)
[mySpeaker setSendPort:thePort];
else printf("\n The sucker was NULL \n");
thePort is not null unless I change the "vern_w_in" text to not match. If the
two text strings don't match the "...was NULL" does print. I try to put text
into kText:
msgDelivered = [mySpeaker performRemoteMethod:"setText"
with: "Hello There"
length:11];
printf("\nmsgDelivered = %d\n",msgDelivered);
msgDelivered is always 0 (unless The sucker was NULL above) no matter
what I send mySpeaker. I've tried "setText:","@selector(setText:)" etc.
No errors on the console, but no text either!! Any help would be appreciated!!!
befuddled in Richmond
Vern
--
Vern Stant | The opinions expressed herein are
Hand Held Products, Inc.| not necessarily those of Hand
804.784.3090 voice | Held Products, Inc., and may not
804.784.3147 FAX | even be mine. Use at your own risk
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads