Posts

Showing posts from February, 2013

java.lang.ClassCastException: android.widget.AbsListView$LayoutParams cannot be cast to android.widget.LinearLayout$LayoutParams -

i trying put message n date below in same bubble messeage textview. used layoutparams make bubble left or right. but i'm getting error. fatal exception: main process: com.rana.sahaj.myyu, pid: 18103 java.lang.classcastexception: android.widget.abslistview$layoutparams cannot cast android.widget.linearlayout$layoutparams @ com.rana.sahaj.myyu.singlemessageroomactivity$messagesadapter.getview(singlemessageroomactivity.java:326) @ android.widget.abslistview.obtainview(abslistview.java:2257) @ android.widget.listview.makeandaddview(listview.java:1790) @ android.widget.listview.filldown(listview.java:691)

Python in ArcGIS - Lookup values in a dictionary and print corresponding value into a new field -

i new python , have been trying days work write function decodes field in attribute table , adds corresponding value (from dictionary below) blank field. (similar vlookup in excel). example when 'e1' shows in attribute table 'e' in dictionary, find corresponding value in dictionary , print list , '1' , print same list (blank field has been added attribute table). add list blank field in attribute table. your data structure not friend @ point. you have information stacked in nested dictionary structure, better off decoding first: #!python3 import collections import itertools luc_dict = { 'estu':'estuaries', 'ice':'ice', 'lake':'lake', 'quar':'quarries/mines', 'rive':'river', 'town':'town/urban', 'class':{'1':'arable (1)', '2':'arable (2)', '3':'arable (3)',

d3.js - d3 units formatting SI with rounding (nvd3 charts) -

i using si units formatting axis using code below. way if value goes 1000 represented 1k, 2.4k etc. d3.format('s') problem cases displaying 13.47899999999k. how can use si units along rounding off 2 decimal places? you can try d3.format(".2s")

c - Why this weird behaviour of memory allocation -

this interesting code allocates 3 gb memory in linux systems if physical ram less 3 gb. how? (i have 2.7 gb ram in system , code allocated 3.054 mb memory!) #include <stdio.h> #include <string.h> #include <stdlib.h> int main(int argc, char *argv[]) { void *ptr; int n = 0; while (1) { // allocate in 1 mb chunks ptr = malloc(0x100000); // stop when can't allocate more if (ptr == null) break; n++; } // how did get? printf("malloced %d mb\n", n); pause(); } by default in linux, don't ram until try modify it. might try modifying program follows , see if dies sooner: #include <stdio.h> #include <string.h> #include <stdlib.h> int main(int argc, char *argv[]) { char *ptr; int n = 0; while (1) { // allocate in 4kb chunks ptr = malloc(0x1000

scroll - Trouble with jquery scrollTop function -

