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 8197239
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T05:42:03+00:00 2026-06-07T05:42:03+00:00

I am trying to have a pop up window display results in a table

  • 0

I am trying to have a pop up window display results in a table after selecting certain things. Below is my .xml of my popup window and the code I’m using to try to pull it up. The problem is that when it pops up, it is only displaying a black box, not the rest of the contents.

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/outerwindow"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingTop="80dp"
android:gravity="center"
android:background="#000000"
android:baselineAligned="true"
>

<TextView
    android:id="@+id/insert"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_gravity="center_horizontal"
    android:background="@drawable/rectangle"
    android:gravity="top"
    android:padding="7dp"
    android:text="@string/insert" />

<LinearLayout
    android:id="@+id/window"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:layout_gravity="center"
    android:baselineAligned="true"
    android:orientation="horizontal"
    android:layout_marginTop="30dp"
    android:weightSum="10" >

    <FrameLayout
        android:layout_width="0dp"
        android:layout_height="fill_parent"
        android:layout_marginLeft="20dp"
        android:layout_weight="2" >

        <LinearLayout
            android:id="@+id/material"
            android:layout_width="fill_parent"
            android:layout_height="fill_parent"
            android:baselineAligned="false"
            android:orientation="vertical"
            android:weightSum="6" >

            <ImageButton
                android:id="@+id/close"
                android:layout_width="wrap_content"
                android:layout_height="33dp"
                android:layout_gravity="center"
                android:contentDescription="@string/back_arraw"
                android:scaleType="centerCrop"
                android:src="@android:drawable/ic_menu_revert" />

            <TableRow
                android:id="@+id/pRow0"
                android:layout_width="fill_parent"
                android:layout_height="0dp"
                android:layout_weight="1"
                android:background="#3b7fcc"
                android:baselineAligned="true" >

                <TextView
                    android:id="@+id/p0"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:gravity="center"
                    android:text="@string/p"
                    android:textColor="#b0b0b0"
                    android:textSize="27dp" />
            </TableRow>

            <TableRow
                android:id="@+id/mRow0"
                android:layout_width="fill_parent"
                android:layout_height="0dp"
                android:layout_weight="1"
                android:background="#ffff57"
                android:baselineAligned="false" >

                <TextView
                    android:id="@+id/m0"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:gravity="center"
                    android:text="@string/m"
                    android:textColor="#b0b0b0"
                    android:textSize="27dp" />
            </TableRow>

            <TableRow
                android:id="@+id/kRow0"
                android:layout_width="fill_parent"
                android:layout_height="0dp"
                android:layout_weight="1"
                android:background="#cc3333"
                android:baselineAligned="false" >

                <TextView
                    android:id="@+id/k0"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:gravity="center"
                    android:text="@string/k"
                    android:textColor="#b0b0b0"
                    android:textSize="27dp" />
            </TableRow>

            <TableRow
                android:id="@+id/nRow0"
                android:layout_width="fill_parent"
                android:layout_height="0dp"
                android:layout_weight="1"
                android:background="#356638"
                android:baselineAligned="false" >

                <TextView
                    android:id="@+id/n0"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:gravity="center"
                    android:text="@string/n"
                    android:textColor="#b0b0b0"
                    android:textSize="27dp" />
            </TableRow>

            <TableRow
                android:id="@+id/sRow0"
                android:layout_width="fill_parent"
                android:layout_height="0dp"
                android:layout_weight="1"
                android:background="#ff8936"
                android:baselineAligned="false" >

                <TextView
                    android:id="@+id/s0"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:gravity="center"
                    android:text="@string/s"
                    android:textColor="#b0b0b0"
                    android:textSize="27dp" />
            </TableRow>

            <TableRow
                android:id="@+id/hRow0"
                android:layout_width="fill_parent"
                android:layout_height="0dp"
                android:layout_weight="1"
                android:background="#898989"
                android:baselineAligned="false" >

                <TextView
                    android:id="@+id/h0"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:gravity="center"
                    android:text="@string/h"
                    android:textColor="#b0b0b0"
                    android:textSize="27dp" />
            </TableRow>
        </LinearLayout>
    </FrameLayout>

    <TabHost
        android:id="@+id/tabhost"
        android:layout_width="0dp"
        android:layout_height="fill_parent"
        android:layout_marginRight="20dp"
        android:layout_weight="8">

        <LinearLayout
            android:id="@+id/linearLayout1"
            android:layout_width="fill_parent"
            android:layout_height="fill_parent"
            android:baselineAligned="false"
            android:orientation="vertical" >

            <TabWidget
                android:id="@android:id/tabs"
                android:layout_width="fill_parent"
                android:layout_height="33dp"
                android:layout_gravity="top" />

            <FrameLayout
                android:id="@android:id/tabcontent"
                android:layout_width="fill_parent"
                android:layout_height="fill_parent" >

                <LinearLayout
                    android:id="@+id/tab3"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:baselineAligned="false"
                    android:orientation="vertical"
                    android:weightSum="6" >

                    <TableRow
                        android:id="@+id/pRow3"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#3b7fcc"
                        android:baselineAligned="true" >

                        <TextView
                            android:id="@+id/p3"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/mRow3"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#ffff57"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/m3"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/kRow3"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#cc3333"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/k3"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/nRow3"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#356638"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/n3"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/sRow3"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#ff8936"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/s3"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/hRow3"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#898989"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/h3"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>
                </LinearLayout>

                <LinearLayout
                    android:id="@+id/tab2"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:baselineAligned="false"
                    android:orientation="vertical"
                    android:weightSum="6" >

                    <TableRow
                        android:id="@+id/pRow2"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#3b7fcc"
                        android:baselineAligned="true" >

                        <TextView
                            android:id="@+id/p2"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/space"
                        android:layout_width="fill_parent"
                        android:layout_height="1dp"
                        android:baselineAligned="true" />

                    <TableRow
                        android:id="@+id/mRow2"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#ffff57"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/m2"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/kRow2"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#cc3333"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/k2"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/nRow2"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#356638"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/n2"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/sRow2"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#ff8936"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/s2"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/hRow2"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#898989"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/h2"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>
                </LinearLayout>

                <LinearLayout
                    android:id="@+id/tab1"
                    android:layout_width="fill_parent"
                    android:layout_height="fill_parent"
                    android:baselineAligned="false"
                    android:orientation="vertical"
                    android:weightSum="6" >

                    <TableRow
                        android:id="@+id/pRow1"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#3b7fcc"
                        android:baselineAligned="true" >

                        <TextView
                            android:id="@+id/p1"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/mRow1"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#ffff57"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/m1"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/kRow1"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#cc3333"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/k1"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/nRow1"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#356638"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/n1"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/sRow1"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#ff8936"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/s1"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>

                    <TableRow
                        android:id="@+id/hRow1"
                        android:layout_width="fill_parent"
                        android:layout_height="0dp"
                        android:layout_weight="1"
                        android:background="#898989"
                        android:baselineAligned="false" >

                        <TextView
                            android:id="@+id/h1"
                            android:layout_width="fill_parent"
                            android:layout_height="fill_parent"
                            android:gravity="center"
                            android:text=""
                            android:textColor="#000000"
                            android:textSize="17dp" />
                    </TableRow>
                </LinearLayout>
            </FrameLayout>
        </LinearLayout>
    </TabHost>
