Posts

amazon web services - aws s3 sdk for iOS putObjectRegquest to "new" region not working -

first let me new ios/xcode aws. i creating app writes data aws s3 bucket. app works when creating bucket , putting objects standard region. however, when change region singapore, app creates bucket - but, cannot put objects bucket , aws not produce error or exception of kind. here code in question. commented code in createbucket method creates bucket in singapore. processgrandcentraldispatchupload method works standard region, not put objects singapore bucket. - (void)createbucket { // create bucket. @try { //s3region *region = [[s3region alloc] initwithstringvalue:ks3regionapsoutheast1]; //s3createbucketrequest *createbucketrequest = [[s3createbucketrequest alloc] initwithname:[constants s3bucket] andregion:region]; s3createbucketrequest *createbucketrequest = [[s3createbucketrequest alloc] initwithname:[constants s3bucket]]; s3createbucketresponse *createbucketresponse = [self.s3 createbucket:createbucketrequest]; nslog(@"create bucket response: ...

CSS position absolute and scroll issue -

im working on website template , want make photo on top. used position absolute set top -50px , left -50px. work have 1 issue scroll bar appear on bottom. css div : #moon { background-image:url('img/moon.png'); width:289px; height:289px; position:absolute; top:-150px; left:-160px; overflow:hidden; } give body overflow-x: hidden also notice on small screens there no horizontal scrollbar(!), unless you'll handle responsive css.

sql server - SSIS prevent warnings from propagating -

Image
i've got script running in foreach loop container, inside package's control flow. in script, throwing warning, exiting success dts.events.firewarning(-1, "", "warning message here", "", 0); dts.taskresult = (int)scriptresults.success; i've set system propagate variables false. also tried setting package property disableeventhandlers true. however, duplicate warning messages still being thrown in order of: script foreach loop container package i possibly log each incident information instead of warning... dont want log information. logging warnings more realistic. create onwarning event handler script task. event handler not need tasks of own, need system variable propagate set false.

java - Can I change the implementation class injected by spring in runtime? -

i have class has injected spring on applicationcontext.xml , need change implementation without change applicationcontext.xml. i heard aop "introductioninterceptor" don't found many useful results. anyone can me? ps. sorry bad english, hope give understand. you can in several ways, here few: write xml file, override configuration adding same bean id , implementation class want use, import new xml existing application context. through code, base on need can set new implementation before calling code. there more have used '1' in number of projects. if have multiple beans same id, spring pickup latest one, e.g. <beans> <import resource="a.xml"/> <import resource="b.xml"/> </beans> now if both a.xml , b.xml have bean defined same id, spring use bean defined in b.xml . cheers !!

keyboard - "Listening" for media key press events -

i'm writing application in c++ needs able listen key presses occur in linux, namely media next, media previous, , media play/pause. what apis exist enable me listen keypresses? assume enduser running x, if they're not, there "guaranteed™" way catch media key presses no matter what? i'm bit new writing c++ , relates linux, i'm in no way new linux (just getting used living on bare metal). i not sure extent globally under x using xlib event handlers . sans x, believe require kernelspace component, if really wanted this, might best bet. however, it's not idea. did not trying do, think falls 1 of 2 categories: either want use keys operate app (case a) or want app monitor use of application uses keys (case b). in case a , it's not idea because associating global keystrokes actions domain of window managers/desktop environments (the associations should dynamic, not hard-coded), , when decide make own rules ignoring fact, users , other ...

Error Querying Active Directory Linked Server from SQL Server 2008 R2 -

i'm developing part of application requires sql server 2008 r2 query active directory. i've done far create linked server doing exec sp_addlinkedserver 'adsi_link', 'active directory service interface', 'adsdsoobject', 'adsdatasource' exec sp_configure 'show advanced options',1 go reconfigure go exec sp_configure 'ad hoc distributed queries',1 go reconfigure go doing exec sp_linkedservers shows linked server active directory created. next step users active directory database. doing open query following returns users should no errors or issue whatsoever. basically, works following query. select * openquery (adsi_link, 'select cn, givenname, sn, objectcategory, samaccountname, mail, department, manager, ou, useraccountcontrol, lockouttime ''ldap://dc=domain,dc=local'' objectcategory = ''person'' , objectcategory = ''user'' ...

database - Inserting a Matlab Float Array into postgresql float[] column -

Image
i using jdbc access postgresql database through matlab, , have gotten hung when trying insert array of values rather store array instead of individual values. matlab code i'm using follows: insertcommand = 'insert neuron (classifier_id, threshold, weights, neuron_num) values (?,?,?,?)'; statementobject = dbhandle.preparestatement(insertcommand); statementobject.setobject(1,1); statementobject.setobject(2,output_thresholds(1)); statementobject.setarray(3,dbhandle.createarrayof('"float8"',outputnodes(1,:))); statementobject.setobject(4,1); statementobject.execute; close(statementobject); everything functions except line dealing arrays. object outputnodes <5x23> double matrix, i'm attempting put first <1x23> table. i've tried several different combinations of names , quotes '"float8"' part of createarrayof call, error: ??? java exception occurred: org.postgresql.util.psqlexception: unable find server arr...