android-intent

How to click on a particular column in a list view android

拥有回忆 提交于 2019-12-23 04:45:44
问题 this is my code: adapter= new EditAdapter(getApplicationContext(),sectionTopic); setListAdapter(adapter); ListView li = this.getListView(); li.setOnItemClickListener(new OnItemClickListener() { @Override public void onItemClick(AdapterView<?> parent, View myView, int position, long arg3) { TableLayout view = (TableLayout) myView ; TextView name = (TextView) view.findViewById(R.id.name); itemName = name.getText().toString(); Intent intent= new Intent(EditActivity.this, SectionDetailsActivity

finding latitude and longitude of android mobile using its number

社会主义新天地 提交于 2019-12-23 04:45:32
问题 i am trying to develop an android app (named ContactListFinder) which follows the following steps access contact list through android.provider.ContactsContract package access phone number likewise calculate the location of the sender and receiver in terms of lattitude and longitude and then find the distance between sender and receiver pop a message if within coverage area otherwise no message is displayed Now here the problem is "finding location using mobile number in terms of longtitute

Android share intent vs actual Facebook integration

早过忘川 提交于 2019-12-23 04:43:31
问题 I am going to integrate "facebook sharing" into an app. Basically a timeline post with a link and an image and text. What is the difference between an elaborate Facebook 3.0 integration vs using the Android OS' share intent with certain parameters, where the latter allows users to choose between apps such as Facebook and it just works if the app is configured to use that intent. 回答1: See this Facebook bug report, I guess you have to do it with the Facebook SDK. Since they only allow posting a

Refresh button onClick Listview data must get update in android [duplicate]

时间秒杀一切 提交于 2019-12-23 04:29:29
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: How to refresh Android listview? I am looking for using Refresh button refreshing the listview data.. DES:In my app there is refresh button when i onclick on it Listview data which coming from server must get refresh & show update listview data. And I have no idea how to do that. plz suggest me with example.. Thanks in advance. below is my code. Mainactivity.java listView = (ListView) findViewById(R.id

how to save intent data passed from 1st activity to 2nd activity

ⅰ亾dé卋堺 提交于 2019-12-23 04:28:20
问题 I have Myactivity which is getting the intent data from the former activity. The intent data is sent through a spinner of the activity. I want to save this intent data of the spinner to the Myactvity. the intent data should persist when i enter the Myactivity through menu option of next activity. 回答1: in your First Activity1 Intent myintent= new Intent(FirstActivity.this,SecondActivity.class); myintent.putExtra("Name", "your String"); startActivity(myintent); in Second Activity2 Intent

How to select multiple images from gallery?

落爺英雄遲暮 提交于 2019-12-23 04:19:07
问题 I am trying to select multiple images from a file location. So far I have managed to select one image but how can I select two images together. Intent intent =new Intent(Intent.ACTION_PICK); intent.setType("image/*"); startActivityForResult(intent, STEP_4_REQUEST); Then in the onActivityResult(int requestCode, int resultCode, Intent data) method the following: case STEP_4_REQUEST: if (resultCode == RESULT_OK) { Uri selectedImage = data.getData(); String[] filePathColumn = { MediaStore.Images

how to make a imageview go in a curve

蹲街弑〆低调 提交于 2019-12-23 04:13:26
问题 i am new in android...i want to make a ferris wheel game and i need to move the ferris wheel chair in the wheel...i use: TranslateAnimation transAnimation1 = new TranslateAnimation(0, 145, 0, 275); transAnimation1.setDuration(6000); ChairA1.startAnimation(transAnimation1); TranslateAnimation transAnimation2 = new TranslateAnimation(0, 50, 0, 50); transAnimation2.setDuration(6000); ChairA2.startAnimation(transAnimation2); TranslateAnimation transAnimation3 = new TranslateAnimation(0, 50, 0, 50

Open Link from Browser in Android Webview

大城市里の小女人 提交于 2019-12-23 03:55:05
问题 I would like to open links in browsers with the host example.com or example.de in my Android application with webview. I created this intent: <intent-filter> <data android:scheme="https" android:host="example.com" /> <data android:scheme="https" android:host="example.de" /> <data android:scheme="http" android:host="example.com" /> <data android:scheme="http" android:host="example.de" /> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category

How to send multiple attachments using Intent

喜你入骨 提交于 2019-12-23 03:49:09
问题 I've found this code to send multiple attachments using Gmail Android App: public static void email(Context context, String emailTo, String emailCC, String subject, String emailText, List<String> filePaths) { //need to "send multiple" to get more than one attachment final Intent emailIntent = new Intent(android.content.Intent.ACTION_SEND_MULTIPLE); emailIntent.setType("text/plain"); emailIntent.putExtra(android.content.Intent.EXTRA_EMAIL, new String[]{emailTo}); emailIntent.putExtra(android

ACTION_LOCATION_SOURCE_SETTINGS : cannot be resolved or is not a field

不问归期 提交于 2019-12-23 03:45:15
问题 I'm calling ACTION_LOCATION_SOURCE_SETTINGS via Intent.its is showing cannot be resolved or is not a field caused while importing Project from outside. What should i do now ? Intent viewIntent = new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS); startActivity(viewIntent); 回答1: Try this.. I guess your import is wrong Use import android.provider.Settings; Or try like below. Intent viewIntent = new Intent(android.provider.Settings.ACTION_LOCATION_SOURCE_SETTINGS); startActivity(viewIntent);