Posts

Showing posts from July, 2015

Handle back pressed of multiple fragments in android -

hi developing application using fragments.totally have 15 fragments , loaded in single activity.while onback pressing on each fragment launch previous fragment.i google , got answers it.but want know more efficient way handle this. by calling addtobackstack() , replace transaction saved stack user can reverse transaction , bring previous fragment pressing button. reference if add multiple changes transaction (such add() or remove()) , call addtobackstack() , changes applied before call commit() added stack single transaction , button reverse them together. just add transaction.addtobackstack(null); for more information may visit handling button press inside fragments

java - how to hide a nested layout after 5 seconds in android? -

i need hide nested layout after 5 seconds. layout code below, <linearlayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/invitation_single" android:layout_width="match_parent" android:layout_height="match_parent" android:divider="?android:dividervertical" android:dividerpadding="5dp" android:showdividers="middle" tools:context=".mainactivity"> <imagebutton android:id="@+id/image" android:layout_width="50dp" android:layout_height="50dp" android:src="@drawable/ic_action_event" /> <linearlayout android:layout_width="0dp" android:layout_height="50dp" android:layout_weight="1" android:clickable="false" android:foc

How to delete string after some charecters in Objective-C? -

this question has answer here: objective-c: extract filename path string 3 answers i have string /uploads/images/mypic_123.png want image name mypic_123.png .please tell me how it? using objective-c. nsstring has method named lastpathcomponent can use

r - Reactive input in Shiny not working -

