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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T15:12:54+00:00 2026-06-15T15:12:54+00:00

I will show a popup screen for getting some description from the user. I

  • 0

I will show a popup screen for getting some description from the user. I can add almost every control (textview, button, checkbox, etc) without any problem except EditText. It gives me an error as below.

Caused by: android.view.InflateException: Binary XML file line #12: Error inflating class <unknown> 

CODE SIDE

    public RouteAdapter(Activity a, RouteResultDto list, boolean editMode, BaseFollower userInfo, boolean isFavoriteStatus) {
    this.activity = a;
    this.routeList=list;
    this.editMode = editMode;
    this.userInfo = userInfo;
    this.isFavorite = isFavoriteStatus;
    inflater = (LayoutInflater)activity.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
    imageLoader=new ImageLoader(activity.getApplicationContext());

//throws the exception at line below
    lnPopupMain = (LinearLayout) LayoutInflater.from(activity).inflate(R.layout.popup_route_edit, null);

    float width = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 200, activity.getResources().getDisplayMetrics());
    float height = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 250, activity.getResources().getDisplayMetrics());
    popupEditRoute = new PopupWindow(lnPopupMain, (int)width, (int)height, true);

    popupEditRoute.setBackgroundDrawable(new BitmapDrawable());
    popupEditRoute.setOutsideTouchable(true);
}

LAYOUT SIDE

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
              android:orientation="vertical"
              android:padding="10dip"
              android:layout_width="200dip"
              android:layout_height="160dip"
              android:background="@color/black"
              android:id="@+id/lnPopupMain"
              android:focusable="true"
        >

    <EditText android:layout_width="match_parent"
              android:layout_height="80dip"
              android:id="@+id/txtRouteEdit"
            android:background="@color/white">
    </EditText>
</LinearLayout>

(There is no any exception if I use TextView or Button instead of EditText. What is the problem with EditText?)

  • 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-15T15:12:55+00:00Added an answer on June 15, 2026 at 3:12 pm

    Resolved. I dont know why but you should create popup window in listener.

            imgEditOk.setOnClickListener(new View.OnClickListener() {
                @Override
                public void onClick(View view) {
                    lnPopupMain = (LinearLayout)inflater.inflate(R.layout.popup_route_edit, null);
                    float width = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 200, activity.getResources().getDisplayMetrics());
                    float height = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 250, activity.getResources().getDisplayMetrics());
                    popupEditRoute = new PopupWindow(lnPopupMain, (int)width, (int)height, true);
                    popupEditRoute.setBackgroundDrawable(new BitmapDrawable());
                    popupEditRoute.setOutsideTouchable(true);
                    popupEditRoute.showAtLocation(lnPopupMain, Gravity.CENTER, 10, 10);
                }
            });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

from this code will show in original color how can i change it to
My ProgressDialog will not show up. In my program the user selects bitrate from
I will show a UITextView with all messages from the NSLog in my debug
Occasionally a TextView with dynamic content will show a price. For example, as part
I have an app that will show some images using UIImageView, now I want
Have a gridview control which will show X amount of rows. I want to
i made a chrome extension, and my extension will show popup on webpage. I
In my application, on some screen, I launch a popup. Depends on what button
The HTML below will show a page with 2 buttons. One will open a
I need to generate report that will show number of new / changed rows

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.