Showing posts with label Eclipse IDE. Show all posts
Showing posts with label Eclipse IDE. Show all posts

Wednesday, April 8, 2015

Eclipse - Add HTML Editor Plugin

How to add an HTML Editor for Eclipse

I started using Eclipse to work with PhoneGap(Cordova). However, editing HTML files in Eclipse was not nice - it felt similar to using Windows notepad.  I found the following information on stackoverflow about adding a HTML editor: http://stackoverflow.com/questions/54868/what-is-the-best-html-editor-for-eclipse 
This post details the instructions for adding Web Page Editor to your installation of Eclipse (if it wasn't installed with your version initially). It is really simple, but I've detailed it out anyway.

I'm using Eclipse Juno (SDK Version 4.2.0). It's probably a similar process in other versions. 

1. Go to Help --> Install New Software...

 2. Select the Juno repository (http://download.eclipse.org/releases/juno/) from the 'Work with:' menu:

3. In the search box, enter 'web' to filter the results, and select 'Web Page Editor':
4. Click Next:
5. Accept the terms and click Finish:
6. Wait for the install to run:
7. You might see this - just click OK:
8. Click Yes when ready:



Now that you have finished installing this, and restarted, you might notice that none of the text in your existing html files has changed colour in the editor as you might expect. I wasn't sure how to adjust this, so thanks to balla85 for figuring this out for me. All you need to do is go to the Window --> Preferences menu as shown:


Then for both *.htm and *.html, click on the 'HTML Editor' in the window below and click the 'Default' and 'OK' to apply. The result should be similar to below:


Anyway that was pretty easy wasn't it? Now get working!

Source: http://lizusefulstuff.blogspot.in/2012/07/how-to-add-html-editor-for-eclipse.html

Android - How to browse Android Emulator SQLite Database


In this tutorial, we will show you how to browse android emulator SQLite database.
You need these tools! Trust me, if you not able to browse data that you have saved you will spend a lot of time and killing your brain cell to debug line by line. That is a nightmare :).

How to browse Android Emulator SQLite Database

There are 2 ways to browse SQLite database in Android Emulator
  • View from the eclipse with a plugin tool.
  • Pull data out from eclipse and view data with SQLite database Browser, (There are some other tools also can view the database like SQLiteSpy.)

  • View from the eclipse with a plugin tool
  1. Download com.questiod.sqlitemanager.jar and save into “X:\…\eclipse\dropins” folder, Eclipse update manager will install any jar in this directory, if you like to uninstall it just simply delete the jar file.
  2. Restart Eclipse.
  3. Navigate menu to Windows>Show View>Other>Questiod SQLite Manager
    Show View
  4. Find the DDMS icon, and click on it. The SQLite manager tools should be installed and it will look like below
    SQLitemanager
  5. So, Let’s try it!
  6. In this tutorial,
    We will use com.android.providers.email database that available in the emulator as testing target and it’s locate in data/data/com.android.providers.email/databases/EmailProvider.db. Click on the File Explorer. You should see something like this. Please take note you need a “db” extension file or else the tool will not enabled.
    File Explorer
  7. Click on the Open File in SQLite Manager… icon
  8. You will see the image like below for viewing all tables and data.
    Browse android emulator database
  9. Click on the Browse Data tabs, and choose a table named android_metadata, you will see data in this table.

  • Pull data out from eclipse and view it with SQLite database Browser.
  1. Click on DDMS icon. Icon in the highlight circle is for import file from and to emulator, the left icon is export and right icon is for export. Click on the left icon to save it to the desktop.
    Pull data
  2. In case you can’t see DDMS as showed in image. You can bring it out by going to Window > Open Perspective > DDMS
  3. Use SQLite Browser, Click Open Existing Database file and then select EmailProvider.db from where you save in step 1.
  4. And you will see image like below. This tool allow you to insert, update data and write query in Execute SQL tab.
    Pull data

Tips:
1. When you create your database, please make sure create with “db” extension. i.e. instinctcoder.db.
2. Personally i preffered the 2nd method as it allow you to insert, update data and select data.
3. During development, sometimes you need to run in debug mode(F11) in order to get latest data.

Source:  http://instinctcoder.com/how-to-browse-android-emulator-sqlite-database/

Saturday, April 4, 2015

Android - Browse an Android Emulator SQLite Database in Eclipse

UPDATE - It appears the Questoid SQLite Browser is no longer available from the maker's website, sorry! Perhaps this link will be of use: http://www.java2s.com/Code/Jar/c/Downloadcomquestoidsqlitebrowser120jar.htm
After a fresh format in Ubuntu I needed to browse an Android emulator's SQLite database inside Eclipse. After a bit of research, I recalled this is how it can be done with DDMS and a cool plugin for Eclipse called Questoid SQLite Browser.

  1. Download the Questoid Plugin
  2. Place the plugin .jar file in your Eclipse plugins folder (e.g. /usr/lib/eclipse/plugins)
  3. Restart Eclipse
  4. Start up an Android Emulator w/ Debugging in Eclipse
  5. Switch to the DDMS Perspective in Eclipse
  6. Go to the 'File Explorer' tab to locate your device's database file
  7. Navigate to: e.g. 'data -> data -> com.myproject -> databases -> myproject
  8. Open the database file in Questoid (see screen shot)
  9. Switch to the 'Questoid SQLite Browser' tab that appears (mine appears next to LogCat by default)
  10. Switch to the 'Browse Data' sub tab
  11. Select your table from the drop down menu
  12. Browse your data here and onward into the digital sunset
Source: http://tylerfrankenstein.com/browse-android-emulator-sqlite-database-eclipse

Wednesday, November 5, 2014

eclipse recognise Lenovo adb devices

Eclipse cannot detect Lenovo devices

1. Connect Lenovo device to PC as Built-in CD ROM (Connect to USB Storage).
-- Scroll from Connecting USB/Built-in ...

2. Install LenovoUsbDriver_1.0.1.exe 
3. Disconnect your device and Install LenovoUsbDriver_1.0.1.exe and then restart PC.
4. Connect again your device to your PC as a USB Storage again instead of MTP/PTP.
5. In Eclipse, on the menu bar,click Run->Run Configurations. Click target tab and choose 'Always Prompt to Pick Device'.
6. Apply and Run. Now, you can see your device is listed in the 'Choose a running Android device'.
7. done.

Thursday, April 18, 2013

Thursday, April 4, 2013

Eclipse IDE

Display line numbers in Eclipse

In Eclipse IDE, select “Windows” > “Preference” > “General” > “Editors” > “Text Editors” , check on the “Show line numbers” option.
line numbers in Eclipse
See result.
line number in eclipse editor

Ref: http://www.mkyong.com/eclipse/how-to-display-line-numbers-in-eclipse/