Posts

Showing posts from August, 2010

ionic framework - Vertical Scroll Parent on ionicScroll -

ionic framework - Vertical Scroll Parent on ionicScroll - this going bit hard explain sick best. i'm working on ionic project, have on home screen several horizontal scrolling divs, , whole view vertically scrollable. problem if drag screen, , start dragging items in horizontal list, cant vertically drag whole view, makes sense, cause horizontal list has ionic scroll direction set x. but want mimic effect on facebook timeline, there suggested apps ads, can horizontally scroll through them, if u dragged vertically u scroll whole timeline normal. ionic-framework

c# - How do dynamic and value types work? -

c# - How do dynamic and value types work? - there little piece of code can not understand: class programme { static void main(string[] args) { var ts = new teststruct() { = 2 }; object ots = ts; dynamic dts = ots; ts.a = 6; dts.a = 4; console.writeline(dts.gettype()); //type teststruct console.writeline("ts.a =" + ts.a); //6 console.writeline("unboxed ts.a =" + ((teststruct)ots).a); //4 console.writeline("dts.a =" + dts.a); //4 console.readkey(); } } public struct teststruct { public int a; } dts , ots refer same variable on heap, gettype returns dts teststruct . dts teststruct stored on heap? or not understand? tl;dr: dts , ots point same, boxed, re-create of ts . ts contains original teststruct separately. as may know, boxing , unboxing works this: a key difference same operations on class types boxing , unboxing copie

find - Jquery wildcard not select not working -