</LinearLayout>
</LinearLayout>

code in my main:

inflater = (LayoutInflater) this.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
    popView = inflater.inflate(R.layout.popup, (ViewGroup) findViewById(R.id.outerwindow));
    popup = new PopupWindow(popView,100,100, true);
    popup.setBackgroundDrawable(new BitmapDrawable());

later I use this command to bring it up

popup.showAtLocation(findViewById(R.id.primary), Gravity.CENTER, 0, 0);

Obviously my main screen’s ID is called primary, and when the the pop up comes up, its just a black square in the center of the screen (because I used black to see it actually pop up) and clicking outside of it makes it go away. This is becoming a very annoying problem, any help would be appreciated.

  • 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-06-07T05:42:03+00:00Added an answer on June 7, 2026 at 5:42 am

    Yeah… So as you can see above my window was only 100×100… That’s why the content was blank… I was only showing the first 100×100 lol. Sorry all for being dumb. Took me a good few hours to realize this.

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

Sidebar

Related Questions

I've been trying to use 'import poplib' to access gmail, since I have Pop
Trying to have my PHP script return some SQL table queries. Here's my script
I am trying to have a table like this: Manager Expert Adminis. Staff Dept
So I'm trying to have a window that I can drag around by the
I'm trying to implement a basic popup window that asks the user if they
So I'm trying to open a pop up window in IE8. So far no
I'm trying to get rid of the error pop-up window that appears in IE
I'm trying to pop a window up, from inside a procedure running in SharePoint.
Trying to figure out how to make a modal pop up on browser window
I'm trying to get my application to display a popup context menu when a

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.