How To Create Pop Up Window In Android

Filip Vujovic · 287K views · 2015 · 6:54

Open on YouTube

Software (other)UX & UI designtutorialdated

Why Stack Overflow recommends it

Stack Overflow users link it as the tutorial they followed to build a popup window in Android, then come back with questions about errors, styling and behaviour that arose from it.

Recommended by 0 people across 0 different months, 2016 to 2021.

What it is

A short 2015 Android tutorial by Filip Vujovic showing how to create a pop up window in an Android app. It walks through building a floating popup, including the theme and layout setup needed to make an activity appear as a window.

What people said

Cites Kevin Murvie · 2016-01 · Stack Overflow · on “Android - Popup window creation and styling”

I'm trying to create a popup window which has several RelativeLayout , several TextView and a single Button . Here's the popup window : <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android=" [LINK] " android:id="@+id/popup_handphone_MainLayout" android:layout_width="match_parent" android:layout_height="match_parent"> <RelativeLayout android:id="@+id/popup_handphone_Wrapper" android:layout_width="wrap_content" android:layout_height="wrap_content"> <TextView android:id="@+id/popup_handphone_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/popupPhoneMessage"/> <RelativeLayout android:id="@+id/popup_handphone_functionalities" an

Cites Marios Ath · 2016-04 · Stack Overflow · on “How to change text from java code?”

Excuse me if this is an easy problem. I have been unable to find an answer so far.I have followed this tutorial( [this video] ) to create a pop up window. While it works as intended I want to change the text when the button is pressed from the java code. To be more specific, I have a string array and whenever the button is pressed I want it to show a random element of the array. How can I go about doing those things? My onCreate method is(mundaneLoot is the id of the button): protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); Button b = (Button)findViewById(R.id.mundaneLoot); b.setOnClickListener(new View.OnClickListene

Cites the_dani · 2017-02 · Stack Overflow · on “ListView in a pop up window”

I typed "PopupWindow" into google and found this: [this video] I didn't knew the PopupWindow until now and I'd recommend to use a dialog e.g. AlertDialog with a costum view. I hope I could help!

Cites Sujay U N · 2017-08 · Stack Overflow · on “Android No resource matches android:windowIsFloating”

I am trying to make my activity as popup / floating activity after watching this video [this video] But I want to make window background Semi Translucent. So I added windowIsFloating -> true <style name="AppTheme.NamTheme"> <item name="android:windowIsFloating">true</item> <item name="android:windowCloseOnTouchOutside">true</item> </style> But getting following error Error:(2374, 21) No resource found that matches the given name: attr 'android:windowIsFloating'.

Cites Sujay U N · 2017-08 · Stack Overflow · on “Android Theme Style Programmatically”

After watching this video I got a good idea for designing my own Popup Boxes [this video] The pain is I need to add Theme Style in XML, Set this as theme in manifest Then add in Java Activity So I was searching if there is way to modify Themes programmatically instead of putting in XML. So I can copy single Java file to all my projects instead of adding in 3 places. <style name="AppTheme.MsgBoxSreen" parent="android:Theme.Light.NoTitleBar" > <item name="android:windowIsFloating">true</item> <item name="android:windowCloseOnTouchOutside">true</item> </style> There is only setTheme(R.style. MsgBoxSreen) option and nothing else Kindly help me to do this programmatically. I am sure there must be a wa

Cites user14224509 · 2020-09 · Stack Overflow · on “Cannot find symbol: method findViewByID(int)”

Been trying to figure out the problem for the last two hours. The solutions I have seen and tried are as follows: Invalidate caches/restart getView().findViewByID(R.id.button) or rootView.findViewById(R.id.button) Casing Button popUp = (Button) findViewByID(R.id.button); This is the video that I was following to create this. [this video] Any help would be greatly appreciated, thank you.

Cites Cooper Wainczak · 2021-05 · Stack Overflow · on “Trying to Make Pop-Up Window/Overlay in Android Studio (Java)”

I am trying to create a pop-up window/overlay in Android Studio with 2 activities. When a certain button (the green plus button in the first picture below) is pressed, it will start a second activity at a smaller size with a different layout (.xml) file. When the second activity is declared in the AndroidManifest.xml, it uses a custom theme I have created to make the first activity appear under it, however, it is not working properly. Here are pictures of both activites: First Activity - [LINK] Second Activity - [LINK] Here is the code: MainActivity - public class MainActivity extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInsta

Cites AmirHossein · 2021-10 · Stack Overflow · on “Popup window in fragment in kotlin”

because those codes didn't work I was really angry so I deleted all of them and then push that project to git lab but if u want i can share the link of project and this is one of the souses that I have tried but still didn't worked [this video]