find - Jquery wildcard not select not working - i have form send off various orders, happens in th ebackground via ajax. 1 order can sent @ time when send button clicked want hide other send buttons still show one. the id of table cells "send(order_number)1". jquery code is $('#all_orders').find('[id^=send]').not('#send'+order_id+'1').replacewith(); where +order_id+ clicked order. currently hides of buttons. each order repeated in table within div id of all_orders. <td id="send<?=$order['id']?>1"> <input type='button' class='submit subtitle' value='send' onclick="export_leads(<?=$order['id']?>, '<?=$orders[$order['id']]['type']?>', '<?=$orders[$order['id']]['amount']?>', <?=$client_id?>)"> </td> function export_leads(order_id, type, amount, client_id){ $('#a

forEach array javascript incomplete -

forEach array javascript incomplete - updated i trying build array calling callback function , feeding values other arrays. however, few values , cannot understand why. the construction like: var sorteddata = []; arrayprovidingthevalues.foreach(pushel,sorteddata); and callback function is function pushel(element,index) { console.log("pushel called"); this[index] = element; } input: saisinearray = {obj1, obj2 obj3, obj4, obj5, obj6}; contratarray = {obj21, obj22 obj23, obj24, obj25, obj26}; intervalnb = 5; expected output sorteddata = {obj1, obj2 obj3, obj4, obj5, obj6,obj21, obj22 obj23, obj24, obj25,obj6,obj26}; ps: detailled code show in more detail. for (var k = 0; k < intervalnb; k++) { if (k * interval >= saisinearray.length) { } else if ((k + 1) * interval >= saisinearray.length) { saisinearray.slice(k * interval, saisinearray.length).foreach(pushel, sorteddata); } else { saisinearray.slic

indexing - why oracle CHOOSE INDEX RANGE SCAN over FAST FULL INDEX SCAN -

indexing - why oracle CHOOSE INDEX RANGE SCAN over FAST FULL INDEX SCAN - i have read documentation indexes, did examples , have doubts. i create table , insert random values, (a column has unique values) column not null create index on a, b, c. (b-tree) select count(*) demo_full_index_scan; =1000 select * demo_full_index_scan; b c d e f ---------- ---------- ---------- ---------- ---------- ---------- 1 7 109 1 1 1 2 12 83 2 2 2 3 21 120 3 3 3 4 13 74 4 4 4 5 2 1 5 5 5 ... documentation says when query values in index, values gathered index (index fast total scan), here optimizer choosing operation. explain plan select a,b,c demo_full_index_scan = 1;

How to replace servlet doPost method with PHP or Python or Perl? -

How to replace servlet doPost method with PHP or Python or Perl? - i uploading image file on server using javascript , servlet. servlet dopost method follows. protected void dopost(httpservletrequest request, httpservletresponse response) throws servletexception, ioexception { // todo auto-generated method stub system.out.println( " image sent server "); servletinputstream servletinputstream = request.getinputstream(); file capturefile = new file("./images/img1.jpg"); system.out.println(capturefile.getabsolutepath()); if(!capturefile.exists()) { capturefile.createnewfile(); } fileoutputstream fileoutputstream = new fileoutputstream(capturefile); int c; while((c = servletinputstream.read()) != -1) { fileoutputstream.write((char)c); //system.out.print((char)c); } fileoutputstream.close(); } in javascript creating header , body follows: header = 'post /file/upload http/1.1\

javascript - Changing style of input without display:none -

javascript - Changing style of input without display:none - a mutual way replace standard input display:none input, , add together background-image label. css: class="lang-css prettyprint-override"> input[type="checkbox"] { display: none; } input[type="checkbox"]+label { background: url('../images/checkbox_unchecked.png') left center no-repeat; background-size: 25px; } input[type="checkbox"]:checked+label { background: url('../images/checkbox_checked.png') left center no-repeat; background-size: 25px; } the problem: html broken afterwards. when want alter direction of elements, have alter within css ( background: right ). how can alter image/style of input field without create display:none first, , alter background image? has work in android 2.3. edit: jsfiddle. the simple prepare rtl issue (assuming main problem here, based on jsfiddle demo), style on dir attribute when set &quo

jquery - Rendering JavaScript templates -

jquery - Rendering JavaScript templates - i wish display popup when user hovers on particular link. to so, first request particular json info server via ajax. the server queries db, , escapes info happens user provided using htmlspecialchars() , , echos json_encode($data) . the client assembles html using below template. the client displays popup. my question relates rendering template. is there improve approach provide 1 or of next benefits? templates more readable. templates easier maintain. templates can extended. custom methods display phone numbers, etc need not created. site safer xss respective. htmlspecialchars escaping moved server client. other benefits have not thought of? thank you function gettemplate(type,json) { switch(type) { case 'person': homecoming '<dl><dt>name:</dt><dd>'+((d.firstname&&json.lastname)?json.firstname+' '+json.lastname:((json.firstname)?json

ios - Sending only one iBeacon Packet -

ios - Sending only one iBeacon Packet - is possible send 1 ibeacon packet? have tried using cbperipheralmanager ,but since there 2 method start , stop advertising, can't command how many packet beingness broadcast. what want seek utilize ibeacon packet command, instead of broadcasting id. send 1 ibeacon packet, , if receiver got message, can send acknowledgement ibeacon packet. intention avoid pairing of bluetooth send simple data. info linked uuid, major, , minor of packet. or there improve ways using ibeacon. yes, you can utilize ibeacon technology send info , forth between 2 ios devices without pairing. if have 2 devices, device , device b, set both of them range beacons mutual proximityuuid, say, e2c56db5-dffb-48d2-b060-d0f5a71096e0. , can exchange info in 2 byte major , minor fields. what can't do command transmitter plenty send single ibeacon advertisement. transmitter in ios sends out 10 advertisement packets per second, best start transm

mysql pivot table image list (vertical to horizontal data) -

mysql pivot table image list (vertical to horizontal data) - i have been searching hours limited mysql knowledge can't figure out answer. i want transform table: listingsdb_id listingsimages_file_name ----------- ------------ 93 name-a.jpg 93 name-b.jpg 94 name-c.jpg 95 name-d.jpg 95 name-e.jpg 95 name-f.jpg 95 name-g.jpg into this: listingsdb_id image1 image2 image3 image4, image5,image6... ----------- ------------ ------------ ------------ ------------ 93 name-a.jpg name-b.jpg 94 name-c.jpg 95 name-d.jpg name-e.jpg name-f.jpg name-g.jpg using mysql mysql table pivot

java - renameTo() not working -

java - renameTo() not working - i need rename file replacing - _ in file name. suppose if file name ab-9.xml , should ab_9.xml . renameto() not working me. there other way that? here code: file replacecheracter(file file) { file oldpath = new file(file.getpath()) string filepath = file.getpath() if(filepath.contains("-")){ string newfilepath = filepath.replace("-", "_") if(oldpath.renameto(newfilepath)) { system.out.println("renamed"); } else { system.out.println("error"); } } homecoming oldpath } you should consider using java.nio.file package: final path file = paths.get("path\\to\\your-file.txt"); files.move(file, file.resolvesibling(file.getfilename().tostring().replace("-", "_"))); used handy function path#resolvesibling() sec argument files#move(

google glass - Alternatives to Card.getText() in CardBuilder -

google glass - Alternatives to Card.getText() in CardBuilder - after latest update glass, code broken because of deprecation of card.gettext() method. painless alternative method? .tostring of no utilize because of object homecoming type. the getters deprecated because cardbuilder not designed used info model application; should used plug in info , views out. if need retain info can query later, should design own objects contain info (and might add together simple method/factory creates cardbuilder s objects). google-glass

windows phone 8.1 - Is there anyway to make TCP socket keep alive when switching to other App? -

windows phone 8.1 - Is there anyway to make TCP socket keep alive when switching to other App? - i'm trying create tcp socket maintain live in windows phone 8.1 using winrt. don't seem no way accomplished. read documents on msdn (this) controlchanneltrigger isn't supported on windows phone. i'm sure there way since remote desktop microsoft can switched other app , connection still alive. thanks advance. tcp socket maintain live ... can switched other app , connection still alive i think mix concepts. tcp socket maintain live observe loss of connectivity peer. see remote desktop maintains own state on multiple tcp connections. kind of resuming has implemented application , in application specific way. sockets windows-phone-8.1

javascript - How would you make the result print "computer wins" or "user wins" -

javascript - How would you make the result print "computer wins" or "user wins" - obviously, print out rock/paper/scissors wins or it's tie. what best way accomplish result "rock beats scissors -- computer wins!" , such? var userchoice = prompt("do take rock, paper or scissors?"); var computerchoice = math.random(); if (computerchoice < 0.34) { computerchoice = "rock"; } else if(computerchoice <= 0.67) { computerchoice = "paper"; } else { computerchoice = "scissors"; } console.log("computer: " + computerchoice); var compare = function(choice1, choice2) { if (choice1 === choice2) { homecoming "the result tie!"; } else if (choice1 === "rock") { if (choice2 === "scissors") { homecoming "rock wins"; } else { homecoming "paper wins"; } } else if (choice1 ===

javascript - Mashable velocity graph (image) -

javascript - Mashable velocity graph (image) - i wondering how can create mashable velocity graph. i don't want real actually, want show random positive velocity graph. how can create such velocity graph image using php or javascript ? i want this: http://i.imgur.com/y7r6jvz.png this achievable using canvas & javascript. i won't waste time listing relative resources here, google "draw canvas graph" or similar. you need store share data, can retrieved via social site api's. facebook, twitter, pinterest, linked in easy calls, , 1 time again quick google give tutorials that. in principle though, have to: record share counts on time (php + mysql) load page including data write javascript draw graph based on data javascript php graph velocity

java - Where do Jersey json serialization errors get logged? -

java - Where do Jersey json serialization errors get logged? - this dead simple bailiwick of jersey request fails server error 500. i'm pretty sure on serialization. had object doing same thing , stepped through in debugger , discovered fellow member wasn't serializable. anyway, question - bailiwick of jersey logs root cause of these problems? they're not going tomcat logs. when in debugger, getting logged something, quite figure out going. @path("myresource") public class myresource { @get @produces(mediatype.application_json) public map<string, string> getprops() { properties props = system.getproperties(); map<string, string> results = new hashmap<>(); (object o : props.keyset()) { string key = (string) o; results.put(key, props.getproperty(key)); } homecoming results; } jersey uses jdk logging api. here tutorial setting up: http://ya

javascript - Modal progress bar breaks my dropdown Menus bootstrap 3.x -

javascript - Modal progress bar breaks my dropdown Menus bootstrap 3.x - when utilize progress bar in modal, add together @ bottom of html document following: <script src="http://netdna.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script> this works fine, after adding line bootstrap dropdown menus stop working. if remove script src line above, dropdown menus start working 1 time again modal progress bar doesn't work. modal shown no progress action performed. progress bar works when in regular page. modal doesn't work. when utilize inspector of dropdown menu. doesn't perform action when click. no error in js console. html <td class="text-center"> <div class="btn-group"><a href="#" data-toggle="dropdown" class="dropdown-toggle"><i class="fa fa-cog"></i></a> <ul class="dropdown-menu pull-right text-left"&g

Included chef cookbook provider not working -

Included chef cookbook provider not working - i'm trying utilize gem_specfic_install cookbook can utilize specificinstall provider chef doesn't seem take it's there. i've added cookbook 'gem_specific_install', '~> 0.2.4' berksfile i've added depends 'gem_specific_install' metadata.rb i've added include_recipe "gem_specific_install" install recipe file chef errors no matter way utilize (as specified here) what doing wrong? p.s. reason i'm trying utilize because need install event_machine gem it's github repo contains prepare .gem on rubygems.com doesn't have. would worth downloading fixed version, build .gem file , host locally or on our artifactory server instead of using specific_install ? edit: it either goes: [2014-10-27t17:36:16+00:00] fatal: nomethoderror: undefined method `repository' chef::resource::gempackage or options takes string not hash edit: doesn't ma

c# - passing model to RedirectToAction without using session or tempdata? -

c# - passing model to RedirectToAction without using session or tempdata? - i m modifying existing code. from 1 action utilize redirecttoaction transfer execution command action. need pass model redirecttoaction well. thought can't done straight passing model 2nd action without using session or tempdata. still want inquire there technique pass model redirecttoaction ? don't want set model in session or tempdata. thanks you can seek that, doesn't sense natural action: public actionresult index() { homecoming redirecttoaction("anotheraction", new { parameter1 = parameter1, parameter2 = parameter2, }); } [httpget] public actionresult anotheraction(modelclass model) { //model.parameter1 //model.parameter2 homecoming view(model); } c# .net asp.net-mvc asp.net-mvc-4

python - I need to reverse the output format of a printed triangle using O's -

python - I need to reverse the output format of a printed triangle using O's - i need reverse output format of printed triangle using o's my code is userrows=int(input("enter positive number less or equal 20!")); while((userrows>21) or (userrows<0)): userrows=int(input("try again! please come in positive number less or equal 20.")); rows=1; while(rows<=userrows): columns=1; while(columns<=rows): print("o",end=''); columns=columns+1; print(''); rows=rows + 1; the output is enter positive number less or equal 20!20 o oo ooo oooo ooooo oooooo ooooooo oooooooo ooooooooo oooooooooo ooooooooooo oooooooooooo ooooooooooooo oooooooooooooo ooooooooooooooo oooooooooooooooo ooooooooooooooooo oooooooooooooooooo ooooooooooooooooooo oooooooooooooooooooo i'm trying align right left, instead of left right(as shown above). >>> userrows=int(input("ent

java - RateLimit issue with selenium scripts test run -

java - RateLimit issue with selenium scripts test run - i using http://mailinator.com/ in automation scripts email related tests. works me after having amount of script execution not work , routes user page called "ratelimit.jsp". it not work couple of days , 1 time again start working. can help me here deal ratelimit email providers? mailinator has rate-limits on how many email's can send. can help me deal ratelimit email providers? you have couple options can think of. since mailinator qa testing, upgrade plan. see pricing plans... switch different provider. there several options, gmail. or utilize own custom mail service server. java selenium selenium-webdriver

javascript - Change class on date -

javascript - Change class on date - absolute scripting noob here, i've got problem that's been bugging me 3 day's straight now. i'm trying create script work advent calendar. so: 01 dec 2014 door 1 opens, 02 dec 2014 door 2 opens (door 1 stay's open) ect... now might have gotten totally wrong i've got @ moment : class="snippet-code-js lang-js prettyprint-override"> $(function(){ // event handler close current popup when clicking on widgets "close_when_clicked" css class $('body').on('click', '.boxy-content.close_when_clicked', function(e){ if (!$(e.target).is('a')){ e.preventdefault(); var boxy = boxy.get(this); boxy.hideandunload(); } }); var i, current_day, day, startdate; var $cal = $('.calendar'), $prizes = $('.prizes > *'), $lo

ruby - validating only itunes app store and play store url in rails -

ruby - validating only itunes app store and play store url in rails - i having simple problem validating url using ruby on rails technology.there alot of solution validating url none works me.as want allow play store , app store url save in database. say have play store app link. here model: class appstore < activerecord::base validate :custom private def custom if self.url_name.match /paly.google.com|itunes.apple.com/ else self.errors.add(:url_name, 'must app store url or paly store url') end end end now when come in url "http://play.google.com" total url of app validation failling. sample url https://play.google.com/store/apps/details?id=com.viber.voip please help me solve problem as.i new rails technology. give thanks guys. please seek following: class appstore < activerecord::base valid_stores = ['play.google.com', 'itunes.apple.com'] validate :store_url_format private def store

jquery - Cannot get fancybox thumbnails to work -

jquery - Cannot get fancybox thumbnails to work - so sense i've tried been unable fancybox thumbails work. here code: javascript: $(document).ready(function() { $(".fancybox-thumb").fancybox({ preveffect : 'none', nexteffect : 'none', helpers : { title : { type: 'outside' }, thumbs : { width : 200, height : 200, position:'top' } } }); }); html: <a class="fancybox-thumb" rel="fancybox-thumb" href="images/royalty.jpg" title="simple cake"> <img src="images/royalty.jpg" alt="" /> </a> <a class="fancybox-thumb" rel="fancybox-thumb" href="http://lorempixel.com/output/business-q-c-50-50-10.jpg"> <img s

jquery - Triggering colorbox on page load using href and rel properties results in empty colorbox -

jquery - Triggering colorbox on page load using href and rel properties results in empty colorbox - i using colorbox allow readers view , navigate through series of divs in page -- mixed media slideshow, more or less. using script, , can view page functionality @ http://new.evideoexpress.com/services/. jquery(".colorbox").colorbox({ inline:true, rel:'colorbox', transition:"elastic", width:"75%", height:"75%", current:"", previous:"previous", next:"next", close: "close" }); i utilize rel property create grouping of divs gallery, each of assigned id. anchors in document trigger lightbox this: <a class="colorbox" href="#commercial-distribution"><span>learn more</span></a> this works expected. under conditions, want trigger colorbox when page loads. test, running script when document ready, using href property ide

javascript - jQuery on click event function to be used as a normal function as well -

javascript - jQuery on click event function to be used as a normal function as well - i have event handler method executes on click of button. pass on info shown below $( "button" ).on( "click", {name: "hello"}, greet ); and method defined as: function greet(event) { // utilize info event.data.name // access dom element on click method invoked $(this) } but want utilize function normal js function. how pass on info ({name: "namaskara"}) ? how set context - illustration have button <button id="kannada" /> , want utilize button context , sent greet() function $(this) used in function button 1). reply first question. but want utilize function normal js function. how pass on info {name: "namaskara"}?": you need pass in object data property: greet({data: {name: "namaskara"}}); 2). sec question context: var $kannada = $('#kannada');

sql server - GROUPING_ID functionality -

sql server - GROUPING_ID functionality - i don't quite understand how function works, i've been looking on below documentation, , have issues. http://msdn.microsoft.com/en-us/library/bb510624.aspx so, understand how grouping() works perfectly, output grouping_id quite impossible me comprehend how it's done because it's not same explanation. for illustration have next string of ones , zeroes: 010 . in documentation says it's equal 2. read in sql book each byte (the rightmost) is equal 2 @ powerfulness of byte position minus one. so, (2^2 - 1) + (2^1 - 1 ) + (2^0 - 1), isn't same each binary number? (100/101/110/etc), , result isn't 2 either.... edit 1 : how explanation book is: another function can utilize identify grouping sets grouping_id. function accepts list of grouped columns inputs , returns integer representing bitmap. rightmost bit represents rightmost input. bit 0 when respective element part of grouping set , 1 wh

java - Why is my code skipping through the if statement? -

java - Why is my code skipping through the if statement? - i'm posting segment of larger block of code i'm having problem with. should run itself. purpose of testing, input 1 @ first prompt. 1 time runs print statement, programme terminates instead of asking variable. don't understand why. can help me? import java.util.scanner; public class physics { public static void main(string[] args) { scanner input = new scanner(system.in); int switchnumber; string variablecaseone; double distance; double initialvelocity; double time; double gravity; system.out.println("this section projectile motion."); system.out.println("which equation use?"); system.out.println("1. horizontal equation: d = vi * t"); system.out.println("2. vertical equation: d = vi * t - (1/2)g * (t^2)"); switchnumber = input.nextint(); if (switchnumber == 1) { system.out.println("tell me variable

javascript - How to load the 3D model (JSON) on current mouse position in Three.JS? -

javascript - How to load the 3D model (JSON) on current mouse position in Three.JS? - i'm trying accomplish functionality load 3d model on current mouse coordinates. i'm using jquery drag , drop functionality load 3d model. can load model canvas, not snapping mouse coordinates. i've used below code convert 2d mouse coordinates 3d coordinates it's not providing exact position. function 2dto3dspace(event) { var planez = new three.plane(new three.vector3(1500, 1500, 1500), 0); var mv = new three.vector3((event.clientx / window.innerwidth) * 2 - 1, -(event.clienty / window.innerheight) * 2 + 1, 0.5); var raycaster = projector.pickingray(mv, camera); var pos = raycaster.ray.intersectplane(planez); homecoming pos; } make sure utilize mouse position relative canvas elemente. see this thread. javascript three.js

javascript - Google Pie Chart not showing in broser -

javascript - Google Pie Chart not showing in broser - i'm trying populate info table list object , display result in pie chart. reason cannot identify pie chart not showing in browser (blank page). below code. can seek run code , identify error!... since cannot identify i'm wrong. the default.aspx <%@ page language="c#" autoeventwireup="true" codefile="default.aspx.cs" inherits="_default" %> <!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <script type="text/javascript" src="https://www.google.com/jsapi"></script> <script type="text/javascript"> google.load("visualization", "1", { packages: ["corechart"] }); google.setonload

css - Positioning an image next to a number -

css - Positioning an image next to a number - i'm trying have number of coins right next image of coins, fails displaying them right next eachother live example: html: <div class="coins"> <div class="cointextfix">5</div> <div class="coinimgfix"></div> </div> css: .coins{ text-align:center; font-size:35px; padding-top:15px; } .cointextfix{ display:inline-block; margin-top:0px; padding-top:0px; width:50px; height:40px; background-color:green; } .coinimgfix{ background-image:url("http://i.imgur.com/h6at9tj.png"); display:inline-block; margin-top:0; padding-top:0; width:50px; height:40px; background-color:blue; } and @ point managed them next eachother, impossible move letter up/down without moving image.. i'm stuck first problem.. you need verical-align css rule: .cointextfix{ display:inline-block; margin-top:0; padding-top:0; widt

api - How to implement multiple Dropbox Javascript Choosers on a page? -

api - How to implement multiple Dropbox Javascript Choosers on a page? - dropbox's official page teaches how implement single chooser, doesn't teach how implement multiple choosers on page. is possible that? yes, possible. createchoosebutton method can used multiple times create multiple chooser buttons can set wherever want. e.g.: var button = dropbox.createchoosebutton(options); document.getelementbyid("container").appendchild(button); var button2 = dropbox.createchoosebutton(options2); document.getelementbyid("container").appendchild(button2); javascript api dropbox

Problems to add using UPDATE -

Problems to add using UPDATE - how increment value in field update in mysql using pdo? not working. must added in order perform update $atualizar = array(':campoa '=>$valora,'campob'=>$valorb); $atualizar_voto = $conn->prepare("update tabela set votos = votos + '1' (campoa = :ida, campob = :idb)"); sql-update

ios - Add a framework to an existing project without using cocoapods -

ios - Add a framework to an existing project without using cocoapods - i've got existing project want add together framework called coreactionsheetpicker https://github.com/skywinder/actionsheetpicker-3.0 the problem cant seem add together framework project? when pull framework on existing project none of files below added , when seek import says not exist import coreactionsheetpicker i want without cocoapods. steps in order such? i'm using swift. first need create workspace? i've cloned it, , appears project file invalid. can see trying open it. should raise issue owner on github, how you're supposed inquire questions projects there. feedback straight creator or @ to the lowest degree else knows project. as adding project, download source drag .xcodeproj project within xcode add framework in build phases / link binary libraries add build phase / target dependency. note @ moment, should builds 3rd part libraries swift project, , not

excel - Adding value to the last cell -

excel - Adding value to the last cell - i need help something, in theory @ least, simple: you come in value in 1 cell (a1), value added b1. add together value (replacing previous value) in a1, c1 created value, , goes on. i need maintain history saved, @ same time, simplifying input method. i appreciate help. thanks. put next event macro in worksheet code area: private sub worksheet_change(byval target range) dim range, n long set = range("a1") if intersect(target, a) nil exit sub application.enableevents = false n = cells(1, columns.count).end(xltoleft).column + 1 cells(1, n).value = a.value application.enableevents = true end sub because worksheet code, easy install , automatic use: right-click tab name near bottom of excel window select view code - brings vbe window paste stuff in , close vbe window if have concerns, first seek on trial worksheet. if save workbook, macro saved it. if using version of

onedrive - The request entity body has an incorrect value in the 'Content-Disposition' header. The expected format for this value is 'Content-Disposition: -

onedrive - The request entity body has an incorrect value in the 'Content-Disposition' header. The expected format for this value is 'Content-Disposition: - i have tried multiple http apis post file onedrive using post method, , getting same error. i went extreme case of creating own ssl tcp socket , send next bytes: post /v5.0/folder.a4fb14adbccd1917.a4fb14adbccd1917!32089/files http/1.1 accept-encoding: authorization: bearer ewciaq1dbaaugccxc8wu/zfu9qnldzxy%2bynelfkaaxa4ajqtmipoouadokv98madpbzp8sef0zjyzu4%2bva0fvr/awr4x0chwazef7s7hbeabbptxlwckheyrgkfbh2ybadpxeju0grroz37winvpsgfvd8bz9gtcqwdhh3guxunbm/nlqh1tizelmjyupegaebbwt25f8sokzizi2kpvlzdpokjjbq2bxrycawyddk74ivuiudgkx4hmpmwzmwtergeybpn2egobhqa8o3gt2a9ta2hps0elcv0gkhwg/u1t19/xjokw2dnbbsj01a9ijkmyxhamtyg71sgjqzhdxjajf0hxng8niioty82mlhqewcweyzfxosgddt0clkidzgaacedf3skfts5%2bwahgkglcwfj4drlrn3/f2dvozwgyeitjkwfzdx%2b4b8m5olyo5oykwf77zjvxnukj50ciovcjq/ognv1kmgb45eexy3%2b3t9jjn0rm91dognufgj1m/vuzvn3ep5f3jr0hmvxbmpzf

parsing - How exactly is a PHP script executed? -

parsing - How exactly is a PHP script executed? - i thinking myself "how php script executed?" thought parsed first syntax errors etc, , interpreted , executed. however, don't know why believe correct. i'm wrong. so, how php file interpreted , executed? stages involve? how included files fit parsing of script? this help me head around it. i'm interested , can not find reply google. take hear to: http://techportal.inviqa.com/2010/02/02/php-compiler-internals/ this great question, wonder same thing. in presentation introduce new language build demonstrate how 1 might go modifying php interpreter. internals of follow pattern mutual many language implementations, lexical analysis, parsing, code generation, , execution phases. (as side note: ibuildings seems leader in php development. based in uk. similar company in us?) php parsing interpreter

xcode - codesign plugins for mac app -

xcode - codesign plugins for mac app - following article, i'm running codesign frameworks. however, i'm still getting codesign error plugins. /.../applications/myapp.app: code object not signed @ in subcomponent: /.../myapp.app/contents/plugins/flash player.plugin command /usr/bin/codesign failed exit code 1 how should add together codesign command plugins? tried various directories/files, didn't work: codesign --verbose --force --sign "$identity" "$plugins_location/flash player.plugin" we had codesign plugin separately: codesign --deep --verbose --force --sign "developer id application" plugins/flash\ player.plugin xcode xcode5 code-signing codesign

html - Scrollable div inside fixed div -

html - Scrollable div inside fixed div - i have div .div-wrapper within position: fixed div .div-header . want scroll div jquery. i have working solution below, ugly(with width: 5000% ) can't stop myself finding improve way this. is there way accomplish same effect without having width: 5000% ? html: <div class="div-header"> <div class="div-wrapper"> <div class="div-long"> wide content... </div> </div> </div> css: .div-header { position: fixed; left: 15px; right: 100px; top: 20px; } .div-wrapper { overflow: hidden; height: 57px; } .div-long { width: 5000%; } jsfiddle: http://jsfiddle.net/pyzk27xj/6/ thanks in advance! take @ document: https://developer.tizen.org/dev-guide/2.2.0/?topic=%2forg.tizen.web.appprogramming%2fhtml%2fguide%2fui_guide%2fui_framework_scrollview.htm i believe has reply need! html css fi

I have a deserialize Json C# class now i want to fetch information from it -

I have a deserialize Json C# class now i want to fetch information from it - this deserialize json response c# class public class apppage { public pagelayout[] pagelayouts { get; set; } public string pagename { get; set; } public string pagetype { get; set; } } public class pagelayout { public string layout { get; set; } public pagecontrol[] pagecontrols { get; set; } } public class pagecontrol { public string __type { get; set; } public string controltype { get; set; } public int height { get; set; } public int pageid { get; set; } public bool visible { get; set; } public int width { get; set; } public string text { get; set; } public string textcolor { get; set; } public string type { get; set; } public bool autosize { get; set; } public string labelposition { get; set; } public bool showlabel { get; set; }

wpf - How to see Windows's "default" colors in the properties window when using the designer? -

wpf - How to see Windows's "default" colors in the properties window when using the designer? - it's "quality of life" question, because there no bug or anything, annoys me. you can see in visual studio, when you're editing xaml properties, given control, can select "default" colors background , foreground properties (for example), chocolate, salmon, or plain red or green , on. the problem beingness you can not select them list, have know them already, not intuitive. is there way show these "default" values such properties in properties window of visual studio 2010? wpf visual-studio-2010 xaml system-properties

c++ - Code::Blocks process terminated with status 1 -

c++ - Code::Blocks process terminated with status 1 - my default "hello world" code code::blocks terminated status 1. can't open it! know why? #include <iostream> using namespace std; int main() { cout << "hello world!" << endl; homecoming 0; } this shows when compile: mingw32-g++.exe -o bin\debug\bucky.exe obj\debug\main.o mingw32-g++.exe: internal error: aborted (program collect2) please submit total bug report. see <url:http://www.mingw.org/bugs.shtml> instructions. process terminated status 1 (0 minute(s), 0 second(s)) 0 error(s), 0 warning(s) (0 minute(s), 0 second(s)) thanks! jesper c++ codeblocks

c++ - Boosts say boost::log does not support forked processes. Is this still the case if the logger wasn't initialized until after the fork? -

c++ - Boosts say boost::log does not support forked processes. Is this still the case if the logger wasn't initialized until after the fork? - i have process forks, , creates boost loggers, different file names , different channel names in each kid process. still, when effort log anything, deadlocks occur. don't see how matter if logging create/initialized after fork occurred. child 1: #0 in pthread_rwlock_wrlock () /lib64/libpthread.so.0 #1 in boost::log::v2s_mt_posix::aux::light_rw_mutex::lock() () /usr/local/php54/lib/php/extensions/x.so #2 in boost::log::v2s_mt_posix::sources::multi_thread_model<boost::log::v2s_mt_posix::aux::light_rw_mutex>::lock() const () /usr/local/php54/lib/php/extensions/x.so #3 in boost::log::v2s_mt_posix::aux::exclusive_lock_guard<boost::log::v2s_mt_posix::sources::multi_thread_model<boost::log::v2s_mt_posix::aux::light_rw_mutex> >::exclusive_lock_guard(boost::log::v2s_mt_posix::sources::multi_thread_model<boost

plugins - Tool to display geo-spatial data from MongoDB? -

plugins - Tool to display geo-spatial data from MongoDB? - i searching tool such geoserver or qgis display geo-spatial info stored in mongodb (mongodb provides specific 2d-indices that). in case storing linestrings. the existing plugin integration of mongodb sources in geoserver not supported , wasn't published in name of geoserver. http://osgeo-org.1560.x6.nabble.com/mongodb-plugin-td5042018.html my seek led same problem of missing layer. for combination of mongodb , qgis there plugin internally converts mangodb info in csv , integrates in qgis. is there open-source software visualizing geo-spatial info supporting integration of info mongodb? any suggestions? best, tron i've developed simple solution time beingness , it's available in official qgis plugin repo: http://plugins.qgis.org/plugins/qgis-mongodb-loader/ i have plugin allows create edits , save changes in mongodb through qgis, i'm sure if i'm allowed release plugin

hadoop - How to convert sas7bdat file to csv? -

hadoop - How to convert sas7bdat file to csv? - i want convert .sas7bdat file .csv/txt format can upload hive table. i'm receiving .sas7bdat file outside server , not have sas on machine. thanks in advance. use 1 of r foreign packages read file , convert csv tool. http://cran.r-project.org/doc/manuals/r-data.pdf pg 12 using sas7bdat bundle instead. appears ignore custom formatted, reading underlying data. in sas: proc format; value agegrp low - 12 = 'pre teen' 13 -15 = 'teen' 16 - high = 'driver'; run; libname test 'z:\consulting\sas programs'; info test.class; set sashelp.class; age2=age; format age2 agegrp.; run; in r: install.packages(sas7bdat) library(sas7bdat) x<-read.sas7bdat("class.sas7bdat", debug=true) x csv hadoop hive sas hdfs

Android 5 emulator not responding after few app launches -

Android 5 emulator not responding after few app launches - i'm using android studio v0.8.9 latest android sdk on windows 7 64-bit. after running app 4 or 5 times in emulator android 5, emulator stops responding , need close , restart it. emulator crashes info: description: problem caused programme stop interacting windows. problem signature: problem event name: apphangb1 application name: emulator-x86.exe ... i had no problems other android versions in emulator. android android-emulator

linux - OpenVPN and iptables -

linux - OpenVPN and iptables - openvpn , iptables my internal aws network not straight accessible internet, may accessed through secure openvpn gateway. network configuration the openvpn server ubuntu server 14.04.1 aws ec2 instance exposes udp 1194 on external (internet) interface 'eth0', allows ports/protocols on internal interface 'eth1'. when openvpn tunnel created between openvpn client , openvpn server, creates new interface on each side of tunnel called 'tun0', allows ports/protocols. the openvpn server binds ip address 10.8.0.1 tun0 interface, , openvpn clients dynamically assigned ip addresses starting 10.8.0.2, in ascending order. interfaces of internal resources have statically-assigned ip addresses within 10.0.100.0/24. packet forwarding enabled on openvpn server in /etc/sysctl.conf: net.ipv4.ip_forward=1 'source / destination checking' has been appropriately disabled. packet forwarding requirements the openvpn server mus

ios - Share data with different types in UIActivityViewController -

ios - Share data with different types in UIActivityViewController - there extremely similar question asked next post: different info sharing providers in uiactivityviewcontroller. question different. i know how share different different info of same type different activities using itemforactivitytype . example: - (id) activityviewcontroller:(uiactivityviewcontroller *)activityviewcontroller itemforactivitytype:(nsstring *)activitytype { if ( [activitytype isequaltostring:uiactivitytypeposttotwitter] ) homecoming @"this #twitter post!"; if ( [activitytype isequaltostring:uiactivitytypeposttofacebook] ) homecoming @"this facebook post!"; if ( [activitytype isequaltostring:uiactivitytypeairdrop] ) homecoming @"airdrop message text"; else homecoming nil; } however, question is: what if have different kind of info share different activities, should do?. example, if share: a string

java - Trouble with finding a substring in a string -

java - Trouble with finding a substring in a string - i need print words appear more 1 time in string. example input:s = "java ruby php. java good. php please looks @ java" output: java php set<string> words = new hashset<>(); string str = "java ruby php. java good. php please looks @ java"; matcher mat = pattern.compile("\\b(\\w+)(?=\\b.*\\1)").matcher(str); while(mat.find()){ words.add(mat.group(1)); } system.out.println(words); also can split string words , calculate count using map. , filter words count > 1. java string

objective c - Core Data + NSTextView + Undo Manager -

objective c - Core Data + NSTextView + Undo Manager - i'm trying create non-trivial job core info backed nstextview. want store in core info model not whole nstextstorage, instead break paragraphs , persist paragraphs each in individual entity. in fact got work. can't deal undo/redo support. if store every alter in textdidchange notification or something, lose nstextview's undo support, because core info begins store every single character did entered text storage. so, undo manager registers actions individually. , when undo, undo character-by-character , isn't thing want. if don't store inputted text in core data, textview's undo management works fine. how can know when undo manager begins , closes grouping of actions, store changes when grouping closed? i trying observe nsundomanagerdidcloseundogroupnotification of nsundomanager didn't help, because notification during every single character input , still annoying character-by-characte

javascript - Slideshow on key press not working properly -

javascript - Slideshow on key press not working properly - so have code. i'm doing wrong. want left arrow go (show previous image) isn't working. shows next image (like right arrow). whatever arrow click, left or right shows next image. i've tried millions of different things , can't seem find problem. can help me? i sources loop. when lastly source array has been reached, want loop first source 1 time again (and lastly source when reach first). btw, have code image alter on click. i'm pretty sure has nil problem, decided maintain it, in case it's messing up. give thanks :) html: <div class="container"> <div id="slideshow"> <img alt="slideshow" src="1.jpg" id="imgclickandchange" onclick="changeimage()"/> </div> </div> js: <script> var imgs = ["2.jpg", "3.jpg", "4.jpg", "5.jpg"

timer - Why does times give me the same output after sleep(5) in C -

timer - Why does times give me the same output after sleep(5) in C - i have problem want measure time of function. phone call timer @ origin , @ end of function returns same value though when phone call sleep(5). here code: #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <sys/times.h> void function_to_time(void); int main(void) { double clockticks, cticks; clock_t tcend, tcstart; struct tms tmend, tmstart; if ((clockticks = (double) sysconf(_sc_clk_tck)) == -1) { perror("failed determine clock ticks per second"); homecoming 1; } printf("the number of ticks per sec %f\n", clockticks); if (clockticks == 0) { fprintf(stderr, "the number of ticks per sec invalid\n"); homecoming 1; } if ((tcstart = times(&tmstart)) == -1) { perror("failed start time"); homecoming 1; } function_to_time(); if ((tcend = times(&tmend)) == -1) { perror("failed end times");

uitableview - Image View in Auto Layout using SDWebImage in Storyboards -

uitableview - Image View in Auto Layout using SDWebImage in Storyboards - i'm having no luck getting image , uiimageview show right size in custom uitableviewcell . image correct, place in uitableviewcell not, , isn't close. i don't have plenty reputation points post images sadly. i have suggested constraints xcode 6 added or suggested, image showing huge , in front end of in uitableviewcell . here's code have related it. viewcontroller.m self.tableview.rowheight = uitableviewautomaticdimension; self.tableview.estimatedrowheight = 600.0; nsstring *imageurl = [nsstring stringwithformat:@"%@", standardresolutionlocal.url]; __weak uitableviewcell *wcell = api2cell; [wcell.imageview sd_setimagewithurl:[nsurl urlwithstring:imageurl] placeholderimage:[uiimage imagenamed:@"320x180.gif"] ]; customtableviewcell.m - (void)layoutsubviews { [super layoutsubviews];

c# excel create a button on excel worksheet -

c# excel create a button on excel worksheet - i trying add together button on excel worksheet. according illustration internet, trying next code. using excel = microsoft.office.interop.excel; using vbide = microsoft.vbe.interop; private static void exceladdbuttonwithvba() { excel.application xlapp = new excel.application(); excel.workbook xlbook = xlapp.workbooks.open(@"path_to_excel_file"); excel.worksheet wrksheet = xlbook.worksheets[1]; excel.range range; seek { //set range insert cell range = wrksheet.get_range("a1:a1"); //insert dropdown cell excel.buttons xlbuttons = wrksheet.buttons(); excel.button xlbutton = xlbuttons.add((double)range.left, (double)range.top, (double)range.width, (double)range.height); //set name of new button xlbutton.name = "btndosomething"; xlbutton.text = "click me!"; xlbutton.onaction = "btndosomething_click"; buttonmacro(xlbutton.name, xlapp,