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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T01:25:47+00:00 2026-06-17T01:25:47+00:00

I made an application in which a user can fill in some information in

  • 0

I made an application in which a user can fill in some information in some fields. This works. But when I want to change the lay-out, I have a problem.
I want to have the fields that the user should fill in, in a colored block (background3). So, I put the code in my XML-file in a linear lay-out, but when I do this, all the fields that the user should fill in dissappear. Does anyone know what I did wrong or how I can correct this?

This is the code of my XML-file:

  <?xml version="1.0" encoding="UTF-8"?>
  <LinearLayout 
     xmlns:android="http://schemas.android.com/apk/res/android" 
     android:id="@+id/LinearLayout01" 
     android:layout_width="wrap_content" 
     android:layout_height="wrap_content" 
     android:background="@drawable/background"
     android:orientation="vertical"
     android:padding="30dip">



        <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
            android:layout_width="fill_parent"
            android:layout_weight="1"
            android:layout_height="0dp"
            android:orientation="vertical"
           >
                     <include layout="@layout/header"/>
         </LinearLayout>

         <LinearLayout
              xmlns:android="http://schemas.android.com/apk/res/android"
             android:layout_width="fill_parent"
             android:layout_height="0dp"
             android:layout_weight="6"
             android:background="@color/background3"
             android:orientation="vertical" >   
            <TextView 
                android:id="@+id/button1_label" 
                android:layout_height="fill_parent" 
                android:layout_width="wrap_content" 
                android:text="Voer hieronder je rooster in:" 
                android:textSize="24.5sp" 
                android:layout_gravity="center" 
                android:layout_marginBottom="25dip" />

            <TextView 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" 
                android:text="Dag:" 
                android:layout_gravity="center" 
                android:textSize="14.5sp" />

           <Spinner
                android:id="@+id/dag_spinner"
                android:layout_width="fill_parent"
                android:layout_height="wrap_content" />

            <TextView 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" 
                android:text="Uur:" 
                android:layout_gravity="center" 
                android:textSize="14.5sp" />

            <EditText 
                android:id="@+id/uur" 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" />

            <TextView 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" 
                android:text="Vak:" 
                android:layout_gravity="center" 
                android:textSize="14.5sp" />

            <EditText 
                android:id="@+id/vak" 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" />

            <TextView 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" 
                android:text="Docent:" 
                android:layout_gravity="center" 
                android:textSize="14.5sp" />

            <EditText 
                android:id="@+id/docent" 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" />


            <TextView 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" 
                android:text="Lokaal:" 
                android:layout_gravity="center" 
                android:textSize="14.5sp" />

            <EditText 
                android:id="@+id/lokaal" 
                android:layout_width="fill_parent" 
                android:layout_height="wrap_content" />

            <LinearLayout 
                android:id="@+id/LinearLayout02" 
                android:orientation="horizontal" 
                android:layout_width="wrap_content" 
                android:layout_height="wrap_content" 
                android:paddingLeft="20sp">

                    <Button 
                        android:text="Gegevens opslaan" 
                        android:id="@+id/Button01add" 
                        android:layout_width="wrap_content" 
                        android:layout_height="wrap_content" 
                        android:layout_marginTop="20sp" 
                        android:layout_marginLeft="20sp">  
                    </Button>

                    <Button 
                        android:text="Terug" 
                        android:id="@+id/Button01home" 
                        android:layout_width="wrap_content" 
                        android:layout_height="wrap_content" 
                        android:layout_marginTop="20sp" 
                        android:layout_marginLeft="20sp">      
                    </Button>

            </LinearLayout>
        </LinearLayout>
   </LinearLayout>
  • 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-17T01:25:49+00:00Added an answer on June 17, 2026 at 1:25 am

    Your layout’s height is 0dp, use wrap_content instead. So change to this:

    <LinearLayout
             android:layout_width="fill_parent"
             android:layout_height="wrap_content"
             android:layout_weight="6"
             android:background="@color/background3"
             android:orientation="vertical" >   
    

    And you don’t have to declare the android namespace in every layout (the xmlns:android="http://schemas.android.com/apk/res/android" line)

    And in your

    <TextView 
                android:id="@+id/button1_label" 
                android:layout_height="fill_parent" 
                android:layout_width="wrap_content" 
                android:text="Voer hieronder je rooster in:" 
                android:textSize="24.5sp" 
                android:layout_gravity="center" 
                android:layout_marginBottom="25dip" />
    

    there is a 25dp bottom margin, try to reduce that.

    EDIT:
    AND your layout_height is set to fill_parent, set it to wrap_content

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

Sidebar

Related Questions

I've made an application which supports game center. A user can play a certain
We have this PHP application which selects a row from the database, works on
I have made an application which allows a user to login using their facebook
I have about 20 text fields on a form that a user can fill
I made a secondary form named Form2 for my application in which the user
I made an Android Application which requires some data to be save. So to
I have made a simple script application which accepts radius as input from user
I have my little client application which - when started - creates some user
I have an application in which the user can select from local video files.
I have this web application which I have made with MVC pattern, however I

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.