my renderdatatable() not seem react reactive input. not sure missing. before when entered text input every 'enter' key pressed changed text detected. have explicitly click submit buttonthe code below server.r shinyserver(function(input, output) { toggle("inputbox") toggle("text") datainput <- reactive({input$text}) output$table1 <- renderdatatable({(options = list(pagelength = 10,searchable = false)) <- function1(datainput()) }) output$table2 <- renderdatatable({ b <- function2(datainput()) }) }) u1.r fluidrow( column(4, code(id = "inputbox", "please wait, loading ..."), hidden(textinput("text", label = h3("enter words"), value = "xxxx xxxx")),br(), actionbutton("action", label = " please hit enter or click submit"), br(), br(), submitbutto

c# - Why is my web socket receiving data packets in the wrong order? -

i have c# desktop app sends jpegs server @ rate of 10 per second. each jpeg has time stamp part of header , read server. i experiencing disorderly arrival on server. the majority of time jpegs received sever in order have been sent client. but, every , order becomes 'jumbled'. are tcp packets supposed guaranteed sent in order or subject delays network/internet? if order guaranteed post code. thanks my code: on client: class websocketclient { static websocket websocket = null; public static void start() { try { console.writeline("started at: " + datetime.now.tostring()); if (websocket != null) { websocket.dispose(); } websocket = new websocket("ws://a uri"); websocket.opened += new eventhandler(websocketclient_opened); websocket.error += websocket_error; websocket.closed += new eventhandler(websocketcli

Rails 4 - Update Join Table Attributes with has_many through -

this follow-up of question: rails 4 - access join table value in views now know how retrieve join table attributes , show them in view. still can't find right approach edit , update attribute. models: class recipe < activerecord::base has_many :recipe_ingredients has_many :ingredients, through: :recipe_ingredients end class ingredient < activerecord::base has_many :recipe_ingredients has_many :recipes, through: :recipe_ingredients end class recipeingredient < activerecord::base belongs_to :recipe belongs_to :ingredient #there attribute t.text :amount end recipe#edit: ... <%= simple_form_for @recipe |f| %> <div class="form-group"> <%= f.input :name, input_html: { class: "form-control"} %> <%= f.input :description, input_html: { class: "form-control"} %> <%= f.collection_select(:ingredient_ids, ingredient.all, :id, :title, {}, {multiple: true}) %> <!-- re

php - String to array conversion if string has content like an array -

i have this: array('fields' => array( 0 => array('name' => 'family_name', 'label' => 'family names'), array('name' => given_names', 'label' => 'given names'), array('name' => 'additional_names', 'label' => 'additional names'), array('name' => 'honorific_prefixes', 'label' => 'honorific prefixes'), array('name' => honorific_suffixes', 'label' => 'honorific suffixes') ) ) in variable string. whole thing in 1 database field. if output variable, string. have array content subarrays. how convert value array? i searched google, found exp

powershell - Returns objects asyn with Format-Table and a specific layout -

i want return object specific layout, each object should displayed when returned. if run code in powershell (not ise) see result not until function ends. function main { ($i = 1; $i -lt 10; $i++) { [pscustomobject]@{index=$i; timestamp=(get-date)} sleep -seconds 1 } } main | format-table @{label="index"; expression={$_.index};width=10}, @{label="timestamp"; expression={$_.timestamp};width=20} this works, want specific layout. function main { ($i = 1; $i -lt 10; $i++) { [pscustomobject]@{index=$i; timestamp=(get-date)} sleep -seconds 1 } } main and why behavior different if execute script in ise? this line in powershell profile responsible behavior. # following function automatically adds -autosize when use format-wide or format-table $psdefaultparametervalues['format-[wt]*:autosize'] = $true

Can not play a mp4 video in android VIdeoview from a remote url -

i have been trying play mp4 video remote url/dailymotion .i have played other video in .3gp format other website ,it worked fine ,can not play video daily motion in android app , here code ,can not understand issue.any help <relativelayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="fill_parent" android:layout_height="fill_parent" > <videoview android:id="@+id/videoview" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_centerhorizontal="true" android:layout_centervertical="true" /> ` public class songs extends activity { string videourl = "http://www.dailymotion.com/video/x2trnoh_indian-girl-mehndi-dance_fun"; videoview videoview; @override protected void oncreate(bundle savedinstancestate) { super.oncreate(sav

scala - format a (K, (v, w)) pair in spark rdd -

i have rdd this: val custfile = sc.textfile("custinfo.txt").map(line => line.split('|')) val custprd = custfile.map(a => (a(0), ((a(1)), (a(2), a(3), a(4), a(5), a(6), a(7), a(8))))) val custgrp = custprd.groupbykey custgrp.saveastextfile("custinfo2") that produces this: (1104,compactbuffer((s_savg,(1,1,1,1,1,1,1)), (cn_savg,(4,4,1,1,4,1,1)))) how can use this: custprdgrp.map{case (k, vals) => {val valsstring = vals.mkstring(", "); s"{$k:, {$valsstring}}" }} to format (k, (v, w)) pair...i tried got error: val custprdrep = custprdgrp.map({case (k, (v, w)) => {val valsstring = v.mkstring(", "); val valsprvcy = w.mkstring(", "); s"'${k}'| [$valsstring]" }}) <console>:27: error: constructor cannot instantiated expected type; found : (t1, t2) required: iterable[(string, (string, string, string, string, string, string, string))] val custprdrep = custprdgrp.m

scheduled tasks - Python script to send mail at specific time and day every month -

i want send mail every 2nd friday in month @ 4:00 p.m. how in python. know following logic not efficient, is there other way in python ? // pseudocode check 2nd friday , time 4:00 p.m. function(day='fri',time='4:00 p.m.') while(1){ string current_date=new date();// in following formate. // fri aug 21 2015 16:00:00 gmt+0530 (ist). // here can see combination of date, day , time. //now current_date string search sub string 'fri' if(current_date.substring('fri') && current_date.substring('16:00:00')){ // search date 2nd friday or not, int day=current_date.getday(); if(day>7 && day<=13) start_script send mail } } you can use celery periodic tasks automate this. @ here http://celery.readthedocs.org/en/latest/userguide/periodic-tasks.html celery handle cron in behalf , provide number of additional tools such login , interfaces should make script scalable (to more use

PHP CRC not the same as Java CRC -

i'm trying crc16 in php , same results in java. some criteria crc16 polynomial of 8005 initial remainder of 0 a final xor value of 0 neither input nor output reflected in java pass 5 byte message containing values 1,2,3,4,5 , value 0xb059. java code package crc; public class crc { public static void main(string[] args) { char crc = 0x0000; char temp = 0x0000; char[] data = new char[5]; data[0]=1;data[1]=2;data[2]=3;data[3]=4;data[4]=5; for(int i=0; i<data.length; i++){ char value = (char)data[i]; temp =(char)(value ^(char)(crc >> 8)); temp =(char)(temp ^(char)(temp >> 4)); temp =(char)(temp ^(char)(temp >> 2)); temp =(char)(temp ^(char)(temp >> 1)); crc = (char)((char)(crc << 8) ^ (char)(temp<<15)^(char)(temp << 2)^temp); } system.out.println(crc); } } php code function crc16($str){ $crc = 0x00

c# - How to mock other class object using Rhino Mocks -

i using visual studio 2013 , mstest unit test , rhino mocks mocking object. is there way, can mock other class object public class organization { public dataset getusers() { dataset ds = new dataset(); // added columns , rows here // class interacting database. that's why want create // mock of class. return ds; } } my main class below public class users { public dataset getusers(organization org) { dataset ds = org.getusers(); return ds; } } my test method below [testmethod] public void getuserstest() { dataset ds = new dataset(); //added mock rows , columns dataset var objorg = mockrepository.generatemock<organization>(); objorg.expect(x => x.getusers()).return(ds); users obj = new users(); dataset dsresult = obj.getusers(objorg); } it giving me error. can me write unit test above class's getusers method please? your method not virtual method. when

ios - two taps to full and two tap the screen to return to normal -

i want have 2 taps make full screen , 2 taps return regular. however, 2 gesturerecognizers conflicting , both getting called resulting in screen not changing. how fix that? here code: -(void) tap2full { //teste apartir daqui "tap" uitapgesturerecognizer *fullscreen = [[uitapgesturerecognizer alloc] initwithtarget:self action:@selector(fullscreen)]; fullscreen.numberoftapsrequired = 1; uitapgesturerecognizer *screenout = [[uitapgesturerecognizer alloc] initwithtarget:self action:@selector(screenout)]; screenout.numberoftapsrequired = 2; // stops taponce overriding taptwice [fullscreen requiregesturerecognizertofail:screenout]; fullscreen.delegate = self; screenout.delegate = self; [self.webview addgesturerecognizer:fullscreen]; [self.webview addgesturerecognizer:screenout]; } - (void)fullscreen { self.navigationcontroller.navigationbar.layer.zposition = -1; [self.view bringsubviewtofront:self.webview];

ios - Add a Video Frame in Player -

Image
want implement movie player cropping functionality. need show full video in 1 frame , user can select vedio portion wants crop. example image. try this, nice video trimmer library ios https://github.com/itsmeichigo/icgvideotrimmer

Is there a simple javascript API for Google Drive? -

the google drive api looks more complicated me like, stuff authorization, client-ids, scopes, boundaries, delimiters , on. if have javascript code in browser, , logged google account, more hoping simpler api like: google.drive.savefile(path, contents, statuscallback); google.drive.loadfile(path, onloadcallback); i guess there parameters depending on type of data being stored (e.g. string, binary), along these lines. is there javascript wrapper google drive provides simple this? checkout apps script , driveapp .

MYSQL Replace data in a column via csv -

sorry if duplicate question im not quote sure im looking when comes mysql terminology. im wp developer little new me. i have _postmeta table load of different meta fields. 1 particular called "description". have downloaded csv , replaced data in description content. have csv 3 columns (post id, meta key (all description) & meta value). want use phpmyadmin run query update current meta values content have in csv. your appreciated. thanks

sql - Correlated subquery to find employees earning more than average salary in their departments -

i writing oracle query find employees earn more average salary within departments. need display last_name,employee_id, salary, department_id , average salary of department. have written query not getting desired answer. can please tell me, making mistake select last_name,employee_id,salary,department_id,avg(salary) employees e1 salary > (select avg(salary) employees e2 e1.department_id=e2.department_id) group last_name,employee_id,salary,department_id with med (select department_id, avg(salary) avgsalary employees group department_id) select last_name, employee_id, salary, e.department_id, avgsalary employees e, med m e.department_id = m.department_id , e.salary > m.avgsalary

swift - attributed text not working with custom font in xcode 7 -

i using xcode 7. when using attributed text custom font displays in storyboard not working on device. tried following code: var mymutablestring = nsmutableattributedstring() let paragraphstyle = nsmutableparagraphstyle() paragraphstyle.linespacing = 8 paragraphstyle.alignment = nstextalignment.center mymutablestring = nsmutableattributedstring(string: "\"taking out shorts , t-shirt night before has helped create great morning routine walk\"", attributes: [nsfontattributename:uifont(name: "gotham medium", size: 20.0)!]) mymutablestring.addattribute(nsparagraphstyleattributename, value:paragraphstyle, range:nsmakerange(0, mymutablestring.length)) quoteslabel.attributedtext = mymutablestring make sure app contains font file gotham medium . check out great article common mistakes adding custom fonts in ios apps . include fonts in xcode project make sure they’re included in target double check fonts included resour

javascript - freeze scrolling for period of time -

wanna make scroll on this link . problem can't prevent scrolling 1 sec after switching different zone. wrote some code below already, works, have couple of bugs (in example above can't scrolling while zone transition happening. in code can. need disable non-pause-transition). working on problem while, grateful help. var zoneheight = $('#zone1').height(); zoneheight += 10; //border var lastscrolltop = 0; $(window).scroll(function(event){ var scrollposition = $(window).scrolltop(); disablescroll(); if (scrollposition > lastscrolltop){ // downscroll code if(scrollposition > 0 && scrollposition < zoneheight){ window.scrollto(0, zoneheight); } else if(scrollposition > zoneheight && scrollposition < zoneheight * 2){ window.scrollto(0, zoneheight * 2); } } else { // upscroll code if(scrollposition < zoneheight * 2 && scrollposition > zoneheight)

servlets - Start a thread as soon as a long post request comes in -

i trying upload image. need start synchronising thread http request comes in. presently grails code starts after entire post data has been received. the controller in fact invoked request comes in. when image data fetched http request body code stall , wait upload finish.

php - can anyone tell why $auth_url is going blank in this code? -

my code given below: i'm trying use code import yahoo contacts in i've given app_id, callback url, customer id , customer secret. don't understand why link creating pop ups same url. may due $auth_url, can i'm missing? file).'/lib/yahoo.inc'; //for converting xml array function xmltoarray($xml) { $array = json_decode(json_encode($xml), true); foreach ( array_slice($array, 0) $key => $value ) { if ( empty($value) ) $array[$key] = null; elseif ( is_array($value) ) $array[$key] = xmltoarray($value); } return $array; } // debug settings //error_reporting(e_all | e_notice); # not show notices library php4 compatable //ini_set('display_errors', true); yahoologger::setdebug(true); yahoologger::setdebugdestination('log'); // use memcache store oauth credentials via php native sessions //ini_set('session.save_handler', 'files'); //session_save_path('/tmp/'

javascript - How to call function in AngularJS controller with $scope method? -

i have function inside controller want able call $scope method can reuse code within controller. use function clear input fields. call after user inserted assign "clear" button click. calling function after inserting works fine assigning function method isn't. if assign function directly $scope.clearuser method works can't call after inserting user. function clearuser() { $scope.employeenumber = ''; $scope.isadmin = false; }; $scope.clearuser = clearuser(); //also tried $scope.clearuser = this.clearuser(); //$scope.clearuser = function() { // $scope.employeenumber = ''; // $scope.isadmin = false; //}; <button ng-click="clearuser()" class="btn btn-default"> <i class="fa fa-times"></i> clear </button> omit () pass function: $scope.clearuser = clearuser; or, create @ once: var clearuser = $scope.clearuser = function() { }

c# - EF 6 table mapping error -

i'm running error trying save data in mvc app. we're using code first. i'm saving data this: var fielddefinition = db.customfields .firstordefault(x => x.customfieldid == thisresp.customfieldid); var newdata = new customdata { projectid = new guid("280288d7-7630-e511-8420-00215e466552"), customfieldid = thisresp.customfieldid }; if (fielddefinition.allowmultiple) { var values = thisresp.value.split(','); foreach (var thisvalue in values) { var newmulti = new customdatamulti { customdataid = newdata.customdataid, customvalue = thisvalue }; db.customdatamulti.add(newmulti); } } db.customdata.add(newdata); db.savechanges(); however, message: unable determine principal end of 'publicationsystem.model.customdata_customdatamultis' relationship. multiple added entities may have same primary key. my classes set this: public partial class customdata :

Log not being recorded for quickfix c++ Session -

i running fix initiator , succesfully connecting acceptor. problem is, no log being recorded. .cfg application written below. [default] connectiontype=initiator reconnectinterval=2 resetonlogon=y filestorepath=store filelogpath=logging starttime=00:00:00 endtime=00:00:00 usedatadictionary=y # standard config elements [session] # inherit connectiontype, reconnectinterval , sendercompid default beginstring=fix.4.4 sendercompid=init targetcompid=accept socketconnecthost=xxx socketconnectport=xxx heartbtint=30 datadictionary=fix44md.xml [session] beginstring=fix.4.4 sendercompid=init targetcompid=accept1 socketconnecthost=xxx socketconnectport=xxx heartbtint=30 datadictionary=fix44oms.xml the excerpt code initiates connection written below: std::string file = argv[ 1 ]; fix::sessionsettings settings( file ); application application; fix::filestorefactory storefactory( settings ); fix::screenlogfactory logfactory( settings ); fix::socketinitiator initi

ios - Why the NSNumber *test = [NSNumber numberWithInt:i] does not add memory footprint in a for loop? -

i trying reproduce huge memory footprint in loop.for example, in loop below, if there not autorelease pool in it. cause peak memory footprint. for(int i=0; i< 500000; i++){ nsnumber *test = [nsnumber numberwithint:i]; } because expression [nsnumber numberwithint:i] return autorelease object , if no autorelease in loop, autoreleased objects released once, cause peak memory footprint. tested in xcode6, result not reproduced. used totalsize += malloc_size((__bridge const void *) test); calculate total size of objects, got totalsize = 0 result. can reproduce huge memory footprint code [nsstring stringwithformat:@"%d ", i]; . can 1 explain question, in advance. small nsnumber s (those fit in 60 bit) stored tagged pointers. it's actual 64-bit pointer value carries numeric value, there's no heap allocation going on. done transparently obj-c runtime. more on topic: https://mikeash.com/pyblog/friday-qa-2012-07-27-lets-build-tagged-pointers.html

c# - How to inner join(filtering for nested properties) with expression tree? -

my users should able configure filter result database. decided use expression tree, flexible query. have problems expression tree filtering referencecode. entities: pumpstartup duration (timespan) dutdbid (guid/fk) timestamp (datetime) dut (deviceundertest) deviceundertest adminid (string/unique) dbid (guid/pk) referencecode (string) startups (list) here part of filter in equivalent linq. linq can't use, because don't know how many referencecodes defined user.: //-------------------reference code filter--------------------------- var query = context.pumpstartups.where((p => p.dut.referencecode == "hkr566" || p.dut.referencecode == "hsh967" || . . .)); startups = query.tolist(); for filtering deviceundertest part of filter, solution is: // --------

amazon web services - AWS API Gateway IAM Policy Role in Docs Fails in Simulation -

Image
the aws iam policy docs aws ( shown here ) indicate following policy gives full access role hit api gateway { "version": "2012-10-17", "statement": [ { "effect": "allow", "action": [ "apigateway:*" ], "resource": [ "*" ] } ] } when simulating policy api gateway target, policy denies access. seems direct contradiction provided documentation. amazon's permissions model divides api gateway permissions 2 services: amazon api gateway - permissions clients, action execute-api:invoke . manage - api gateway - admin permissions configuring api gateway, has crud actions fitting apigateway:* spec. the policy have applies manage api gateway service, simulation should work if select that. this same separation visible in regular iam policy wizard, "manage - api gateway" sorts bottom of service list can

javascript - After sending the data to the server, I get the message 'Uncaught TypeError: Illegal invocation' -

i have problem sending ajax request in php-script. my jquery script selects fields form , sends arguments jquery function. but! after sending data server, message 'uncaught typeerror: illegal invocation'. example ajax ... this.createorderbykey = function(optionsdata, customerdata) { $.ajax({ url: 'index.php?route=module/pd_quick_order/createorderbykey', type: 'post', data: {options: optionsdata, customer: customerdata}, async: false, success: function(order) { console.log(order); } }); }; ... example optionsdata variable var productoptions = $('.product-info input[type=\'text\'], .product-info input[type=\'hidden\'], .product-info input[type=\'radio\']:checked, .product-info input[type=\'checkbox\']:checked, .product-info select, .product-info textarea'); console.log(optionsdata) 0: input.quantity 1: input context: document length: 2 prev

spring integration jdbc inbound poller is failing on update query with invalid column type -

we using following config polling db table pick rows , rows picked want update status else not picked again in next poll. here config failing on update query error message caused by: java.sql.sqlexception: invalid column type <int-jdbc:inbound-channel-adapter auto-startup="true" channel="pollingchannel" query="$select id,status test_table status='ready'" data-source="datasource" id="pollingchanneladapter" row-mapper="testrowmapper" update="update test_table set status='picked' id in (:id)" update-per-row="true" > <int:poller default="false" id="poller" max-messages-per-poll="1" fixed-rate="1000"/> </int-jdbc:inbound-channel-adapter> found fix. have use proper property defined in value object parsing select query response using row mapper value object did not had property named &quo

vba - MS Access 2010, Excel 2010, Windows Server 2008 R2 64-bit: SaveAs method of Workbook class failed -

services used: ms access 2010, excel 2010, windows server 2008 r2 (64-bit) in our ms access database, wrote process exports queries .xlsx format , saves them on network drive. uses syntax: objxl.activeworkbook.saveas filename, fileformat:=xlopenxmlworkbook and xlwbk.saveas filename, fileformat:=xlopenxmlworkbook where objxl declared as: private objxl object and files opened via: dim xlwbk object if objxl nothing set objxl = createobject("excel.application") end if if dir(sourcefile) = vbnullstring set xlwbk = objxl.workbooks.add else set xlwbk = objxl.workbooks.open(sourcefile) blnfileexists = true end if this code works fine when run manually. reasonably confident code correct, i'm posting here in case. however, need automate database have run account via scheduled task, set run if account not logged in (and account has admin rights, etc). unfortunately, when running program this, error in our logs: "saveas method of workb

xaml - WinRT - ImageButton for transparent PNGs -

i'm using xaml toolkit imagebutton control able create normal , pressed states button. code is: <toolkit:imagebutton normalstateimagesource="ms-appx:///assets/1_off.png" pressedstateimagesource="ms-appx:///assets/1_on.png" width="500" height="200"> </toolkit:imagebutton> issue i'm facing is, have shape isn't rectangle or square. example have pngs star , arrow object. there way set boundary corresponding shape? if not, please advice best approach handle such scenarios. there 2 options tried when clicking using mouse or touch - you'd check last position of pointer before click , see if image in button has non-transparent pixel @ position. pros: it's simpler option 2. you precise information cons: you can't tell if button got clicked mouse, touch, pen, keyboard or narrator using automation, end filtering out

r - seed object for reproducible results in parallel operation in caret -

i trying use code reproducible parallel models in caret not understand how set size of vectors in seed object. gbm have 4 tuning parameters total of 11 different levels, , have 54 rows in tuning grid. if specify value < 18 last value in "for(i in 1:10)" line below, error: "bad seeds: seed object should list of length 11 10 integer vectors of size 18 , last list element having single integer." why 18? runs without errors values > 18 (e.g., 54) - why? many help. following based on http://topepo.github.io/caret/training.html , added things. library(mlbench) data(sonar) str(sonar[, 1:10]) library(caret) library(doparallel) set.seed(998) intraining <- createdatapartition(sonar$class, p = .75, list = false) training <- sonar[ intraining,] testing <- sonar[-intraining,] grid <- expand.grid(n.trees = seq(50,150,by=50), interaction.depth = seq(1,3,by=1), shrinkage = seq(.09,.11,by=.01),n.minobsinnode=seq(8,10,by=2)) # set seed run reprodu

database - Cannot login to Oracle Enterprise Manager Express -

Image
i have downloaded oracle developer days database 12c virtualbox image. can boot , access desktop. when try log in enterprise manager (em) express using url http://127.0.0.1:8888/em asked install adobe flash. install , login screen. if try login system following error: but when try log in user sys strange error: security token not match. must login again.. to me looks credentials sys ok, there wrong user in database. correct , if how can fix it? or em express not setup on image? this document oracles metalink solves ( https://support.oracle.com/epmos/faces/documentdisplay?_afrloop=185690872522025&id=1968763.1&_afrwindowmode=0&_adf.ctrl-state=16vhefh1mo_9 ). solution contains 3 steps. make sure xdb_wallet recreated succesfully. make sure xdb installed succesfully , appropriate roles, em_express_basic/all applied. use ie 11.0.9600.16476 compatibility view. mark stewards answer covers step 2. actually first 2 step not necessary. looks have

msbuildextensionpack - How do I add files to a specific folder inside the zip with MSBuild ExtensionPack Zip? -

i want copy files 1 project project's published zip (don't ask). i've got <target name="copyfiles" aftertargets="_copywebapplicationlegacy"> <itemgroup> <files include="$(webprojectoutputcontentdir)\*"> </files> </itemgroup> <msbuild.extensionpack.compression.zip taskaction="addfiles" compressfiles="@(files)" zipfilename="$(outdir)\_publishedwebsites\userinterface_package\userinterface.zip" compresspath="\(huge path)\(destination project)\packagetmp" removeroot="\(huge path)\(source project)"/> </target> this dumps zip's root folder, though. need in packagetmp folder. i don't think possible extension itself, copy file correct structure beforehand: <copy sourcefiles="@(files)" destinationfolder="packagetmp\" /> then reference packagetmp\@(files) in compressfiles

ios - position a view in storyboard at 1/3 of screen size -

Image
i'm trying position view in storyboard have top edge @ 1/3 of screen size. have set constraint top layout guide, constraint's constant is...well constant no matter screen size used in, want 1/3 of screen size. can done entirely in storyboard? answers screenshot of current state: create constraint between view's top edge , superview's bottom edge. set constraint's constant zero, , set multiplier 1:3. this:

select - Selecting fields by ordinal_Number, adapting MS-SQL-Code to MySQL -

i need extract fieldnames great number of tables, having same structure unfortunately not same field names. varying. need check ordinal position of fields required, because tables have same order of fields. newbie on mysql. my ms-sql-guru gave me 'blueprint' of procedure want via sys.columns, cannot adapt mysql. want have resulting select statement handover next batch of commands. here have done far: create definer=`root2`@`%` procedure `sp_getcolsfromschema`(in lsid int) begin set @cols=''; set @tbls = concat('mytableprefix_', lsid); select @cols = @cols + column_name + ', ' information_schema.columns table_name = @tbls collate utf8_unicode_ci , table_schema = 'myschema' , ordinal_position in (2 , 4, 5, 7); set @cols = left(@cols, length(@cols)-1); set @str = 'select ' + @cols + ' ' + @tbls +';'; prepare stmt @str; execute stmt; end when calling procedure error 1064 hint "

css - How to fill the white spaces out with divs -

how fill white spaces out divs? i need divs behave each of them fill out white spaces. so, if needed, div goes top, joining div above, this, wherever if use float: left or display: inline-block/inline main { font-size: 0; } main > div { width: 25%; display: inline-block; vertical-align: top; } main > div:nth-child(4n+1) { height: 200px; background: red; } main > div:nth-child(4n+2) { height: 100px; background: blue; } main > div:nth-child(4n+3) { height: 300px; background: orange; } main > div:nth-child(4n+4) { height: 150px; background: darkcyan; } <main> <div></div> <div></div> <div></div> <div></div> <div></div> <div></div> <div></div> <div></div> <div></div> <div></div> <div></div> <div></div> </main>

discretization in R with arules package -

i using arules package discretize continuous variables in data frame. using particular line discretize(data1,categories = 3) but giving me error error in cut.default(x,k2) : k2 must numeric i trying convert continuous variables "data1" data frame 3 bins discrete variables. appreciated...thanks in advance this worked me : data1.disc <- as.data.frame(lapply(data1, function(x) discretize(x, categories=5) ) )

javascript - HTML Textarea will not allow me to type in it when added to DOM after DOM loaded -

Image
i have strange issue have never had before have html textarea element on page added dom after dom loaded within javascript application. the issue cannot cursor go type/select mode inside textarea. it acts if there clear div on top of blocking cursor access textarea! inspecting in chrome dev tools shows nothing on top of textarea though lost cause , solution issue. i created mockup demo here show problem http://bit.ly/1k74vkh on page if click card in last 4th column right of kanban boards open modal window. in modal window can click on reject & move pending validation button open modal on top of textarea not allow text entry. so makes me think might related being added dom after dom loaded my app has modal windows open order database records them. there several different modal windows built why content generated after dom loaded. content created determined on type of order item clicked on. this image below shows textarea in app. have textarea selected in chr

javascript - Node Module Caching -

i creating application using express , ran issue using module.exports. have route handle checking out user creating pdf based on order. keep things modular have been separating route functionality modules , requiring them when necessary, example: route1.js module.exports = function(req, res){ // route functionality }; routes/index.js route1 = require('./route1'); router.post('/api/v1/route1', route1); this has been working great keep things organized, created route lot of complex functionality , there seems issue caching. first time call route works fine, second time call it gets stuck in infinite loop because 1 of variables last request persisting , never breaks out of loop because greater number needs equal loop exit. resetting of variables @ beginning of function passed through module.exports. to fix problem no longer exporting route functionality , instead passing directly route. here example: works everytime router.post('/api/v1/dostuff&#

internet explorer - IE 11 Error: This page can't be displayed. Where as it works fine on Chrome -

i have installed service can accessed http/https protocol locally. address http://127.0.0.1:8081/ when open browser (ie or chrome), both display correctly (no issue) when click login: chrome redirects https://127.0.0.1/login/ shows security error bypass , after works fine. ie 11 redirects http://127.0.0.1:8081/login/ displays 'this page can't displayed'. my work arround: i reset settings. i removed/deleted history, cookies etc. i tried google lot no luck. what think: i think issue ie setting or something, because site running in chrome should run. there might not iis issue. what opinion? any appreciated. thanks i figure out problem. think there might number of reason issue. want put way figure out fix problem might someone. the issue ip address. the pc ip was: 10.0.0.121 and sub net was: 255.255.255.0 i changed sub net to: 255.0.0.0 , issue resolved. thanks happy coding :)