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

  • SEARCH
  • Home
  • 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 3277332
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T19:21:24+00:00 2026-05-17T19:21:24+00:00

I am creating an extension of ItemizedOverlay. When a user taps a pin on

  • 0

I am creating an extension of ItemizedOverlay. When a user taps a pin on the map (onTap) I want to display a RelativeLayout, which is included in the same .xml file as the map. When the RelativeLayout is visable, it covers the map.

Since this view is the context for the main class, I do not know how to access the view (DetailLayout) from within the onTap() call.

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 
xmlns:android="http://schemas.android.com/apk/res/android"    
android:id="@+id/mainlayout"    
android:orientation="vertical"    
android:layout_width="fill_parent"    
android:layout_height="fill_parent" >

    <com.google.android.maps.MapView
        android:id="@+id/mapview"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:clickable="true"
        android:apiKey="MY KEY HERE"
    />    



    <RelativeLayout 
        android:id="@+id/DetailLayout" 
        android:layout_width="fill_parent" 
        android:layout_height="fill_parent"  
        android:gravity="left"
        xmlns:android="http://schemas.android.com/apk/res/android">
            <LinearLayout
                android:id="@+id/DetailCloseButtonLayout"
                android:layout_width="fill_parent" 
                android:layout_height="36dp" 
                android:gravity="center_vertical|right"
                xmlns:android="http://schemas.android.com/apk/res/android">
                <Button       
                    android:id="@+id/DetailCloseButton"     
                    android:background="@drawable/close"  
                    android:layout_width="15dp"        
                    android:layout_height="15dp"
                    android:layout_marginRight="10dp" 
                    android:gravity="center_vertical">
                </Button>
            </LinearLayout>
            <TextView 
                android:text="Detail Here. Detail Here." 
                android:id="@+id/DetailTextView" 
                android:layout_width="wrap_content" 
                android:layout_height="wrap_content"
                android:layout_below="@id/DetailCloseButtonLayout">
            </TextView>

    </RelativeLayout>       

  • 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-17T19:21:24+00:00Added an answer on May 17, 2026 at 7:21 pm

    If your ItemizedOverlay is an inner class of your MapActivity, just call findViewById(). Here is a sample project from one of my books showing the sort of thing you are trying to do.

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

Sidebar

Related Questions

I'm creating a Firefox extension, in which I want to iterate through the Application.windows
I am creating an extension for Chrome. I want to show an alert() with
I'm creating a chrome extension, and want to be able to get a profile
I am creating a firefox extension. I want to get the URL of the
I am creating a firefox extension that should give a notification when the user
I am working on creating a Google Chrome extension. We have it included in
I am creating a Chrome extension which will send the URL of every page
I am creating an extension for Visual Studio 2008, and because I didn't want
I was creating a chrome extension in which some icons are shown in a
I'm creating a Safari Extension. At one point, I want to open a new

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.