try using following code(i have modified your code, not added any other stuff) :
<?xml version="1.0" encoding="utf-8"?> <framelayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:background="#0099cc" tools:context=".mainactivity" xmlns:app="http://schemas.android.com/apk/res/com.example.simple_calculator"> <textview android:id="@+id/textview1" android:layout_width="match_parent" android:layout_height="94dp" android:text="" android:textappearance="?android:attr/textappearancelarge" /> <gridlayout android:layout_width="wrap_content" android:layout_height="match_parent" android:layout_marginleft="232dp" android:layout_margintop="100dp" > </gridlayout> <gridlayout android:layout_width="232dp" android:layout_height="match_parent" android:layout_margintop="100dp" > <button android:id="@+id/button1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_column="0" android:layout_gravity="left" android:text="button" /> </gridlayout> </framelayout>
in this code grid layout and the app:column and gravity parts are modified and the exception reported was corrected and code works fine and also for the layout rules please check the following link:
hope this helps in resolving problem :)
- Exception raised during rendering: Circular dependencies cannot exist in RelativeLayout Exception details are logged in Window > Show View > Error Log
- Exception raised during rendering: com.android.layoutlib.bridge.MockView cannot be cast to android.view.ViewGroup
- Exception raised during XML rendering in Eclipse
- An exception raised during rendering
- Exception raised during rendering: invalid LOC header (bad signature) in android
- Exception raised during rendering: java.lang.System.arraycopy
- Eclipse - break on user code when unhandled exception is raised on Android App
- Proguard error during Android project export - System cannot find the specified file
- Testing Android app: Exception during suite construction
- An internal Exception occurred during push: cannot store objects
- Exception in thread pydevd.CommandThread (most likely raised during interpreter shutdown) - PyDev
- R cannot be resolved - Android error
- AVD Manager - Cannot Create Android Virtual Device
- Cannot create or edit Android Virtual Devices (AVD) from Eclipse, ADT 22.6
- Eclipse Indigo - Cannot install Android ADT Plugin
- Android Error in Eclipse: "Unable to execute dex: Cannot merge new index 65799 into a non-jumbo instruction!"
- Android Hello, Gallery tutorial -- "R.styleable cannot be resolved"
- android.os.Bundle cannot be resolved in libgdx Android project
- import android packages cannot be resolved
- Android CalendarView class cannot be found
- Eclipse Android SDK cannot see new Samsung Galaxy S4 device via a USB connection
- Android : Cannot complete the install because of a conflicting dependency
- "Selection cannot be launched and there are no recent launches” when Eclipse for Android Project Dev
- Cannot create a new Android Project using Eclipse
- how do i push to git repo given the following error: an internal exception occurred during push: ssh://firstname.lastname@example.org/yyy/yyy.git: session is down
- R cannot be resolved to a variable (new android project)
- cannot access memory at address 0X1 after setting up gdb and eclipse to debug shared library from Android Application
- Exception occurred during code generation for the WSDL : java.lang.NoClassDefFoundError: org/apache/ws/commons/schema/utils/NamespacePrefixList
- Android Eclipse - Cannot see annotation processing option
- Cannot create an emulator with Android L (API 20)
More Query from same tag
- How to jump out of brackets in IntelliJ IDEA
- Eclipse Kepler crashes immediately after its opened
- Eclipse for BlackBerry, set up the Eclipse envirorment
- Eclipse m2eclipse getting dependencies from local repository
- Wrapping sencha touch with Phonegap in eclipse for android
- App Name is Eclipse MainActivity?
- Change Maven local repository in Eclipse Workspace
- Why is a disabled SWT link not grayed out?
- Using Litetext in my project
- How to install PHP Xdebug in Eclipse on Windows?
- How to track/handle changes made by other users to source contorl shared emf resource
- Eclipse luna crashed (Eclipse IDE closed abrubtly) during Eclipse Marketplace loading
- How to take a good quality screenshot on emulator?
- Eclipse is hiding a package from me, why is that?
- Recommended Linux Distro for Android Development Workstation
- wicket Exception starting filter wicket
- I can not see the Server option in eclipse
- Eclipse Software Updates unable to satisfy dependency
- How to use correct version of JavaFX in Eclipse Plugin?
- How to make Eclipse "Open Type" window to show project classes first in list, third-party classes last?
- How to deploy created .jar file in Apache Tomcat server in Eclipse IDE?
- Palindrome detector returns true even when it's not a palindrome
- Android, viewing SQLite database in runtime (not like other questions)
- SWF built with ANT has different size from built on Eclipse
- Extracting a method in eclipse doesn't seem to work
- Debugging PHP files on browser with Eclipse and xDebug
- Create a new console for each thread in java
- Joss & Struts issue. Where should I put the breakpoint?
- Eclipse and SVN question. Please help!
- How to import JUnit 5 source to Eclipse?