unified_texts
stringlengths
32
30.1k
OpenStatus_id
int64
0
4
input_ids
list
token_type_ids
list
attention_mask
list
Unable to reopen dialog box after closing === Here's my problem... I have the following jQuery UI script : <script> $(function() { $( "#dialog" ).dialog({ autoOpen: false, show: "slideUp", hide: "slideDown", height: "300", width: "400", title: "Test pop-up", buttons: { "Close": function(){ $(this).dialog("close"); } } } ); $( "p.diag").click(function(e) { var monUrl = 'test2.php'; $('#dialog').load(monUrl, function(response, status) { $('#test_dialog').html(response); }); e.preventDefault(); }); $( "p.diag").click(function() { $( "#dialog" ).dialog("open"); }); It's a pretty simple code, it opens correctly my dialog box when I click on a p.diag class, but it won't re open after I close it. The test2.php page just print a "lol" with a echo "lol"; And here's my HTML : <div style="height: 200px; min-height: 109px; width: auto;" class="ui-dialog-content ui-widget-content" id="dialog"> </div> Thanks !
0
[ 2, 2343, 20, 21398, 28223, 1649, 75, 4239, 800, 3726, 3726, 235, 22, 18, 51, 1448, 9, 9, 9, 31, 57, 14, 249, 487, 8190, 93, 13, 5661, 3884, 13, 45, 13, 1, 8741, 1, 5579, 5, 22359, 5, 6, 13, 1, 5579, 5, 13, 7, 5910, 4286, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Incorrect Syntax '. ' === Can someone help me out with this one, im getting a syntax error when i run my code, i dont know what it could be.. thanks in advance SqlCommand scGetPostings = new SqlCommand ("SELECT D1.dr,D1.cr,d1.asset_no ,(open_bal+dr-cr) as closing_balance FROM" + "(SELECT COALESCE(SUM(dr_amount),0) as dr, COALESCE(SUM(cr_amount),0) as cr,invasset.asset_no FROM posting,sysasset,invasset" + "WHERE posting.asset_no = invasset.asset_no AND posting.asset_no = @AssetNo, AND period >= asset_open_per GROUP BY invasset.asset_no)" + "as D1,asset", DataAccess.AConnection);
3
[ 2, 18867, 22649, 13, 22, 9, 13, 22, 800, 3726, 3726, 92, 737, 448, 55, 70, 29, 48, 53, 15, 797, 1017, 21, 22649, 7019, 76, 31, 485, 51, 1797, 15, 31, 1049, 143, 98, 32, 110, 44, 9, 9, 3669, 19, 3612, 4444, 255, 16239, 4729, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Hbase rest Api get type value === I have table in hbase.Key, rowkey , colum key type is String Command line query is : > 1239847783741150613 column=f:2012.06.15, timestamp=1341386702824, value=tinmoi.vn//ban-dam-nghin-do-toi-bi-o an-toi-se-kien-va-chuong-tu-di-06928773.html\x0Atinmoi.vn//vu-nhung-nguoi-dep-ban-dam-a- hau-xe-do-tuyet-nhung-cau-cuu-bo-cong-an-06929849.html\x0Atinmoi.vn//\x0Atinmoi.vn//\x0A Rest query localhost:9999/Userinfo/1239847783741150613 ><'CellSet><'Row key="MTIzOTg0Nzc4Mzc0MTE1MDYxMw=="><'Cell timestamp="1341386704764" column="ZjoyMDEyLjA2LjEw">ZGFudHJpLmNvbS52bi8vYzE3MC9zMTcwLTU5NDg0My9uaGFuLXRpbmgtY3VhLWNob25nLWRvYS1naWV0LW5ndW9pLXZvLWJpLWJhdC14ZW0tY2xpcC1zZXguaHRtCmRhbnRyaS5jb20udm4vL2MxNzAvczE3MC02MDU0MjkvY2FuLWJvLWNvbmctY2h1Yy1tdWEtZGFtLXRob25nLWJhby12ZS1jby1xdWFuLmh0bQpkYW50cmkuY29tLnZuLy9jMTcwL3MxNzAtNjA1NDc4L3Nhbi10cmluaC1nYWktdHJlLWJlbmgtaG9hbi1oYXktY2hvaS1uZ29uZy5odG0KZGFudHJpLmNvbS52bi8vYzE3MC9zMTcwLTYwNDU2Mi9jYWMtaG9hLWtob2ktbmd1b2ktbWF1LWJhbi1kYW0tbmdhbi1kby1iaS14dS1waGF0Lmh0bQpkYW50cmkuY29tLnZuLy9jMTcwL3MxNzAtNTk3MjA3L2RhdS1sb25nLXRyZS0zLXR1b2ktYmktaGllcC1kYW0tYm9pLWtlLW5naGktbmhpZW0taGl2Lmh0bQpkYW50cmkuY29tLnZuLy9jMTcwL3MxNzAtNjA1NDEzL2JhdC1kb2ktdHVvbmctaGllcC1kYW0tdHJlLWVtLWx1Yy1udWEtZGVtL<'/Cell><'/Row><'/CellSet> How to get result type as String, long, int with **res** api.Thanks.
0
[ 2, 746, 8436, 760, 21, 2159, 164, 1001, 1923, 800, 3726, 3726, 31, 57, 859, 19, 746, 8436, 9, 4237, 15, 3131, 4237, 13, 15, 326, 4404, 1246, 1001, 25, 3724, 1202, 293, 25597, 25, 13, 45, 13, 1, 390, 3412, 3790, 24658, 3555, 4499...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
splitting string into array with a specific number of elements, c# === I have a string which consists number of ordered terms separated by lines (\n) as it shown in the following example: (note, the string I have is an element of an array of string) term 1 term 2 ....... ....... term n I want to split a specific number of terms, let we say (1000) only and discard the rest of the terms. I'm trying the following code : string[] training = traindocs[tr].Trim().Split('\n'); List <string> trainterms = new List<string>(); for (int i = 0; i < 1000; i++) { if (i >= training.Length) break; trainterms.Add(training[i].Trim().Split('\t')[0]); } Can I conduct this operation without using List <string> or any other data structure? I mean just extract the specific number of the terms into the the Array (training) directly ?? thanks in advance.
0
[ 2, 17282, 3724, 77, 7718, 29, 21, 1903, 234, 16, 2065, 15, 272, 5910, 800, 3726, 3726, 31, 57, 21, 3724, 56, 2043, 234, 16, 1905, 1663, 4196, 34, 1560, 13, 5, 1, 103, 6, 28, 32, 1721, 19, 14, 249, 823, 45, 13, 5, 10280, 15, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Cobertura didn't found and instrumented classes === I am new in Cobertura, and try to instrument classes from compliled jar file. After unpacking I run next command: D:\cobertura-1.9.4.1\7.6.300.01>D:\cobertura-1.9.4.1\cobertura-instrument.bat --basedir D:\cobertura-1.9.4.1\7.6.300.01 Cobertura 1.9.4.1 - GNU GPL License (NO WARRANTY) - See COPYRIGHT file Instrumenting 0 files Cobertura: Saved information on 0 classes. Instrument time: 0ms In D:\cobertura-1.9.4.1\7.6.300.01 locates class files. Why cobertura cannot find them?
0
[ 2, 326, 4461, 3031, 223, 22, 38, 216, 17, 5529, 69, 2684, 800, 3726, 3726, 31, 589, 78, 19, 326, 4461, 3031, 15, 17, 1131, 20, 5529, 2684, 37, 6479, 1210, 1294, 5112, 3893, 9, 75, 367, 8573, 68, 31, 485, 328, 1202, 45, 13, 43,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Tegra 2 Linux, libEGL warning using software fallback === I am trying to run my OpenGL ES application, however when I use packages: libegl1-mesa, libegl1-mesa-dev, libegl1-mesa-drivers libgles2-mesa, libgles2-mesa-dev application reports: libEGL warning using software fallback I was getting the same message when I tried to start example provided in package mesa-utils-extra called /usr/bin/es2gears but after updating drivers: export LDK_ROOTFS_DIR=/ cd Linux_for_Tegra ./apply_binaries.sh and creating symlinks like in "Tegra Linux Driver Package Developers Guide" mv /usr/lib/libEGL.so /usr/lib/libEGL.so.1 mv /usr/lib/libGLESv2.so /usr/lib/libGLESv2.so.2 ln -s /usr/lib/libEGL.so.1 /usr/lib/libEGL.so ln -s /usr/lib/libGLESv2.so.2 /usr/lib/libGLESv2.so I am able to start es2gears using hardware acceleration (2x faster). My question is where can I get development packages that use appropriate libEGL.so and libGLESv2.so libraries so I can compile my application?
0
[ 2, 2392, 4973, 172, 13024, 15, 2093, 17143, 255, 3590, 568, 2306, 1080, 1958, 800, 3726, 3726, 31, 589, 749, 20, 485, 51, 368, 8430, 13, 160, 3010, 15, 207, 76, 31, 275, 16875, 45, 2093, 17143, 255, 165, 8, 3845, 58, 15, 2093, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Iterate double array php and ajax === i need some help with this issue: In the php controller I have: if($request->isXmlHttpRequest()){ ..... $appResult = new array(....etc); $return=json_encode(array("appResult"=>$appResult,"rowcount"=> 2)); return new Response($return,200,array('Content-Type'=>'application/json')); And in the javascript I want to print the result $.ajax({ type: "POST", url: "{{ path('login') }}", data:data, dataType: "json", success: function(res) { $.each(res, function(index, res) { $("#result").append( "<div id='wrap'> <div id='Username'>" + res.name + "</div>" + "</div>"); }); } }); I had checked that ajax javascript works fine because If i only pass one array it works fine: $appResult = new array(....etc); $return=json_encode($appResult); return new Response($return,200,array('Content-Type'=>'application/json')); But i also want to pass an ID to the javascript in the result, i want to pass the array and the id and i don't know how to get the array in the javascript and iterate. I have tried all. Please help!
0
[ 2, 32, 106, 1373, 1494, 7718, 13, 26120, 17, 20624, 800, 3726, 3726, 31, 376, 109, 448, 29, 48, 1513, 45, 19, 14, 13, 26120, 9919, 31, 57, 45, 100, 5, 4403, 99, 10351, 8, 1, 403, 396, 8184, 21127, 99, 10351, 5, 6, 6, 1, 13, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
mod rewrite, redirect wihtout changing the URL === I need to redirect some specific URLs to another controller. I have this rules in the .htaccess, for example: RewriteEngine On RewriteBase / RewriteCond %{REQUEST_URI} diving/costa-rica-cr$ RewriteRule ^diving/costa-rica-cr$ new/url?id=29&landingact=11 [R,L] What I'm not getting is redirecting without changins the URL that the user see in the browser (must be *diving/costa-rica-cr*). I tried with QSA and PT options but none worked. Afted this rules I have the following: RewriteCond %{REQUEST_URI} guias/(.*)(\..*){2,}\.php$ RewriteRule ^guias/(.*)(\..*){2,}\.php$ viajes/$1 [R=301,L] RewriteCond %{REQUEST_URI} guias/(.*)\.(.*)\.php$ RewriteRule ^guias/(.*)\.(.*)\.php$ viajes/$1-${countrymap:$2} [R=301,L] RewriteCond %{REQUEST_URI} viaje-a/(.*)(\..*){2,}\.php$ RewriteRule ^viaje-a/(.*)(\..*){2,}\.php$ viajes/$1 [R=301,L] RewriteCond %{REQUEST_URI} viaje-a/(.*)\.(.*)\.php$ RewriteRule ^viaje-a/(.*)\.(.*)\.php$ viajes/$1-${countrymap:$2} [R=301,L] RewriteCond %{REQUEST_URI} viajes-a-medida/(.*)(\..*){2,}\.php$ RewriteRule ^viajes-a-medida/(.*)(\..*){2,}\.php$ tours/$1 [R=301,L] RewriteCond %{REQUEST_URI} viajes-a-medida/(.*)\.(.*)\.php$ RewriteRule ^viajes-a-medida/(.*)\.(.*)\.php$ tours/$1-${countrymap:$2} [R=301,L] RewriteCond %{REQUEST_URI} recomendaciones-viaje/(.*)(\..*){2,}\.php$ RewriteRule ^recomendaciones-viaje/(.*)(\..*){2,}\.php$ visados-y-vacunas/$1 [R=301,L] RewriteCond %{REQUEST_URI} recomendaciones-viaje/(.*)\.(.*)\.php$ RewriteRule ^recomendaciones-viaje/(.*)\.(.*)\.php$ visados-y-vacunas/$1-${countrymap:$2} [R=301,L] RewriteCond %{REQUEST_URI} (que-ver-en|como-es|idioma-moneda-horarios|vuelos|hoteles|alquiler-de-coches|fotos-de|viajar-con-ninos|tours|esqui)/(.*)(\..*){2,}\.php$ RewriteRule ^(que-ver-en|como-es|idioma-moneda-horarios|vuelos|hoteles|alquiler-de-coches|fotos-de|viajar-con-ninos|tours|esqui)/(.*)(\..*){2,}\.php$ $1/$2 [R=301,L] RewriteRule ^(que-ver-en|como-es|idioma-moneda-horarios|vuelos|hoteles|alquiler-de-coches|fotos-de|viajar-con-ninos|tours|esqui)/(.*)\.(.*)\.php$ $1/$2-${countrymap:$3} [R=301,L] RewriteCond %{REQUEST_URI} !tools/.* RewriteCond %{REQUEST_URI} !blog/.* RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /([^.]+\.)+php?\ HTTP RewriteRule ^(.*)\.php$ $1 [R=301,L] RewriteCond %{REQUEST_URI} !fotos-tours/.* RewriteCond %{REQUEST_URI} (que-ver-en|como-es|idioma-moneda-horarios|vuelos|hoteles|alquiler-de-coches|fotos-de|viajar-con-ninos|tours|viajes|actividades|cuando-ir|visados-y-vacunas|esqui)/.* RewriteCond %{REQUEST_URI} !(.*)\.php$ RewriteRule ^(.*)$ $1.php [QSA,L] RewriteRule ^blog/(.*) public_html/blog/$1 [L] RewriteRule ^$ %{REQUEST_URI}donde-me-voy/vacaciones [L] RewriteRule (.*) public_html/$1 [L] Maybe another one of there rules affect, but I think that putting the [L] flag finishes the rewriting right?
0
[ 2, 7226, 27891, 15, 302, 14706, 4807, 9020, 1320, 4226, 14, 287, 6362, 800, 3726, 3726, 31, 376, 20, 302, 14706, 109, 1903, 13, 911, 7532, 20, 226, 9919, 9, 31, 57, 48, 1761, 19, 14, 13, 9, 9020, 20604, 15, 26, 823, 45, 27891, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
scroll to bottom of heightless dynamic div === I have a div that contains some log <div id="log"> <div class="logitem"></div> <div class="logitem"></div> <div id="containerbottom"></div> </div> To the log , on runtime, Im appending more unknown number of "<div class="logitem"></div>". I want to scroll to the bottom of the container right after appending the item I have tried using : $('#log').animate({ scrollTop: $('#containerbottom').offset().top }); but it doesnt seem to perform well. what are my other options to do that ? thanks
0
[ 2, 12159, 20, 2129, 16, 2947, 923, 7782, 13, 12916, 800, 3726, 3726, 31, 57, 21, 13, 12916, 30, 1588, 109, 6738, 13, 1, 12916, 4924, 3726, 7, 5567, 7, 1, 13, 1, 12916, 718, 3726, 7, 5567, 2119, 79, 7, 1, 118, 12916, 1, 13, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Determining if a html request comes from inside the office using PHP === I am wondering about a certain server setup. Lets say I have a web server running on my local network, which is accessible using an url such as www.example.com from within and also outside the network. I would like my PHP website to be able to determine if a request comes from within the internal LAN or from the outside. I doubt that this will be possible using the IP address as the request will look as if it is coming from a public IP address, and not the internal one 192.168.x.x. Also the public IP might change from time to time. Would this be possible, and how could i achieve this in PHP?
0
[ 2, 13521, 100, 21, 13, 15895, 3772, 1624, 37, 572, 14, 488, 568, 13, 26120, 800, 3726, 3726, 31, 589, 5712, 88, 21, 1200, 8128, 18161, 9, 6884, 395, 31, 57, 21, 2741, 8128, 946, 27, 51, 375, 982, 15, 56, 25, 7342, 568, 40, 287...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Jar file not running from MSSQL stored procedure? === Hi All I'm trying to run a jar a file from MSSQL stored procedure. But I'm getting the error "'java' is not recognized as an internal or external command," I'm using the following command from stored procedure EXEC master..xp_cmdshell 'java -jar C:\admin\yyyyy\xxxx.jar' I have installed JRE and also added it in environment variables. I'm able to execute the same jar file from command prompt. Please let me know if I'm missing something
0
[ 2, 5112, 3893, 52, 946, 37, 4235, 18, 22402, 8214, 7004, 60, 800, 3726, 3726, 4148, 65, 31, 22, 79, 749, 20, 485, 21, 5112, 21, 3893, 37, 4235, 18, 22402, 8214, 7004, 9, 47, 31, 22, 79, 1017, 14, 7019, 13, 7, 22, 1004, 1385, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Prevent duplicate results in SQL === I have a combo box (`comboBox1`) in my application that lists catagories from my SQL database. It is pulling the data correctly at the moment. My only problem is that when the data is listed in the combo box, there are duplicate results. For example: What I want it to list: Example 1 Example 2 Example 3 What it actualy lists: Example 1 Example 1 Example 1 Example 1 Example 1 Example 2 Example 2 Example 2 Example 3 Example 3 Example 3 Here is the code that I am using to list the data: public void ListCat() { DataTable linkcat = new DataTable("linkcat"); using (SqlConnection sqlConn = new SqlConnection(@"Connection stuff;")) { using (SqlDataAdapter da = new SqlDataAdapter("SELECT name FROM list WHERE name <> 'NULL'", sqlConn)) { da.Fill(linkcat); } } foreach (DataRow da in linkcat.Rows) { comboBox1.Items.Add(da[0].ToString()); } } In short, my question would be how can I prevent duplicate data from being listed?
0
[ 2, 2501, 19429, 1736, 19, 4444, 255, 800, 3726, 3726, 31, 57, 21, 22621, 1649, 13, 5, 1, 960, 1192, 5309, 165, 1, 6, 19, 51, 3010, 30, 7227, 2008, 9668, 2829, 37, 51, 4444, 255, 6018, 9, 32, 25, 3303, 14, 1054, 12044, 35, 14, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Counting the number of Sundays, Mondays,...,Saturdays === I like to count the number of Sundays, Mondays, Tuesdays, ...,Saturdays in year 2001. Taking the following dates { 1 Jan, 5 April, 13 April, 25 Dec and 26 Dec} as public holidays and consider them as Sundays. How can I do it in R? - Thanks
0
[ 2, 11195, 14, 234, 16, 2608, 18, 15, 5745, 18, 15, 9, 9, 9, 15, 27759, 18, 800, 3726, 3726, 31, 101, 20, 2468, 14, 234, 16, 2608, 18, 15, 5745, 18, 15, 9369, 18, 15, 13, 9, 9, 9, 15, 27759, 18, 19, 159, 1089, 9, 741, 14,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
JV Slideshow autoplay in joomla 1.5 === I created a slideshow with JV Slideshow in joomla 1.5 and I want slides to automatically move to next slide. how can I create an interval to this for me?
0
[ 2, 487, 710, 18066, 1544, 3108, 5438, 19, 2640, 2636, 531, 137, 9, 264, 800, 3726, 3726, 31, 679, 21, 18066, 1544, 29, 487, 710, 18066, 1544, 19, 2640, 2636, 531, 137, 9, 264, 17, 31, 259, 18066, 20, 7499, 780, 20, 328, 6464, 9,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0...
Symfony 2 Dependency Injection: is it possible to get a service by class name? === Traditionally, you would use the service container this way: <!-- language-all: lang-php --> $container->get('my_service'); However, provided that only one definition of a specific class exists, I'd like to get this service by class name: $container->xxx('My\Application\Service'); Is this possible with the [service container][1]? [1]: http://symfony.com/doc/current/book/service_container.html
0
[ 2, 13, 7261, 10229, 93, 172, 26835, 13646, 45, 25, 32, 938, 20, 164, 21, 365, 34, 718, 204, 60, 800, 3726, 3726, 6159, 15, 42, 83, 275, 14, 365, 12147, 48, 161, 45, 13, 1, 187, 8, 8, 816, 8, 1233, 45, 4544, 8, 26120, 13, 8...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
jQuery param dynamic object name === why can't i have a variable in an object? I get an error like: "Uncaught SyntaxError: Unexpected token this" My code is like this. $("#search_options input:checkbox").on('click', function() { var params = { $(this).attr('name') : $(this).val(), }; var str = jQuery.param(params); }); I'm sure that $(this) is working because I tried to console.log it outside the params object then i is working.
0
[ 2, 487, 8190, 93, 2258, 79, 7782, 3095, 204, 800, 3726, 3726, 483, 92, 22, 38, 31, 57, 21, 7612, 19, 40, 3095, 60, 31, 164, 40, 7019, 101, 45, 13, 7, 1020, 150, 12647, 22649, 29992, 45, 9380, 20, 2853, 48, 7, 51, 1797, 25, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I get DISTINCT column A, with SUM of column B? === I'm relatively new to coding and have tried searching for a solution, but am not entirely sure how to phrase my question. What would be simplest way to achieve the result I need, as detailed in the example that follows? I'm using MSSQL. <pre><code>SELECT Unit, Quantity FROM SomeTable WHERE Parameter1 = 'x'</code></pre> Gives me the result: <pre> Unit | Quantity --------------- a | 10 b | 10 c | 10 a | 10 </pre> This is the result I need: <pre> Unit | Quantity --------------- a | 20 b | 10 c | 10 </pre> Any help would be greatly appreciated.
0
[ 2, 184, 107, 31, 164, 4421, 4698, 21, 15, 29, 3907, 16, 4698, 334, 60, 800, 3726, 3726, 31, 22, 79, 3109, 78, 20, 13, 15458, 17, 57, 794, 5792, 26, 21, 4295, 15, 47, 589, 52, 2894, 562, 184, 20, 6845, 51, 1301, 9, 98, 83, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Trigger Yii field validation onchange of another field === I have two related fields in a Yii model. They are items_per and items_period. **items_per** is an integer that reflects how many items to be processed in a given time period. **items_period** is the number of seconds in that period (a dropdown with options labelled as seconds, minutes, hours). Multiply items_per by items_period and you have "items per second". I've got a custom validation rule set up to limit items per second being above a certain amount. That all works fine and gives a sensible error message using ajax validation when you change the value in the items_per field (on blur). I need for the validation on the items_per field to be triggered whenever the items_period field is changed (100 / second may not be allowed, but 100 / minute is). I tried adding an onchange function to the items_per dropdown to trigger "blur" or "change" on the items_per field, but it doesn't seem to make the ajax request for validation. Submitting the form just to trigger the validation isn't an option, as it's possible it might not have any errors and simply save the record before the user is ready. Any suggestions how I can force one field to trigger ajax validation in another?
0
[ 2, 7286, 7679, 49, 575, 27999, 27, 16229, 16, 226, 575, 800, 3726, 3726, 31, 57, 81, 1597, 2861, 19, 21, 7679, 49, 1061, 9, 59, 50, 3755, 1, 1432, 17, 3755, 1, 27441, 9, 13, 1409, 2119, 79, 18, 1, 1432, 1409, 25, 40, 13820, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I launch my application via sending instruction over GPRS === As per my requirement I am able to Start my application over incoming SMS. But i am curious to know about how to start the application if some Android Device like Android TAB having no SIM card but it have GPRS.May i use a custom URL like [this][1] [1]: http://stackoverflow.com/questions/5265539/how-do-i-launch-my-app-via-a-custom-url-in-an-email Thanks in Advance
0
[ 2, 184, 107, 31, 3394, 51, 3010, 1197, 4907, 7304, 84, 10538, 1224, 800, 3726, 3726, 28, 416, 51, 8981, 31, 589, 777, 20, 799, 51, 3010, 84, 17126, 7613, 18, 9, 47, 31, 589, 7686, 20, 143, 88, 184, 20, 799, 14, 3010, 100, 109,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Is there a simpler way to get the current time in SQL Server 2008? === I need to store the current time (format `'hi'`) as char(4) in a table (is created and used by another program, I can't change it) and now wondered what is a suitable way to retrieve it via SQL. I know MySQL is not that standard-orientated, but I thought it could be something similiar to `DATE_FORMAT(NOW(), 'Hi').` <br />The code below which I found works, but feels little intricately.<br /> SELECT CAST(DATEPART(hour, GETDATE()) AS nvarchar)+CAST(DATEPART(minute, GETDATE()) AS nvarchar); Is there a better way to achieve this?
0
[ 2, 25, 80, 21, 19120, 161, 20, 164, 14, 866, 85, 19, 4444, 255, 8128, 570, 60, 800, 3726, 3726, 31, 376, 20, 1718, 14, 866, 85, 13, 5, 23588, 13, 1, 22, 1822, 22, 1, 6, 28, 4892, 5, 300, 6, 19, 21, 859, 13, 5, 403, 679, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How can solve zend exception? === I use Zend libray, especially Loader class. But I take the following exception: " Uncaught exception 'Zend_Http_Client_Adapter_Exception' with message 'Unable to Connect to ssl://www.googleapis.com:443. Error #0: " I sould say that when i run my code local, I dont face any problem, but the exception show when I try to run my file in server. The server I use has ssl security. Is there any possibility to there is any conflict with it?
0
[ 2, 184, 92, 8402, 10526, 43, 5391, 60, 800, 3726, 3726, 31, 275, 10526, 43, 13, 8326, 2787, 15, 1118, 6305, 106, 718, 9, 47, 31, 247, 14, 249, 5391, 45, 13, 7, 16061, 12647, 5391, 13, 22, 4257, 43, 1, 21127, 1, 150, 18513, 38,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
how to restrict user from deleting words with special characters from textbox asp.net javascript === i am working in email CMS using ckeditor.net. At runtime user can change the body of email I want to restrict user deleing all special words starting with @@ here is example Email Alert! :<br /> <br /> **@@Comments**<br /> <br /> Please do not reply to this email. i dont want user to delete @@comments word and all "@@" characters in other email templates can you give any code in javascript at run time i replace @@ words with some paragraph
0
[ 2, 184, 20, 15436, 4155, 37, 121, 1336, 68, 715, 29, 621, 1766, 37, 1854, 5309, 28, 306, 9, 2328, 8247, 8741, 800, 3726, 3726, 31, 589, 638, 19, 8517, 2390, 18, 568, 13, 2601, 13401, 9, 2328, 9, 35, 485, 891, 4155, 92, 753, 14...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
short way should respond_to(:attribute) rspec === I have a bunch attributes for my model post in my rspec test: it { should respond_to(:title) } it { should respond_to(:description) } it { should respond_to(:instruction) } . . . **Can I be more precise, use less lines in the test something like:** it { should respond_to(:title, :description, :instruction) }
0
[ 2, 502, 161, 378, 4590, 1, 262, 5, 45, 721, 14755, 6, 13, 1224, 12610, 800, 3726, 3726, 31, 57, 21, 7653, 13422, 26, 51, 1061, 678, 19, 51, 13, 1224, 12610, 1289, 45, 32, 13, 1, 378, 4590, 1, 262, 5, 45, 22235, 6, 13, 1, 3...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Converting Projects === I have some projects that are created on Visual Studio 2010. I want to convert them to Visual Studio 2002 format and change their project names like: Project1.VS2010.v1.00, Project1.VS2002.v1.00, and so on. I don't just want to change the name of the folders, but the projects as well. I can copy/paste resources and link them inside IDEs. I can do the dirt work, it's OK for me if there's a way to change my project names. And, how do people change project names when there's a new version? Do people change the project name or just add a comment to your source codes? I've been asked to change the project names as well to make the archiving process easy. Thank you very much for your help already.
0
[ 2, 19583, 2314, 800, 3726, 3726, 31, 57, 109, 2314, 30, 50, 679, 27, 3458, 1120, 498, 9, 31, 259, 20, 8406, 105, 20, 3458, 1120, 1093, 2595, 17, 753, 66, 669, 1817, 101, 45, 669, 165, 9, 710, 18, 2751, 9, 710, 165, 9, 2032, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
calculate duration for the given set of timestamp === I have a set of intime and outtime, and i want to calculate the duration between the intime and outtime and add all the duration to get the total duration. example: `Array ( [1] => Array ( ['intime'] => 1342086993 ['outime] => 1342087585 ) [3] => Array ( ['intime'] => 1342087669 ['outtime] => 1342096165 ) [5] => Array ( ['intime'] => 1342096339 ['outime'] => 1342096345 ) )' $total_duration = 0; foreach($logArray as $log) { $duraton = $log['intime'] - $log['outime']; $total_duration += $duration; } $duration_hrs = $total_duration/3600; echo 'Time spend in hrs :'.$duration_hrs; but this is not giving me the proper duration. is there any other way to do so.
0
[ 2, 18469, 9403, 26, 14, 504, 309, 16, 436, 38, 10158, 800, 3726, 3726, 31, 57, 21, 309, 16, 19, 891, 17, 70, 891, 15, 17, 31, 259, 20, 18469, 14, 9403, 128, 14, 19, 891, 17, 70, 891, 17, 3547, 65, 14, 9403, 20, 164, 14, 60...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Android - service keep alive === have a problem with a system. I have running service, which is constantly checking the position and counting the distance and time since user start it. But after 20-25 minutes and many interactions with other applications service is being killed. How I can prevent it? I'm thinking to add second service which will keep my alive.
0
[ 2, 13005, 13, 8, 365, 643, 2481, 800, 3726, 3726, 57, 21, 1448, 29, 21, 329, 9, 31, 57, 946, 365, 15, 56, 25, 7545, 9886, 14, 649, 17, 11195, 14, 1583, 17, 85, 179, 4155, 799, 32, 9, 47, 75, 434, 8, 1811, 902, 17, 151, 112...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
PHP get parameter from variable with url === I would like to get parameter from variable that holds URL.<br/> I got the following variable: `$lastPage` that holds the URI of the previous page. I would like to get a parameter from it.<br/>I got the following script in javascript (which I use for something else) function getUrlVar(key) { var result = new RegExp(key + '=([^&]*)', 'i').exec(window.location.search); return result && unescape(result[1]) || ''; } I want something like that but for PHP. Thank you very much
0
[ 2, 13, 26120, 164, 18906, 37, 7612, 29, 287, 6362, 800, 3726, 3726, 31, 83, 101, 20, 164, 18906, 37, 7612, 30, 2763, 287, 6362, 9, 1, 5145, 118, 1, 31, 330, 14, 249, 7612, 45, 13, 1, 4403, 8558, 6486, 1, 30, 2763, 14, 13, 35...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Combining Porter-Duff and Blend Mode operations === I have implemented many blend modes such as Screen, Color Dodge, Color Burn, etc. Can someone share experience, how do you combine now blend modes with Porter-Duff operations? I know there is one formula for doing this, but I am interested how you implemented that, the general design. Thanks
1
[ 2, 12803, 8158, 8, 43, 5386, 17, 11138, 3740, 1311, 800, 3726, 3726, 31, 57, 6807, 151, 11138, 12770, 145, 28, 2324, 15, 1665, 9441, 15, 1665, 4306, 15, 2722, 9, 92, 737, 1891, 1496, 15, 184, 107, 42, 12287, 130, 11138, 12770, 29,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Combobox doesn't alow me to select item === i have the following combobox <ComboBox Grid.Column="1" HorizontalAlignment="Stretch" Text="{Binding GroupInvoicing.AdminInvoiceBreakdownMembership}" SelectedValuePath="Tag" SelectedValue="{Binding Path=GroupInvoicing.AdminInvoiceBreakdownMembership}"> <ComboBoxItem Content="None" Tag="N" /> <ComboBoxItem Content="Level of Cover" Tag="L" /> <ComboBoxItem Content="Members" Tag="M" /> <ComboBoxItem Content="Payment Type" Tag="P" /> <ComboBoxItem Content="Work Area" Tag="W" /> </ComboBox> althogh the GroupInvoicing.AdminInvoiceBreakdownMembership comes back with "L" it does not select the coresponding text and doesn't let me to select anything, any ideeas what i have done wrong?
0
[ 2, 22621, 5309, 1437, 22, 38, 21, 4121, 55, 20, 5407, 9101, 800, 3726, 3726, 31, 57, 14, 249, 22621, 5309, 13, 1, 960, 1192, 5309, 7354, 9, 716, 4404, 103, 3726, 7, 165, 7, 10095, 192, 9693, 1130, 3726, 7, 29360, 7, 1854, 3726, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Advice needed on how to set up a session of "wish list" products on shared computers === I have a bit of a complex question but it's a simple idea. On a products website, we require a "wish list" where you can simply 'like' or 'add' your favourite products to your wish list. You don't need to be logged in to access this, but if you log in, a few extra features are available for the wish list such as what your delivery address is (because it is stored on your account). We currently maintain a VISITOR SESSION table just to track their sessionID via a cookie, so we can remember certain preferences of the visitor. Primary key: "sessionid". We also have a CUSTOMER table to hold all our customers. Primary key: "custid". The above two tables don't directly link to each other as such. I'm very confused on a 'good' way of implementing the wish list (i.e. designing the database). The two possibilities are: a) Maintain one wishlist table, with a unique "custid" foreign key. If the customer is logged in, this table is used. If the customer is NOT logged in, we store the wish list as a serialized array in the VISITOR SESSION table which continues to be updated regardless of whether the customer is logged in or not. Advantage: the wishlist can be updated regardless of whether the customer is logged in. On a shared computer, if one customer A uses the wish list, logs in, logs out..and then another visitor B uses the wish list and updates it. Since the first customer A's profile also has a copy of the wish list, then he can log in later from home and his wish list will be as he left he left it on the shared computer. Even though the second customer B changed the visitor-session wish list, the original wish list attach to Customer A's "custid" remains in tact. Disadvantage: much duplication of data and overhead between the visitor table and customer table. OR b) Maintain ONE wishlist table, with an optional (NULL) "custid" foreign key and an optional (NULL) "sessionid" to the above tables. If the customer is logged in we can use the custid, and the "sessionid" can be used if the visitor has a session cookie set. The major problem with this is on shared computers. If Customer A uses the wish list, then logs in, attaches the wish list to his account, and logs out..and later Customer B uses the shared machine and updates the wish list... the same list is being updated. Later Customer A logs in from home, to see that his wish list has changed drastically, because customer B managed to change it via his visitor session from that shared computer. I've been thinking about this a lot so I'm a little spaced out, would really appreciate some advice on this or if there's something obvious I am missing :) I mainly want to know what database you would use and why? Many thanks!
0
[ 2, 4978, 851, 27, 184, 20, 309, 71, 21, 3723, 16, 13, 7, 16871, 968, 7, 1985, 27, 2592, 7774, 800, 3726, 3726, 31, 57, 21, 1142, 16, 21, 1502, 1301, 47, 32, 22, 18, 21, 1935, 882, 9, 27, 21, 1985, 2271, 15, 95, 4077, 21, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to use <sec:authorize access="hasRole('ROLES)"> for checking multiple Roles? === I want to display some content conditionally based on Roles using Spring Security JSP taglibs. But in Spring Security 3.1.x <sec:authorize access="hasRole('MANAGER')"> is checking for only one role. I can use <sec:authorize ifAllGranted="ROLE_USER,ROLE_ADMIN"> but **ifAllGranted** is deprecated. Any help?
0
[ 2, 184, 20, 275, 13, 1, 14332, 45, 10007, 2952, 1381, 3726, 7, 6482, 661, 413, 5, 22, 661, 1355, 6, 7, 1, 26, 9886, 1886, 2954, 60, 800, 3726, 3726, 31, 259, 20, 3042, 109, 2331, 2874, 1326, 432, 27, 2954, 568, 1573, 1221, 487...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How can I access what a previous variable was set to? === I have a foreach nested inside a foreach. I need to check whether d is less than all the other d's. How can I do this? If there is a way to see what a variable was previously set to, then I would be able to do this myself. If not, could you please devise a solution? Here is my code: foreach (DataRow newRow1 in dt.Rows) { string zipCode1 = newRow1[2].ToString(); double latitude2 = Convert.ToDouble(newRow1[3]); double longitude2 = Convert.ToDouble(newRow1[4]); foreach (DataRow newRow2 in dt2.Rows) { if (newRow2[2].ToString().Equals(zipCode1)) { newRow1[5] = newRow2[1].ToString(); double latitude = Convert.ToDouble(newRow1[3]); double longitude = Convert.ToDouble(newRow1[4]); double d = Math.Sqrt(Math.Abs(latitude - latitude2) * Math.Abs(latitude - latitude2) + Math.Abs(longitude - longitude2) * Math.Abs(longitude - longitude2)); Console.WriteLine("Found match!"); } } }
0
[ 2, 184, 92, 31, 1381, 98, 21, 1158, 7612, 23, 309, 20, 60, 800, 3726, 3726, 31, 57, 21, 26, 14322, 5618, 69, 572, 21, 26, 14322, 9, 31, 376, 20, 2631, 1472, 13, 43, 25, 787, 119, 65, 14, 89, 13, 43, 22, 18, 9, 184, 92, 3...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
data.table 1.8.1.: "DT1 = DT2" is not the same as DT1 = copy(DT2)? === I've noticed some inconsistent behaviour in data.table when using different assignment operators. I can't see why "=" and copy() should be different, which they are. If you use "=" or "<-" instead of copy(), upon changing the copied data.table, the original data.table will change as well. Please execute the following commands and you will see what I mean library(data.table) example(data.table) DT x y v 1: a 1 42 2: a 3 42 3: a 6 42 4: b 1 4 5: b 3 5 6: b 6 6 7: c 1 7 8: c 3 8 9: c 6 9 DT2 = DT now i'll change the v column of DT2: DT2[ ,v:=3L] x y v 1: a 1 3 2: a 3 3 3: a 6 3 4: b 1 3 5: b 3 3 6: b 6 3 7: c 1 3 8: c 3 3 9: c 6 3 but look what happened to DT: DT x y v 1: a 1 3 2: a 3 3 3: a 6 3 4: b 1 3 5: b 3 3 6: b 6 3 7: c 1 3 8: c 3 3 9: c 6 3 it changed as well. so: changing DT2 changed the original DT. not so if I use copy(): example(data.table) # reset DT DT3 <- copy(DT) DT3[, v:= 3L] x y v 1: a 1 3 2: a 3 3 3: a 6 3 4: b 1 3 5: b 3 3 6: b 6 3 7: c 1 3 8: c 3 3 9: c 6 3 DT x y v 1: a 1 42 2: a 3 42 3: a 6 42 4: b 1 4 5: b 3 5 6: b 6 6 7: c 1 7 8: c 3 8 9: c 6 9 is this behaviour expected?
0
[ 2, 1054, 9, 5924, 137, 9, 457, 9, 165, 9, 45, 13, 7, 43, 38, 165, 800, 13, 43, 38, 135, 7, 25, 52, 14, 205, 28, 13, 43, 38, 165, 800, 4344, 5, 43, 38, 135, 6, 60, 800, 3726, 3726, 31, 22, 195, 2711, 109, 22380, 7727, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do i postback ? === I have this web application which is supposed to move rows up and down on button click, but it does only when I close the webpage and re run my program from viusal studio. protected void Page_Load(object sender, EventArgs e) { if (Page.IsPostBack) { DataView view = (DataView)SqlDataSource1.Select(DataSourceSelectArguments.Empty); DataTable result = view.ToTable(); } } is this all I need ?
0
[ 2, 184, 107, 31, 678, 1958, 13, 60, 800, 3726, 3726, 31, 57, 48, 2741, 3010, 56, 25, 2293, 20, 780, 11295, 71, 17, 125, 27, 5167, 10840, 15, 47, 32, 630, 104, 76, 31, 543, 14, 2741, 6486, 17, 302, 485, 51, 625, 37, 1790, 267...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
COM interop dictionary used in C# === I have a third party DLL i need to call from my C# program. I have added the dll to the references in my project and VS2010 has generated an COM - interop wrapper dll. The interfaces and classes defined in the DLL are now available in my program and working as they should. Now the problem are the methods which returns a "dictionary" consisting of a key value pair of an integer and a TSEnt object. In the DLL the return type are defined as VARIANT* and in the wrapper as "object". The DLL dosn't include any dictionary interface. The only interface i have found in C#, that I can successfully cast this returnvalue to is a IEnumerable. But fetching values from the returnvalue using a foreach statement only returns a int32, which is the key-part of the underlying key/value pair. How do i get the value-part of this dictionary ? I have tried to cast this to IDictionary, IDictionary< int, object >, Hashtable and many more but all with the same result ... cast error. I guess the DLL is originally written in an early version of Visual Basic. Please help ... The problem has haunted me for the last 2 weeks ... Regards Jesper Sandgaard From the documentation: Query(String ObjectType, String PropName, String Pattern) Queries the repository for Objects of type ObjectType with the property PropName that have the value Pattern. Returns a Dictionary object containing a list of TSEnt objects that the repository returns. This list is keyed by the index of the elements in the list starting from 0. Pattern can contain ‘*’ as wildcard. If the Property name is a Domained value, use the Display Value in the repository model. From the DLL (ITypeLib Viewer): [id(0x00000006), helpstring("method Query")] HRESULT Query( [in] BSTR Type, [in] BSTR PropertyName, [in] BSTR Pattern, [out, retval] VARIANT* result); Definition in VS: [DispId(6)] object Query(string Type, string PropertyName, string Pattern);
0
[ 2, 13, 960, 1480, 2594, 9186, 147, 19, 272, 5910, 800, 3726, 3726, 31, 57, 21, 422, 346, 13, 43, 211, 31, 376, 20, 645, 37, 51, 272, 5910, 625, 9, 31, 57, 905, 14, 13, 43, 211, 20, 14, 7231, 19, 51, 669, 17, 4611, 2751, 63...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Android: Google Voice Recognition Server === I am currently playing around with Google's Voice Recognition API for Android SDK. What I want to know is the URL for their voice recognition. You need a data connection to use the feature, so obviously they are parsing things server-side. Does anyone know this URL?
0
[ 2, 13005, 45, 8144, 430, 3514, 8128, 800, 3726, 3726, 31, 589, 871, 791, 140, 29, 8144, 22, 18, 430, 3514, 21, 2159, 26, 13005, 13, 18, 43, 197, 9, 98, 31, 259, 20, 143, 25, 14, 287, 6362, 26, 66, 430, 3514, 9, 42, 376, 21, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to format XML using XmlWriter in C#.Net? === I want the XML in format like : <?xml version="1.0" encoding="UTF-8"?> <ac:Main xmlns:trip="http://www.test.com/main.xsd" xmlns:abc="http://www.test.com/Types.xsd" xmlns:tw="http://www.test.com/TW.xsd" xmlns:ck="http://www.test.com/CK.xsd" xmlns:k1="http://www.test.com/K1.xsd" xmlns:d1="http://www.test.com/D1.xsd" xmlns:ac="http://www.test.com/Ac.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.test.com/Ac.xsd file:/D:/schema/AC.xsd"> <ac:Records> <d1:Header> <abc:FirstElement>firstValue</abc:FirstElement> </d1:Header> </ac:Records> </ac:Main> So, I wrote code using XmlWriter as following: using (XmlWriter writer = XmlWriter.Create(path, settings)) { writer.WriteStartElement("ac", "Main", "xmlns"); writer.WriteAttributeString("xmlns", "trip", null, http://www.test.com/main.xsd"); writer.WriteAttributeString("xmlns", "abc", null, http://www.test.com/Types.xsd"); writer.WriteAttributeString("xmlns", "tw", null, http://www.test.com/TW.xsd"); writer.WriteAttributeString("xmlns", "kc", null, "http://www.test.com/CK.xsd"); writer.WriteAttributeString("xmlns", "k1", null, "http://localhost:8080/K1.xsd"); writer.WriteAttributeString("xmlns", "d1", null, "http://localhost:8080/D1.xsd"); writer.WriteAttributeString("xsi","schemaLocation", "http://www.w3.org/2001/XMLSchema-instance", "http://www.test.com/Ac.xsd file:/D:/schema/AC.xsd"); // writer.WriteAttributeString("xmlns", "ac", null, "http://www.test.com/Ac.xsd "); writer.WriteStartElement("ac", "Records", "xmlns"); writer.WriteStartElement("d1", "Header", "xmlns"); writer.WriteStartElement("abc", "FirstElement", "xmlns"); writer.WriteString("firstValue"); writer.WriteEndElement(); writer.WriteEndElement(); writer.WriteEndElement(); } But uncommenting line writer.WriteAttributeString("xmlns", "ac", null, "http://www.test.com/Ac.xsd "); yields error "The prefix 'ac' cannot be redefined from 'xmlns' to 'http://www.test.com/Ac.xsd ' within the same start element tag." So, I commment that line as shown in above code and I got output as : <?xml version="1.0" encoding="utf-8"?> <ac:Main xmlns:wctrp="http://www.test.com/main.xsd" xmlns:abc="http://www.test.com/Types.xsd" xmlns:tw="http://www.test.com/TW.xsd" xmlns:ck="http://www.test.com/CK.xsd" xmlns:k1="http://www.test.com/K1.xsd" xmlns:d1="http://www.test.com/D1.xsd" xmlns:ac="http://www.test.com/Ac.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.test.com/Ac.xsd file:/D:/schema/AC.xsd" xmlns:ac="xmlns"> <ac:Records> <d1:Header xmlns:hd1="xmlns"> <abc:FirstElement xmlns:iaiabc="xmlns">firstValue</abc:FirstElement> </d1:Header> </ac:Records> </ac:Main> The unwanted attibutes are xmlns:ac="xmlns" in element 'Main', xmlns:hd1="xmlns" in 'd1:Header' and xmlns:iaiabc="xmlns" in 'abc:FirstElement'. Any one kindly suggest me what should I do to remove the unwanted attibutes and to get the output in topmost format. I am new to XmlWriter.
0
[ 2, 184, 20, 2595, 23504, 568, 23504, 9657, 19, 272, 5910, 9, 2328, 60, 800, 3726, 3726, 31, 259, 14, 23504, 19, 2595, 101, 13, 45, 13, 1, 60, 396, 8184, 615, 3726, 7, 165, 9, 387, 7, 19608, 3726, 7, 1982, 410, 8, 457, 7, 60,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
JQueryUI Slider - Tooltip for the Current Position === At the moment I have a slider and an small input text box which updates based on where you scroll on it. Here is the javascript: $("#slider").slider({ value: 500, min: 0, max: 1000, step: 50, slide: function(event, ui) { $("#budget").val(ui.value); }, change: function(event, ui) {} }); $("#budget").val($("#slider").slider("value"));​ And here is the html/css: <input type="text" id="budget" style="width:50px;text-align:center"/> <div id="slider"></div>​ However it looks a bit odd having the small text box with the figure just at the top of the slider, so I would like it to update its horizontal position so it is above the handle of the slider (.ui-slider-handle) if possible - like a sort of tooltip. Thanks in advance for any help
0
[ 2, 487, 2005, 11867, 49, 3295, 106, 13, 8, 5607, 10169, 26, 14, 866, 649, 800, 3726, 3726, 35, 14, 688, 31, 57, 21, 3295, 106, 17, 40, 284, 6367, 1854, 1649, 56, 16779, 432, 27, 113, 42, 12159, 27, 32, 9, 235, 25, 14, 8247, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
jQuery fadeIn() fadeOut() black halo in IE7 === Just like many other developers, I'm having the same black halo issue while using a CSS PNG background. (Disregard the blurriness. Focus on the black halo). ![IE7 Black Halo][1] ==========HTML========== <div class="s4-notdlg append-bottom-x" id="header"> <a class="show-settings active" href="javascript:;"></a> <div class="container"> <div class="span-13 last"> <div id="explore"> <a id="header-home-icon" href="" class=""></a> <a id="menu" href="javascript:;" class=""></a> <div id="dropdown" style="display: none;"> <div id="wrap"> </div> </div> <a style="bottom: 112px;position: absolute;right: 84px;" class="closeThis close" href="javascript:;"></a> </div> </div> </div> </div> ==========CSS========== a#menu.active { background-position: -399px -41px; } #dropdown { background: url(images/bg/menu_dropdown_bg.png) no-repeat; height: 340px; /*height: 556px;*/ position: absolute; right: -66px; top: 48px; width: 875px; z-index: 99999; display:none; } #dropdown #wrap { /*height: 413px;*/ height: 211px; margin: 26px 91px 0; width: 698px; } ==========jQuery========== //menu var menu = $('#menu'); var dropdown = $('#dropdown'); menu.toggle(function () { menu.addClass('active'); dropdown.fadeIn(); }, function () { menu.removeClass('active'); dropdown.fadeOut(); return false; }); dropdown.mouseleave(function () { menu.trigger('click'); }); This is what I have implemented and no dice: - [how-to-solve-hack-fading-semi-transparent-png-bug-in-ie8][2] - [jquery-ie-fadein-and-fadeout-opacity][3] - [jacklmoore ie-transparency-problems][4] [1]: http://i.stack.imgur.com/qeQA2.jpg [2]: http://stackoverflow.com/questions/1204457/how-to-solve-hack-fading-semi-transparent-png-bug-in-ie8 [3]: http://stackoverflow.com/questions/1284163/jquery-ie-fadein-and-fadeout-opacity [4]: http://www.jacklmoore.com/notes/ie-transparency-problems
0
[ 2, 487, 8190, 93, 11381, 108, 5, 6, 11381, 1320, 5, 6, 319, 14923, 19, 13, 660, 465, 800, 3726, 3726, 114, 101, 151, 89, 10168, 15, 31, 22, 79, 452, 14, 205, 319, 14923, 1513, 133, 568, 21, 272, 18, 18, 351, 2723, 2395, 9, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Disposing of object multiple times === I have the following code, which uses a stream to open and modify an Open XML document, and then save the new binary representation of that stream: MemoryStream stream = null; try { stream = new MemoryStream(); stream.Write(this.GetBinaryRepresentation(), 0, this.GetBinaryRepresentation().Length); using (WordprocessingDocument document = WordprocessingDocument.Open(stream, true)) { OfficeDocument.ModifyDocument(document); this.SetBinaryRepresentation(stream.ToArray()); stream = null; } } finally { if (stream != null) { stream.Dispose(); } } I had originally used two using blocks (one for the MemoryStream and the second for the WordprocessingDocument), but received warning CA2202: "Object 'stream' can be disposed more than once in method..." Per the [MSDN article][1], I modified the code to above (converting the outer using to a try), but I am still receiving this warning. I'm unsure of how I can structure this method to ensure that Dispose is called exactly once on the stream. I would prefer not to simply suppress this warning since the MSDN article states that you shouldn't rely on Dispose being safely callable multiple times. [1]: http://msdn.microsoft.com/en-us/library/ms182334.aspx
0
[ 2, 1460, 14717, 16, 3095, 1886, 436, 800, 3726, 3726, 31, 57, 14, 249, 1797, 15, 56, 2027, 21, 3766, 20, 368, 17, 17579, 40, 368, 23504, 4492, 15, 17, 94, 2079, 14, 78, 14171, 5442, 16, 30, 3766, 45, 1912, 11260, 3766, 800, 1620...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to play a movie fullscreen using MPMoviePlayerViewController on a view that is being called modally === In a view I have this code to play a movie fullscreen: NSURL *movieURL = [NSURL URLWithString:@"http://stream.qtv.apple.com/events/jan/1201oihbafvpihboijhpihbasdouhbasv/12pibasvpqihbsdfvihbasdv01_iphone_vod_ref.mov"]; self.mpc = [[MPMoviePlayerViewController alloc] initWithContentURL:movieURL]; NSLog(@"self mpc: %@", self.mpc); [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviePlayBackDidFinish:) name:MPMoviePlayerPlaybackDidFinishNotification object:self.mpc ]; self.mpc.moviePlayer.movieSourceType = MPMovieSourceTypeUnknown; self.mpc.moviePlayer.shouldAutoplay = YES; self.mpc.view.frame = self.view.frame; [self.view addSubview:self.mpc.view]; self.mpc.moviePlayer.fullscreen = YES; [self.mpc.moviePlayer play]; The view itself is being called with this code UIStoryboard *mainStoryboard = [UIStoryboard storyboardWithName:@"MainStoryboard_iPhone" bundle: nil]; TestViewController *controller = [mainStoryboard instantiateViewControllerWithIdentifier: @"testController"]; [self presentModalViewController:controller animated:YES]; The movie is playing ok, but on the top there is some room the MPMoviePlayerViewController isn't using. Here's a screenshot showing the problem: https://www.dropbox.com/s/1dje2ar6ynk6855/IMG_2447.PNG (I've made the background of the testController view yellow) How can this movie be played fullscreen?
0
[ 2, 184, 20, 418, 21, 1308, 503, 7187, 568, 4628, 22607, 14049, 4725, 12898, 1252, 27, 21, 1418, 30, 25, 142, 227, 7226, 1326, 800, 3726, 3726, 19, 21, 1418, 31, 57, 48, 1797, 20, 418, 21, 1308, 503, 7187, 45, 13, 103, 4082, 255,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Parsing and running .sql script using TinyTds Ruby Gem === I am automating the deployment of db scripts for a push button nightly deploy. My first approach was to use sqlcmd on windows terminal, save the results to txt file, and parse it to ensure the script was successful. Parsing the file and finding the return code was problematic, so I turned to TinyTds. Here is my code: client = TinyTds::Client.new(:username => DB_USER, :password => DB_PASSWORD, :dataserver => DB_SERVERNAME, :timeout => 1200) result = client.execute(IO.read(filename)) puts result.return_code Yields either nil or the following error (depending on the contents of the .sql script) run_sql.rb:24:in `execute': Attempt to initiate a new Adaptive Server operation with results pending (TinyTds::Error)
0
[ 2, 2017, 18, 68, 17, 946, 13, 9, 18, 22402, 3884, 568, 3228, 38, 43, 18, 10811, 8551, 800, 3726, 3726, 31, 589, 3108, 79, 1880, 14, 10475, 16, 13, 9007, 17505, 26, 21, 3250, 5167, 343, 102, 17617, 9, 51, 64, 2141, 23, 20, 275,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Interface builder: lock selection === Is it possible to select an item in the outline view (under "Object") and lock the selection so I want be able to select any other item in the canvas? Basically, I have lots of objects all over the canvas and would like to move the items around but every time I click there something else gets selected.
0
[ 2, 6573, 14960, 45, 3991, 3155, 800, 3726, 3726, 25, 32, 938, 20, 5407, 40, 9101, 19, 14, 11160, 1418, 13, 5, 4579, 13, 7, 23793, 7, 6, 17, 3991, 14, 3155, 86, 31, 259, 44, 777, 20, 5407, 186, 89, 9101, 19, 14, 9696, 60, 113...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
MySql insert statment is giving Error 1064: exited abnormally with signal 11: Segmentation fault: 11 === I am trying to insert data into a mySql database using a python script. When I run the python script I receive the following error: Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'dataBaseName' exited abnormally with signal 11: Segmentation fault: 11 ')' at line 2 Here is the insert statement in my code: with con: cur = con.cursor() for mID,l,tm,s,f,p,m in zip(messageID,level,time,sender,facility,pid,message): cur.execute("INSERT INTO LogData(ASLMessageID,Level,Time,Sender,Facility,PID,Message) VALUES('"+ mID + "','" + l + "'," + tm + ",'" + s + "','" + f +"','" + p +"','" + m + "')") There are 7 lists one for each column in the table and I am trying to simply fill the table.This worked for 4 other tables but for some reason this one is giving this error.Thanks for any help you can give.
0
[ 2, 51, 18, 22402, 14692, 12819, 1130, 25, 1438, 7019, 332, 3470, 45, 16974, 17804, 102, 29, 2800, 547, 45, 5631, 857, 4173, 45, 547, 800, 3726, 3726, 31, 589, 749, 20, 14692, 1054, 77, 21, 51, 18, 22402, 6018, 568, 21, 20059, 3884...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Android running infinite loop === I'm creating and android program which needs to to continuously keep sending data over the bluetooth now i use something like this for(;;) { //send message } though this works it freezes my UI and app how can i implement the same without freezing my ui? iam sure that the app is sending the data as i monitor the data.
0
[ 2, 13005, 946, 9698, 5293, 800, 3726, 3726, 31, 22, 79, 2936, 17, 13005, 625, 56, 2274, 20, 20, 11738, 643, 4907, 1054, 84, 14, 705, 15808, 130, 31, 275, 301, 101, 48, 26, 5, 73, 73, 6, 13, 1, 12894, 18, 2451, 2802, 13, 1, 3...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Building monodroid sample map applications === Using latest download of map sample application 'MapsAndLoactionDemo' from Xamarin and in Visual Studio 2010 I get the following compile error(s): Error 10 Activate(java.lang.String,java.lang.String,java.lang.Object,java.lang.Object[]) in mono.android.TypeManager cannot be applied to (java.lang.String,java.lang.String,mapsandlocationdemo.MapWithOverlayActivity,java.lang.Object[]) mono.android.TypeManager.Activate ("MapsAndLocationDemo.MapWithOverlayActivity, MapsAndLocationDemo, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null", "", this, new java.lang.Object[] { }); D:\Projects\Android\MapsAndLocationDemo\MapsAndLocationDemo\obj\Debug\android\src\mapsandlocationdemo\MapWithOverlayActivity.java 25 28 MapsAndLocationDemo What is wrong?
0
[ 2, 353, 4129, 43, 18524, 5717, 2942, 3767, 800, 3726, 3726, 568, 5736, 7121, 16, 2942, 5717, 3010, 13, 22, 15022, 18, 290, 1415, 8645, 19274, 22, 37, 993, 3812, 2445, 17, 19, 3458, 1120, 498, 31, 164, 14, 249, 26561, 7019, 5, 18, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I loop mount programmatically? === I have recently written a [guide on how to mount partitions from image files on Raspberry Pi.SE](http://raspberrypi.stackexchange.com/q/855/86). The instructions are rather complicated and I have a bit of time, so want to replace them by [a C program](https://github.com/alexchamberlain/piimg). I have successfully listed the partitions of the image and calculated to appropriate offsets. In the original instructions, we needed to run $ sudo mount -o loop,offset=80740352 debian6-19-04-2012.img /mnt I now need to do this in code. I have found the [mount](http://linux.die.net/man/2/mount) function and [libmount in util-linux](http://git.kernel.org/?p=utils/util-linux/util-linux.git;a=summary), but I'm struggling to find any decent docs for it. So, does anyone know how I can loop mount a partition/offset from a file programmatically?
0
[ 2, 184, 107, 31, 5293, 2149, 625, 6732, 1326, 60, 800, 3726, 3726, 31, 57, 1989, 642, 21, 636, 17599, 27, 184, 20, 2149, 10711, 18, 37, 1961, 6488, 27, 29476, 4194, 9, 870, 500, 5, 21127, 6903, 525, 3401, 7393, 2159, 9, 25325, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Aligning Drop Down Menu's CSS === I am currently working on a pure css multilevel drop-down menu and I cannot for the life of me figure out how to get the drop-down to automatically align to the left of side of the parent menu. **Here is a screenshot** ![Click to see Drop-down screenshot][1] [1]: http://i.stack.imgur.com/bhl4r.jpg **Here is the css** /*---------HEADER MENU---------*/ #header .content ul.menu li ul{ display: none; margin: 0; float: left; padding: 0; position: absolute; z-index: 200;} #header .content ul.menu li ul li{ position: relative; top: 20px; margin: 0; } #header .content ul.menu li:hover > ul{ display: inline; float: left; width: 125px; } #header .content ul.menu li ul li li{ width: 125px; float: left; position: absolute;} /*---------VISITORS MENU---------*/ #block-menu-menu-visitors .content ul.menu{ z-index: 200; } #block-menu-menu-visitors .content ul.menu li{ padding: 2px 15px 2px 15px; display: inline-block; float: left; background-color: #ffff90; } #block-menu-menu-visitors .content ul.menu li:hover{ padding: 2px 15px 2px 15px; float: left; display: inline-block; background-color: #ffffaa; } Any help or push in the right direction will help! Thank you
0
[ 2, 23389, 68, 2804, 125, 11379, 22, 18, 272, 18, 18, 800, 3726, 3726, 31, 589, 871, 638, 27, 21, 4267, 272, 18, 18, 1889, 3906, 2804, 8, 2968, 11379, 17, 31, 1967, 26, 14, 201, 16, 55, 1465, 70, 184, 20, 164, 14, 2804, 8, 29...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to force Entity Framework 4.0 to generate parameters of equivalent size to their corresponding database columns === I have a very simple table called `Member`, which consists of the following: CREATE TABLE [dbo].[Member]( [Member_MemberId] [int] IDENTITY(1000,1) NOT NULL, [Member_ExternalId] [varchar](32) NULL, [Member_ConsumerId] [varchar](32) NULL, CONSTRAINT [PK_Member] PRIMARY KEY NONCLUSTERED ( [Member_MemberId] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY] I’m running a query using EF 4.0 from a datacontext as follows: return Members.SingleOrDefault(member => member.ExternalId == externalId); The generated SQL looks like this: exec sp_executesql N'SELECT TOP (2) [Extent1].[Member_MemberId] AS [Member_MemberId], [Extent1].[Member_ExternalId] AS [Member_ExternalId], [Extent1].[Member_ConsumerId] AS [Member_ConsumerId] FROM [dbo].[Member] AS [Extent1] WHERE [Extent1].[Member_ExternalId] = @p__linq__0',N'@p__linq__0 varchar(8000)',@p__linq__0='Paul' From a performance POV, this query is suboptimal, given that it automatically casts the Member_ExternalId column as `varchar(8000)`, given that the column itself is limited to `varchar(32)`. Is there a way to force EF to generate on-the-fly parameters of size equivalent to their corresponding rows?
0
[ 2, 184, 20, 558, 9252, 6596, 268, 9, 387, 20, 7920, 12905, 16, 4602, 1072, 20, 66, 7265, 6018, 7498, 800, 3726, 3726, 31, 57, 21, 253, 1935, 859, 227, 13, 1, 6990, 1, 15, 56, 2043, 16, 14, 249, 45, 1600, 859, 636, 43, 1192, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
call from an array with an array === i want to call from an array using the get array but it doesn't work what is the correct way to format this? if(isset($_GET["category"])){ $cat = 'SELECT DISTINCT `Category` FROM `products`'; $result = $mysqli->query($cat); $i='0'; while ($row = $result->fetch_array(MYSQLI_ASSOC)){ $i++; $Category = $row["Category"]; $id = array($i => $Category); } $result->close(); $query = 'SELECT * FROM products ORDER BY Code WHERE Category="'. $id[$_GET["category"]]. '"'; }
0
[ 2, 645, 37, 40, 7718, 29, 40, 7718, 800, 3726, 3726, 31, 259, 20, 645, 37, 40, 7718, 568, 14, 164, 7718, 47, 32, 1437, 22, 38, 170, 98, 25, 14, 4456, 161, 20, 2595, 48, 60, 100, 5, 11001, 38, 5, 4403, 1, 3060, 2558, 7, 143...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
open word document when running service === I have written the following statement to open the word document. System.IO.Directory.CreateDirectory("D:\\urvashi"); objMyDoc = ApObj.Documents.Open(filename, MsoTriState.msoTrue, MsoTriState.msoTrue, MsoTriState.msoFalse); System.IO.Directory.CreateDirectory("D:\\komal"); Its working fine when I checking it by debugging the code. but when running this code through service its not working properly. its creating directory "urvashi" in D drive but its not creating directory "komal" in D drive. its meaning that the error is in the second statment when running service. what could be problem? Help
0
[ 2, 368, 833, 4492, 76, 946, 365, 800, 3726, 3726, 31, 57, 642, 14, 249, 3331, 20, 368, 14, 833, 4492, 9, 329, 9, 1963, 9, 10197, 93, 9, 6037, 1373, 10197, 93, 5, 7, 43, 45, 1, 911, 28787, 49, 7, 6, 73, 5122, 728, 915, 1379...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Matching regex at specific positions === Is it possible to match strings using regex that also have constraints on their position within the text? For example given a hex encoded file I would like to match hex representations that correspond to characters whose hex representation is larger than 0x40. The position constraint should be that matching should start at even positions. E.g. `034673911921` should match at `46`,`73`,`91` but not at `92`.
0
[ 2, 10120, 7953, 1706, 35, 1903, 3062, 800, 3726, 3726, 25, 32, 938, 20, 730, 7887, 568, 7953, 1706, 30, 67, 57, 16747, 27, 66, 649, 363, 14, 1854, 60, 26, 823, 504, 21, 24, 396, 13665, 3893, 31, 83, 101, 20, 730, 24, 396, 1866...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Instantiate class with type parameters with the type of a variable in Scala === I’ve got the following types class Translator[To <: Language] { ... } abstract class Language object English object German Is there a way to instantiate `Translator` from a `val` that is either of type `English` or `German`? I’m looking for something like the following (which doesn’t work): val lang = if (someCondition) English else German val translator = new Translator[classOf[lang]]
0
[ 2, 6322, 15882, 718, 29, 1001, 12905, 29, 14, 1001, 16, 21, 7612, 19, 25975, 800, 3726, 3726, 31, 1, 195, 330, 14, 249, 2551, 718, 10889, 2558, 262, 13, 1, 45, 816, 500, 13, 1, 13, 9, 9, 9, 13, 1, 8502, 718, 816, 3095, 486, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to make CITE tag entirely indented? === How to make CITE tag entirely indented? I have tested all of the padding-left: 200px; margin-left: 200px; text-indent: 200px; and in all cases only first line was affected. How to shift right entire paragraph?
0
[ 2, 184, 20, 233, 13, 10424, 3383, 2894, 19, 817, 1427, 60, 800, 3726, 3726, 184, 20, 233, 13, 10424, 3383, 2894, 19, 817, 1427, 60, 31, 57, 7631, 65, 16, 14, 4432, 3258, 8, 9742, 45, 2327, 306, 396, 73, 5440, 8, 9742, 45, 2327...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Can't delete element from @OneToMany collection === i have an entity **Entity1** that have **one to many** relation with **Entity2** as follows: **1- Entity1:** @Entity @Table(name = "Entity1", catalog = "mydb") public class Entity1 implements java.io.Serializable { @OneToMany(fetch = FetchType.LAZY, mappedBy = "entity1", cascade = CascadeType.ALL) @OrderBy("id") private Set<Entity2> collection = new HashSet<Entity2>( 0); } **2- Entity2:** (equals and hashcode method overridden) @Entity @Table(name = "entity2", catalog = "advertisedb") public class Entity2 implements java.io.Serializable { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Column(name = "pkid", unique = true, nullable = false) @Basic(fetch = FetchType.EAGER) private long id; @ManyToOne(fetch = FetchType.EAGER) @JoinColumn(name = "fk_entity1", nullable = false) private Entity1 entity1; @ManyToOne(fetch = FetchType.EAGER) @JoinColumn(name = "apid", nullable = false) private Entity3 entity3; } **3- Here's how i am removing the entity from the collection:** entity1Obj.getEntity2().remove(entity2); log.debug("size after remove: "+ entity1Obj.getEntity2().size()); // size decreases correctly, so the entity is removed from the collection entity1Dao.updateEntity1(entity1); **4- DAO method:** public void updateEntity1(Entity1 entity1) { getCurrentSession().update(getCurrentSession().merge(entity1)); } **Problem:** what i get in the console, is a select query for the entity2 that should be removed, and no delete query, and nothing is getting deleted. please advise how to fix this issue.
0
[ 2, 92, 22, 38, 27448, 4520, 37, 13, 1, 849, 262, 14842, 1206, 800, 3726, 3726, 31, 57, 40, 9252, 13, 1409, 2291, 856, 165, 1409, 30, 57, 13, 1409, 849, 20, 151, 1409, 5827, 29, 13, 1409, 2291, 856, 135, 1409, 28, 2415, 45, 13,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
MySQL making whitespace matter === Apparently a very rare issue, but IMO extremely annoying and WRONG: Trailing whitespace in MySQL aren't used in comparison: mysql> SELECT "A" = "A "; +------------+ | "A" = "A " | +------------+ | 1 | +------------+ 1 row in set (0.00 sec) This is especially problematic in the following scenario: mysql> SELECT COUNT(*) FROM eq WHERE name != TRIM(name); +------------+ | COUNT(*) | +------------+ | 0 | +------------+ 1 row in set (0.00 sec) mysql> UPDATE eq SET name=TRIM(name); Query OK, 866 row affected (0.01 sec) Rows matched: 650907 Changed: 866 Warnings: 0 Is there a way to configure MySQL to treat whitespace properly?
0
[ 2, 51, 18, 22402, 544, 359, 5582, 1161, 800, 3726, 3726, 3083, 21, 253, 2890, 1513, 15, 47, 13, 11947, 3898, 17610, 17, 1389, 45, 14323, 359, 5582, 19, 51, 18, 22402, 4847, 22, 38, 147, 19, 6050, 45, 51, 18, 22402, 1, 5407, 13, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is perfect pitch,variance and speed values in flite tts for iphone === Hi i am successfully added flite-tts(flite-1.4) and i am here the voice for my input text but the problem is some times the words are not clearly to heard, can any one suggest what are the best values(pitch,variance) to here the input text . Thanks in advance.
0
[ 2, 98, 25, 2107, 5678, 15, 8220, 2416, 17, 1362, 4070, 19, 25028, 62, 13, 38, 38, 18, 26, 21024, 800, 3726, 3726, 4148, 31, 589, 3673, 905, 25028, 62, 8, 38, 38, 18, 5, 410, 10601, 8, 165, 9, 300, 6, 17, 31, 589, 235, 14, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Few Questions on MVC and HMVC === I recently started learning MVC and HMVC with swing and have a few questions. As an example I'll say that there is a view A with controller A and model A. View A contains another view B with controller B and model B. So controller B would be the child of controller A. 1) With MVC is it not possible to have multiple view components in a given window? Because with HMVC when the controller of a view component does not know how to handle an event it will pass to other controllers. For example an action on view A goes to controller A and if controller A cannot handle it, it will be passed to controller B. How can this kind of functionality be achieved with MVC? 2) With HMVC it is possible for one view component to send messages ( through the controller hierarchy ) to models that are not directly related to the view. But what if multiple view components should be informed of the change of a single model? For example if a change in model B should be informed to both view A and B. Does both those views register as listeners to model B? Or does both controllers A and B register as listeners to model B and views A and B get to know the change in model B through the controllers? Thanks for any answers.
0
[ 2, 310, 2346, 27, 307, 8990, 17, 13, 7015, 8990, 800, 3726, 3726, 31, 1989, 373, 2477, 307, 8990, 17, 13, 7015, 8990, 29, 5587, 17, 57, 21, 310, 2346, 9, 28, 40, 823, 31, 22, 211, 395, 30, 80, 25, 21, 1418, 21, 29, 9919, 21,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
In android list view swipe action only to one item at one time ? === I have implemented list view in this item can swipe to left or right.When user swipe any item then automatically another item gets swiped. eg. There are 10 items in list 5 are showing on screen and other get view after scrolling list view.now when i left swipe on item 1 item 6 automatically get swiped . how to resolve this problem. I have used notifyDataSetChanged() on my adapter but not get solved. Thanks in advance ....
0
[ 2, 19, 13005, 968, 1418, 27246, 1028, 104, 20, 53, 9101, 35, 53, 85, 13, 60, 800, 3726, 3726, 31, 57, 6807, 968, 1418, 19, 48, 9101, 92, 27246, 20, 225, 54, 193, 9, 3185, 4155, 27246, 186, 9101, 94, 7499, 226, 9101, 3049, 26551,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Returning html of an element along with the element in jquery === I have mark up like <div id="div1"> <div id="div2"> blah blah </div> </div> If I use $("#div1").html(), it returns the div#div2. But I want to get the complete html. i.e, along with div#div1. Is there any way to do this?
0
[ 2, 2485, 13, 15895, 16, 40, 4520, 303, 29, 14, 4520, 19, 487, 8190, 93, 800, 3726, 3726, 31, 57, 943, 71, 101, 13, 1, 12916, 4924, 3726, 7, 12916, 165, 7, 1, 13, 1, 12916, 4924, 3726, 7, 12916, 135, 7, 1, 27220, 27220, 13, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to add text shadow to navbar links (Twitter Bootstrap)? === So far I've tried: .navbar-inner { text-shadow: black 0.1em 0.1em 0.2em; } And: .nav > li > a { text-shadow: black 0.1em 0.1em 0.2em; } Neither works. What gives? FYI my navbar html code is the same as the Twitter Bootstrap demo code: <div class="navbar navbar-fixed-top"> <div class="navbar-inner"> <div class="container"> <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </a> <a class="brand" href="#">Test Inc.</a> <div class="nav-collapse"> <ul class="nav"> <li class="active"><a href="#">Home</a></li> <li><a href="#about">About</a></li> <li><a href="#contact">Contact</a></li> </ul> </div><!--/.nav-collapse --> </div> </div> </div>
0
[ 2, 184, 20, 3547, 1854, 3118, 20, 16048, 1850, 6271, 13, 5, 38, 13098, 106, 5894, 16514, 6, 60, 800, 3726, 3726, 86, 463, 31, 22, 195, 794, 45, 13, 9, 18343, 1850, 8, 18005, 13, 1, 1854, 8, 18396, 45, 319, 713, 9, 165, 1503, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Write result into text file in CUDA / Optix === I wanted to know if it was possible to write a text file of variables calculated in my program Cuda / Optix. That's variables are in my .cu files and therefore can not be written by the CPU. If someone have an idea, i would be very kind :) thanx!!!!
0
[ 2, 2757, 829, 77, 1854, 3893, 19, 272, 5729, 13, 118, 17034, 4028, 800, 3726, 3726, 31, 417, 20, 143, 100, 32, 23, 938, 20, 2757, 21, 1854, 3893, 16, 12157, 10785, 19, 51, 625, 272, 5729, 13, 118, 17034, 4028, 9, 30, 22, 18, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
360 degree view in iOS application === I am working in an iPhone application which requires to create a 360degree view of an image. Upon my search what i could find is that images taken of the image and the images are rotated in a view . I would like to know if anyone has a good solution or any good tutorial on how to achieve a really good this work. Thank you
0
[ 2, 11760, 1168, 1418, 19, 13, 7760, 3010, 800, 3726, 3726, 31, 589, 638, 19, 40, 21024, 3010, 56, 4781, 20, 1600, 21, 11760, 17513, 1418, 16, 40, 1961, 9, 685, 51, 2122, 98, 31, 110, 477, 25, 30, 3502, 658, 16, 14, 1961, 17, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I initialize a XAML UserControl with fake data design-time when working with the control itself? === I have a basic WinRT XAML UserControl with a single dependency property as implemented below. The user control is apparently only constructed design-time when used in another Page or UserControl. The text "Hello world" is not rendered when I work in the designer with the user control itself. How can I make the designer initialize the user control with data also in this case? XAML: <UserControl x:Class="GTWin8.Ui.SimpleBinding" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:GTWin8.Ui" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" d:DesignHeight="300" d:DesignWidth="400" x:Name="ThisControl"> <Grid Background="Black"> <TextBlock Text="{Binding Path=Message, ElementName=ThisControl}" HorizontalAlignment="Left" Margin="10,10,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Height="280" Width="380"/> </Grid> </UserControl> Code-behind: public sealed partial class SimpleBinding : UserControl { public static DependencyProperty MessageProperty = DependencyProperty.Register( "Message", typeof(String), typeof(SimpleBinding), new PropertyMetadata(null)); public String Message { get { return (String)GetValue(MessageProperty); } set { SetValue(MessageProperty, value); } } public SimpleBinding() { this.InitializeComponent(); Message = "Hello world"; } }
0
[ 2, 184, 107, 31, 2104, 2952, 21, 13, 6791, 8184, 4155, 12898, 29, 7031, 1054, 704, 8, 891, 76, 638, 29, 14, 569, 1145, 60, 800, 3726, 3726, 31, 57, 21, 2125, 628, 5256, 13, 6791, 8184, 4155, 12898, 29, 21, 345, 26835, 1354, 28, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Magento Sitemap === I have about 3500 products in magento cart, when I generate sitemap from admin, it generate only 2268 url, is this correct amount, as I have categories, layered navigation, but layered navigation Urls are not being displayed. Any Idea
0
[ 2, 4723, 17050, 689, 15022, 800, 3726, 3726, 31, 57, 88, 203, 6000, 1985, 19, 4723, 17050, 6420, 15, 76, 31, 7920, 689, 15022, 37, 21, 43, 2160, 15, 32, 7920, 104, 1024, 4279, 287, 6362, 15, 25, 48, 4456, 2006, 15, 28, 31, 57, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
cocoa status app can't be show === @implementation testIconAppDelegate @synthesize window = _window; -(void)awakeFromNib{ statusItem = [[[NSStatusBar systemStatusBar] statusItemWithLength:NSVariableStatusItemLength] retain]; [statusItem setMenu:menu]; [statusItem setTitle:@"Notification Center"]; [statusItem setHighlightMode:YES]; [statusItem setImage:[NSImage imageNamed:@"img"]]; } - (IBAction)connect:(id)sender { [NSApp activateIgnoringOtherApps:YES ]; [_window makeKeyAndOrderFront:nil]; } - (IBAction)quit:(id)sender { [NSApp terminate:nil]; } - (void)applicationDidFinishLaunching:(NSNotification *)aNotification { // Insert code here to initialize your application } @end /* I developed this cocoa status app, but when I run my project the icon appears and disappears very quickly. Any suggestion ? how can fix this problem and make the app be shown all time? */
0
[ 2, 24507, 1782, 4865, 92, 22, 38, 44, 298, 800, 3726, 3726, 13, 1, 8983, 413, 1130, 857, 1289, 49, 1126, 7753, 24249, 3322, 13, 1, 9507, 124, 10454, 1463, 800, 13, 1, 27508, 73, 13, 8, 5, 2625, 1340, 6, 58, 22016, 2665, 889, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
checking if it is windows or unix before creating a directory in C++ === I wrote this piece of code to check if a directory exists in both Windows and Unix, but I'm not sure whether it is correct: int writeFiles(std::string location) { // USED TO FILE SYSTEM OPERATION struct stat st; // DEFINE THE mode WHICH THE FILE WILL BE CREATED const char * mode = "w+b"; /* local curl variable */ // CHECK IF THE DIRECTORY TO WHERE THE FILE ARE GOING EXIST // IF NOT, CREATE IT if(stat(location.c_str(), &st) != 0){ #ifndef (defined _WIN32 || defined __WIN64) /* WIN32 SYSTEM */ if (!CreateDirectory(location.c_str(), NULL)){ std::string msg("The location directory did not exists, can't be created\n"); throw std::runtime_error(msg); } #elif defined __unix__ /* in the case of unix system */ if(mkdir(location.c_str(), S_IRWXU) != 0){ std::string msg("The dest_loc directory did not exist, can't be created\n"); throw std::runtime_error(msg); } #endif ... more code down here. `location` is the path to where the files are supposed to copied. However, before I start copying the files, I have to check whether the directory exists or not, for both Windows and Linux. Could someone please give me some input on that problem? Thanks
0
[ 2, 9886, 100, 32, 25, 1936, 54, 22540, 115, 2936, 21, 16755, 19, 272, 20512, 800, 3726, 3726, 31, 738, 48, 1855, 16, 1797, 20, 2631, 100, 21, 16755, 5636, 19, 156, 1936, 17, 22540, 15, 47, 31, 22, 79, 52, 562, 1472, 32, 25, 44...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
TFS 2010 - Making fields required === I'm a first time user of this site. Apologies in advance if I hadn't searched well enough for my question. I'm looking at tweaking TFS 2010's bug creation abilities slightly. I'd like to force the 'Comment' field linked to the History. Basically, after someone makes a series of changes, I want to force that person to enter some details before committing the changes. Does anyone have any experience with this? Thanks, Chris
0
[ 2, 13, 11720, 18, 498, 13, 8, 544, 2861, 1390, 800, 3726, 3726, 31, 22, 79, 21, 64, 85, 4155, 16, 48, 689, 9, 27101, 19, 3612, 100, 31, 1241, 22, 38, 9036, 134, 511, 26, 51, 1301, 9, 31, 22, 79, 699, 35, 28769, 68, 13, 117...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Error when trying to use PDO object === I'm an inexperienced php programmer and only found out about PDO a few days ago. I'm now trying to port my website code over to using PDO, but I am getting an error when I try to use the PDO object that I create. The error I'm getting is: Fatal error: Call to a member function prepare() on a non-object in ... file2.php ... The code looks like this: **index.php** class myClass { ... variables ... ... functions ... public function myFunction() // gets called on page load, outputs content to page { ... stuff ... require('file1.php'); ... stuff ... } } **file1.php** require_once('mysql_connect.php'); // create pdo object if not created ... stuff ... require_once('file2.php'); // I can use the PDO object in here to make queries $output = function2(); // function2 is in file2.php ... stuff ... **file2.php** require_once('mysql_connect.php'); // create pdo object if not created function function2() { ... stuff ... // PDO error occurs here $stmt = $db->prepare(...); makeQuery($stmt, array(...)); return $something; } **mysql_connect.php** try { $db = new PDO("mysql:$dbhost=localhost;dbname=$dbname;charset=utf8", $dbuser, $dbpass, array(PDO::ATTR_EMULATE_PREPARES => false, PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)); } catch (PDOException $e) { print "Error!: " . $e->getMessage() . "<br/>"; die(); } function makeQuery($stmt, $array = array()) { try { $stmt->execute($array); } catch (PDOException $e) { print "Error!: " . $e->getMessage() . "<br/>"; die(); } }
0
[ 2, 7019, 76, 749, 20, 275, 351, 537, 3095, 800, 3726, 3726, 31, 22, 79, 40, 27624, 13, 26120, 17968, 17, 104, 216, 70, 88, 351, 537, 21, 310, 509, 1464, 9, 31, 22, 79, 130, 749, 20, 1295, 51, 2271, 1797, 84, 20, 568, 351, 53...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Ria Context.Load method error list === Where can I find a list of all possible errors when accesing Context.Load for Silverlight 5.0 C# RIA services ? thanks
0
[ 2, 13, 2548, 4141, 9, 8294, 2109, 7019, 968, 800, 3726, 3726, 113, 92, 31, 477, 21, 968, 16, 65, 938, 11908, 76, 7602, 160, 68, 4141, 9, 8294, 26, 1172, 3130, 331, 9, 387, 272, 5910, 13, 2548, 687, 13, 60, 3669, 3, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Download android source code for 2.3.3 & open it as an eclipse project === I found this [http://source.android.com/source/downloading.html][1] but it seems to have so many steps has to be done. Is there another way of downloading android source version we need from a zip file or svn & build it as an eclipse project? I downloaded source as jar and extracted source files from [http://grepcode.com/snapshot/repository.grepcode.com/java/ext/com.google.android/android/2.3.3_r1][2] but could not open it as eclipse project. What I need is to build customized android version of my own. [1]: http://source.android.com/source/downloading.html [2]: http://grepcode.com/snapshot/repository.grepcode.com/java/ext/com.google.android/android/2.3.3_r1
0
[ 2, 7121, 13005, 1267, 1797, 26, 172, 9, 240, 9, 240, 279, 368, 32, 28, 40, 11652, 669, 800, 3726, 3726, 31, 216, 48, 636, 21127, 6903, 12097, 9, 290, 18524, 9, 960, 118, 12097, 118, 2968, 16866, 9, 15895, 500, 2558, 165, 500, 47...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Visual Studio 2010 builds excluded files === We have some excluded files in a web application project. One developer's machine builds the project fine. Another developer's machine sees the excluded files and decides to compile them, therefore throwing compilation errors related to those files. Both are using VS2010 SP1. I am not aware of any compilation options that could cause this difference. Any ideas?
0
[ 2, 3458, 1120, 498, 1895, 18, 13599, 6488, 800, 3726, 3726, 95, 57, 109, 13599, 6488, 19, 21, 2741, 3010, 669, 9, 53, 10058, 22, 18, 1940, 1895, 18, 14, 669, 1123, 9, 226, 10058, 22, 18, 1940, 6895, 14, 13599, 6488, 17, 6674, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Modifying UISearchBar Cancel button font text color and style === Is there any way to change the text font and color of the UISearchBar Cancel button without subclassing the searchbar?
0
[ 2, 17579, 68, 13, 5661, 25136, 1850, 14815, 5167, 9978, 1854, 1665, 17, 1034, 800, 3726, 3726, 25, 80, 186, 161, 20, 753, 14, 1854, 9978, 17, 1665, 16, 14, 13, 5661, 25136, 1850, 14815, 5167, 366, 972, 1898, 68, 14, 2122, 1850, 60...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Faking a 404, 500 and === I am creating a simulation game (web service), and need to fake those error pages. As far as I know, and can see, there isn't a way to fake a 404, or 500 etc. Is this right? Are we able to do this programmatically? I know I could just make a 404 page and redirect to it... But I'm trying to make it a little more realistic.
0
[ 2, 1399, 1581, 21, 13, 23397, 15, 3033, 17, 800, 3726, 3726, 31, 589, 2936, 21, 10926, 250, 13, 5, 14113, 365, 6, 15, 17, 376, 20, 7031, 273, 7019, 4434, 9, 28, 463, 28, 31, 143, 15, 17, 92, 196, 15, 80, 2532, 22, 38, 21, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Word list file for Oxford Dictionary === I need to have a dict file based on the list of words in the Oxford Dictionary. now I have access to Linux's word list and that's just not good for my purpose. does anyone know where I can download this, as hours of googling has thrown a null argument exception! Any help is much appreciated. Cheers.
0
[ 2, 833, 968, 3893, 26, 2845, 9186, 800, 3726, 3726, 31, 376, 20, 57, 21, 13, 16315, 3893, 432, 27, 14, 968, 16, 715, 19, 14, 2845, 9186, 9, 130, 31, 57, 1381, 20, 13024, 22, 18, 833, 968, 17, 30, 22, 18, 114, 52, 254, 26, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
VC 2010 Executable Not Running on Other Computers - No Errors === I'm running into a strange thing while making a game in VC++. I'm using the Cocos2d-x platform and VC++ 2010 in Windows 7 and it works perfectly fine on my machine. However, I have another computer that is Windows XP. I am currently using /MT so there is no problem with the runtime library, but the program doesn't run in Windows XP and it doesn't even produce an error. I have tried with 2010 C++ redist on the other computer, and it doesn't work with or without. There is nothing in the console and no error log. Nothing appears odd in DependencyWalker, only missing internet explorer frame stuff. What can cause a program on windows XP to execute and close immediately without leaving an error? Anyone has any ideas? I am using the game framework's dynamic linked libraries, so could that be a problem? Also, even though I linked statically, my executable is only about 140 KB. Is something messing up? Thanks for any help
0
[ 2, 13, 8990, 498, 1396, 17194, 5924, 52, 946, 27, 89, 7774, 13, 8, 90, 11908, 800, 3726, 3726, 31, 22, 79, 946, 77, 21, 2578, 584, 133, 544, 21, 250, 19, 13, 8990, 20512, 9, 31, 22, 79, 568, 14, 22470, 18, 135, 43, 8, 396, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to pass arguments to jQuery widget? === This is a noob question. Suppose I have a `jQuery` dialog opened on a button click. The dialog is implemented as a `jQuery` widget: <pre> (function ($) { $.widget("myApp.myDialog", { _create: fnction() {...} // create a dialog _init: fnction() {...} // open a dialog }) }(jQuery)); </pre> I open this dialog on button click as follows: <pre> $('#myButton').bind('click', function() { $(this).myDialog(); }); </pre> So far, so good. I hope it makes sense. Now I would like to _disable_ that button when the dialog is opened and _enable_ it when the dialog is closed. How can I pass the button to the dialog widget ?
0
[ 2, 184, 20, 1477, 10553, 20, 487, 8190, 93, 4807, 43, 3060, 60, 800, 3726, 3726, 48, 25, 21, 90, 4995, 1301, 9, 5787, 31, 57, 21, 13, 1, 728, 8190, 93, 1, 28223, 520, 27, 21, 5167, 10840, 9, 14, 28223, 25, 6807, 28, 21, 13, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
how to write a C/C++ function as mylogsend(),intending to send messages complied with the Syslog Protocol(similar to UDP)? === I'd like to send some information using the syslog protocol to a linux server.But I want to do it in different OSs,so I'd like to write a C/C++ function mylogsend() to allow me to realize it.Just to funtion strictly complying with the syslog protocol,using a UDP socket.Thanks very much!
1
[ 2, 184, 20, 2757, 21, 272, 118, 150, 20512, 1990, 28, 51, 5567, 18, 2451, 5, 6, 15, 6391, 7601, 20, 2660, 7561, 27498, 29, 14, 10315, 18, 5567, 8494, 5, 19107, 20, 287, 7431, 6, 60, 800, 3726, 3726, 31, 22, 43, 101, 20, 2660, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is wrong with saving image into sqlite database? === I want to write an image into database as blob type. But when i load this image from database, it's different from source image. I write source image into database as follow: ByteArrayOutputStream bs = new ByteArrayOutputStream(); Bitmap medBmp = BitmapFactory.decodeStream(this.getResources().openRawResource(R.drawable.source_image)); medBmp.compress(Bitmap.CompressFormat.JPEG, 100, bs); initialValues.put(IMAGE_COL,bs.toByteArray()); And here are images source image: ![enter image description here][1] Image is loaded from database ![enter image description here][2] The background of source image is transparent, but the image is loaded from db has background in black.why are they different?What is wrong with my code? Please help me out, thanks you so much. [1]: http://i.stack.imgur.com/5CiyV.png [2]: http://i.stack.imgur.com/tLtRZ.jpg
0
[ 2, 98, 25, 1389, 29, 7599, 1961, 77, 4444, 10601, 6018, 60, 800, 3726, 3726, 31, 259, 20, 2757, 40, 1961, 77, 6018, 28, 334, 10904, 1001, 9, 47, 76, 31, 6305, 48, 1961, 37, 6018, 15, 32, 22, 18, 421, 37, 1267, 1961, 9, 31, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
microsoft visio installation fail === After installation of MS Visio, it display "Please wait while Visio updates its directory cache" at 80% for a long time without any proceed. How can I solve this problem?
0
[ 2, 7099, 9060, 1963, 7758, 7476, 800, 3726, 3726, 75, 7758, 16, 4235, 9060, 1963, 15, 32, 3042, 13, 7, 6744, 1760, 133, 9060, 1963, 16779, 82, 16755, 16522, 7, 35, 15254, 26, 21, 175, 85, 366, 186, 11158, 9, 184, 92, 31, 8402, 4...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
MVC html.dropdownlistfor not updating model field === I searched online and I think my code should be correct but when you submit the model field is always 0. Model: public class ProductsModel { public List<Products> ProductCommission; public List<ProductGroupType> ProductGroupType; public CommissionType CommissionType; public int FilterProductGroupTypeId; public string Status; } View: @Html.DropDownListFor(m => Model.FilterProductGroupTypeId, new SelectList(Model.ProductGroupType, "ID", "Description"), "All") @Html.HiddenFor(m => Model.FilterProductGroupTypeId); @* @Html.ActionLink("Filter", "FilterProductTypes", "Products", new { filterid = Model.FilterProductGroupTypeId });*@ <a href="@Url.Action("FilterProductTypes", "Products", new { filterid = Model.FilterProductGroupTypeId})">Filter</a> Controller: public ViewResult FilterProductTypes(int filterid) { ... } THe dropdownlist displays correctly but no matter what I select it sends 0 to the controller.
0
[ 2, 307, 8990, 13, 15895, 9, 12361, 2968, 5739, 1106, 52, 71, 43, 1880, 1061, 575, 800, 3726, 3726, 31, 9036, 2087, 17, 31, 277, 51, 1797, 378, 44, 4456, 47, 76, 42, 12298, 14, 1061, 575, 25, 550, 713, 9, 1061, 45, 317, 718, 19...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to compute aggregates like in relational databases === Say I have a data set like this: MONTH REGION SALES NOV_2011 North 15000 NOV_2011 North 15000 OCT_2010 West 14000 NOV_2011 North 15000 OCT_2010 West 14000 OCT_2010 West 7000 APR_2010 North 3000 DEC_2011 South 24000 APR_2010 North 9000 I want to get a sum of sales by month and region. MONTH REGION SALES APR_2010 North 12000 DEC_2011 South 24000 NOV_2011 North 45000 OCT_2010 West 35000 If this data was in a relational table I can easily write a sql to get the answer. All databases can give an answer almost instantaneously ( of course depending on volume, indexes etc). I would like to use C++ facilities to do this kind of computation because sometimes the task is not worth adding a sql library. Are there data structures algorithms out there that can make such tasks easier?
0
[ 2, 184, 20, 23909, 8544, 18, 101, 19, 5827, 192, 6018, 18, 800, 3726, 3726, 395, 31, 57, 21, 1054, 309, 101, 48, 45, 1617, 632, 2598, 16112, 1, 3097, 200, 357, 3993, 16112, 1, 3097, 200, 357, 3993, 9543, 1, 2751, 280, 513, 3993,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I create an NSString containing an NSLineSeparatorCharacter? === `NSString` is pretty unicode friendly. So normally when I want to create a string containing unicode, I can pop it directly into a string literal like so: NSString *myString = @"Press ⌘Q to quit…"; But that doesn't work with using a line separator (AKA: 
`NSLineSeparatorCharacter`, Unicode U+2028, UTF-8 E2 80 A8). The compiler (correctly) interprets this as a line break, which is a no-no in C syntax. `-stringWithFormat:` doesn't help either. Trying NSString *myString = [NSString stringWithFormat@"This is%don two lines…", NSLineSeparatorCharacter]; gives me the string "This is8232on two lines…".
0
[ 2, 184, 107, 31, 1600, 40, 13, 2172, 11130, 3503, 40, 13, 2172, 7939, 62, 3574, 3457, 24589, 60, 800, 3726, 3726, 13, 1, 2172, 11130, 1, 25, 1772, 28010, 4753, 9, 86, 4147, 76, 31, 259, 20, 1600, 21, 3724, 3503, 28010, 15, 31, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Moving Obj-C Design Patterns to C++ for porting? === I was about to begin porting a relatively large game from iPhone Obj-C to a platform neutral C++. In our game, we made heavy use of the NSNotificationCenter for notifying menus and game items of downloads and cache updates from our server. I was thinking of re-creating the NSNotificationCenter using a singleton class and then having any class which would receive notifications inherit a base NotificationReceiver base class using multi-inheritance. The singleton would keep a Map of notification names that would keep an array of pointers to the base class. When the notification is sent, it would then call a virtual member in the base class of the receivers which could be overridden. My Questions: 1. Is there a better design pattern to use in C++ for this type of operation? 2. Would there be a better way to implement this? As there is a lot this type of code to move over, I just want to make sure I have the optimal solution prior to starting my port. Thanks for the input!
0
[ 2, 1219, 5122, 728, 8, 150, 704, 6282, 20, 272, 20512, 26, 1295, 68, 60, 800, 3726, 3726, 31, 23, 88, 20, 2348, 1295, 68, 21, 3109, 370, 250, 37, 21024, 5122, 728, 8, 150, 20, 21, 2452, 8387, 272, 20512, 9, 19, 318, 250, 15, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
the sum of values of a second column of a file === I have a txt file containing on each line 2 values separated by a space: x1 y1 x2 y2 x3 y3 ... xn yn I want to get another file containing: x1 y1 x2 y1+y2 x3 y1+y2+y3 ... xn y1+y2+y3+...+yn What is the quickest (I mean easiest) way to do this in python ?
0
[ 2, 14, 3907, 16, 4070, 16, 21, 153, 4698, 16, 21, 3893, 800, 3726, 3726, 31, 57, 21, 20225, 38, 3893, 3503, 27, 206, 293, 172, 4070, 4196, 34, 21, 726, 45, 993, 165, 13, 93, 165, 993, 135, 13, 93, 135, 993, 240, 13, 93, 240,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
iPhone: How to remove glow (light) from UIBarButtonItem when pressed? === I'm trying to remove the glow from a UIBarButton item so that my text appears to be a label instead of a button. I've seen various posts talking about how to do this through interface builder or by setting a boolean variable "showsTouchWhenHighlighted", but neither of these options are available to me it appears. I've tried setting the showsTouchWhenHighlighted in the .m viewDidLoad where I change the font and font-size but the UIBarButtonItem doesn't appear to have that property. I also only have the options in the following image to change in InterfaceBuilder. ![enter image description here][1] [1]: http://i.stack.imgur.com/3ZYUr.png
0
[ 2, 21024, 45, 184, 20, 4681, 6839, 13, 5, 3130, 6, 37, 13, 5661, 1850, 811, 444, 2119, 79, 76, 2931, 60, 800, 3726, 3726, 31, 22, 79, 749, 20, 4681, 14, 6839, 37, 21, 13, 5661, 1850, 811, 444, 9101, 86, 30, 51, 1854, 1780, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Finding MostOccuringChar in array of char === I'm trying to find the MostOccuringChar in this array with algorithm . char a[]={"aaaadddddaa"}; int max=0; int count=0; char maxCharcter; for(char q='a';q<='z';q++) { for(int i=0; i<strlen(a);i++) {if(a[i]==q) count++;} if(count>max) { max=count; maxCharcter=q; } } cout<<max<<endl; cout<<maxCharcter<<endl; the output should be max=6 maxCharcter=a but i get max=11 and maxCharcter=d
0
[ 2, 3007, 127, 2499, 4734, 68, 5433, 19, 7718, 16, 4892, 800, 3726, 3726, 31, 22, 79, 749, 20, 477, 14, 127, 2499, 4734, 68, 5433, 19, 48, 7718, 29, 9083, 13, 9, 4892, 21, 2558, 500, 3726, 1, 7, 22160, 14854, 8096, 593, 58, 7, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to identify whether a WPF Control is a Conatiner control? === At runtime i am creating a **WPF control**.It can be any WPF Control. i want to find out whether this WPF Control, IS A **CONTAINER CONTROL** . i.e. can this control can embed/contain another control . Does there exist any Attribute through which the above can be achieved??
0
[ 2, 184, 20, 5808, 1472, 21, 619, 7721, 569, 25, 21, 1065, 5166, 1031, 569, 60, 800, 3726, 3726, 35, 485, 891, 31, 589, 2936, 21, 13, 1409, 499, 7721, 569, 1409, 9, 242, 92, 44, 186, 619, 7721, 569, 9, 31, 259, 20, 477, 70, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Settings child.frame = parent.bounds? === Is it logically valid to do this: child.frame = parent.bounds Let's say I want add new CALayer as view's default layer sublayer, and I want that new CALayer to be positioned at (0,0) and have exactly the same size as it's parent. Then I would write this: self.customSublayer.frame = self.view.layer.bounds; I think this should work without problems in any scenario, but I want other opinions :)
0
[ 2, 12410, 850, 9, 8361, 800, 4766, 9, 7410, 18, 60, 800, 3726, 3726, 25, 32, 11545, 102, 7394, 20, 107, 48, 45, 850, 9, 8361, 800, 4766, 9, 7410, 18, 408, 22, 18, 395, 31, 259, 3547, 78, 1658, 15187, 28, 1418, 22, 18, 12838, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
require all gems in Gemfile in non-Rails app? === When we write `Rails` app it requires all the gems defined in `Gemfile` for us. How to make a non-Rails app do this?
0
[ 2, 4077, 65, 8551, 18, 19, 8551, 16877, 19, 538, 8, 7301, 18, 4865, 60, 800, 3726, 3726, 76, 95, 2757, 13, 1, 7301, 18, 1, 4865, 32, 4781, 65, 14, 8551, 18, 2811, 19, 13, 1, 20231, 16877, 1, 26, 182, 9, 184, 20, 233, 21, 5...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0...
I'm making a html object raw dump method in a rails model. Is there a better way to do this? === I'm developing a rails application and I've found that it's convenient to have a method on all of my models to be able to dump themselves to a pretty print html view. I'm accomplishing this using a slight modification of the aweseome_print gem output: "<pre>".html_safe + ActionController::Base.helpers.sanitize( (self.awesome_inspect :html => :true), :tags => "kbd", :attributes => "style" ) + "</pre>".html_safe <br> This gives me nice output: <pre># { :id<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: blue;">71</kbd>, :unit_id<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: blue;">129</kbd>, :start_date<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: darkgreen;">Fri, 19 Oct 2012</kbd>, :end_date<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: darkgreen;">Sat, 08 Dec 2012</kbd>, :length<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: blue;">50</kbd>, :type<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: red;">nil</kbd>, :notes<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: brown;">""</kbd>, :completed<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: red;">false</kbd>, :scheduled<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: red;">nil</kbd>, :estimated_length<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: blue;">50</kbd>, :list_opens_on<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: red;">nil</kbd>, :created_at<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: darkgreen;">Mon, 13 Feb 2012 00:14:43 UTC +00:00</kbd>, :updated_at<kbd style="color: slategray;"> =&gt; </kbd><kbd style="color: darkgreen;">Sat, 25 Feb 2012 19:36:18 UTC +00:00</kbd> }</pre> In the real app this is also colorized. Stackoverflow strips that formatting here. <br> I've added this as a method to all my models using a monkey patch method: <br> in **app/initializers/active_record_monkey_patch.rb** class ActiveRecord::Base def pp_html "<pre>".html_safe + ActionController::Base.helpers.sanitize( (self.awesome_inspect :html => :true), :tags => "kbd", :attributes => "style" ) + "</pre>".html_safe end end <br> I'm a bit of a MVC n00b. **I'm not entirely sure the model is the correct place for this.** I do call this method from both controllers as well as ActionMailer mailers. Is there some way this should be put into a view_helper or is it safe in the model? If this does need to be relocated, **please show an example of definition and call**. I'm not as good with views as I am with models.
0
[ 2, 31, 22, 79, 544, 21, 13, 15895, 3095, 4333, 11424, 2109, 19, 21, 2240, 18, 1061, 9, 25, 80, 21, 574, 161, 20, 107, 48, 60, 800, 3726, 3726, 31, 22, 79, 3561, 21, 2240, 18, 3010, 17, 31, 22, 195, 216, 30, 32, 22, 18, 128...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
iterating through EMF models with EMF Query === I'm trying to iterate through a collection of EMF elements that represents simple EObjects using EMF Query. The problem that I have, is, I cannot pass to FROM Clause from the EMF Query statement tuples of objects. This means I only can pass a collection of simple EObjects like: models = (EObject1, EObject2, ... ) What I would like to do is, passing the following collection to EMF Query: models = ((EObject1.1, EObject 1.2), (EObject 2.1, EObject 2.2), ...) Do you maybe have any idea in solving the problem?
0
[ 2, 32, 106, 1880, 120, 3579, 410, 2761, 29, 3579, 410, 25597, 800, 3726, 3726, 31, 22, 79, 749, 20, 32, 106, 1373, 120, 21, 1206, 16, 3579, 410, 2065, 30, 4719, 1935, 13, 62, 23793, 18, 568, 3579, 410, 25597, 9, 14, 1448, 30, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Unable to retrieve DDL SelectedValue bound in ASPX after Page Load === I have the following markup / code block in the ASPX file. The binding of the ddl is triggered after Page_Load event which is in the code behind file. This results me not able to get the selected value of the dropdownlist if I were to use such flow. However for some purpose I require it to work this way. Any idea how I could get the dropdownlist selected value when a post back is being triggered? I've tried enabling ViewState for the ddl but still doesn't seem to get the value. <% ddl.DataValueField = "value"; ddl.DataTextField = "text"; ddl.DataSource = ds; ddl.DataBind(); %> <form runat="server" id="user_form" class="form-horizontal"> <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server"> </asp:ToolkitScriptManager> <asp:UpdatePanel ID="updPanel" runat="server"> <ContentTemplate> <asp:DropDownList runat="server" ID="ddl"> </asp:DropDownList> </ContentTemplate> </asp:UpdatePanel> </form> Thanks in advance!
0
[ 2, 2343, 20, 11917, 13, 43, 8643, 1704, 15165, 4138, 19, 28, 306, 396, 75, 2478, 6305, 800, 3726, 3726, 31, 57, 14, 249, 943, 576, 13, 118, 1797, 1921, 19, 14, 28, 306, 396, 3893, 9, 14, 8728, 16, 14, 13, 43, 8643, 25, 15164, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
multilanguage site with sub folder === Please help me with php file that must redirect to correct language. the site architecture is site.com/en site.com/fr my cod: <?php $sites = array( "en" => "/en/index", ); $lang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2); if (!in_array($lang, array_keys($sites))){ $lang = 'en'; } // перенаправление на субдомен header('Location: ' . $sites[$lang]); ?>
0
[ 2, 1889, 7020, 689, 29, 972, 19294, 800, 3726, 3726, 2247, 448, 55, 29, 13, 26120, 3893, 30, 491, 302, 14706, 20, 4456, 816, 9, 14, 689, 2607, 25, 689, 9, 960, 118, 219, 689, 9, 960, 118, 6177, 51, 14395, 45, 13, 1, 60, 26120,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Being able to debug staging locally === Basically I have come up with an idea to use at my company and wanted to put it out their to the "stack overflow" universe to rip to pieces. Currently we are tagging each release of "Project X" in a tags folder within SVN. This is working perfectly. However, the inefficiency comes when developer X has to perform the following steps in order to be able to debug staging.: 1. Take a backup of the staging DB. 2. Create a new database locally and restore using the staging DB. 3. Checkout the tagged release (on staging) from SVN. 4. Edit their web.config to point to the new database. My idea is to have a connection string which will hook straight into the staging database. Therefore the developer just has to checkout tag 0.1.0 and run the application using the "LocalStaging" web.config transformation. Can anyone see any issues with this approach?
0
[ 2, 142, 777, 20, 121, 16254, 16824, 6680, 800, 3726, 3726, 11374, 31, 57, 340, 71, 29, 40, 882, 20, 275, 35, 51, 237, 17, 417, 20, 442, 32, 70, 66, 20, 14, 13, 7, 25325, 20285, 7, 3799, 20, 6310, 20, 2491, 9, 871, 95, 50, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Android app installation error: com.android.ddmlib.SyncException: Directory not empty === I frequently get the following error when starting an app: [2012-06-24 11:08:53 - Onvifer] Failed to install Myapp.apk on device 'emulator-5554': Directory not empty [2012-06-24 11:08:53 - Onvifer] com.android.ddmlib.SyncException: Directory not empty [2012-06-24 11:08:53 - Onvifer] Launch canceled! The only remedy that I have found so far is to start the emulator with "Wipe out user data" which is no big deal except all the time consuming customization is lost. Could anyone shed some light on this?
0
[ 2, 13005, 4865, 7758, 7019, 45, 13, 960, 9, 290, 18524, 9, 8096, 79, 8326, 9, 9507, 150, 10066, 872, 45, 16755, 52, 2424, 800, 3726, 3726, 31, 3086, 164, 14, 249, 7019, 76, 1422, 40, 4865, 45, 636, 3212, 8, 3370, 8, 1996, 547, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
scope of variables java === Is a variable inside the main, a public variable? public static void main(String[] args) { ......... for(int i=0;i<threads.length;i++) try { threads[i].join(); } catch (InterruptedException e) { e.printStackTrace(); } long time=0; .... } i and time are they both public variables? Of course if my reasoning is correct, also any variable belonging to a public method should be considered public.. am i right? Thanks
0
[ 2, 9914, 16, 12157, 8247, 800, 3726, 3726, 25, 21, 7612, 572, 14, 407, 15, 21, 317, 7612, 60, 317, 12038, 11364, 407, 5, 11130, 2558, 500, 13, 10663, 18, 6, 13, 1, 13, 9, 9, 9, 9, 9, 9, 9, 9, 9, 26, 5, 6391, 31, 3726, 38...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
ios - Passing on values from a UIPickerView when it is subclassed === I am sorry since this has asked before, but I just can't get my head wrapped around it. I have a UIPickerView that works all fine and I add it to my UIViewController with _pv = [[CategoryPicker alloc] init]; _textField.inputView = _pv; _pv is the UIPickerView and _textField is the textField where I want the results to appear in. So I when I use this line of code: _pv.categoryPicker.delegate = self; //set in my viewDidLoad and this is then placed in the UIViewController: - (void)pickerView:(UIPickerView *)pickerView didSelectRow: (NSInteger)row inComponent:(NSInteger)component { // Handle the selection _textField.text = [_pv.categoryArray objectAtIndex:row]; } I am able to populate the the TextField, but the UIPickerView is filled with a "?" for every entry of the array. Now when I do this: _pv.categoryPicker.delegate = _pv.self; //set in my viewDidLoad and I put this in the UIPickerView: - (void)pickerView:(UIPickerView *)pickerView didSelectRow: (NSInteger)row inComponent:(NSInteger)component { // Handle the selection _outputArray = [_categoryArray objectAtIndex:row]; NSLog(@"The item selected = %@", _outputArray); } The UIPickerView is populated, but the data is not passed on to the TextField. So this is where I am stuck - I need to have the results in both places. Now I thought I do that with subClassing, but everything I have read on that does not work for me. Please help me:-) Advance Thanks.
0
[ 2, 13, 7760, 13, 8, 2848, 27, 4070, 37, 21, 13, 5661, 16855, 106, 4725, 76, 32, 25, 972, 1898, 69, 800, 3726, 3726, 31, 589, 1875, 179, 48, 63, 411, 115, 15, 47, 31, 114, 92, 22, 38, 164, 51, 157, 3684, 140, 32, 9, 31, 57,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I store a list of Python dictionaries in MySQL the Pythonic way? === I have a dictionary of list of dictionaries. Why did I pick this bizarre approach? This is part of a web scraping effort wherein I am storing different sections of a massive webpage in different dictionaries. I have the column names to keep track of the data. I don't have ordered dicts cos' I am on Python 2.6.6. What is a more efficient way of storing this data (dictionary to mysql)? Every time I scrape the website, I create a temp table to store the data for further processing. I first create a record for the id and then update the columns for that id. Is there a quicker and more efficient way of doing it? Thank you! **Python** import MySQLdb db=MySQLdb.connect(db="mydb") c=db.cursor() mydict = {'1': [{'First': 'John', 'Last': 'Doe'}, {'Company': 'Trulia Inc.', 'Title': 'CEO', 'YearsattheCompany': 4}, {'Cell': '216-453-4322', 'Home': None}]} for key, value in mydict.items(): id = key c.execute("insert into deldictmysql (id) values (%s)" % id) for eachdict in value: print eachdict for finalkey, finalvalue in eachdict.items(): print finalkey, finalvalue if finalvalue: query = "update deldictmysql set %s = '%s'" c.execute(query % (finalkey, finalvalue)) c.close() **MySQL** create table deldictmysql (id integer, first varchar(40), last varchar(40), company varchar(200), title varchar(200), yearsatthecompany integer, cell varchar(20), home varchar(20)); **Output** select * from deldictmysql; "id" "first" "last" "company" "title" "yearsatthecompany" "cell" "home" "1" "John" "Doe" "Trulia Inc." "CEO" "4" "216-453-4322" ""
0
[ 2, 184, 107, 31, 1718, 21, 968, 16, 20059, 29783, 19, 51, 18, 22402, 14, 20059, 596, 161, 60, 800, 3726, 3726, 31, 57, 21, 9186, 16, 968, 16, 29783, 9, 483, 144, 31, 2036, 48, 15701, 2141, 60, 48, 25, 141, 16, 21, 2741, 25611,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Why is my mongoDB hosting uri settings for mongoid.yml not working correctly? === I'm currently using the following settings in my mongoid.yml and i've correctly added the `MONGOLAB_URI` environmental variable to my heroku environment: production: sessions: default: another: uri: <%= ENV['MONGOLAB_URI'] %> I'm getting the following error on the heroku push: Running: rake assets:precompile There is a configuration error with the current mongoid.yml. Problem: No database provided for session configuration: :default. Summary: Each session configuration must provide a database so Mongoid knows where the default database to persist to. What was provided was: {"another"=>{"uri"=>nil}}. Resolution: If configuring via a mongoid.yml, ensure that within your :default section a :database value for the session's default database is defined. Example: \_\_development: \_\_\_\_sessions: \_\_\_\_\_\_default: \_\_\_\_\_\_\_\_database: my_app_db \_\_\_\_\_\_\_\_hosts: \_\_\_\_\_\_\_\_\_\_- localhost:27017 There is a configuration error with the current mongoid.yml. Problem: No database provided for session configuration: :default. Summary: Each session configuration must provide a database so Mongoid knows where the default database to persist to. What was provided was: {"another"=>{"uri"=>nil}}. Resolution: If configuring via a mongoid.yml, ensure that within your :default section a :database value for the session's default database is defined. Example: \_\_development: \_\_\_\_sessions: \_\_\_\_\_\_default: \_\_\_\_\_\_\_\_database: my_app_db \_\_\_\_\_\_\_\_hosts: \_\_\_\_\_\_\_\_\_\_- localhost:27017 Asset precompilation completed (15.47s) What am I doing wrong here? I've followed the mongoid.org instructions: http://mongoid.org/en/mongoid/docs/installation.html
0
[ 2, 483, 25, 51, 3521, 5474, 220, 10637, 13, 3594, 12410, 26, 21028, 6516, 9, 93, 8184, 52, 638, 12044, 60, 800, 3726, 3726, 31, 22, 79, 871, 568, 14, 249, 12410, 19, 51, 21028, 6516, 9, 93, 8184, 17, 31, 22, 195, 12044, 905, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...