Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Re-Opening View Problem
Re-Opening View Problem [message #962624] Mon, 29 October 2012 07:52 Go to next message
Ted Mosby is currently offline Ted Mosby
Messages: 9
Registered: April 2012
Junior Member
Hi!

Following situation: in my RCP-Application, when i close a view programmatically (with "IWorkbenchPage.hideView(myView.ID") and re-open the view in a commandhandler, all the widgets in the view are marked as "disposed" at the first time and some exceptions will be thrown. Why are they marked as disposed? When the the view is closed they will be disposed, right? And when the view is re-opened, all the widgets will be created again, or did i miss something?
Is there a better way to close and open a view/views than using "IWorkbenchPage.hideView(myView.ID)" and "IWorkbenchPage.showView(myView.ID)" because a have absolut no idea.

Thanks in advance!
Re: Re-Opening View Problem [message #962695 is a reply to message #962624] Mon, 29 October 2012 08:58 Go to previous messageGo to next message
sumit singh is currently offline sumit singh
Messages: 131
Registered: October 2012
Location: Bangalore
Senior Member

I think these links should helps for you.
www.vogella.com/blog/2009/07/13/eclipse-activities/
www.stackoverflow.com/questions/1227059/how-to-close-a-viewpart-in-eclipse

[Updated on: Mon, 29 October 2012 09:00]

Report message to a moderator

Re: Re-Opening View Problem [message #962808 is a reply to message #962695] Mon, 29 October 2012 10:47 Go to previous message
Mario Marinato is currently offline Mario Marinato
Messages: 29
Registered: March 2011
Location: Brazil
Junior Member
There's a chance you are adding some listeners during the creation of the view and not removing them when it is closed.

If it's happening, listened-to objects might still be firing events to the previous view, leading to the widget-is-disposed errors.


Mário Marinato
From Brazil
Previous Topic:can we reuse the Parts in eclipse 4.2 for RCP.?
Next Topic:Adding a SortAction to my View
Goto Forum:
  


Current Time: Thu Oct 23 02:29:03 GMT 2014

Powered by FUDForum. Page generated in 0.01905 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software