顯示具有 adt 標籤的文章。 顯示所有文章
顯示具有 adt 標籤的文章。 顯示所有文章

2012年12月6日 星期四

Eclipse更新後出現錯誤(Incorrect line ending: found carriage return (\r) without corresponding newline (\n))

今天更新後,在xml出現這個錯誤
Incorrect line ending: found carriage return (\r) without corresponding newline (\n)
使用更新前的版本卻沒有出錯,後來找到了解決方法

 原本的寫法
 <LinearLayout    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:background="@drawable/gradient_white"
    android:orientation="vertical" >

後來改成
 <LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:background="@drawable/gradient_white"
    android:orientation="vertical" >

這樣子就解決了,推測更新的版本要求每個xml指令,必須換行才能正確執行

另一種方法更有效,Ctrl+Shift+F  按下後,儲存即可

2012年7月9日 星期一

eclipse執行時出現(string.out.xml,main.out.xml)

     
更新到4.1的sdk及eclipse之後跟以前的用法總有些差別,不知道是編譯時
太聰明了,還是有bug= =~(實在弄不清楚)
     不過很清楚的是新版的功能至少都要API11(也就是android3.0的平板才能用)
而更強的功能必須要API14(Android4.0)這也告訴我們,如果在後來的幾個月
之後,想要使用新的軟體,你可能手機要升級(或直接換新的了~)

咳~回到主題

要避免不要出現string.out.xml或是main.out.xml的方法,就是~
不要在xml的檔案上按run(也就是不要在res資料夾內按run)最好在src的activity
上面按run(就是有.java的地方按)
為什麼要做這麼多餘的事= =(我還不知道為何要這麼做,而以前不需要這麼做)

2012年7月8日 星期日

eclipse更新到4.1無法寫新專案?

好不容易更新到4.1,搞好久的新界面設定,結果寫不了新專案- -~
一直叫我下載、叫我check(用了幾次還是不行)
  這是個bug,一直叫我們更新version8,但下載version9@@

解決的方法:

找一下你的sdk-tools的位置
在你的sdk路徑下找\extras\android
在這個位址下有個資料夾compatibility
改成support就解決了……

2012年7月5日 星期四

Eclipse無法更新!


今天要用很久沒開的筆電寫一些範例程式,結果進入Eclipse時提示我要更新,
卻發現我無法更新這些ADT?原來google將更新網址改變了,所以提醒一下自
已這個新網址https://dl-ssl.google.com/android/eclipse/,免得突然又找不到了@@