Posts

vb.net - DataTable belongs to another Data set / Saves extra Entries in XML -

i know question has been asked , answered here. ds.tables.add(dt.copy) ds.tables(0).tablename = "items" ds.writexml("inventory.xml") dt.copy resolve "datatable belongs data set" message when save, of course screws xml file , saves entries in file, when data grid loads xml file shows entries weren't there before. here's code. try dt = new datatable() dim ds new dataset 'dtcopy = dt.copy() dt.columns.add(new datacolumn("product_name", type.gettype("system.string"))) dt.columns.add(new datacolumn("product_sku", type.gettype("system.string"))) dt.columns.add(new datacolumn("product_price", type.gettype("system.decimal"))) dt.columns.add(new datacolumn("product_quantity", type.gettype("system.int32"))) dim integer = pinventory.rows.count = - 1 each prow in pinventory.rows if <> 0 or > 0 ...

wcf - Inconsistent behavior when executing New-WebServiceProxy in a loop -

i'm having problem powershell script wrote call method on wcf web service. wcf service has composite datacontract sole request parameter. have modified servicecontract (by adding 2 new methods), new methods not being called powershell script. here original contract: [servicecontract] public interface ifilesystemservice { [operationcontract] hashfileresponse hashfile(hashfilerequest req); [operationcontract] void generatefiles(generatefilesrequest req); } and here new contract: [servicecontract] public interface ifilesystemservice { [operationcontract] hashfileresponse hashfile(hashfilerequest req); [operationcontract] void generatefiles(generatefilesrequest req); [operationcontract] parsefilepathresponse parsefilepath(parsefilepathrequest req); [operationcontract] archiveparsedfileresponse archiveparsedfile(archiveparsedfilerequest req); } the generatefiles method 1 being called powershell script. have not modified gen...

php - smtp error on vps hosting when sending email -

i installed smtp module (with phpmailer). can work on gmail , sends mail fine. when try set on hosting company's server error. 2015-06-29 13:41:52 server -> client: 220-server.safensahookup.com esmtp exim 4.85 #2 mon, 29 jun 2015 13:41:52 +0000 220-we not authorize use of system transport unsolicited, 220 and/or bulk e-mail. 2015-06-29 13:41:52 client -> server: ehlo 173.214.189.92 2015-06-29 13:41:52 server -> client: 250-server.safensahookup.com hello server.safensahookup.com [173.214.189.91] 250-size 52428800 250-8bitmime 250-pipelining 250-auth plain login 250-starttls 250 2015-06-29 13:41:52 client -> server: starttls 2015-06-29 13:41:52 server -> client: 220 tls go ahead 2015-06-29 13:41:53 client -> server: ehlo 173.214.189.92 2015-06-29 13:41:53 server -> client: 250-server.safensahookup.com hello server.safensahookup.com [173.214.189.91] 250-size 52428800 250-...

vb.net - Githubbing a ClickOnce application -

i want upload application github people start aiding in it's development. what issues should aware of? know theres matter or security...they not able open solution without .pfx file right? i've read if people access certificate sign malware certificate. how should go doing this? you might want delay signing .

class - c# and functional purity -

i've been having use c# lately, don't have experience in. conundrum keep finding myself in is, when building class, having state dependent on state initialized before it class foo{ public bar_ {get;} public dum_ {get;} public foo (){ bar_ = buildbar(); dum_ = builddum(bar_); } } its bit redundant builddum carry parameter if it's going use accessable member. on other hand explicitly pointing out dependencies function relies on i guess asking: best way handle situation? both ways fine. current version of builddum made static , in case it's fine method not access member variables, because cannot anyway: private static dum builddum(bar b) { ... } if make builddum accesses bar_ directly, should make access _dum , i.e. should non-static void : private void builddum() { ... _dum = ... }

python - How do I make this snippet Pythonic? -

i want know how python programmers write following snippet: for in range(10): indexvector[i] = empavg[i] + upperbound(t, pullcount[i]) here t constant. can see, used c/c++ style code want use python right way. if want use list comprehension create indexvector (assuming not have other value outside 10 indexes entered in snippet) , can use - indexvector = [empavg[i] + upperbound(t, pullcount[i]) in range(10)]

ios - Basic auth header from username and password is not working In AFNetworking 2.0 -

i invoking api required authorisation header. this api need on given url username : testingyouonit@gmail.com password : testingyouonit2 to create authorisation header step 1 - base64 encoding of given password. step 2 - sha256 hash on password obtained in step 1 step 3 - use password obtained in step 2 , given username create authorization header now passing request using afnetworking nsstring *email=@"testingyouonit@gmail.com"; nsstring *password=[self encodestringto64:@"testingyouonit2"]; here encoded password - (nsstring*)encodestringto64:(nsstring*)fromstring { nsdata *plaindata = [fromstring datausingencoding:nsutf8stringencoding]; nsstring *base64string; if ([plaindata respondstoselector:@selector(base64encodedstringwithoptions:)]) { base64string = [plaindata base64encodedstringwithoptions:kniloptions]; } else { base64string = [plaindata base64encoding]; } return base64string; } now passin...