i'm trying follow dry principle changing bunch of repeated functions, i'm stuck here. want change scroll function repeated 4 times different classes , ids more generic way (i'm using jquery ): $('.empresa').click(function(event){ $('html, body').animate({ scrolltop: $("#empresa").offset().top }, 500); return false; }); $('.nosotros').click(function(event){ $('html, body').animate({ scrolltop: $("#nosotros").offset().top }, 500); return false; }); the classes elements of navigation within ul looks this. <ul class="nav"> <li><a href="index#nosotros" class="nosotros">link anchor</a></li> <li><a href="index#empresa" class="empresa">link anchor</a></li> </ul> and scroll tags div elements tags. <div class="some-random-class" id="emp

php - What does this get_text function do? -

panique did great job answering question on thread: php directory list remote server but created function don't understand @ , hoping sort of explanation. example, what's random 8192 number? function get_text($filename) { $fp_load = fopen("$filename", "rb"); if ( $fp_load ) { while ( !feof($fp_load) ) { $content .= fgets($fp_load, 8192); } fclose($fp_load); return $content; } } it loads file path in $filename , returns it's content. 8192 not random. means read file in chunks of 8kb . the while loop runs long file wasn't entirely read. each iteration adds latest 8kb of file $content returned @ end of function.

possible mistake/bug in Stanford CoreNLP and/or NLP parse visualization -

Image
don't think wrong tag 'me meal on flight ua 386 san francisco denver' in sentence 'show me meal on flight ua 386 san francisco denver' s? image created using nlp parse visualization available @ http://nlpviz.bpodgursky.com/ the stanford parser worse @ imperatives on other sentences. simple parse error, inherent in fact these imperfect models. the dependency parser seems mess on sentence; suspect it's hard sentence.

install - Instal Deap for Python (Spyder) -

how should instal deap package python spyder? i have tried: pip instal deal, import deap, deap.download() assuming deap not installed, type: pip install deap if response collecting deap installing collected packages: deap installed deap-1.0.2 then have installed deap , ready import projects. if response, requirement satisfied (use --upgrade upgrade): deap in ./path/to/site-packages , deap installed , ready import it.

HTML Signature in Gmail using media queries for show/hide container? -

based research, gmail , other email clients doesn't support media queries can't simple conditional show , hide of container. i have 2 designs. 1 desktop email signature , other 1 mobile devices. there other ways on how implement responsive html email signatures in gmail browser/mobile app? thanks.

javascript - Chrome Extension Storing Custom Object Type Strips Prototype Methods -

i have created custom object using in extension. when save objects of type group (my object type) , later pull objects out of storage, appears prototype methods no longer present. read in documentation objects serialize down object literals {} , can't seem figure out how keep methods objects. have provided code of group class below. when try , use 1 of methods file below on object retrieved storage, error function not exist. used in loop loop through of properties , object has name , urls property. appreciated! group.js: // create group class var group = function (name, urls) { this.name = name; this.urls = urls; }; // clears urls group group.prototype.clearurls = function () { this.urls = []; }; // adds specified url group group.prototype.addurl = function (url) { this.urls.append(url); }; // removes specified url group group.prototype.removeurl = function (url) { this.urls = this.urls.filter(function(_url){ return url !== _url; }); }; // renames group

python - TypeError: object takes no parameters -

i'm trying create code utilizes __iter__() method generator, getting error saying: typeerror: object() takes no parameters. additionally, unsure whether yield function should called within try: or within main() function i new python , coding, suggestions , advice appreciated can learn. thanks! class counter(object): def __init__(self, filename, characters): self._characters = characters self.index = -1 self.list = [] f = open(filename, 'r') word in f.read().split(): n = word.strip('!?.,;:()$%') n_r = n.rstrip() if len(n) == self._characters: self.list.append(n) def __iter(self): return self def next(self): try: self.index += 1 yield self.list[self.index] except indexerror: raise stopiteration f.close() if __name__ == "__main__": word in counter(

java - JScrollPane isn't visible -

the scroll pane isn't visible here. know problem setlayout(null) . can write instead of this? labelsend.addmouselistener(new mouseadapter(){ public void mouseclicked(mouseevent e3){ framelogin.setvisible(false); jframe framesend = new jframe(); framesend.setsize(500,500); jpanel panelsend = new jpanel(); panelsend.setlayout(null); jlabel labelsendname = new jlabel("name: "); labelsendname.setbounds(20,20,50,10); panelsend.add(labelsendname); jtextfield textsendname = new jtextfield(); textsendname.setbounds(60, 15, 400, 18); panelsend.add(textsendname); jlabel labelmessagesend = new jlabel("message: "); labelmessagesend.setbounds(1,50,80,14); panelsend.add(labelmessagesend); jtextarea textmessagesend = new jtextarea(5,10); textmessagesend.setbounds(60,50,400,300); jscrollpane scrollsend = new jscrollpane(textm

Yii2 URLs with published year, month, and slug -

i creating blog using yii2 have post urls year, month, , slug of post. have slug working validate against not sure how tell sluggable behavior take year , month consideration when generating unique slugs. in post table have slug (based on post title) , published_at datetime. have following setup retrieves given post based on year, month, , slug. the urlmanager has '/<year:\d{4}>/<month:\d{2}>/<slug>' => 'post/view', , in controller following: public function actionview($year, $month, $slug) { $model = $this->findmodel($year, $month, $slug); return $this->render('view', [ 'model' => $model, ]); } ... protected function findmodel($year, $month, $slug) { $model = post::find() ->where(['slug' => $slug]) ->andwhere(['from_unixtime(publish_at, "%m")' => $month]) ->andwhere(['from_unixtime(publish_at, "%y")' =>

php - Unable to extract data from Database and convert it into Json data -

i trying extract data database , convert json data. i have table id, image , name , price of product. want convert these data json , extract them website. <?php //config file used connect php db include_once('config.php'); // images table name $sql= "select * `images` "; $res= mysql_query($sql); $result = array(); while ($row = mysql_fetch_array($res)) //image stored longbob, name varchar , price int array_push($result, array('id'=> $row[0], 'image' = > $row[1], 'name'=> $row[2], 'price'=> $row[3] )) echo json_encode(array()); ?> you don't need array_push. continue array , this: <?php //config file used connect php db include_once('config.php'); // images table name $sql= "select * `images` "; $res= mysql_query($sql); $result=array(); while (($row = mysql_fetch_array($res))!==

Decode base64_encode Image from JSON in Swift -

i have mysql database contains images. receive data php file: php: $result[$key]['image'] = based64_encode($resultarray[$key]['image']); now json file, this: json: {"image":"\/9j\/4q\/+rxhpzgaatu0akgaaaagacgepaaiaaaagaaaahgeqaaiaaaakaaaajaesaamaaaabaayaaaeaaauaaaabaaaalgebaauaaaabaaaangeoaamaaaabaaiaae... i have swift project , want decode image uiimage, far have no idea how decode image. have following. swift: alamofire.request(.get, url).responsejson { (response) -> void in if let json = response.result.value as? [[string : anyobject]]{ json in json{ json let encodedimage = json["image"] let imagedata = nsdata(base64encodedstring: encodedimage) } } how can decode image can display it? you have cast dictionary value anyobject string. have decode string data using .ignoreunknowncharacters option. try this if let encodedima

Python: create a list of lists -

i have 2 list l1= ["apple", "orange"] l2 = ["red", green", "black", "blue"] i want create list appends both. l3 = [["apple", "orange"], ["red", green", "black", "blue"]]. so l3[0] =["apple", "orange"] , l3[1]=["red", green", "black", "blue"] . how do above? just put references in. l3 = [l1, l2] note that, if this, modifying l1 or l2 produce same changes in l3 . if don't want happen, use copy: l3 = [l1[:], l2[:]] this work shallow lists. if nested, you're better off using deepcopy : import copy l3 = [copy.deepcopy(l1), copy.deepcopy(l2)]

angularjs - Saving $stateParams while refreshing a $state - UI-Router -

i'm using ui-router , have few stateparams in state, while refresh page stateparams going undefined. how can maintain stateparam when refresh. you should store parameter state inside of localstorage. cache.$inject = ['$localstorage', '$cookiestore', 'config', 'constant']; export function cache($localstorage, $cookiestore, config: iappconfig, constant) { return { storestate: function (state) { $localstorage.state = state; } } } this sample code written typescript.

javascript - Get widest element in a jQuery set -

let's have bunch of <span> elements different text content. how can widest <span> ? jquery fine. care identifying span, not value of width itself. a similar question here . value of width. here's how i'd start: $('span').each(function(id, value){ if ($(this).width() > w) { largestspan = id; } }); var maxwidth = 0; var widestspan = null; var $element; $("span").each(function(){ $element = $(this); if($element.width() > maxwidth){ maxwidth = $element.width(); widestspan = $element; } });

java - Does @Transient field value get loaded? -

i know @transient field value not persisted in database. field value loaded table when entity created query? (the field exists in table) @transient @column (name = "zipcode") integer zipcode; no, @transient totally ignored either in storing or loading database

How to dynamically load scripts in jQuery Mobile -

i developing mobile application using jquery mobile running on top of phonegap. facing issue using google places api+jquery ui maps. problem need load google maps api script when loading particular page. seems scripts loaded @ first dom load in jquery mobile. issue have ask user turn on data on mobile because otherwise javascript error thrown jquery ui maps script. is there way can dynamically load google maps api script when loading particular page in jquery mobile? edit: i have jquery ui maps related javascript files load well, complication arises. appreciate help.. edit: adding code example; <div data-role="page" id="showinfopage" data-theme="a" data-close-btn="right"> <div data-role="header" data-theme="d"> <h1>information</h1> </div>

css - Linear gradient in safari not working -

linear gradient background property not working in safari browser.i tried -webkit- prefix no result. what's wrong? here code: html: <header> <div class="container"> <div class="logo"> <img src="images/logo.png" alt=""/> </div> </div> </header> css: .container{max-width:1550px;margin:0 auto;border:1px solid red;} .clear{clear:both;} header{width:100%;float:left;position:relative;background:linear-gradient(to right, #e9eae2 0%,#e9eae2 59%,#7acec3 59%,#7acec3 100%);background:-webkit-linear-gradient(to right,#e9eae2 0%,#e9eae2 59%,#e9eae2 59%,#e9eae2 100%);} .logo{float:left;} try using prefixes linear-gradient: background: -moz-linear-gradient(0deg, #e9eae2 0%, #e9eae2 59%, #7acec3 59%, #7acec3 100%);/* ff3.6+ */ background: -webkit-gradient(linear, 0deg, color-stop(0%, #e9eae2), color-stop(59%, #e9eae2), color-stop(59%, #7acec3), color-stop(100%, #7ac

video - How to play a .ts file in iPhone? -

i want play .ts file in iphone, i have been trying copy itunes not allowing copy itunes movies, converted .mp4 , tried again, copied. so converted file working file should not converted. i sent through mail , tried download it, showing "these types of attachment cant accessed on device." does iphone supports file type or not?

android - I use DownloadManager.ACTION_DOWNLOAD_COMPLETE but occur ActivityNotFoundException -

i want apk in server, after install apk on android but when install apk shows activitynotfoundexception. perhaps, permission problem? <uses-permission android:name="android.permission.internet"/> <uses-permission android:name="android.permission.write_external_storage"/> thanks please advice me this source public class mainactivity extends appcompatactivity { @override protected void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); setcontentview(r.layout.activity_main); button btn = (button) findviewbyid(r.id.btn); btn.setonclicklistener(new view.onclicklistener() { @override public void onclick(view view) { string url = "myserver/apk"; file apkfile = new file("/sdcard/download/openapk.apk"); uri muri = uri.parse(url); downloadmanager.request r = new downloadmanager.request(muri);

powershell - How do I create Subnet in existing Vnet -

i using classic portal , have vnet "rgvnet" configured 10.0.0.0/16 subnet :- 10.0.0.0/24 configured. i want add new subnet in same vnet without using get-azurevnetconfig -exporttofile c:\networkconfig.xml . is there other way add subnet in classic portal add in rm vnet? appreciate assistance. :) you not need exporttofile create subnet in vnet: new-azurermvirtualnetwork -resourcegroupname testrg -name rgvnet` -addressprefix 10.0.0.0/16 -location centralus $vnet = get-azurermvirtualnetwork -resourcegroupname testrg -name testvnet add-azurermvirtualnetworksubnetconfig -name frontend ` -virtualnetwork $vnet -addressprefix 10.0.0.0/24 add-azurermvirtualnetworksubnetconfig -name backend ` -virtualnetwork $vnet -addressprefix 10.0.1.0/24 set-azurermvirtualnetwork -virtualnetwork $vnet the last step applies configuration. msdn virtual-networks-create-vnet-arm-ps

Rails missing route -

so have website class. creating login website, start "rails generate scaffold user name:string password:digest --no-test-framework" create model. ran "rake db:migrate" create database. i ran rails server , opened chrome check webpage out entering url "localhost:3xxx/users/new" , routing error says "no route matches [get] "/users/new" i did "rake routes" check out , correct, there no route "/users/new". when ran generate scaffold noticed did created route not showing up! missing something? nevermind, manually added "user/new" => "users#new" routes.rb file , worked! i'm new rails , whenever use generate scaffold never problem. if knows how or why route wasn't added when used generate scaffold, please let me know future reference, thanks!

c# - "Cannot find central directory" error appears when extracting 7z file using SharpZipLib -

there no problem .zip file 7z. filestream fs = file.openread(archivefilenamein); zf = new zipfile(fs); // encountered error the zipfile class handles .zip files, not .7z files. in fact, sharpziplib not support .7z files @ all . a "central directory" list of files present in zip-file , they're located, used speedily extract 1 file or file listing without reading whole file.

javascript - which one should be used in case of jquery ajax call, success/ error callback or done()/fail() chain function -

sometimes if ajax call has returned error, calls done() chain function rather fail(). confused whether use success/error callback or done()/fail() chain function. for eg 1 advisable 1 or 2? $.ajax({ url: someurl, success: function(){ //some code if ajax request successful }, error: function(){ //some code if ajax request fails } }) $.ajax({ url: someurl }).done(function(){ //some code changes }).fail(function(){ //some code changes }); these interchangeable ways of doing ajax call in jquery. second method describe uses promises, whereas first method handles successes/errors options on ajax call.

ios - Could not cast value of type '__NSDictionaryM' to 'NSArray" -

this question has answer here: swift json error : not cast value of type '__nsdictionarym' 'nsarray' 2 answers this part of code: let quotesdata = try nsjsonserialization.jsonobjectwithdata(data!, options: .mutablecontainers) as! nsdictionary var quotedictionary: [nsdictionary]! quotedictionary = quotesdata["response"] as! [nsdictionary] this part of json tumblr api: { "meta": { "status": 200, "msg": "ok" }, "response": { "blog": { "title": "a sea of quotes", "name": "aseaofquotes", "total_posts": 10089, "posts": 10089, "url": "http://www.aseaofquotes.com/", "updated": 1461556819, "description": "", "is_nsfw": false, "ask&qu

javascript - how to delete scene? -

there's code creates scene function parallaxauto() { var viewer = document.queryselector('.viewer'), frame_count = 6, offset_value = 500; // init controller var controller = new scrollmagic.controller({ globalsceneoptions: { triggerhook: 0, reverse: true } }); // build pinned scene var scene = new scrollmagic.scene({ triggerelement: '#sticky', duration: (frame_count * offset_value) + 'px', reverse: true }) .setpin('#sticky') //.addindicators() .addto(controller); // build step frame scene (var = 1, l = frame_count; <= l; i++) { var scene = new scrollmagic.scene({ triggerelement: '#sticky', offset: * offset_value }) .setclasstoggle(viewer, 'frame' + i) //.addindicators() .addto(controller); } } i can not figure out how clicking on button delete scene. tr

sorting - Android automatic sort list of model when new item is added -

hi have , android app using recycleview. have model class topstory variable time (data long value). new item added list of topstory (topstories) json response server. want update recycle view add new item sort items time (i.e: newest appear first (by time)). this model public class topstory { private int id; private string title; private string author; private int score; private jsonarray kids; private long time; private string url; public topstory() { } public topstory(int id, string title, string author, int point, long time,string url) { this.id = id; this.title = title; this.author = author; this.score = point; this.time = time; this.url = url; } and response contain item add list of topstory (topstories) private void gettopstorydetail(requestqueue requestqueue, string topstoryurl, final progressbar progressbar) { progressbar.setvisibility(view.visible);

SoapUI/Groovy: can not get response when set test step name variable -

my groovy code below. can request , response when use real test step name in the: def request=context.expand('${"teststepname"#request}') def response=context.expand('${"teststepname"#response}') when change use variable: def request=context.expand('${${currentstep.name}#request}') def response=context.expand('${${currentstep.name}#response}')** i can request, while fail response. error is org.apacge.xmlbeans.xmlexception: error: unexpected end of file after null error @ line: xx the test step currentstep points has been executed , has request/reponse. can anyboby here kindly me? import com.eviware.soapui.support.xmlholder import com.eviware.soapui.impl.wsdl.testcase.wsdltestruncontext import groovy.sql.sql import oracle.jdbc.driver.oracletypes import com.eviware.soapui.impl.wsdl.teststeps.wsdltestrequeststep def currentstep = testrunner.testcase.getteststepat(6) log.info "currents

Google Chrome extension's content script not working on few pages -

i developing simple chrome extension, when password-input box focused. i'm using following content script achieve same (code simplified asking question). code not work on pages https://accounts.google.com/ works pages https://www.linkedin.com/ . because of javascript/jquery conflicts? or other reason? please help. tried using noconflict api, didn't help. content script: var inputs = document.getelementsbytagname('input'); function foo() { (var = 0; < inputs.length; i++) { if (inputs[i].type.tolowercase() == 'password') inputs[i].addeventlistener("focus", bar); } } function bar() { alert(1); } foo(); above script finds input elements of type passwords, not add event listener. manifest: { "manifest_version": 2, "name": "myextension", "version": "1.0", "options_page": "options.html", "browser_action": {

Moving tests from windows to Linux server - Selenium -

i have tests, using maven 3.1 selenide v3.5 selenium v2.53 firefox v45.0.1 i run them on windows , thing going fine successful run, noticed browser on windows explicitly open , see tests directly on browser. then need move run on ubuntu server, used xvfb , try run tests. notice: i can't see graphical browser, search thing , called headless browser. i got different problems tests, of them couldn't have successful test , others can't find elements! although worked on windows. my questions, main points have consider while moving our test windows client environment linux server? i reading headless browsers, have use 1 of them? or selenium can handle issue. what changes in code have consider run tests on server? or same code should work fine on both environments? you can use phantomjs (headless browser). better htmlunit driver. see link better understanding. http://www.guru99.com/selenium-with-htmlunit-driver-phantomjs.html you can download

c++ - File output error -

my program crashes after user inputs outputfilename. c1 char array, out string , len int length of c1. here code: ofstream outfile; char outputfilename[256]; cout << "enter output file name: "; cin >> outputfilename; cout << endl; outfile.open(outputfilename,ios::trunc); for(int i=0; i<len-1; i++){ //-1 b/c added \n @ end. out[i] = c1[i]; } outfile << out; outfile.close(); i think i'd more this: { std::cout << "please enter output file name: "; std::string outputfilename; std::getline(outputfilename, std::cin); std::ofstream outputfile(outputfilename.c_str()); outputfile.write((static_cast<char *>(&c1), len); } // file closes automatically when goes out of scope.

http - how to download a file using a java program file that is uploaded in a website -

i have written java program httprequest using httpurlconnection download/upload file of format( xml , image, documents) specific server using it's authentication api-key . program works fine. need upload java program file in website cloud service , need able download file server using java program file uploaded website. how can it? 1 thing make sure java program wrote not web application, java program. for downloading file create function follows: private void exportexcel(httpservletresponse response, hssfworkbook workbook) throws cpaserviceexception{ try{ response.reset(); response.setcontenttype("application/vnd.ms-excel"); response.setheader("content-disposition", "attachment;filename=" + workbook.getsheetat(0).getsheetname()+".xls"); workbook.write(response.getoutputstream()); }catch(ioexception e){ throw new cpaserviceexception(cpaconstants.application_general_error); } } then cal

html - Why are my list items breaking in columns? -

Image
i want have "bubbles" intact, aren't can see in picture. have tried break-inside: avoid; in areas appropriate. pardon media screen i'm testing out , when works apply handheld tag instead of more appropriate size. the code: ol { padding: 1em; list-style: none; } li { background-color: wheat; border-radius: 1.5em; padding: .5em; font-size: 1em; margin: 1em; color: black; border: .25em solid lightblue; } nav { text-align: center; width: 20%; background-color: rgb(170, 70, 0); border-radius: 3em; position: absolute; left: 0%; border: .25em solid lightblue; top: 50%; margin: 2em; -webkit-transform: translate(0%, -50%); } div { position: absolute; left: 50%; width: 70%; transform: translate(-50%, 0%); height: 40em; } @media screen , (max-width: 2560px){ ol { -webkit-column-count: 4; } li { break-after: always; } figcaption { break-before: always;

IntelliJ IDEA 2016.1 , all java project can not be compiled -

when upgrade idea version 15.1 2016 projects report following compile time error: error:module '**' production: java.lang.unsupportedclassversionerror: com/intellij/openapi/vfs/vfsutil : unsupported major.minor version 52.0 env: mac osx10.11 jdk7 maven3.3.9 who knows reasons, thanks!

date - tar unpack and file/folder time -

a linux (busybox) device has no real time clock (so after booting 1970). upload tarball device. want take on date of files in archive, file date 1 archive. found, doesn't works, if system time lower archive time. workaround possible set date future possible, files archive time. but: subfolders (future) system time, not time in archive. is there chance prevent this, files , folder archive time?

d3.js - Having issue with translate function -

i have coordinatesx , coordinatesy arrays. example if want draw arc between coordinatesx[1] , coordinatesy[4], part of code goes : svg.append("path") .attr("d", arc) .attr("fill", "red") .attr("transform", "translate(coordinatesx[1],coordinatesy[4])"); i having problem translate function. says : error: invalid value attribute transform="translate(coordinatesx[1],coordinatesy[4])" how can overcome problem? thanks in advance. it has single string. salvador pointed out in comments, in example using coordinatesx[1] etc literally. but, if concatenate, javascript creates single string (if add number string, result string). in case: .attr("transform", "translate(" + coordinatesx[1] + "," + coordinatesy[4]) + ")");

tortoisesvn - Tortoise SVN - different credentials for same repository server -

i have googled lot on internet/stack overflow, no success. came here ask question. summary: tortoise svn - different credentials same svn server different repository. background: have 2 different svn repositories created on our intranet server. out of which, one shared among group members (we call technicalgroup) - https://intranet/svn/tg . repo accessible thru common username (say tg). second current project - https://intranet/svn/prjbala . repo accessible thru individual username (say bala). problem: both these repos created on same svn server (i.e. url). once checking out first repo (i.e. tg), if trying checkout 2nd 1 (i.e. bala), directly checking out "tg" , not prompting me credentials. solution required: want set "tg"-credentials first repo , "bala"-credentials second repo. using tortoise svn. please help/guide me achieve goal.

c# - Full text index search for complex query in Entity framework -

i trying perform full text index search using ef 6.0. using idbcommandinterceptor ( http://www.entityframework.info/home/fulltextsearch ) perform full text search throwing me exception: cannot use contains or freetext predicate on column 'firstname' because not full-text indexed. linq query: listofemployees = _context.employeecvs.include(x => x.employee) .include(x => x.tags) .include(x => x.projectexperiences) .where(x => x.employee.firstname.contains(searchquery.keyword) || x.employee.lastname.contains(searchquery.keyword) || x.projectexperiences.any(y => y.projecttitle.contains(searchquery.keyword) || y.description.contains(searchquery.keyword)) || x.tags.any(t => t.title.contains(searchquery.keyword))) .tolist(); below query executed ef: exec sp_executesql n'select [unionall1].[id] [c1], [unionall1].[id1] [c2], [unionall1].[id2] [c3], [unionall1].[id3] [c4], [unionall1].[id4] [c5], [unionall1].[id5] [