text stringlengths 0 30.5k | title stringclasses 1
value | embeddings listlengths 768 768 |
|---|---|---|
On this project I am working on right now, one of the newest feature requests is to output expense information which is stored into expense report that matches an Excel worksheet they already use for all of their expense reporting.
I was curious if there was a way that I could take this excel worksheet (with all of i... | [
0.8430841565132141,
0.21944575011730194,
0.1456671506166458,
0.3414694666862488,
0.07919888198375702,
-0.17985668778419495,
-0.2159101516008377,
0.2918245196342468,
-0.1517220437526703,
-0.5683706402778625,
0.3025708496570587,
0.4807542860507965,
0.055685363709926605,
-0.026080144569277763... | |
on the server.
Note: development environment is ASP.NET 2.0
I am pretty sure you can can use OleDB to open the excel file(with the template)
**Example 1**
```
string ConnectionString=@"Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=C:\Test Projects\Excel example\Excel - reading an excel file\Read... | [
0.07429315894842148,
0.35759416222572327,
0.7392424941062927,
0.014210663735866547,
-0.1025184914469719,
-0.19246000051498413,
0.09749448299407959,
-0.16729570925235748,
-0.0581633485853672,
-0.8399527668952942,
-0.20293384790420532,
0.4145391881465912,
-0.3882933557033539,
0.1374634504318... | |
Properties=Excel 8.0;";
OleDbConnection objConn = new OleDbConnection(connectionString);
objConn.Open();
OleDbCommand ObjCommand = new OleDbCommand("SELECT * FROM [Sheet1$]", objConn);
OleDbDataAdapter objAdp = new OleDbDataAdapter();
objAdp.SelectCommand = ObjCommand;
DataSet myDataSet = new DataSet();
objAdp.F... | [
-0.28576645255088806,
0.021201500669121742,
0.8384299874305725,
0.021911637857556343,
0.09552095085382462,
-0.5152802467346191,
0.4401364326477051,
-0.1731528788805008,
-0.5039437413215637,
-1.079775333404541,
-0.4228402078151703,
0.5426926612854004,
-0.14273163676261902,
0.369720935821533... | |
If I just want to run the new style web services on, say a Windows 2000, IIS 5 machine with .NET 2.0 installed, but .NET 3.0 not installed, can I do it by just adding the System.ServiceModel.dll to my bin?
I doubt this would work. System.ServiceModel resides in the GAC. It also has dependencies on a few other 3.0 assem... | [
0.3728998005390167,
-0.001873599598184228,
0.40324994921684265,
0.04021333530545235,
-0.04177146032452583,
-0.3510254919528961,
0.19645509123802185,
-0.2019801139831543,
-0.08839218318462372,
-0.678640604019165,
0.07435746490955353,
0.6071528196334839,
-0.3403957188129425,
0.15294571220874... | |
work correctly is another question (See the requirements section in: <http://msdn.microsoft.com/en-us/library/aa480198.aspx>). If you were successful but something broke further down the road then the install would be unsupported by MS.
Best bet would be to save yourself a world of pain and install FW 3.0 on a compati... | [
0.6009514331817627,
0.13382801413536072,
0.2445225566625595,
-0.004496229812502861,
0.12446734309196472,
-0.1506413221359253,
0.8916050791740417,
-0.44411757588386536,
0.1539400815963745,
-0.2088136225938797,
-0.21090248227119446,
0.9112455248832703,
0.16745707392692566,
-0.284523367881774... | |
I wonder if it is possible (and how) to provide a class in Objective-C with something like:
```
Person.Select(@"Name").OrderAsc(@"Name").Where(@"Id").EqualTo(1).And(@"Id").NotEqualTo(2).Load<Array>
```
That could be very handy for a project I'm doing.
I like this way of coding present in Django & SubSonic.
The shor... | [
0.275098979473114,
0.2755032777786255,
0.16511507332324982,
-0.0016969661228358746,
-0.1528709977865219,
0.07379446923732758,
0.1669849008321762,
-0.19598940014839172,
-0.08145087212324142,
-0.5804337859153748,
0.10003573447465897,
0.6615208983421326,
-0.2623871862888336,
-0.00152908719610... | |
entityForName:@"Employee"
inManagedObjectContext:managedObjectContext];
[request setEntity:entity];
// assume salaryLimit defined as an NSNumber variable
NSPredicate *predicate = [NSPredicate predicateWithFormat:
@"salary > %@", salaryLimit];
[request setPredicate:predicate];
NSError *error = nil;
NSArr... | [
-0.4187692105770111,
-0.2341419905424118,
0.19599130749702454,
-0.020242881029844284,
0.003537994809448719,
0.3088685870170593,
0.07936985790729523,
-0.3332342803478241,
-0.03139810264110565,
-0.3010256290435791,
0.04979628697037697,
0.504247784614563,
-0.11901859939098358,
0.2761185765266... | |
**EDIT**: This issue has been fixed by google in gtest 1.4.0; [see the original bug report](http://code.google.com/p/googletest/issues/detail?id=114) for more information.
I've recently switched to gtest for my C++ testing framework, and one great feature of it which I am presently unable to use is the ability to gene... | [
-0.28500130772590637,
0.05038406327366829,
0.19283917546272278,
0.015170681290328503,
-0.24510781466960907,
0.15166692435741425,
0.4361250400543213,
0.18271616101264954,
0.08922740817070007,
-0.8656996488571167,
-0.06733262538909912,
0.751151442527771,
-0.31581899523735046,
0.1470690965652... | |
time="0" classname="application" />
...etc.
</testsuite>
</testsuite>
```
I've also tried adding a JUnitReport task to my ant build script, which works fine, and generates XML like so:
```
<?xml version="1.0" encoding="UTF-8"?>
<testsuite tests="370" failures="0" disabled="0" errors="0" time="45.61" name="AllTes... | [
0.004939103964716196,
-0.06966841965913773,
-0.07665185630321503,
-0.2281147837638855,
0.0846799835562706,
0.2898966073989868,
0.5051020383834839,
-0.17847052216529846,
0.08319449424743652,
-1.049301266670227,
0.07275819033384323,
0.45482155680656433,
-0.18686437606811523,
-0.0923131629824... | |
always complains about finding no test results there.
I'm not a java guy, so I can't tell what's going on here, and I can't find an example of how the JUnit XML ought to look like. Can someone help to point me in the right direction?
**Edit**: Google test has fixed this issue, which is included in the gtest 1.4.0 rele... | [
0.08695558458566666,
0.3183349668979645,
0.06052746623754501,
0.0573558546602726,
-0.1523146778345108,
-0.23650532960891724,
0.46194568276405334,
0.16983561217784882,
-0.1369251161813736,
-0.5728715658187866,
-0.13466082513332367,
0.4316163659095764,
-0.26086539030075073,
0.044031120836734... | |
perl script as a workaround for this issue](http://www.teragon.org/stuff/SO/gtest-hudson.pl). To use it, you would make a target in your ant xml script which looks something like this:
```
<target name="runtests">
<exec executable="wherever/${ant.project.name}Test" failonerror="false" dir="tests">
<arg value="--... | [
-0.1673736572265625,
-0.27496954798698425,
0.2082817107439041,
-0.17920534312725067,
-0.3246453106403351,
0.4867674708366394,
0.17302802205085754,
-0.14635977149009705,
-0.0727054700255394,
-0.5287855863571167,
0.2246021181344986,
0.2563689351081848,
-0.3481137156486511,
0.0058543905615806... | |
on a windows server. Change to '/' for unix, obviously.
I've also [filed an issue for this on the gtest page](http://code.google.com/p/googletest/issues/detail?id=114), and also one on [hudson's issue tracker](https://hudson.dev.java.net/issues/show_bug.cgi?id=3007), so hopefully one of the two teams will pick up on t... | [
0.04463149234652519,
0.08692874759435654,
0.20803238451480865,
-0.12170642614364624,
0.34482118487358093,
-0.06477643549442291,
0.28022146224975586,
0.262376070022583,
-0.31194210052490234,
-0.6754326224327087,
-0.2504473030567169,
0.645403265953064,
-0.12955397367477417,
0.050380825996398... | |
I have not used Windows Vista. I knew that many APIs have been changed/deprecated in Vista, so programs need to be fixed or configured to execute in XP Compatible mode.
So, what should windows programmer know when they move from XP/Vista to Windows 7?
For starters, and if history has taught us anything - don't rely on... | [
0.27341386675834656,
0.032854385673999786,
0.5011661648750305,
0.01924997754395008,
0.07893233001232147,
-0.35453537106513977,
0.2666994631290436,
0.227482870221138,
-0.2557655870914459,
-0.5361871719360352,
-0.1246008351445198,
0.9816786050796509,
-0.041369982063770294,
0.2906306684017181... | |
same (or similar) security models. It's likely the same will apply to driver requirements too, but again too early to tell.
At this early stage, about all you could do is see if your application deploys, installs and runs under the Windows 7 beta. If you already have updated your application to run within the restrict... | [
0.528589129447937,
-0.053532324731349945,
0.6991515755653381,
0.04905557632446289,
0.12094701826572418,
-0.32804107666015625,
0.3951461613178253,
0.041219621896743774,
-0.13326600193977356,
-0.5186594128608704,
-0.15102963149547577,
0.882228672504425,
-0.15587754547595978,
0.10269763320684... | |
jump to Windows 7, but really you'd have to look at Windows 7 closer to 2010.
At this stage we might see the .Net Framework 4.0 by 2010, so if your application is a .Net application, you might be tempted to upgrade to 4.0 to take advantage of new language features.
**Edit:** I almost forgot about this - (1) [a whitep... | [
0.3007237911224365,
-0.3895721733570099,
0.5921523571014404,
0.03302209451794624,
0.08591418713331223,
-0.3011036515235901,
0.3739740252494812,
0.08638881146907806,
-0.45972418785095215,
-0.3894231915473938,
-0.1603705883026123,
0.8522921204566956,
-0.017110759392380714,
-0.206411853432655... | |
be compatible with applications and device drivers that work with Windows Vista."
- "With Windows BranchCache, clients can retrieve data from other clients in their own branch that have already downloaded the data, instead of having to retrieve the data over remote servers. "
- "Built on the Sensor platform, the Wind... | [
0.2374608963727951,
-0.37081992626190186,
0.7233192324638367,
0.2632904648780823,
0.39283064007759094,
-0.15338706970214844,
0.18868735432624817,
-0.30403193831443787,
-0.22681528329849243,
-0.5081866383552551,
-0.2850527763366699,
0.6128501892089844,
-0.06038789823651314,
-0.1796876341104... | |
For web development what are some standard/good java tools. That apply to all aspects of development.
For example, The IDE (Eclipse, RAD, Intellij) is important, but what else is there.
Ant is a good one.
Cygwin, Linux OS possibly.
Another good IDE for Java web development I use is [Netbeans](http://www.netbeans.org/... | [
0.4515572488307953,
0.08829798549413681,
0.05977366492152214,
0.11491908878087997,
-0.3018423020839691,
-0.4512993097305298,
-0.054362572729587555,
0.2325250208377838,
-0.3261096775531769,
-0.850141704082489,
0.003147502662613988,
0.42939019203186035,
-0.15017418563365936,
0.03022619336843... | |
What is the difference between storing a datatable in Session vs Cache? What are the advantages and disadvantages?
So, if it is a simple search page which returns result in a datatable and binds it to a gridview. If user 'a' searches and user 'b' searches, is it better to store it in Session since each user would most... | [
0.4224950671195984,
0.035795908421278,
0.04001696780323982,
0.295483261346817,
-0.18271148204803467,
-0.031466975808143616,
-0.1377941071987152,
-0.39997050166130066,
-0.3306834399700165,
-0.615874707698822,
0.30532708764076233,
0.5004361867904663,
-0.2271360605955124,
0.4391123354434967,
... | |
overwritten.
One important difference is, that items in the cache can expire (will be removed from cache) after a specified amount of time. Items put into a session will stay there, until the session ends.
ASP.NET can also remove items from cache when the amount of available memory gets small.
Another difference: the... | [
0.17199090123176575,
0.21965748071670532,
0.3027186393737793,
0.051112569868564606,
0.1893632709980011,
-0.1871558427810669,
0.5211416482925415,
0.1166996881365776,
-0.7153271436691284,
-0.8650190234184265,
-0.2176244556903839,
0.14084894955158234,
-0.2678240239620209,
0.5282313823699951,
... | |
This question is related to this other question I recently asked...
[cf.net exception and other logging](https://stackoverflow.com/questions/417789/cf-net-exception-and-other-logging)
I am generating log messages to be sent to a server using a webservice over a GPRS connection and I want to simply queue these message... | [
0.5542169809341431,
0.3016211688518524,
0.2743229568004608,
0.2544949948787689,
-0.09339578449726105,
-0.15362095832824707,
0.220009446144104,
0.02699592523276806,
-0.5947138071060181,
-0.5522811412811279,
0.18832235038280487,
0.6254697442054749,
-0.20593388378620148,
0.007061046548187733,... | |
what I've done is push the data into a database table (SQLCE is my typical route). When I need to push something to the web service, I send it to the dispatcher, which in turns puts it into the database. The dispatcher has a background thread that pulls data out of the database, sends it, then does a database delete up... | [
0.4308028817176819,
0.02356707490980625,
0.5542007088661194,
0.06286866217851639,
0.29450032114982605,
0.15158651769161224,
0.003365656826645136,
0.23442807793617249,
-0.33886244893074036,
-0.499610036611557,
0.04218708351254463,
0.36835795640945435,
-0.10061529278755188,
0.370647639036178... | |
I am asp.net-MVC using the BeginForm syntax in my source ciew page and I was told if you want the form to submit you have to have the submit Button at the end of the using statement. I don't want to use a Button to call the desired Action I have an Actionlink set up like so:
```
<%=Html.ActionLink("" + CreateMore, "... | [
0.5692321062088013,
-0.06475520133972168,
0.3718617856502533,
-0.24205195903778076,
-0.3780308663845062,
-0.08867079019546509,
0.12299869954586029,
-0.36909058690071106,
-0.07265584915876389,
-0.8409072160720825,
0.030029719695448875,
0.5090861320495605,
-0.032498788088560104,
-0.115255914... | |
button:
```
<input type="submit" />
```
because the link looks better
I would once again turn to jQuery to handle this task
```
$(function(){
$('input:submit').hide(); //hide the submit button
$('#submitLinkID').click(function(){ // bind the link's click event
$('input:submit').click(); //click the hidde... | [
-0.07946310937404633,
-0.15489374101161957,
0.515598475933075,
-0.18996800482273102,
-0.22933116555213928,
-0.08704285323619843,
0.41013196110725403,
-0.2613547444343567,
-0.007224150933325291,
-0.6853957176208496,
-0.13627417385578156,
0.57009357213974,
-0.5124533772468567,
0.319928020238... | |
If yo have multiple users on your website on the same page and they are running queries (searches) and the results are stored in a datatable. Will the last person's search overwrite the application Cache if you store it in the Cache? Is this a reason to use Session?
It depends on how you store the information to the ca... | [
0.1576613038778305,
-0.022320270538330078,
0.18198853731155396,
0.1247103214263916,
-0.10122093558311462,
0.08948948979377747,
0.3239014148712158,
0.04087771475315094,
-0.17135846614837646,
-0.5674986243247986,
0.18436691164970398,
0.6721041202545166,
-0.3342672288417816,
0.172354117035865... | |
Is there a good way to get the process name that created a file in Windows?
I have a directory on a Windows 2000 Server
**C:\WINNT\Temp** that is filling up with files named like:
70618199
21834082
They are always 121,201 KB in size.
Programatically can I "capture" the program name or service name that is... | [
0.3183545172214508,
0.12096240371465683,
0.2639467120170593,
0.2804230749607086,
0.15951843559741974,
0.22261741757392883,
0.018427511677145958,
0.20371757447719574,
-0.5363117456436157,
-0.6082790493965149,
0.18325228989124298,
0.3510206639766693,
-0.053427379578351974,
0.1929179280996322... | |
50,000 TIFF documents on the E:\ drive. This machine also runs SQL Server 2000 w/ Full-Text Indexing turned on. Full-Text Indexing in no way touches the TIFFs - but it shouldn't because this is SQL right? But FTS does require Indexing service be turned on. The weird thing this TIFF seems to be the largest thing served ... | [
0.13376343250274658,
0.2033904790878296,
0.7154853343963623,
0.04719076678156853,
-0.08398877084255219,
-0.16527314484119415,
0.11967097222805023,
0.19014035165309906,
-0.4043337106704712,
-0.542497992515564,
0.1372147649526596,
0.5907046794891357,
-0.2939203083515167,
0.21313060820102692,... | |
grab the largest file it finds and copies it into WINNT\Temp.
This is weird. When you are dealing with a 100MB+ TIFF file, this can cause you to run out of disk space. Very annoying.
Guess I will just shut down the "Web" branch of my Indexing Services.
There's always [Process monitor](http://technet.microsoft.com/en... | [
0.06821300834417343,
-0.17484761774539948,
0.36034998297691345,
0.23435373604297638,
0.1477564424276352,
-0.12801580131053925,
0.11494717746973038,
0.4499104917049408,
-0.6824131011962891,
-0.8731545209884644,
-0.2294003963470459,
0.6566593050956726,
-0.0910002663731575,
0.3735643327236175... | |
I'd like to be able to use jEdit to write, compile and test projects written in Scala. How can I configure it to do so?
The new link appears to be <http://wiki.liftweb.net/index.php?title=SetUp_jEdit> | [
0.6472750902175903,
-0.1422903686761856,
0.45949143171310425,
-0.011614494025707245,
-0.10977129638195038,
-0.19030632078647614,
0.10836826264858246,
-0.12475719302892685,
-0.4550844430923462,
-0.31742507219314575,
0.041243020445108414,
0.03966658562421799,
0.24097563326358795,
-0.14836196... | |
just wondering if anyone could suggest why I might be getting an error? I'm currently trying to execute a macro in a workbook by calling the Application.Run method that the interop exposes.
It's currently throwing the following COM Exception:
```
{System.Runtime.InteropServices.COMException (0x800A03EC): Cannot run t... | [
0.34914112091064453,
0.37651151418685913,
0.2862440049648285,
0.008215468376874924,
0.43138134479522705,
-0.1783541589975357,
0.4990837275981903,
0.23612308502197266,
-0.35794422030448914,
-0.7155895233154297,
0.06931105256080627,
0.5812402367591858,
-0.44227761030197144,
0.152156427502632... | |
can you suggest anything which I could try?
Many thanks!
It turned out that there were actually two identically-named macros which had been injected into the workbook. The exception above translates to a "Compile Error: Ambiguous name detected" error in VBA - I should have gone straight into VBA to look at this, rathe... | [
0.18171769380569458,
-0.04968927800655365,
-0.06158146634697914,
0.058001626282930374,
-0.06685658544301987,
0.12232641130685806,
0.1401614546775818,
0.22323571145534515,
-0.17181193828582764,
-0.5012339949607849,
0.44543665647506714,
0.5386439561843872,
-0.2856022119522095,
-0.12207130342... | |
I've got a record management web application which displays a master record on one screen and AJAXes dynamically built editors into an editor div, which I've used JQuery to make draggable. That works.
Even though the div isn't a window, I thought it might be a nice idea to make it act a bit more like one, so I coded i... | [
-0.10644958168268204,
-0.05627266317605972,
0.6433968544006348,
-0.05325736105442047,
-0.36397117376327515,
0.13720864057540894,
-0.2675929665565491,
-0.4392435550689697,
-0.1469399780035019,
-0.6001142263412476,
0.18730469048023224,
0.3977487087249756,
-0.4187684655189514,
0.0043316902592... | |
set up in CSS as `float:right`.
My problem is that, in IE6 and IE7, the close button floats too far right. It's always against the right edge of the window, no matter where I drag the editor div around to. In Firefox and Safari it looks like I expected it to - the window is as wide as editorbody and closebutton sits i... | [
0.4278689920902252,
-0.0280041191726923,
0.6512220501899719,
-0.07677926868200302,
-0.14861354231834412,
-0.1362796574831009,
-0.2666515111923218,
0.06304443627595901,
-0.11950588971376419,
-0.7911046743392944,
0.10739030689001083,
0.3523150682449341,
-0.17392413318157196,
-0.1869929730892... | |
do on jsbin (thanks, redsquare)
[sample code](http://jsbin.com/ikaka "sample code")
I'm working with legally sensitive information so I can't provide screenshots of the app. I have, however, taken some shots and blocked out the text and interface, leaving only the window structure.
[how it looks in IE7](http://i278.... | [
0.3875885605812073,
-0.03495635464787483,
0.4915936589241028,
-0.20965003967285156,
-0.0802573412656784,
-0.17812295258045197,
0.3794601261615753,
-0.22810934484004974,
-0.17691178619861603,
-0.5642638206481934,
-0.21442340314388275,
0.6267008781433105,
-0.5595082640647888,
-0.363277405500... | |
Consider the following code:
```
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init
If Page.IsPostBack Then
If ViewState("test") IsNot Nothing Then
Response.Write((ViewState("test").ToString))
Else
Response.W... | [
-0.31955358386039734,
-0.16524317860603333,
0.46738216280937195,
-0.22614023089408875,
-0.2315630316734314,
0.11535421758890152,
0.38032403588294983,
-0.2939773499965668,
-0.16414600610733032,
-0.7126048803329468,
-0.2798130512237549,
0.4796034097671509,
-0.19377785921096802,
0.27420642971... | |
End If
Else
ViewState("test") = "viewstate is working."
End If
End Sub
```
This code doesn't work on a particular page in my application. Viewstate is not turned off in the Page directive. I can't figure out what's going on. : \
Oh i just figured it out. See if you notice it.
> .<
Fi... | [
0.007026356644928455,
-0.03437310457229614,
0.7112115621566772,
-0.15516433119773865,
0.07540382444858551,
-0.33679714798927307,
0.5468656420707703,
-0.24271008372306824,
-0.07109064608812332,
-0.6480562090873718,
-0.35589489340782166,
0.5422690510749817,
-0.34934818744659424,
0.2077790200... | |
As System.EventArgs) Handles Me.Init
``` | [
-0.5247470736503601,
-0.31233352422714233,
0.26272040605545044,
-0.07923924177885056,
-0.062054648995399475,
-0.09300476312637329,
0.17763252556324005,
-0.17522986233234406,
-0.24004177749156952,
-0.6469275951385498,
-0.3378538191318512,
0.47499796748161316,
-0.02260882593691349,
0.0331245... | |
We enable "Tools ==> Options ==> Designers ==> Table and Database Designers ==> Auto Generate Change Scripts" in our SQL Server Management Studio (SSMS). When changing our database schema, we save the script and, thanks to DB migration tools we've got installed on all the machines running our applications, we can synch... | [
0.3361492455005646,
0.10096033662557602,
0.44440796971321106,
0.12015699595212936,
0.16602395474910736,
-0.03331543505191803,
0.18063600361347198,
-0.14825254678726196,
-0.10243270546197891,
-0.6849451065063477,
0.21654048562049866,
0.5195187330245972,
-0.15740597248077393,
-0.051388803869... | |
while.
The problem is simple. The scripts generated by SSMS simply don't always work with SQL Server 2005. SMSS is adding extra metadata to the commands (concerning lock escalation, for example). To make our scripts with 2005, we have to manually remove the extra information, otherwise the scripts don't run.
Is the... | [
-0.16263481974601746,
0.12019625306129456,
0.32665523886680603,
0.24536781013011932,
0.057350970804691315,
-0.14837875962257385,
0.5086206197738647,
-0.08269339799880981,
-0.4739566147327423,
-0.19716127216815948,
0.0840878114104271,
0.6957237720489502,
-0.4550158977508545,
-0.016007084399... | |
SQL Server Object Explorer -> Scripting and Select "Script for server version" and change it to SQL Server 2005. | [
-0.42008596658706665,
-0.013278753496706486,
0.4677964150905609,
-0.3474492132663727,
-0.6043790578842163,
-0.2982334792613983,
0.23977646231651306,
0.3689238727092743,
0.10290210694074631,
-0.677528977394104,
-0.03831232711672783,
0.20366865396499634,
-0.4120308756828308,
0.13471716642379... | |
I would like to start tomcat (Web Server) as a privileged user, and then bring it back to an unprivileged user once it has started. Is there a way to do this programatically, or in general with Linux?
Thanks.
I am aware of [kchuid](http://nimh.org/code/kchuid/) which does *exactly* that, and although it appears abando... | [
0.19689784944057465,
0.038058582693338394,
0.27836334705352783,
0.05363919213414192,
0.15688447654247284,
-0.18921425938606262,
0.08119042962789536,
0.1870952844619751,
-0.27476584911346436,
-0.5063298940658569,
-0.07186361402273178,
0.47781118750572205,
-0.19277872145175934,
0.21600869297... | |
start as root- but simply lets non-root users bind to selected IP addresses and selected ports.
The only catch is that [authbind](http://packages.debian.org/stable/authbind) won't work with Java's network abstraction layer *by default*. You will need to disable Java's IPV6 support, and probably specify a *specific* IP... | [
0.16620346903800964,
-0.17757843434810638,
-0.10589318722486496,
-0.04752834141254425,
-0.07598370313644409,
-0.45124414563179016,
0.503983199596405,
-0.15487296879291534,
-0.3406198024749756,
-0.5715116262435913,
-0.2365671992301941,
0.21359863877296448,
-0.4347835183143616,
0.27449634671... | |
i can't find a way to do multiple row tabs with ASP.net ajax tab control. I also can't find a tutorial or example on using CSS to make multiple row of tabs.
In case you don't understand what i'm looking for here is a image of what i'm looking for
<http://bp1.blogger.com/_WCGCQYWEaxs/Rq1c2bLNMDI/AAAAAAAAABU/0sKw_CrKLL4... | [
0.2386544644832611,
-0.08418300002813339,
0.4549168050289154,
0.20180298388004303,
-0.26085543632507324,
0.09809664636850357,
0.1139376163482666,
0.08463143557310104,
-0.38520801067352295,
-0.7740864753723145,
0.36021527647972107,
0.45634913444519043,
-0.2410859763622284,
0.377294600009918... | |
line.
Something as simple as this should work but it might need some kicking:
```
<ul id="nav">
<li><a href="#">link</a></li>
<li><a href="#">link</a></li>
<li><a href="#">link</a></li>
<li><a href="#">link</a></li>
</ul>
```
CSS:
```
#nav {width:200px;}
#nav li {float:left;background:#eee;}
```
... | [
0.16148754954338074,
-0.3737402856349945,
0.4808652400970459,
-0.01800265535712242,
-0.27401039004325867,
0.3990679979324341,
0.1212824136018753,
-0.23710118234157562,
-0.1406054049730301,
-0.6888709664344788,
-0.07412851601839066,
0.14241008460521698,
-0.3795481324195862,
-0.0169113092124... | |
remember mine is completely untested. Read the full sliding doors tutorial to find out what I'm talking about and how it works.
**Edit**: I've just re-read the title and tags. You want this for a prefab ASPNET control. I'd see if you can do a pure CSS method. Try applying the sliding door method to what you've got. If... | [
0.5128318667411804,
-0.015231741592288017,
0.08158370852470398,
0.19828398525714874,
0.01769443042576313,
-0.19887666404247284,
0.3884921371936798,
0.2757861614227295,
-0.0485292486846447,
-0.6538843512535095,
0.1441650390625,
0.4407614767551422,
-0.03819714114069939,
-0.35612553358078003,... | |
According to the [official (gregorian) calendar](http://www.timeanddate.com/calendar/custom.html?year=2008&country=22&month=12&typ=2&months=2&display=0&space=0&fdow=1&wno=1&hol=), the week number for 29/12/2008 is 1, because after the last day of week 52 (i.e. 28/12) there are three or less days left in the year. Kinda... | [
0.16501085460186005,
-0.027010468766093254,
0.47094008326530457,
-0.11090923845767975,
-0.3268985450267792,
0.22679395973682404,
0.46856075525283813,
-0.24949590861797333,
-0.4132678806781769,
0.028438685461878777,
0.05147814005613327,
0.29125353693962097,
0.03329169750213623,
0.2380348742... | |
`FirstFourWeekDay` rule, but I tried all of them just in case.
The last parameter informs which week day should be considered the first day of the week, according to that calendar it's Monday so Monday it is.
So I fired up a quick and dirty console app to test this:
```
using System;
using System.Globalization;
nam... | [
0.3600987195968628,
-0.290584921836853,
0.5622936487197876,
-0.25765886902809143,
-0.012761233374476433,
0.06826619803905487,
0.11562111973762512,
0.37716254591941833,
-0.20915105938911438,
-0.5666359066963196,
0.0854845866560936,
0.777309238910675,
-0.2912391722202301,
0.5119631886482239,... | |
var firstWeekDay = DayOfWeek.Monday;
var twentyEighth = new DateTime(2008, 12, 28);
var twentyNinth = new DateTime(2008, 12, 29);
var firstJan = new DateTime(2009, 1, 1);
var eightJan = new DateTime(2009, 1, 8);
PrintWeekDays(cal, twentyEighth, firstWeekDay); | [
-0.13696782290935516,
-0.16660460829734802,
0.5866379737854004,
-0.23137277364730835,
-0.30880966782569885,
0.5352744460105896,
0.09932153671979904,
0.2939513623714447,
-0.37013041973114014,
-0.4275376498699188,
-0.05729018524289131,
0.3960809111595154,
-0.22435186803340912,
0.525138139724... | |
PrintWeekDays(cal, twentyNinth, firstWeekDay);
PrintWeekDays(cal, firstJan, firstWeekDay);
PrintWeekDays(cal, eightJan, firstWeekDay);
Console.ReadKey();
}
private static void PrintWeekDays(Calendar cal, DateTime dt, DayOfWeek firstWeekDay)
{
Cons... | [
0.19846317172050476,
-0.12295769900083542,
0.06680313497781754,
-0.2204272449016571,
0.29957857728004456,
0.22481687366962433,
0.26480138301849365,
-0.05599263310432434,
0.39852747321128845,
-0.37456464767456055,
-0.17068438231945038,
0.7687475681304932,
-0.38066887855529785,
0.15713463723... | |
Console.WriteLine("--------------------------------------------");
Console.Write(CalendarWeekRule.FirstDay.ToString() + "\t\t");
Console.WriteLine(cal.GetWeekOfYear(dt, CalendarWeekRule.FirstDay, firstWeekDay));
Console.Write(CalendarWeekRule.FirstFourDayWeek.ToString() + "\t");
... | [
-0.5694640278816223,
-0.1582874357700348,
0.7957515120506287,
-0.0741906464099884,
0.12121347337961197,
0.2755916714668274,
-0.04051676765084267,
0.13654378056526184,
0.26657915115356445,
-0.9415959715843201,
-0.38941943645477295,
0.7885972857475281,
-0.11362534016370773,
0.163580194115638... | |
Console.WriteLine("--------------------------------------------");
}
}
}
```
... and this what I get
```
Testing for 28.12.2008
--------------------------------------------
FirstDay 52
FirstFourDayWeek 52
FirstFullWeek 51
--------------------------------------------
Testin... | [
-0.7425048351287842,
-0.277924120426178,
0.754167914390564,
0.2840731143951416,
0.24743832647800446,
-0.0653880387544632,
-0.01320112869143486,
-0.07914905995130539,
0.28345784544944763,
-0.757848858833313,
0.28172358870506287,
0.8497340679168701,
0.4483598470687866,
-0.05627113953232765,
... | |
1
FirstFourDayWeek 1
FirstFullWeek 52
--------------------------------------------
Testing for 08.01.2009
--------------------------------------------
FirstDay 2
FirstFourDayWeek 2
FirstFullWeek 1
--------------------------------------------
```
So as we see, none of t... | [
-0.053065139800310135,
-0.22915548086166382,
0.5699087977409363,
-0.07761291414499283,
-0.18090049922466278,
-0.34690922498703003,
-0.3031128942966461,
-0.024538682773709297,
-0.1952732801437378,
-0.4462614059448242,
0.23474562168121338,
1.0157943964004517,
-0.35279685258865356,
-0.2535826... | |
wrong here? Maybe there's something glaring that I am missing? (it's Friday and late work hours here in Belgium, bear with me ;))
Edit: Maybe I should explain: what I need is a function that works for any year, returning the same results as the gregorian calendar I linked. So no special workarounds for 2008.
This [art... | [
0.2663133442401886,
0.14045745134353638,
0.13957391679286957,
-0.07935830950737,
-0.20272472500801086,
-0.22225724160671234,
0.4615788459777832,
0.31306493282318115,
-0.5279141068458557,
-0.1645541787147522,
-0.069669209420681,
0.4019947946071625,
0.017902985215187073,
0.21839600801467896,... | |
Let's for a moment assume that you're programming in a language that uses camelcase words for identifiers, by convention. All you Ruby types with your underscore-separated method names get to sit this one out.
What approach do you take to capitalising the letters after the first when your name contains an acronym? For... | [
0.5768723487854004,
0.38609713315963745,
0.05212734267115593,
0.1819145828485489,
-0.24173572659492493,
-0.33452102541923523,
0.2216387689113617,
0.10230544954538345,
-0.290589839220047,
-0.3331642746925354,
0.06498772650957108,
0.27315396070480347,
-0.2834351062774658,
0.34732863306999207... | |
really a big deal, but for some reason I sometimes come across a method/class/variable capitalised one way and thing it would look more natural the other. The strange thing is that I'm not even sure it's consistent; it would not surprise me to discover that I like all uppercase for certain names, and lowercased for oth... | [
0.6282334923744202,
0.11168629676103592,
-0.19855251908302307,
0.21801410615444183,
-0.28514426946640015,
-0.1535051465034485,
0.360979825258255,
0.7574611902236938,
-0.26230576634407043,
-0.5512063503265381,
0.06309851258993149,
0.17150002717971802,
0.017105475068092346,
0.033505197614431... | |
I'm looking for a method to resize the page width Crystal Reports gives me to place fields in my .rpt file.
So far I have discovered if I right click on the report, select 'design'/'printer setup', I can select the size of the paper I want the report to print out on. If I select 'Orientation/Landscape' I can increase ... | [
0.4529595673084259,
0.12316521257162094,
0.611305832862854,
0.011015033349394798,
-0.21485471725463867,
0.1825389415025711,
0.06484382599592209,
-0.32971689105033875,
-0.3643468916416168,
-0.7463187575340271,
0.1660599410533905,
0.4148077368736267,
-0.037573374807834625,
0.0646876916289329... | |
place all of the fields in the .rpt file.
Is there a way to increase the width of the page to an arbitrary number?
Found it: <http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=754>
Basically add a dummy printer to your system that can take a larger paper size and select that as your printer for the report. | [
0.5748530626296997,
-0.06269713491201401,
0.7907481789588928,
0.24328003823757172,
-0.21098820865154266,
-0.0549742691218853,
-0.17001114785671234,
-0.1739526093006134,
-0.5391124486923218,
-0.23354950547218323,
0.29637858271598816,
0.3600353002548218,
-0.1694178283214569,
0.04531791061162... | |
I'm running into an issue where granting EXECUTE permissions on a specific Stored Procedure in SQL Server 2005 is not working. Some of the testers messed around with the permissions - and found that if they also granted CONTROL permissions on the Stored Procedure - then it ran fine. They are now convinced that granting... | [
0.17145684361457825,
0.4189409613609314,
0.18713907897472382,
0.026095781475305557,
0.23487962782382965,
-0.4303748309612274,
0.3999883830547333,
-0.23050476610660553,
-0.20213064551353455,
-0.05125310644507408,
0.20238742232322693,
0.6218963265419006,
-0.2979566156864166,
0.15283712744712... | |
seem to find anything online that proves it.
Am I correct? Is anybody aware of any documentation that talks about this?
Thanks in advance.
More info in response to comments:
The stored procedure is doing multiple deletes. It first deletes all of the records that would be orphaned by the "main" record being deleted, ... | [
0.34516870975494385,
0.22578434646129608,
0.0723332017660141,
0.5224596858024597,
0.38798099756240845,
-0.34674951434135437,
0.41258078813552856,
0.12710531055927277,
-0.4993263781070709,
-0.4620513319969177,
-0.12292827665805817,
0.33121368288993835,
0.06355961412191391,
0.327094376087188... | |
using EXECUTE AS CALLER (which I believe is the default), then the caller must have all of the permissions necessary to do whatever the stored procedure does in addition to EXECUTE on the procedure.
From the SQL Server documentation for EXECUTE AS:
> CALLER Specifies the statements inside
> the module are executed i... | [
0.5242490172386169,
0.08455288410186768,
0.45794200897216797,
-0.24537569284439087,
0.1381082832813263,
-0.32212215662002563,
0.3407883048057556,
-0.7153226137161255,
-0.20745576918125153,
-0.12644268572330475,
-0.20219604671001434,
0.7577366828918457,
-0.5338082909584045,
-0.0011275405995... | |
processes permission checks using ownership chains, this isn't always strictly true, and I'm guessing that granting CONTROL on the procedure (which confers ownership status to the grantee) is causing these permission checks to be bypassed.
If you create the procedure with EXECUTE AS OWNER, then you should not need to ... | [
0.1457168012857437,
0.3542913794517517,
0.10725218802690506,
0.3931812644004822,
0.45753028988838196,
-0.46012789011001587,
0.023112626746296883,
-0.2508174180984497,
-0.6364027261734009,
-0.42888548970222473,
-0.13495469093322754,
0.04909660667181015,
-0.0982326939702034,
0.61720788478851... | |
I am trying to write a really simple Outlook VSTO add in that checks email that is being sent for a few simple properties. My problem is that I cannot seem to install/test the add in using Outlook. I have added unit tests that ensure the code I have written likely does what it should but that final level of integration... | [
0.7175557017326355,
0.2858803868293762,
0.0716412216424942,
0.015155503526329994,
-0.1303154081106186,
0.18933196365833282,
0.36400237679481506,
0.14876291155815125,
0.20792894065380096,
-0.9584184885025024,
0.26981210708618164,
0.67697674036026,
-0.00029964614077471197,
-0.058560397475957... | |
it in Outlook and Opens Outlook. Just make sure Outlook is closed before starting as this seems to cause issues. Otherwise in your bin folder where your dll was created there is a vsto file, Click on that and it will install it. | [
0.40064939856529236,
-0.2881574332714081,
0.5972296595573425,
0.27864107489585876,
0.005179884843528271,
-0.2915003001689911,
0.2268330156803131,
0.43301770091056824,
-0.005591863766312599,
-0.9956327080726624,
-0.12420006841421127,
0.6089357733726501,
-0.21880486607551575,
0.0851996988058... | |
I'm writng a small application in PHP + MySQL and have come to the point where there is an object that has a couple (8 so far but not expected to increase) of flags associated with it. The flags are pretty much unrelated although there are some combinations that would make no sense. The object represents a row in a DB ... | [
0.46160128712654114,
0.1461605280637741,
0.2694179117679596,
-0.09612761437892914,
-0.5101264119148254,
0.07547253370285034,
0.1385277658700943,
-0.2678830623626709,
-0.307273268699646,
-0.6182323694229126,
0.3541822135448456,
0.21535705029964447,
-0.20853173732757568,
0.20248164236545563,... | |
them in the DB is in a single integer field as bitwise flags. On the PHP side then I can imagine several ways of representing them:
* Simply export the integer value and define a couple of flag constants; Let every place that needs the flags do their own bitwise magic;
* Define class methods `GetFlag()`, `SetFlag()` a... | [
0.25137922167778015,
-0.031156407669186592,
0.3398374617099762,
0.1291559338569641,
-0.37878507375717163,
-0.042226146906614304,
0.22050637006759644,
-0.6502900123596191,
-0.029306748881936073,
-0.5212110877037048,
-0.07224392145872116,
0.3345535695552826,
-0.1876460611820221,
-0.033375162... | |
represent one flag; Set them on loading from the DB and gather them when saving.
* Create a member variable that is an array of all the flag values. Use predefined constants as array indices to access each flag. Also fill/gather the array on loading/saving.
Another way would be to store them in the DB as separate BIT ... | [
-0.02341330796480179,
-0.09578917175531387,
-0.0064972867257893085,
0.22861391305923462,
-0.385638564825058,
0.08981470763683319,
0.17325647175312042,
-0.5738632678985596,
0.0421808622777462,
-0.40478602051734924,
0.17135973274707794,
0.25315752625465393,
-0.5019080638885498,
-0.1089348271... | |
the messiest of all solutions, considering that there would be only like 3 tables otherwise.
I haven't done much PHP development so I don't know what the best practice would be. In C# I would probably store them as bitwise flags and make properties that do the bitwise magic on a private integer. But PHP doesn't have p... | [
-0.08386287838220596,
0.25592947006225586,
0.37043681740760803,
0.3054072856903076,
-0.12900178134441376,
0.14864429831504822,
0.33451205492019653,
-0.34821903705596924,
-0.60840904712677,
-0.5292722582817078,
0.24477478861808777,
0.17395725846290588,
-0.39762401580810547,
0.26191994547843... | |
who has to maintain this thing will be saying.
```
CREATE TABLE mytable (myfield BIT(8));
```
OK, looks like we're going to have some binary data happening here.
```
INSERT INTO mytable VALUES (b'00101000');
```
Wait, somebody tell me again what each of those 1s and 0s stands for.
```
SELECT * FROM mytable;
+---... | [
0.04019083455204964,
0.34748512506484985,
0.6524643898010254,
0.27485722303390503,
0.12143160402774811,
-0.07208336144685745,
0.44405046105384827,
0.014340945519506931,
-0.08314502984285355,
-0.19387739896774292,
-0.19656109809875488,
0.8009176254272461,
-0.0587746798992157,
0.157590448856... | |
Yes, I do understand the difference between them. What I want to know is: why OVERRIDE a method? What is the good in doing it?
In case of overload: the only advantage is you haven't to think in different names to functions?
*Overloading* generally means that you have two or more functions in the same scope having the s... | [
-0.04299459606409073,
-0.04041066765785217,
0.035298097878694534,
0.4398042857646942,
-0.06216530129313469,
-0.22980886697769165,
0.228001207113266,
-0.3131493628025055,
-0.1249370351433754,
-0.3596445918083191,
-0.01998061127960682,
0.7074186205863953,
-0.39402467012405396,
0.139620885252... | |
static type of the argument. If you have an overload for `B` and one for `D`, and the argument is a reference to `B`, but it really points to a `D` object, then the overload for `B` is chosen in C++. That's called *static dispatch* as opposed to *dynamic dispatch*. You overload if you want to do the same as another fun... | [
-0.1558152288198471,
-0.004707640968263149,
0.2975727915763855,
-0.2635566294193268,
-0.16829758882522583,
0.11870145797729492,
-0.21631723642349243,
-0.06402307748794556,
-0.13892704248428345,
-0.18867309391498566,
-0.28603577613830566,
0.5676873326301575,
-0.9237406849861145,
0.183284446... | |
print their argument, so they are overloaded. But the first prints a foo, and the second prints a bar. If you have two functions that do different things, it's considered bad style when they have the same name, because that can lead to confusion about what will happen actually when calling the functions. Another usecas... | [
0.11955029517412186,
0.3285907208919525,
0.4305703043937683,
-0.3468987047672272,
0.0094611132517457,
0.29385295510292053,
0.15559297800064087,
-0.21434736251831055,
0.04675864428281784,
-0.37374231219291687,
-0.2274675816297531,
0.5824359059333801,
-0.7147741317749023,
-0.0261167716234922... | |
PrintAttributes(header, printBold));
}
```
That can be convenient for the caller, if the options that the overloads take are often used.
*Overriding* is something completely different. It doesn't compete with overloading. It means that if you have a virtual function in a base class, you can write a function with th... | [
0.0632113367319107,
-0.12430397421121597,
0.3119945824146271,
0.008169122971594334,
-0.045288559049367905,
-0.17472074925899506,
0.13645197451114655,
-0.16557960212230682,
-0.06602314859628677,
-0.38556721806526184,
-0.16829121112823486,
0.5680345892906189,
-0.5228524208068848,
0.189466029... | |
call the `print` member function, the print function of the derived is always called, because it overrides the one of the base. If the function `print` wasn't virtual, then the function in the derived wouldn't override the base function, but would merely *hide* it. Overriding can be useful if you have a function that a... | [
0.35774657130241394,
-0.016587836667895317,
0.2798227071762085,
-0.10534405708312988,
-0.03818398341536522,
-0.37469327449798584,
0.005577447358518839,
-0.26833245158195496,
0.01384930219501257,
-0.24325858056545258,
-0.15711946785449982,
0.5564398765563965,
-0.5941128730773926,
0.07614088... | |
the derived class will be called. That's the point of virtual functions. Without them, the print function of the base would be called, and the one in the derived class wouldn't override it. | [
0.050779279321432114,
-0.24590134620666504,
0.14000089466571808,
0.3602082431316376,
0.07850489765405655,
0.04381687939167023,
-0.01176761370152235,
0.08554214984178543,
0.27658459544181824,
-0.3215691149234772,
-0.15877392888069153,
0.7777805924415588,
-0.25308138132095337,
0.117552772164... | |
I have these tables:
```
customer
--------
customer_id int
name varchar(255)
order
-----
order_id int
customer_id int
discount boolean
```
I can get the number of orders made by each customer with a query like:
```
select c.id, count(o.order_id)
from customer c
left join order as o using c.customer_i... | [
-0.10333488881587982,
0.27829068899154663,
0.4122786223888397,
-0.29138386249542236,
-0.2591497600078583,
0.5213578939437866,
-0.2879730761051178,
-0.5066778063774109,
-0.269600510597229,
-0.3576318621635437,
0.16039295494556427,
0.579929530620575,
-0.016314344480633736,
0.1278963685035705... | |
c.id, count(o.order_id), count(o2.order_id)
from customer c
left join order as o using c.customer_id = o.customer_id
left join order as o2 using c.customer_id = o2.customer_id and o2.discount = true
group by 1
```
But it didn't work. Is it possible to calculate both in a single (MySql) query?
Cheers,
Don
How about ... | [
-0.10883361101150513,
0.347062349319458,
0.6402201652526855,
-0.230010986328125,
-0.1291990727186203,
0.5397487282752991,
-0.38135552406311035,
-0.3729627728462219,
-0.1819622665643692,
-0.1974940448999405,
0.14350110292434692,
0.5312662124633789,
-0.08696866780519485,
0.10102026164531708,... | |
The .net framework provides in the Math class a method for powering double. But by precision requirement I need to raise a decimal to a decimal power [ Pow(decimal a, decimal b) ]. Does the framework have such a function? Does anyone know of a library with this kind of function?
To solve my problem I found some [expans... | [
0.21526727080345154,
-0.10658414661884308,
0.32378044724464417,
0.09899801015853882,
-0.06921453028917313,
0.11520446091890335,
0.14149625599384308,
-0.31543710827827454,
-0.08071978390216827,
-0.4237038195133209,
-0.002127634594216943,
0.31420037150382996,
-0.30674347281455994,
-0.0345214... | |
ITERATIONS;
decimal result = 1;
while (iteration > 0)
{
fatorial = Factorial(iteration);
result += Pow(power, iteration) / fatorial;
iteration--;
}
return result;
}
// natural logarithm series
public static decimal LogN(decimal number)
{
decimal aux = (number - 1);
... | [
-0.19241324067115784,
-0.6069158911705017,
0.1541205197572708,
0.13080233335494995,
0.021402817219495773,
0.6966703534126282,
0.36173611879348755,
-0.3068576157093048,
-0.23812295496463776,
-0.29146304726600647,
0.16141650080680847,
0.23484091460704803,
-0.23576562106609344,
0.082822591066... | |
{
result += Pow(aux, iteration) / iteration;
iteration--;
}
return result;
}
// example
void main(string[] args)
{
decimal baseValue = 1.75M;
decimal expValue = 1/252M;
decimal result = DecimalExp(expValue * LogN(baseValue));
}
```
The Pow() and Factorial() functions are simple be... | [
-0.2128523886203766,
-0.4133950471878052,
0.19305945932865143,
-0.32880669832229614,
0.13595259189605713,
0.4127340614795685,
0.15307459235191345,
-0.6084254384040833,
-0.04254540055990219,
-0.22377605736255646,
-0.25046491622924805,
0.4360910952091217,
-0.013724452815949917,
-0.0964028090... | |
I have a webpage on my site that displays a table, reloads the XML source data every 10 seconds (with an XmlHttpRequest), and then updates the table to show the user any additions or removals of the data. To do this, the JavaScript function first clears out all elements from the table and then adds a new row for each u... | [
0.1830514520406723,
0.29028117656707764,
0.5573505759239197,
-0.08603260666131973,
-0.0014811999863013625,
-0.11147329956293106,
0.11451961100101471,
-0.2704039216041565,
-0.2600248157978058,
-0.7592851519584656,
-0.018517404794692993,
0.4479977488517761,
0.03252040594816208,
0.17533695697... | |
are using quietly keeping a reference to every JS object created with `new Element(...)` until the page is unloaded).
With the memory problems solved, we've now uncovered a CPU-based problem: when the user has a large amount of data to view (100+ units of data, which equals 100 `<tr>` nodes to create, plus all of the... | [
0.20437443256378174,
0.16648900508880615,
0.4604094326496124,
-0.07017754018306732,
0.22393342852592468,
-0.0742718055844307,
0.5979228615760803,
0.03281140699982643,
-0.40253663063049316,
-0.7639522552490234,
-0.11557330191135406,
0.3055167496204376,
-0.46010875701904297,
0.33674508333206... | |
your computer may become
> unresponsive.
It seems that running the row-and-cell-creation code times 100+ pieces of data is what is causing the CPU usage to spike, the function to take "too long" (from IE's perspective) to run, thus causing IE to generate this warning for the user. I've also noticed that while the "up... | [
-0.0223871860653162,
0.23942986130714417,
0.3959658145904541,
0.006388195790350437,
0.039044883102178574,
-0.1590208262205124,
0.6602012515068054,
0.21297556161880493,
-0.09216033667325974,
-1.0355947017669678,
-0.025066671893000603,
0.48985227942466736,
-0.20732170343399048,
-0.1943176984... | |
pause JS execution and re-render the DOM? If not, are there any strategies for handling creating large amounts of DOM nodes and *not* having the browser choke?
One method I can think of would be to handle the "update table" logic asynchronously; that is, once the Ajax method to reload the XML data is complete, put th... | [
0.4919728636741638,
-0.35810917615890503,
0.33278775215148926,
-0.18597455322742462,
-0.1543784886598587,
0.06894504278898239,
0.31891509890556335,
-0.018502457067370415,
-0.25695720314979553,
-0.2773160934448242,
-0.09792745113372803,
0.6714450716972351,
-0.2871556282043457,
-0.1623936146... | |
could get very complicated (i.e. what if another Ajax data request fires while I'm still re-creating the table's DOM nodes?, etc.)
---
**update**: Just wanted to explain why I'm accepting RoBurg's answer. In doing some testing, I've found that the `new Element()` method in my framework (I'm using [mootools](http://m... | [
-0.1365712732076645,
-0.03563658520579338,
0.725425124168396,
0.14200547337532043,
0.1688358038663864,
-0.0005273526185192168,
0.3154638409614563,
-0.5130344033241272,
-0.08572916686534882,
-0.8667121529579163,
-0.14375533163547516,
0.5923181772232056,
-0.02973514050245285,
-0.188577100634... | |
for a simple test such as mine: using [DocumentFragments as described by John Resig](http://ejohn.org/blog/dom-documentfragments/). Running the same test on the same machine with IE7 took 247ms, a **9x** improvement from my original method!
100 `<tr>`'s isn't really that much... are you still using that framework's `ne... | [
0.010212232358753681,
-0.013633937574923038,
0.04125983268022537,
0.048033032566308975,
-0.14614318311214447,
-0.18402136862277985,
0.48256853222846985,
-0.41563957929611206,
-0.1792954057455063,
-0.6480315923690796,
0.15421156585216522,
0.6056793332099915,
-0.12584371864795685,
0.01089440... | |
I use C#'s [BackgroundWorker](http://msdn.microsoft.com/en-us/library/system.componentmodel.backgroundworker.aspx "BackgroundWorker") object frequently to start a thread and perform a task. What's the easiest way to accomplish the same thing in Delphi?
Here's some code in C#:
```
private void button1_Click(object sen... | [
0.26199784874916077,
0.08549736440181732,
0.16853538155555725,
-0.06518587470054626,
0.29342496395111084,
0.3527337908744812,
0.3206748962402344,
-0.3908133804798126,
-0.33687886595726013,
-0.413722425699234,
-0.31438907980918884,
0.32231804728507996,
-0.3259776532649994,
-0.08164031803607... | |
both give you similar functionality. | [
0.3583512604236603,
0.22688573598861694,
0.04754665121436119,
0.4620187282562256,
-0.015438095666468143,
-0.11766047030687332,
-0.1831168532371521,
-0.12465649098157883,
-0.06427592039108276,
-0.6635651588439941,
0.22997355461120605,
0.6397176384925842,
0.1638496071100235,
0.12341576814651... | |
I was just wondering if it is possible to capture the output of a separate process running on windows?
For instance if i have a console app running, could i run a second app, a forms app, and have that app capture the output from the console app and display it in a text box?
You can do this:
```
Process[] p = Pro... | [
0.3272343575954437,
-0.24859444797039032,
0.6342968940734863,
-0.03707500547170639,
0.4419216811656952,
0.054163072258234024,
0.23479263484477997,
-0.21627777814865112,
-0.153448686003685,
-0.8553313612937927,
-0.14398005604743958,
0.47031262516975403,
-0.2102736383676529,
0.14771834015846... | |
I'm using the selenium IDE and the Selenium-Fitnesse Bridge fixture and I'm trying to test that when I clear a default value out of a form field, my form displays an error message.
So when I record with the Selenium IDE, what it does is the equivalent of telling Selenium to type nothing.
```
| type | text_field | |
... | [
0.5458505153656006,
-0.1140277236700058,
0.6077779531478882,
-0.29089123010635376,
0.11536357551813126,
-0.12287891656160355,
0.04007718339562416,
-0.16712884604930878,
0.16097307205200195,
-0.6438555717468262,
0.21064172685146332,
0.3415127992630005,
-0.4060170352458954,
0.340878248214721... | |
of my input field.
```
| storeEval | window.document.getElementById('reg_start_date').value = '' |
```
From the selenium reference:
> Note that, by default, the snippet will run in the context of the "selenium" object itself, so `this` will refer to the Selenium object. Use `window` to refer to the window of your a... | [
0.23104752600193024,
0.021921876817941666,
0.6421535015106201,
-0.33834871649742126,
0.24575084447860718,
-0.08088080585002899,
0.3113381564617157,
0.13241472840309143,
0.15876269340515137,
-0.6220294237136841,
-0.4551566541194916,
0.42426222562789917,
-0.26777780055999756,
0.4022758305072... | |
Perl uses reference counting for GC, and it's quite easy to make a circular reference by accident. I see that my program seems to be using more and more memory, and it will probably overflow after a few days.
Is there any way to debug memory leaks in Perl? Attaching to a program and getting numbers of objects of vario... | [
0.35620707273483276,
0.06566957384347916,
0.31682464480400085,
0.29810547828674316,
-0.36773765087127686,
-0.05604194849729538,
0.3061957061290741,
0.07885082811117172,
-0.6842421889305115,
-0.09023334830999374,
0.09901075065135956,
0.3515908122062683,
-0.46143046021461487,
0.3588180243968... | |
by itself: It's all up to `malloc()` and all the rules associated with that.
Knowing how `malloc()` allocates memory is important to answering the greater question, and it varies from system to system, but in general most `malloc()` implementations are optimized for programs allocating and deallocating in stack-like o... | [
0.05808097869157791,
0.18954375386238098,
0.21042880415916443,
0.09594684839248657,
0.05777351185679436,
-0.03269963711500168,
-0.17775866389274597,
-0.2603464722633362,
-0.5148850679397583,
-0.2616315484046936,
-0.3148972988128662,
0.3640015125274658,
-0.16811925172805786,
-0.210187807679... | |
fact- by calling `undef($old_object)` explicitly - and in the right order, in a manner similar to the way C-programmers say `free(old_object);`
For long-running programs (days, months, etc), where I have loads of load/copy/dump cycles, I garbage-collect using `exit() and exec()`, and where it's otherwide unfeasible, I... | [
0.6089849472045898,
0.12361441552639008,
0.22025462985038757,
0.3194676339626312,
0.1739519238471985,
-0.19118715822696686,
-0.014265554025769234,
0.019336434081196785,
-0.21897758543491364,
-0.178609237074852,
-0.33991318941116333,
0.3427855968475342,
-0.4365304410457611,
0.48752462863922... | |
to give back.
Of course, if you do have leaks in *your* code, then the rest of my advice is somewhat more relevant. It was originally posted [to another question on this subject](https://stackoverflow.com/questions/295385/are-there-any-tools-for-finding-memory-leaks-in-my-perl-program#295461), but it didn't *explicitl... | [
0.2255113124847412,
-0.05448119342327118,
0.07259774953126907,
0.3686208724975586,
-0.22326453030109406,
-0.23300524055957794,
0.12915359437465668,
0.12291909009218216,
-0.5407474637031555,
-0.1854652464389801,
0.08853302896022797,
0.20333434641361237,
-0.36797940731048584,
0.1338070482015... | |
good first place, but you'll need a perl built for debugging.
If you suspect the leak is inside XS-space, it's much harder, and [Valgrind](http://valgrind.org/) will probably be your best bet. [Test::Valgrind](http://search.cpan.org/dist/Test-Valgrind/) may help you lower the amount of code you need to search, but thi... | [
0.11915861070156097,
0.020766708999872208,
0.079144686460495,
0.1978403776884079,
-0.0010490085696801543,
-0.39253348112106323,
0.2581672966480255,
0.24153169989585876,
-0.21483752131462097,
-0.3115347921848297,
-0.19150838255882263,
0.4262256622314453,
-0.25150737166404724,
0.018093112856... | |
I've recently started using it. However, after running it against one of my company's largest project. It turns up mountains of problems.
The list of problems was so overwhelming it would take days to find and fix some, if not all of the stuff.
Now, I know that it's not very practical to fix everything FxCop tells yo... | [
0.7077252864837646,
0.12915708124637604,
0.3246331512928009,
-0.022573182359337807,
0.12372388690710068,
0.038841914385557175,
0.001819533878006041,
0.17948876321315765,
-0.1446523517370224,
-0.6927831768989563,
0.4087071120738983,
0.8324161767959595,
0.123947374522686,
-0.1412826180458068... | |
with a small set of rules at the beginning. And then increase the number of rules you apply.
And also you must have a look at [this questio](https://stackoverflow.com/questions/27009/how-does-one-implement-fxcop-static-analysis-on-an-existing-code-base)n's answers... | [
0.2393009215593338,
-0.27944231033325195,
0.261393278837204,
0.004722978454083204,
0.2246740311384201,
-0.04429800435900688,
-0.10074317455291748,
-0.46413442492485046,
-0.3400018513202667,
-0.20396330952644348,
-0.011671406216919422,
0.3525662124156952,
-0.23827405273914337,
-0.3008860647... | |
I have a main TCL proc that sources tons of other tcl procs in other folders and subsequent subdirectories. For example, in the main proc it has:
```
source $basepath/folderA/1A.tcl
source $basepath/folderA/2A.tcl
source $basepath/folderA/3A.tcl
source $basepath/folderB/1B.tcl
source $basepath/folderB/2B.tcl
source $b... | [
0.4439120590686798,
0.21297766268253326,
0.33443936705589294,
-0.049879640340805054,
-0.0939122810959816,
-0.3079860210418701,
-0.06867829710245132,
-0.12685556709766388,
-0.10855165123939514,
-0.19957685470581055,
0.16409525275230408,
0.43938058614730835,
-0.6144179105758667,
0.0271102096... | |
directory tree recursively.
```
# findFiles
# basedir - the directory to start looking in
# pattern - A pattern, as defined by the glob command, that the files must match
proc findFiles { basedir pattern } {
# Fix the directory name, this ensures the directory name is in the
# native format for the platform a... | [
0.004370798356831074,
-0.1214815229177475,
0.7246244549751282,
-0.05800311639904976,
0.40660834312438965,
0.03054111637175083,
-0.07827755063772202,
-0.07692063599824905,
-0.08028654754161835,
-0.7138603925704956,
-0.205183207988739,
0.5369063019752502,
-0.4888869524002075,
-0.125074177980... | |
# means ony readable normal files are looked at, -nocomplain stops
# an error being thrown if the returned list is empty
foreach fileName [glob -nocomplain -type {f r} -path $basedir $pattern] {
lappend fileList $fileName
}
# Now look for any sub direcories in the current directory
foreach ... | [
0.19413501024246216,
-0.307437539100647,
0.7726901769638062,
0.06951295584440231,
0.4238376021385193,
0.0055973120033741,
0.5501003265380859,
-0.10436426103115082,
-0.08147868514060974,
-0.567693829536438,
-0.4253118932247162,
0.9466952085494995,
-0.3432868421077728,
0.0413404181599617,
... | |
and append any
# new files to the results
set subDirList [findFiles $dirName $pattern]
if { [llength $subDirList] > 0 } {
foreach subDirFile $subDirList {
lappend fileList $subDirFile
}
}
} | [
-0.11866437643766403,
-0.33240893483161926,
0.56453537940979,
-0.10212701559066772,
0.371269553899765,
-0.08765193074941635,
0.07328642159700394,
-0.4014022648334503,
-0.18912552297115326,
-0.4668978154659271,
-0.3963298499584198,
0.47007548809051514,
-0.3570452034473419,
-0.10576477646827... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.