Posts

android - Play Song continously -

i working on music application , have recorded audio files, can play song individually have button play on need play song present in particular folder can suggest best way achieve task thanks in advance hello guys got answer question finally please check below code: public class showallrecords extends listactivity { private file file; private list<string> mylist; mediaplayer mp; listview listv; int currentposition = 0; public void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); mp = new mediaplayer(); mylist = new arraylist<string>(); listv = getlistview(); listv.setbackgroundresource(r.drawable.musicapp); string root_sd = environment.getexternalstoragedirectory().tostring(); file = new file(root_sd + "/mymusicapp/"); file list[] = file.listfiles(); (int j = 0; j < list.length; j++) { mylist.add(list[j]....

xamarin - Can't setup Android SDK on Visual Studio 2015 -

Image
i installed vs2015 enterprise , want try "cross platform" or "android blank app" project, in both , got message box error value cannot null parameter name:path1 when try run tools/android /android sdk manager got visual studio error: error: command did not execute uccessfully due unexpected exeption.please check output window aditional information in error window got xamarin.android visual studio requires android sdk. please set android sdk path on tools->options->xamarin->android settings menu when open start/all programs/android sdk tools/sdk manager/tools/options after while got this: it looks can't download something, guess there no android sdk installed on pc. i've tried disabling firewall it's same, idea? your jdk , android ndk locations paths might set sdk might not set. had same problem. solved in 3 steps . if have same problem shown above image, follow these steps. click on change, ...

date - Find most recent result in query - ms access -

i have access database, trying determine recent result in query. want know whether recent loan item complete or not. e.g. tbl_loans loanid equipment number start date return date expr:isonloan 123 78457 16/05/2001 19/06/2003 loan complete 124 79557 17/07/2016 loan in progress 125 78457 03/06/2016 loan in progress 126 79630 01/01/2015 01/01/2016 loan complete 127 79360 02/03/2016 loan in progress 128 78457 01/01/2016 01/03/2016 loan complete where expr:isonloan iif: isonloan: iif([loans]![return date] null,"loan active","loan complete") i return recent result each equipment number in column in query (probably separate query) i.e. loan id equipment number start date return date expr:isonloan 125 78457 03/06/2016 loan in progress 127 79360 ...

javascript - setTimeout firing twice in this code? -

so have got code. var x = 0; function main() { console.log("window load occurred!"); console.log('imgchild log!'); var firstchildren = $('.imgchild'); var arrchildren = []; (var = 0, l = firstchildren.length; < l; += 3) { arrchildren.push(firstchildren.slice(i, + 3)); } console.log(firstchildren); console.log(arrchildren); arrchildren[0].fadein(); var length = arrchildren.length; function myanim() { // debugger; console.log('timeout log'); console.log(x); arrchildren[x].animate({ left: '-100%' }, function() { arrchildren[x].hide().animate({ left: '0%' }).css('top', '0'); x++; console.log(x); arrchildren[x].css({ top: '0px', left: '100%' }).show().animate({ left: '0%' }); settimeout(myanim, 3000); }...

sdl 2 - How to make a SDL2 Window uncloseable? -

i created sdl2 window. how can make, can't close pressing 'x'? flags, wich? just handle close event polling it, , can whenever tries close window program should nothing...that's it.

Find index of first specific result in each group from r -

i have dataset below: outcome have no relationship contact_date, when subscriber response cold call, mark successful contact attempt(1) else (0). count how many times called subscriber. subscriber_id outcome contact_date queue multiple_number count (int) (int) (date) (fctr) (int) (int) 1 1 1 2015-01-29 2 1 1 2 1 0 2015-02-21 2 1 2 3 1 0 2015-03-29 2 1 3 4 1 1 2015-04-30 2 1 4 5 2 0 2015-01-29 2 1 1 6 2 0 2015-02-21 2 1 2 7 2 0 2015-03-29 2 1 3 8 2 0 2015-04-30 2 1 4 9 2 1 2015-05-31 2 1 5 10 2 1 2015-08-25 5 1 6 11 ...

android - How to prevent the RecyclerView from resorting while notifyDataSetChanged -

i use staggeredgridlayoutmanager recyclerview layout manager. when try load next page data , call notifydatasetchanged method update data, while scroll recyclerview, notice resort item. i don't need resort it, how can prevent resorting. , wonder why resort. thx! @ershani gave valuable insight problem , adding more on top of it. use notifydatasetchanged() last resort when using recycler view. notifydatasetchanged() following , quoting doc this event not specify data set has changed, forcing observers assume existing items , structure may no longer valid. layoutmanagers forced rebind , relayout visible views. if writing adapter more efficient use more specific change events if can. rely on notifydatasetchanged() last resort. so in case if call notifydatasetchanged(), bound , visible layouts rebound pointless , ineffective. you use notifyitemrangeinserted() after loading page. more effective , retains default animations provided recyclerview on dat...