Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!tut.cis.ohio-state.edu!ucbvax!decwrl!shelby!polya!ali From: ali@polya.Stanford.EDU (Ali T. Ozer) Newsgroups: comp.sys.next Subject: Re: novice questions about IB Message-ID: <10400@polya.Stanford.EDU> Date: 4 Jul 89 17:06:52 GMT References: <53602@tut.cis.ohio-state.edu> Sender: Ali T. Ozer Reply-To: aozer@NeXT.com (Ali Ozer) Organization: . Lines: 34 In article <53602@tut.cis.ohio-state.edu> Nasir K Amra writes: > ... I get an warning message with the following method: > >- displayresultpanel: sender >{ [ resultpanel display]; > return self; >} > >where the warning message states that ' can not find method' ( I assume >display) and another warning message : 'return type for display defaults to >id' You should "#import" the interface for any class referenced/used in a file. In the above example you say the "resultpanel" instance variable is a object of class Panel; in that case, you should have a #import at the top of the above .m file. This will assure that all Panel methods are known to the compiler, and if you get any warnings, you are indeed calling a method that doesn't exist. The method that makes panels and windows to come on-screen is orderFront:, not display. The display method causes a redraw of the whole panel, including the border view and the content view, and all subviews. orderFront: simply brings the panel on screen. Because orderFront: is a target-action method, you can usually connect a button or menu item to a panel or window without having to create a glue method; in the above case you wouldn't need the displayresultpanel: method, for instance. Ali Ozer, NeXT Developer Support aozer@NeXT.com