Posts

Showing posts from June, 2010

How to Populate the dropdown in angularjs -

i want create 1 dropdown data. here snippet <!doctype html> <html> <head> <script src="scripts/angular.min.js"></script> <title></title> </head> <body> <div data-ng-app="myapp"></div> <div data-ng-controller="programcontroller"></div> program: <select name="" id="program" data-ng-options="program program in programs"> <option value="">selectprogram</option> </select> <script> var myapp = angular.module("myapp", []); myapp.controller("programcontroller", function ($scope) { $scope.programs = ['.net', 'java', 'angular js,'php','c++']; }); </script> </body&g

c# - How do I find PageImagableArea for other papersizes -

im trying fix scaling issue when our application prints on other papersizes a4. there existing method called getprintablearea, returns same values regardless of mediasize is: public size getprintablearea(pagemediasize mediasize) { _printqueue.currentjobsettings.currentprintticket.pagemediasize = mediasize; var capabilities = _printqueue.getprintcapabilities(_printqueue.currentjobsettings.currentprintticket); return new size(capabilities.pageimageablearea.extentwidth, capabilities.pageimageablearea.extentheight); } capabilities.pageimageablearea w/h set same values (761, 1090). , far can see selected printers imageable area a4 (in 1/96" units). how printers pageimageablearea other papersizes example a3?

matplotlib - Unexpected Python TypeError: 'list' object is not callable -

i want draw 2 lines, each works when separated, when draw 2 @ time, there's error: traceback (most recent call last): file "2.py", line 99, in fspe2 = [fspe(t2,x) t2 in t] typeerror: 'list' object not callable full code: # -*- coding: utf-8 -* import numpy np import matplotlib.pyplot plt import matplotlib mpl import math pylab import * c = 2.998*10**10 hp = 6.626*10**-27 hb = 1.055*10**-27 kb = 1.381*10**-16 g = 6.673*10**-8 me = 9.109*10**-28 mp = 1.673*10**-24 q = 4.803*10**-10 sigt = 6.652*10**-25 p = 2.5 r014 = 1 e53 = 1 g42 = 1 delt12 =1 epsbr2 = 1 epser1 = 1 dlg = 1 r0 = r014*10**14 e0 = e53*10**53 g4 = g42*10**2.5 delt0 = delt12*10**12 epser = epser1*0.1 epsbr = epsbr2*0.01 n1 = 1.0 k = 0 dl = dlg*3.086*10**27 n0 = e0/(g4*mp*c**2) sedl = (3*e0/(4*math.pi*n1*mp*c**2))**(1./3) ttw = delt0/c ttn = sedl/(2*c*g4**(3./8)) reta = sedl/g4**(2./3) def gam3(t): if delt0 > sedl/(2*g4**(8./3)): return np.where(t<ttw,(sedl/d

algorithm - What is meant by uniform distribution of hash values in Hashing technique -

in hashing , uniform distribution of hash values mean. please explain in layman's terms using appropriate example. thank you it means if have size of hash-table (say n ), if hashing k values k<n , then: a sequence of outputs function must appear random sequence, if input numbers sequential also, fundamental thing hash function should minimize collisions obviously, @ same time, skewed input, output hash-function should distributed. edit: as asked, here uniform distribution means. say, if size of hash-table n , push k (<n) elements it, then, in every bucket of n/k in hash table, there should element. also, if k=r*c , in every bucket of size n/c in hash table, there should r elements. obviously, perfect uniform distribution not possible...but output distribution should not skewed.

compressing files in JAVA -

my project has requirement have receive file via rest service(using jersey) , store in database. the file size around 2-4mb. the received file can either zip or pdf format. before storing in database compress it. i googled , found there many available classes gzip, zip, deflater... thought of using deflater looked simple.i have written following code zipping. deflater deflater = new deflater(); deflater.setinput(data); bytearrayoutputstream outputstream = new bytearrayoutputstream(data.length); deflater.finish(); byte[] buffer = new byte[1024]; while (!deflater.finished()) { int count = deflater.deflate(buffer); outputstream.write(buffer, 0, count); } outputstream.close(); byte[] output = outputstream.tobytearray(); byte[] output = outputstream.tobytearray(); could 1 please suggest use case if use above code fine or have use other classes perform same. thanks, kitty bytearrayoutputstream caches compressed output in memory. have wrap around fileoutpu

Different values in a JAVA code -

i have code should value it: /* package whatever; // don't place package name! */ import java.util.*; import java.lang.*; import java.io.*; /* name of class has "main" if class public. */ class ideone { public static void main (string[] args) throws java.lang.exception { float a=4, b=8 ; int i=2, j=16 ; double sol1, sol2, sol3, sol4; sol1=(a+2*b/j); sol2=(a/(b-4)+i); sol3=-(b-i/j); sol4=(i*a+j/b); system.out.println(sol1); system.out.println(sol2); system.out.println(sol3); system.out.println(sol4); } } and here java fiddle of solution : 5 3 -8 10 but in sol3, calculated value not -8, -7.875, why takes -8.0. i tried decompose sol3 alone separate execution like in fiddle : /* package whatever; // don't place package name! */ import java.util.*; import java.lang.*; import java.io.*; /* name of class has "main" if class public. */ class ideone

scheduled tasks - Create job report across multiple java classes -

i implementing scheduled job needs create verbose report. report example this: date - started job date - looking stuff process date - got x stuff process date - processing y1 date - done date - processing y2 date - done date - processing y3 date - failed error : this_is_why_processing_failed date - processing completed date - job completed in z seconds the actual code doing processing can in multiple classes. obvious way implement have stringbuilder , pass around messages appended. another more advanced approach create singleton , have id somehow known across classes take part in processing (could thread name?), , store report string there. is there better way this? there best practices creating job reports? the job triggered using ejb timers. instead of passing around stringbuilder should use logger. singleton threadlocal member field place store "token" use classes working same job.

node.js - Protractor - The test running always crashes after some time -

i've 15 scripts inside test cases pull , every full running after 10 passed scripts crashes. don't know reason. the error webdriver log: catch(e) { throw (e instanceof error) ? e : new error(e); }, [body]] 09:07:52.676 info - executing: [find elements: by.cssselector: [ng-click="opensettings()"]]) 09:07:52.704 info - done: [find elements: by.cssselector: [ng-click="opensettings()"]] 09:07:52.719 info - executing: [click: 556 [[chromedriver: chrome on xp (c34b09675c4b68b64f4e311473887133)] -> css selector: [ng-click="opensettings()"]]]) 09:07:52.769 info - done: [click: 556 [[chromedriver: chrome on xp (c34b09675c4b68b64f4e311473887133)] -> css selector: [ng-click="opensettings()"]]] 09:07:52.788 info - executing: [execute async script: try { return (function (rootselector, callback) { var el = document.queryselector(rootselector); try { if (!window.angular) { throw new error('angular not found on window

mysql - php not allowing login -

this question has answer here: php: “notice: undefined variable”, “notice: undefined index”, , “notice: undefined offset” 23 answers i have created log in system when log in email or password incorrect though it's test user , details correct. maybe doesn't match database, have checked on , on again. can't seem find problem. appreciated. php: if(isset($_session['user'])!="") { header("location: index-user.php"); } if(isset($_post['btn-login'])) { $email = mysql_real_escape_string($_post['email']); $upass = mysql_real_escape_string($_post['pass']); $email = trim($email); $upass = trim($upass); $res=mysql_query("select user_id, user_name, user_pass users user_email='$email'"); $row=mysql_fetch_array($res); $count = mysql_num_rows($res); // if uname/pass correct returns must 1

javascript - cannot access property - JS Error Shown -

this question has answer here: how access object properties containing special characters? 1 answer my code access property: var myarray = [{"td_stlmnt":"nn2015227","heading":"nn2015227[02/12/2015]","td_scripcd":"514286","order#":"1000000003042299","trade#":"1124070","time":"14:40:38","security":"ashimasyn (514286)","buy":"250","sell":"0","market rate":"12.90","brokerage":"12.50","buy value":"3237.5000","sell value":".0000","_":"","ordr":"ashimasynb","bdate":"20151202","net value":""},{"td_stlmnt":"nn2015227"

mysql - insert into table only if not exist on other table -

i'm trying following thing: have 2 tables: reportimage (imageid, reportid, counter) , userreportedimages (imageid, userid) i want every user able report image once - means first want check if there row in 'userreportedimages' values (imageid, userid) if nothing, else create row in 'reportimage' values (imageid, reportid, counter), if such row exist (other user reported image) want raise counter. so far before checking same user report had following statement: insert reportimage values (imageid,reportid,1) on duplicate key update counter = counter+1 this statement working fine. i tried change statement first check if row exist on other table, didn't manage it, can me? first, need define unique constraint or compund column primary key on table reportimage , alter table reportimage add contraint tb_uq unique(imageid, reportid) give try, insert reportimage(imageid, reportid, counter) select 'imageid here' im

node.js - Is there a way to upload an image and serve that image using mean.io nodeJS express? -

i have head nodejs not optimal long running operations. overall application based on mean.io (express , nodejs). though node not ideal operation since long running, still use nodejs module uploading image , serving don't have multiple service technologies. don't want switch java or .net operation, because not ideal nodejs task. there reason node not work this? in particular, how can load images folder belonging particular user in mean.io application? thanks user multer . multer body parser express. upload multiple files, user multer.any(). you express code should : var multer = require('multer'); var multerobj= multer({dest : 'local folder dest'}); app.use('/endpoint upload/*',multerobj.any()); //express code app.post('/endpoint upload',function(req,res){ //files cotain file (binary) metadata related files. var files = req.files }

javascript - Show gif while clicking in a key -

hello want make gif appear while m clicking in ctrl key when stop want show image. my code make gif appear when click ctrl if stop gif keeps. code: document.addeventlistener('keydown', function(event) { if(event.keycode == 17) { document.getelementbyid("key").innerhtml = "<img src=\"stick.gif\">"; shoot -= 1; document.getelementbyid("shoot").innerhtml = shoot; } } try this.i have made key-up event replaces gif when key not pressed.you can make react ctrl key well.i have added 2 id tags elements, since had not attached html elements. as comment above mentioned, you need keyup function handle event when key not pressed. <script>document.addeventlistener('keydown', function(event) { console.log("event"); if(event.keycode == 17) { console.log("key pressed"); document.getelementbyid("key").innerhtml = "<img src=\"stick.gif\">"; shoot -= 1

gd - How to create an image in php with justified text -

Image
i want create image contains text letter spacing adapted text stretch within given space. goal split text in lines of max x millimeters , justify (increase letter spacing) text. here example of current output: this how should look: here current code: function imagestringwrap($image, $font, $x, $y, $text, $color, $maxwidth, $textcolor) { $fontwidth = imagefontwidth($font); $fontheight = imagefontheight($font); if ($maxwidth != null) { $maxcharsperline = floor($maxwidth / $fontwidth); $text = wordwrap($text, $maxcharsperline, "\n", 1); } $lines = explode("\n", $text); while (list($numl, $line) = each($lines)) { $fontfile = imageloadfont('app_global/ttf/verdana.ttf'); imagestring($image, 14, $x, $y, $line, $color); #imagettftext ($image, 14 , 0, $x , $y , $color , $fontfile , $line ); $y += $fontheight; } $hight = 20*count($lines); imageline ($image , 10

soapui - Is it possible getting id's from one project to another by using Test Runner -

i have 2 projects.i running these projects 1 one using test runner(project level).is there way passing id's project1 project2. thanks, arivazhagan try testrunner.testcase.testsuite.project.setpropertyvalue("name",value) and different project testrunner.testcase.testsuite.project.workspace.getprojectbyname("projectname").getpropertyvalue("name")

I want to host a wcf web service created in vb.Net on Microsoft azure -

i have web service, created in vb.net , want host webservice on microsoft azure. can me ? new azure. you have @ least few options here: the straightforward , old school - create vm , host on local server. create cloud service easier , scalability , disaster recovery out of box, requires bit of learning path on azure sdk. invest in service fabric , host reliable stateful service - again it's learning path, winning here in terms technology go forward, whereas option 2 deprecated soon.

java - this.getClass().getClassLoader().getResourceAsStream()is not working in RCP product -

this.getclass().getclassloader().getresourceasstream(image_url) working when trying run rcp application eclipse. but, when running product, not running. this.getclass().getclassloader().getresourceasstream() returns `null´. clue how solve this? note: have tried solve using activator.getdefault().getbundle() . not working. seems activator.getdefault() = null means plugin not actiavted. tried put break point there. indeed plugin variable in null in activator. what should do? use filelocator : bundle bundle = frameworkutil.getbundle(getclass()); inputstream = filelocator.openstream(bundle, new path("relative path"), false); other methods of filelocator give url instead of stream.

python - Difference between list comprehension and generator comprehension with `yield` inside -

what difference between list comprehensions , generator comprehensions yield inside? both return generator object ( listcomp , genexpr respectively), upon full evaluation latter adds seem rather superfluous none s. >>> list([(yield a) in zip("abcde", itertools.cycle("12"))]) ['a', '1', 'b', '2', 'c', '1', 'd', '2', 'e', '1'] >>> list(((yield a) in zip("abcde", itertools.cycle("12")))) ['a', '1', none, 'b', '2', none, 'c', '1', none, 'd', '2', none, 'e', '1', none] how come? scientific explanation? the value of yield from expression none . fact second example generator expression means implicitly yielding iterator, yield value of yield from expression. see this more detailed answer.

c++ - Why can't I change address of a pointer of type `const int *` when passed as function argument? -

as far know, const int * implies can change pointer not data, int * const says can't change pointer address can change data, , const int * const states can't change of them. however, can't change address of pointer defined type const int * . here example code: void func(const int * pint) { static int int = 0; pint = &int; int++; } int wmain(int argc, wchar_t *argv[]) { int dummy = 0; const int * pint = &dummy; //const int * pint = nullptr; // gives error when try pass func(). std::cout << pint << '\t' << *pint << std::endl; std::cout << "-------------------" << std::endl; (int i=0; i<5; i++) { func(pint); // set pointer internal variable. (but, doesn't set it!) std::cout << pint << '\t' << *pint << std::endl; } return 0; } code output: 00d2f9c4 0 ------------------- 00d2f9c4

Where do I find project templates for asp.net core 1.0 rc2? -

the project templates available in visual studio 2015 asp.net depend on rc1. some digging led me list of changes between rc1 , rc2 , showed me there's been renaming (webapplication webhost), number of other breaking changes there suggest that, since i've started, it'd easier start on updated project template. except can't find one. are updated project templates available? find them?

c# - Get Sample SOAP request programmatically -

i'm writing tool users make use of asmx webservice, , i'd show users sample soap requests various methods. if have asmx webservice asp.net automatically generates page each method displays sample soap request , response. can see example here . clearly, system.web.services.webservice generates sample somewhere, don't know where. how can hold of soap samples programmatically can use them elsewhere?

sprite kit - How to interpret this Swift SpriteKit example code of a physics body bitmask system -

i taking deep apples spritekit & gameplaykit example code , found project called 'demobots' written in swift. there interesting concepts used in projects wanted adapt projects. i working encapsulating collision-handling handler-class similar way collisions handled in example code. in project found following code struct called rpcollidertype : struct rpcollidertype: optionsettype, hashable, customdebugstringconvertible { // mark: static properties /// dictionary specify `collidertype`s should notified of contacts other `collidertype`s. static var requestedcontactnotifications = [rpcollidertype: [rpcollidertype]]() /// dictionary of `collidertype`s should collide other `collidertype`s. static var definedcollisions = [rpcollidertype: [rpcollidertype]]() // mark: properties let rawvalue: uint32 // mark: options static var obstacle: rpcollidertype { return self.init(rawvalue: 1 << 0) } static var playerbot: rpcollide

javascript - Make a loop in jquery -

Image
hello want know how make loop js through id because have email id 2 fields 2 different forms able choose when click on id of form right displays error on right form , vice versa my code : <script type="text/javascript"> $(document).ready(function(){ $("input#id_st-courriel").focusout(checkemailfield); }); function checkemailfield() { $fieldvalue = $("input#id_st-courriel").val(); $.ajax({ url: '/ajax/checkemailfield', data: ({ value: $fieldvalue }), type: 'get', success: function($data, $textstatus, $xmlhttprequest) { if ($data != '') { $("input#id_st-courriel").parent().prev('errorlist').remove(); $("input#id_st-courriel").parent().before($data); } } }) } </script> i ha

android - how to get facebook game request url? -

we using facebook unity sdk game requests on android. when clicks game request in facebook notifications they switch game or app store page (if it's not installed) when game runs, call fb.getapplink(deeplinkcallback) however, receive empty url. anyone knows how achieve ? thanks. full code: void afterinit(){ fb.getapplink(deeplinkcallback); } void deeplinkcallback(iapplinkresult result) { debug.log("app url = "+result.url); } update: sorry posting same code. have question you. is app life in store , linked facebook developer profile correctly? if in test mode can fail. however believe id need send in-app invites app id facebook developer profile. (check image) facebook developer profile the example code in-app invites this fb.mobile.appinvite( new uri("https: // fb. me/810530068992919"), //the id new uri("http://i.imgur.com/zkylb.jpg"), // optional image appinvitecallb

mysql - create stored procedure for multiple update queries -

select id ids challenges expire_date > today i need loop multiply ids (foreach in php) foreach (ids) update challenges set status = 'expired' id = ids update user_challenge set challenge_status = 'expired' challenge_status = 'pending' , challenge_id = ids update user_challenge set challenge_status = 'failed' challenge_status = 'accepted' , challenge_id = ids end each; can please create stored procedure or single query perform this, thanks your single update query in mysql might this update user_challenge u inner join challenges c on u.challenge_id = c.id set c.status = 'expired', u.challenge_status = case when u.challenge_status = 'pending' 'expired' when u.challenge_status = 'accepted' 'failed' end c.expire_date < curdate() here sqlfiddle example i believe condition expiration make sense should expire_date

machine learning - Vector Quantization Algorithms used to provide observation sequences for Hidden Markov Models -

i building gesture recognition application. extracting features hand (such [angle of motion, width: length ratio,...]). feature vector. obviously, 1 cannot have observation of such vectors input hidden markov model. general info: gesture made of set of postures. thus found paper suggests vector quantization. aim use sort of algorithm feed feature vector 1 side, , obtain integer or simple value (which maps particular state/posture). feed these set of symbols (mapping complete gesture) hidden markov model ( one algorithm k means clustering. unfortunately, if example recognize x amount of symbols, , decided go creating cluster each symbol, k means creates maximum of x clusters, cannot used map each state/posture have. i thinking need sort of clustering algorithm, if possible, can supervised dictate these sets of feature vectors map posture , others map posture b. does there exist form of supervised clustering/ classification algorithm input set of vectors [angle, width, hei

algorithm - Finding parameters of exponentially decaying sinusoids (Matrix Pencil Method) -

the matrix pencil method algorithm can used find individual exponential decaying sinusoids' parameters (frequency, amplitude, decay factor , initial phase) in signal consisting of multiple such signals added. trying implement algorithm. algorithm can found in paper link: http://ieeexplore.ieee.org/xpls/abs_all.jsp?arnumber=370583 or http://krein.unica.it/~cornelis/private/ieee/ieeeantennaspropagmag_37_48.pdf in order test algorithm, created synthetic signal composed of 4 exponentially decaying sinusoids generated follows: fs=2205; t=0:1/fs:249/fs; f(1)=80; f(2)=120; f(3)=250; f(4)=560; a(1)=.4; a(2)=1; a(3)=0.89; a(4)=.65; d(1)=70; d(2)=50; d(3)=90; d(4)=80; i=1:4 x(i,:)=a(i)*exp(-d(i)*t).*cos(2*pi*f(i)*t); end y=x(1,:)+x(2,:)+x(3,:)+x(4,:); i feed signal algorithm described in paper follows: function [f d] = mpencil(y) %construct hankel matrix n = size(y,2); l1 = ceil(1/3 * n); l2 = floor(2/3 * n); l = ceil((l1 + l2) / 2); fs=2205; i=1:1:(n-l) y(i,:)=y(i:(

python - How can open new tkinter window by threading? -

i want open splash window using threading , show loading files page. write simple code open new window , close after 1 second: import tkinter tk threading import thread thread import time class t(): def det(self): self.x = tk.tk() self.x.mainloop() def det2(self): self.x.destroy() k = t() ts = thread(target=k.det, args=()) ts.start() time.sleep(1) k.det2() when try run, steps ok code never finished! in self.x.destroy() hanged. why happed? for simple don't need threading, use after function: import tkinter tk root = tk.tk() root.after(1000, root.destroy) root.mainloop()

Random image with javascript -

without knowing javascript @ somehow created random image generator: <script language="javascript"><!-- document.write("<img src=\"image-"+math.floor(math.random()*12+1)+".jpg\" />"); //--></script> i show random images should there limitations need help. sometimes have more 9 images pages , name "mad-01", "mad-02"... "mad-11" keep them sorted code above can't show images 0 before second digit. have named images , without 0 before second digit: "mad-01", "calm-1". how can solved? or better remove 0 images? is there way make code way won't need keep writing how many images there show? i have code shortest possible that's why i'm not using array. i removing 0 file names easiest solution. depends on whether need or not. not sure mean here. javascript can't detect how many images there in file system on own. if you're using kin

ios - Mutate inout function paramter inside async block -

i have following playground code: import uikit import xcplayground class { var arr : [uiimage] = [] func additem(inout localarr: [uiimage]) { dispatch_after(dispatch_time(dispatch_time_now, (int64)(2 * nsec_per_sec)), dispatch_get_main_queue()) { () -> void in localarr.append(uiimage()) print("from inside function localarr: \(localarr)") print("form inside function: \(self.arr)") } } } let = a() a.additem(&a.arr) print("instant print :\(a.arr)") dispatch_after(dispatch_time(dispatch_time_now, (int64)(3 * nsec_per_sec)), dispatch_get_main_queue()) { () -> void in print("print after delay: \(a.arr)") } xcplaygroundpage.currentpage.needsindefiniteexecution = true the output is: instant print :[] inside function localarr: [<uiimage: 0x7f99e8706f10>, {0, 0}] form inside function: [] print after delay: [] my question is, why localarr not same self.arr

javascript - Hide <td> when i click the print button -

now have print button.when click print button hide existing column content , show content.each column having different contents. code <button class="btn" id="print"><i class="icon-print"></i> print</button> <div id="drop1" > <td><?php echo $detail->remarks;?></td> </div> <div id="drop2" > <td> <a href="#view_popup_descriptive_index" class="btn green" title="reason" data-toggle="modal" title="reason">reason <input name="app_id" id="appid" class="appid" type="hidden" value="<?php echo $detail->remarks;?>"/> </a> </td> </div> script $("#print").on('click', function(){ document.getelementbyid('drop2').style.display = "none"; document.getelementbyid('drop1'

scala - match for types failed on Map -

i'm learning scala , trying write simple code. when tried write method this: def func(value: any) { value match { case i: int => println(1) case vector: vector[any] => println(2) case map: map[any, any] => println(3) case _ => println(4) } } i got warn: [warn]........:31: non-variable type argument in type pattern scala.collection.immutable.map[any,any] (the underlying of map[any,any]) unchecked since eliminated erasure [warn] case map: map[any, any] => println(3) [warn] ^ [warn] 1 warning found i wondering why using map[any, any] warn vector[any] not. the problem map[x, y] not covariant in type parameter x (but vector[x] is). what mean? suppose b <: a (read, b subtype of a ). then have vector[b] <: vector[a] . makes sense: if retrieve element x vector[b] , b . means a subtyping relationship. (a similar argument applies other methods.) following similar reasoning, map[x, b] <:

ms access - Search for text with specific length and no spaces -

i learning access (2010) , trying set criteria query brings names length 10 letters , there no spaces. i tried len([name])="10" , returns names length of 10, includes names space in it. the hint given was: use wildcards * , ?, , phrases , not like" however not enough me sort out. what criteria solve this? for else looking solve sort of issue, try this: select communication.communicationcode, communication.communicationname communication len([communicationcode])=10 , communicationname not "* *" you need remove quotes 10 .

How do I make yeoman reload bla.html instead of index.html -

when change made html file in root, yeoman fires reload task, but, yeoman http://localhost:3501/index.html . how let yeoman know wanna reload http://localhost:3501/bla.html ? maybe gruntgile.js configurations? yeoman 1.0 no problems, it's pretty easy install. here quick guide: make sure have node installed npm uninstall old version of grunt install requirements npm this: npm install -g yo grunt-cli bower you have need, can run yo confirm have correct version installed. there lot less dependencies, moved per-project-basic. you can read lot more on website here http://yeoman.io make sure read migration guide. note: wiki says not work on windows, not case anymore, run windows 7 , works charm.

java - Create a cake divided in 4 buttons in android studio -

i not able create cake divided in 4 buttons shown in attached photo . i've got png image, start center circle align center without problems, i'm not able align 4 buttons project remain aligned. hope understand want do; english poor. thank much i'm using android studio , i'm programming in java create android application. try relativelayout, it's more easy align stuff this.

Need Oracle sql query for grouping the date -

i have table date 02/11/2015 01/12/2015. eg... attndate -------- 02/11/2015 03/11/2015 -- -- -- 01/12/2015. this table may have missing dates also.. lets assume 06/11/2015 , 20/11/2015 missing table. i want output like sl.no attnfrom attntill 1. 02/11/2015 05/11/2015 2. 07/11/2015 19/11/2015 3. 21/11/2015 01/12/2015 kindly me output in oracle plsql you can lead , lag analytic functions - in subquery group over, may missed - can analytic 'trick'. if @ difference between each date , lowest date broken sequence, in case 0, 1, 2, 3, 5, ..., 27, 28, 29. can see attndate - min(attndate) on () . you have unbroken sequence available row_number() on (order attndate) , gives 1, 2, 3, ... 28. if subtract 1 other each contiguous block of dates gets same answer, i've called 'slot_no': select attndate, attndate - min(attndate) on () - row_number() on (order attndate) slot_no your_tabl

opencv3.0 - OpenCV 3.0 Python, stitch and blend 2 images given Homography -

i have computed homography between 2 images. can stitch them fine i.e. can choose image show on overlapped region. doing manually (pixel pixel) , time consuming. is there built-in function it? plus, want blend well, want blend in overlap region. though quite late i'll answer question other people might stumble post can use addweighted function of opencv. documentation provided here @ addweighted documentation . function combines 2 images linearly proportion being set alpha , beta(1 - alpha) shown below : ires = alpha * i1 + (1-alpha) * i2; the code same shown below : cv2.addweighted(orig1, alpha, orig2, (1- alpha), 0, output); here orig1 , orig2 images blended.

How to check maximum core count,Storage account count in azure resource manager portal using powershell -

Image
i have check maximum core count , storage count in azure arm using powershell. when give command (get-azurermsubscription -current -extendeddetails).maxstorageaccounts shows error "get-azurermsubscription : parameter cannot found matches parameter name 'current'." please let me know how count. in advance. use get-azurermstorageusage current usage , limits. use get-azurermvmusage -location yourlocation core usage , limits.

c# - Server not picking up information from database and passing it to client -

i trying server sso logged in user (web) , pass as3 client. if set specific sso in client (bellow) server picks user database. currently error: error 1: have invalid sso ticket. please re-login , reload. package { import com.archicruise.external.roommanager; import com.archicruise.server.connection; import flash.display.bitmap; import flash.display.bitmapdata; import flash.display.loaderinfo; import flash.display.sprite; import flash.events.event; import flash.system.security; import flash.system.system; public class main extends sprite { [embed(source = '../assets/client_back.png')] private static const clientbackimage:class; public static var site_url:string = "http://localhost/archicruise/"; public var roomloader:roommanager; private var connection:connection; public function main():void { if (stage) init(); else addeventlistener(even