Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3871516
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T21:49:53+00:00 2026-05-19T21:49:53+00:00

I am currently building a RCP application based on Eclipse. In one of my

  • 0

I am currently building a RCP application based on Eclipse.
In one of my plugins I am adding two views via code:

    layout.addView("dev.asd.tableviewer.tree", IPageLayout.LEFT, 0.25f, IPageLayout.ID_EDITOR_AREA);
    layout.addView("dev.asd.tableviewer.view", IPageLayout.RIGHT, 0.75f, IPageLayout.ID_EDITOR_AREA);

The first view contains a treeviewer, the second one a tableviewer. Now I want to update the tableviewer’s content according to the selection of the treeviewer. My question is, how can I reference the tableviewer from within the treeviewer? Or is there an other way to solve this problem?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T21:49:53+00:00Added an answer on May 19, 2026 at 9:49 pm

    In each view, define an ID. The ID is the same as what you defined in the ID field when you defined the view in the extension element details. Here’s one of mine:

    public static final String ID = "gov.bop.rabid.ui.views.PrefetchedInmatesView";
    

    In your RCP plug-in, define the following method:

    public static IViewPart getView(IWorkbenchWindow window, String viewId) {
        IViewReference[] refs = window.getActivePage().getViewReferences();
        for (IViewReference viewReference : refs) {
            if (viewReference.getId().equals(viewId)) {
                return viewReference.getView(true);
            }
        }
        return null;
    }
    

    When you want to reference a view from a different view, use the following code:

    PrefetchedInmatesView view = (PrefetchedInmatesView) 
                    RabidPlugin.getView(window,  PrefetchedInmatesView.ID);
    

    Substitute the name of your view for PrefetchedInmatesView, and the name of your plug-in for RabidPlugin.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently building an internal web application used in a factory/warehouse type location.
We're currently building an application that executes a number of external tools. We often
I'm currently building a small web application that includes a fair amount of JavaScript.
I am currently building an application using ASP.NET MVC. The data entry pages are
I'm currently building a Java app that could end up being run on many
I am currently building in Version 3.5 of the .Net framework and I have
I am currently building an Excel 2007 Add-in using VSTO (latest version + sp1)
I am currently building a web site and I just implemented SqlCacheDependency using LinqToSQL
I am currently building a small website where the content of the main div
I'm currently building a project and I would like to make use of some

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.