Hi All,

I want to have two NSObjects (controllers) - one for the tableview and all the actions that it needs to perform, and one for the web view. I am having difficulty getting the tableview controller to tell the webview controller to display a particular page. And I can't find anything about this subject in my Cocoa books or on the web. Am I barking up the wrong tree here? Should I only have one controller per window?

I've read the replies but can't get any approach to work. I must be missing something simple.

For example, I have an instance method called "fileString" in my "MyDocument" class, that returns the path to that document. But how do I call it from my "MyController"? In MyController.m, when I say:

#import "MyDocument.h"
...
[MyDocument fileString];

I get a runtime error:

+[MyDocument fileString]: unrecognized selector sent to class.

The error makes sense because I am trying to call an instance method on a class. But how to I refer to the instance of MyDocument that sits in the same nib instance as the MyController that is calling it?

When you stop laughing, can you please lay it out for me.

I also tried to use bindings, which I've made work well for linking text views, table columns, even outline view columns, to data in my model. But I can't seem to set up bindings to link an instance variable in one controller to another controller. So I guess bindings are only for linking view objects to model objects, yes?

Thanks,
Tom
BareFeet


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to