text stringlengths 0 30.5k | title stringclasses 1
value | embeddings listlengths 768 768 |
|---|---|---|
appgroup.Description
}
}).ToArray()
};
return Json(jsonData);
}
```
And here is my HTML/Javascript:
```
$(document).ready(function() {
$("#listGroups").jqGrid({
url: '<%= ResolveUrl("~/JSON/GetAppGroups/") %>',
datatype: 'json',
mtype: 'GET',
caption: 'App ... | [
-0.18560323119163513,
-0.07280857861042023,
0.7081668972969055,
-0.2955664396286011,
0.23590759932994843,
0.29434362053871155,
0.322294682264328,
-0.24783600866794586,
-0.4732482135295868,
-0.6801172494888306,
-0.6327353119850159,
0.7615663409233093,
-0.7246352434158325,
-0.169652655720710... | |
colModel: [
{ name: 'Name', index: 'Name', width: 250, resizable: true, editable: false},
{ name: 'Description', index: 'Description', width: 650, resizable: true, editable: false},
],
loadtext: 'Loading Unix App Groups...',
multiselect: true,
pager: $("#pager"),
rowNum: 10,
rowL... | [
-0.7412965893745422,
0.005320398602634668,
0.7640994787216187,
-0.4056893289089203,
-0.06536020338535309,
0.4873018264770508,
-0.1505647897720337,
-0.18824316561222076,
-0.3259873688220978,
-0.48213639855384827,
-0.44858238101005554,
0.6899259686470032,
-0.2846653163433075,
-0.123542547225... | |
I have a WCF service hosted in IIS. The intention is for clients to make a call and receive a custom class that is defined in another project/dll. I have generated a service client using the svcutil.exe. The problem is this autogenerated client contains a new partial / proxy definition for the class I am trying to retu... | [
0.35688406229019165,
-0.08611457049846649,
0.3866015672683716,
-0.10828090459108353,
-0.506944477558136,
-0.02856624685227871,
0.207437664270401,
-0.4252103865146637,
-0.13637104630470276,
-0.6260191202163696,
0.0935959741473198,
0.3538864850997925,
-0.2361457496881485,
0.14757652580738068... | |
can add a reference to the shared dll (rather than using the generated proxy class)
* yes, it defeats a lot of the intent of data-contracts, and if any kind of custom serialization is happening, you may have issues extending your service
I have gone down this road before, and in some ways wish I hadn't. Re extensibili... | [
0.5371416211128235,
-0.21651336550712585,
0.3947840631008148,
0.29886195063591003,
-0.09695859998464584,
-0.2639281749725342,
0.045768991112709045,
-0.05486961826682091,
-0.30794113874435425,
-0.9495282173156738,
-0.04168853163719177,
0.6059538125991821,
-0.18999391794204712,
0.16657991707... | |
classes is that it makes it a bit easier to test: since you have the same `IFoo` everywhere, you can mock that `IFoo` with reasonable chance of success. It is harder to mock when the proxy gets involved (as you change more moving parts between the test code and the production code). | [
0.04453721269965172,
-0.03893822059035301,
-0.3406488299369812,
0.5970730185508728,
-0.304417222738266,
-0.10706163942813873,
0.2490110695362091,
0.21605698764324188,
-0.04469116032123566,
-0.7773762941360474,
-0.043522223830223083,
0.24492549896240234,
0.014170780777931213,
0.273564070463... | |
I have a few tables that have similar fields but not exactly the same.
The same fields they have are description (text field) and modified (unixtime)
I would like to select the last modified items from these tables based on unixtime. I cant use UNION since the tables aren't the same and the multiple table select time... | [
0.42699000239372253,
0.09159045666456223,
0.255534291267395,
0.017957625910639763,
-0.05270114168524742,
0.04360993579030037,
-0.2006882280111313,
-0.15335889160633087,
-0.26688140630722046,
-0.8445625901222229,
0.14200787246227264,
0.508370041847229,
-0.3828073740005493,
0.214439809322357... | |
I am executing If statement based on some vales but Nunit executes all statements even if the condition is false
Nunit doesn't actually evaluate your statements, it simply instantiates your tests and runs them. I would suggest that you install [TestDriven.NET](http://testdriven.net), if you haven't already, and use the... | [
0.5779511332511902,
0.03418874740600586,
-0.271755576133728,
-0.12890978157520294,
-0.29506826400756836,
-0.08206505328416824,
0.7369534373283386,
-0.24920231103897095,
0.3473898768424988,
-0.49551644921302795,
0.11897146701812744,
0.6358759999275208,
-0.06755585968494415,
-0.0996444001793... | |
Does anyone know how one can get the total number of calls to an MSSQL2000 server during a specified time, let’s say 24 hours?
We want figures of how many calls our production machine gets per day, but we can’t find any good tools/strategies for this.
Best regards
Fredrik
I think using SQL Profiler here is overkill i... | [
0.3653704822063446,
0.1975831687450409,
0.3902762532234192,
0.06291592866182327,
0.08713681250810623,
-0.22086550295352936,
0.35701245069503784,
-0.23846344649791718,
-0.576560914516449,
-0.11788640916347504,
0.3957032263278961,
0.5047450661659241,
-0.04867817834019661,
0.19134847819805145... | |
and subtract the values to work out how many SQL requests you received for the day:
```
SELECT cntr_value
FROM sysperfinfo
WHERE object_name = 'SQLServer:SQL Statistics'
AND counter_name = 'Batch Requests/sec'
```
This will obviously only work if the server is up for the whole day; restarting will reset the numbe... | [
0.1462523490190506,
-0.028162071481347084,
0.6463173031806946,
-0.059851158410310745,
0.09198828041553497,
-0.14627225697040558,
0.07519739866256714,
-0.03044556826353073,
-0.414920836687088,
-0.32064902782440186,
-0.003514803946018219,
0.6336601972579956,
-0.1292765885591507,
0.2110388725... | |
I have this kind of code in some applications (from microsoft)
```
[assembly: System.Diagnostics.CodeAnalysis.SuppressMessage(
"Microsoft.Naming",
"CA1702:CompoundWordsShouldBeCasedCorrectly",
MessageId = "CounterClockwise",
Scope = "member",
Target = "ScePhotoViewer.PhotoDisplayControl.#RotatePhotoCount... | [
0.5700839757919312,
0.1472398191690445,
-0.017733268439769745,
0.15744946897029877,
-0.19809335470199585,
-0.2970706522464752,
0.3074718117713928,
-0.3339863121509552,
-0.14127352833747864,
-0.6840206384658813,
0.12314635515213013,
0.23358707129955292,
-0.14302322268486023,
-0.052281934767... | |
the "Suppress Message" option is selected in the error list. | [
-0.021751509979367256,
-0.2435384839773178,
-0.00007863273640396073,
-0.07236800342798233,
0.3261110782623291,
0.08139300346374512,
0.5075150728225708,
0.01687156967818737,
-0.0422198660671711,
-0.4391971826553345,
-0.5741217136383057,
0.8327516913414001,
-0.3663683533668518,
-0.3451141715... | |
This is an incredibly simple question (I'm new to Python).
I basically want a data structure like a PHP array -- i.e., I want to initialise it and then just add values into it.
As far as I can tell, this is not possible with Python, so I've got the maximum value I might want to use as an index, but I can't figure out... | [
0.34414634108543396,
0.12576739490032196,
-0.12561635673046112,
0.12443169206380844,
-0.2306271195411682,
-0.20477060973644257,
-0.03801241144537926,
-0.06401803344488144,
-0.17447227239608765,
-0.47903189063072205,
0.3649180233478546,
0.32729625701904297,
-0.36984822154045105,
0.027589958... | |
it seemed unhappy with storing strings.
Edit: Sorry, I didn't explain very clearly what I was looking for. When I add items into the list, I do not want to put them in in sequence, but rather I want to insert them into specified slots in the list.
I.e., I want to be able to do this:
```
list = []
for row in rows:
... | [
-0.12164975702762604,
0.025651965290308,
0.16933602094650269,
-0.025612743571400642,
-0.2756767272949219,
0.17379403114318848,
0.11159764230251312,
-0.187437504529953,
-0.2606140375137329,
-0.4569757580757141,
-0.015078413300216198,
0.4001530110836029,
-0.46271470189094543,
0.0273647904396... | |
list_of_categories.index(row["id"])
print c
d[c] = row["name"]
```
... or more compactly:
```
d = dict((list_of_categories.index(row['id']), row['name']) for row in rows)
print d
```
PHP arrays are much more like Python dicts than they are like Python lists. For example, they can have strings for keys.
And co... | [
0.0018881210125982761,
0.05639675632119179,
0.21940840780735016,
0.09078603982925415,
-0.5014495253562927,
-0.0674021914601326,
-0.08192482590675354,
-0.4618859589099884,
-0.4203019440174103,
-0.15286903083324432,
-0.029050586745142937,
0.44994083046913147,
-0.5121979117393494,
-0.11878690... | |
When I click `Ctrl`+`Shift`+`R` in **eclipse** I get a dialog that allows me to find a resource. However it shows all resources regardless if they are not compiled or compiled. Is there any way to filter so it shows just not compiled resource? Or can I hide compiled resources in some way?
To hide compiled resources whe... | [
0.13031770288944244,
-0.0727812722325325,
0.18466949462890625,
0.32277315855026245,
-0.3101220726966858,
-0.22979286313056946,
-0.015985792502760887,
0.15516899526119232,
-0.3706746995449066,
-0.6819323897361755,
0.03124702163040638,
0.5161299109458923,
-0.07903639227151871,
-0.05945246294... | |
With valid HTML the following finds the object as expected in all browsers but gets NULL in IE (6 & 7).
```
$(document).ready(function() {
alert( '$(.rollover):\n' + $('.rollover'));
});
```
I've tried by switching it to something simpler like $('a') but I always get NULL in IE.
**Update:**
After running the pa... | [
0.1679796725511551,
0.26676690578460693,
0.6407445073127747,
-0.2950752377510071,
-0.37256208062171936,
-0.34744906425476074,
0.6875093579292297,
-0.23377880454063416,
-0.25292906165122986,
-0.6308295726776123,
-0.3264068365097046,
0.4475839138031006,
-0.4329341650009155,
-0.12245078384876... | |
simple document works as expected in IE.
If you're having $ conflicts there are many way to avoid this as documented [here](http://docs.jquery.com/Using_jQuery_with_Other_Libraries). | [
0.1215686947107315,
0.06642736494541168,
0.34479987621307373,
0.14955395460128784,
-0.07530538737773895,
-0.3540339171886444,
0.5412983298301697,
-0.1278190016746521,
-0.0859907865524292,
-0.9873636960983276,
-0.30003514885902405,
0.801901638507843,
-0.13748714327812195,
-0.202601701021194... | |
I am using VS2008 to develop a WinForms 2.0 application. I have read about how to localize my app in the Visual Studio by setting the Localizable property to true in the designer etc.
I would like to ask about your experience, how does it work when I translate the app into several languages and then make changes to th... | [
0.310209184885025,
-0.07222603261470795,
0.29139241576194763,
0.08032315224409103,
0.01525189634412527,
0.03381561115384102,
0.3033519387245178,
-0.04207365959882736,
0.029278863221406937,
-0.7478945255279541,
-0.05202062427997589,
0.5116245150566101,
-0.22278547286987305,
0.04008140414953... | |
features. Does it all work or will I end with some corrupted resource files or such?
The reason I am asking is that I had used Borland C++ Builder before, which had big problems when I changed UI in an already localized app.
When you add controls to your form and set properties they will be added to the culture neutra... | [
0.5013882517814636,
-0.16756585240364075,
0.4791877269744873,
0.2610794007778168,
-0.15751966834068298,
-0.05696374550461769,
0.4055773615837097,
-0.0889640599489212,
-0.2867737114429474,
-0.6497867107391357,
-0.09395294636487961,
0.5313395857810974,
-0.12609665095806122,
-0.24067440629005... | |
and if no resources are found for that either it will load the neutral resource.
So even if you add new controls but don't add culture specific resources for them your application will work but with english (?) texts instead of translated texts. | [
0.21986931562423706,
0.05342418700456619,
0.11210193485021591,
0.465248167514801,
-0.01711295358836651,
-0.06764262914657593,
0.2844415307044983,
0.2257636934518814,
0.04869427904486656,
-0.5204694867134094,
-0.20581942796707153,
0.5220593810081482,
-0.08608465641736984,
-0.181118503212928... | |
When I try to load a solution in Visual Studio 2008, it immediately closes. I get the following error in the event log:
> .NET Runtime version 2.0.50727.3053 -
> Fatal Execution Engine Error
> (6E875E00) (80131506)
I've searched the web high and low and can't find a resolution to this problem. I've found similar is... | [
0.1561293751001358,
0.2408212423324585,
0.27764835953712463,
-0.11932095140218735,
-0.1263030618429184,
-0.16028577089309692,
0.5468490123748779,
-0.24317985773086548,
-0.052847761660814285,
-0.593278169631958,
-0.05497433990240097,
0.9043155908584595,
-0.3136407434940338,
0.04185946285724... | |
which one.
Anyone experience this? This is very frustrating!
EDIT: The answer to this problem for future reference was to uninstall Gallio. This was the only add-in that caused the crash. Thanks to all for the help!
Try creating a new solution and importing your existing projects.
Alternitivly, uninstall ReShaper, G... | [
0.3653618395328522,
-0.20837140083312988,
-0.02089138701558113,
0.48039308190345764,
-0.3400253653526306,
-0.1342865377664566,
0.18191105127334595,
0.08385886996984482,
-0.1503259837627411,
-0.4588930308818817,
0.22065326571464539,
0.7122505903244019,
-0.2686062157154083,
-0.07194618880748... | |
In the code below I tried in two ways to access the parent version of methodTwo, but the result was always 2. Is there any way to get the 1 result from a ChildClass instance without modifying these two classes?
```
class ParentClass
{
public int methodOne()
{
return methodTwo();
}
virtual publ... | [
-0.03591255471110344,
-0.37503504753112793,
0.18912136554718018,
-0.08093943446874619,
0.3387250304222107,
0.0012920823646709323,
0.47230732440948486,
-0.23512664437294006,
-0.0035015034954994917,
-0.6970261931419373,
0.054874349385499954,
0.5708054900169373,
-0.16452008485794067,
0.202390... | |
{
return 2;
}
}
class Program
{
static void Main(string[] args)
{
var a = new ChildClass();
Console.WriteLine("a.methodOne(): " + a.methodOne());
Console.WriteLine("a.methodTwo(): " + a.methodTwo());
Console.WriteLine("((ParentClass)a).methodTwo(): "
+ ((Par... | [
-0.025699863210320473,
-0.1389426290988922,
0.22151502966880798,
-0.3417603671550751,
0.273693323135376,
0.18143977224826813,
0.505957841873169,
-0.21260061860084534,
-0.09585223346948624,
-0.4290105700492859,
-0.42476946115493774,
0.4466415345668793,
-0.3303273022174835,
0.547485828399658... | |
don't know
> any easy way; but, perhaps, I don't
> know what happens if you try
> reflection: use the Type.GetMethod
> method to find the MethodInfo
> associated with the method in the
> ParentClass, and then call
> MethodInfo.Invoke
That answer was deleted. I'm wondering if that hack could work, just for curio... | [
0.46963122487068176,
-0.05782147869467735,
0.2969793975353241,
0.22570006549358368,
0.1692499816417694,
-0.3019844889640808,
0.6325474381446838,
-0.22061696648597717,
-0.03525266423821449,
-0.38709375262260437,
-0.2829824686050415,
0.7750688791275024,
-0.2416146993637085,
0.065738029778003... | |
fine; too clever by half...)
Inside the `ChildClass` type, you can use `base.methodTwo()` - however, this is not possible externally. Nor can you go down more than one level - there is no `base.base.Foo()` support.
However, if you disable polymorphism using method-hiding, you can get the **answer** you want, but for ... | [
0.2812124192714691,
-0.16136737167835236,
-0.051320880651474,
0.1259489804506302,
0.2919771373271942,
-0.062348246574401855,
0.5080745816230774,
-0.27589163184165955,
-0.15849275887012482,
-0.43377166986465454,
0.03148217126727104,
0.681735098361969,
-0.2492927461862564,
0.2808135151863098... | |
as a `ChildClass` or a `ParentClass`. | [
-0.0017962830606848001,
-0.3077801764011383,
-0.38197216391563416,
0.010165367275476456,
-0.06879252940416336,
0.21116824448108673,
0.324374258518219,
0.2313840240240097,
-0.3909584581851959,
-0.5112349390983582,
-0.6135627031326294,
0.02070847898721695,
0.017945878207683563,
0.62443435192... | |
I'm writing a little utility that starts with selecting a file, and then I need to select a folder. I'd like to default the folder to where the selected file was.
`OpenFileDialog.FileName` returns the **full path & filename** - what I want is to obtain just the **path portion (sans filename)**, so I can use that as th... | [
0.10289105027914047,
-0.14303357899188995,
0.7923829555511475,
-0.13467371463775635,
0.06817064434289932,
0.07278748601675034,
0.08496370911598206,
-0.2382631003856659,
-0.03334169089794159,
-0.8185165524482727,
-0.17646174132823944,
0.44963473081588745,
-0.4536465108394623,
0.130452200770... | |
string sourceFolder = ???;
}
...
fbd.SelectedPath = sourceFolder; // set initial fbd.ShowDialog() folder
if (fbd.ShowDialog() == DialogResult.OK)
{
...
}
```
Are there any .NET methods to do this, or do I need to use `regex, split, trim,` etc??
Use the [`Path`](http://msdn.microsoft.com... | [
0.03665448725223541,
-0.2569922208786011,
0.6385147571563721,
0.0007087434059940279,
0.10591766238212585,
0.01791951432824135,
0.02138654701411724,
-0.38796913623809814,
-0.011221948079764843,
-0.5873118042945862,
0.03680184856057167,
0.4599364995956421,
-0.48680272698402405,
0.07104182243... | |
Path.GetDirectoryName(filePath);
``` | [
0.15953736007213593,
-0.4202035367488861,
0.3199615180492401,
0.32292062044143677,
0.22783420979976654,
-0.20275162160396576,
0.12443619221448898,
0.26572126150131226,
-0.16033121943473816,
-1.0351762771606445,
-0.19807326793670654,
0.4787524342536926,
-0.5162319540977478,
0.38050910830497... | |
I am eventually wanting to program in Objective-C to write programs for OS X and possibly the iPhone. I do not have any direct experience with C and I come from a web programming background. I am much more familiar with java syntax than C and Objective C.
I am just looking for suggestions on how to get started. It loo... | [
0.25177818536758423,
0.4440899193286896,
0.11837942898273468,
0.037091214209795,
0.14787444472312927,
-0.07733901590108871,
0.1987346112728119,
0.36348214745521545,
-0.004865752067416906,
-0.8386012315750122,
0.14830921590328217,
0.6607306003570557,
-0.10705576092004776,
-0.171691313385963... | |
helpful too, I am used to eclipse)). I am just looking for book recommendations, online tutorials or any other pointers to keep in mind. Keep in mind though that my end goal is to work with Objective-C, so is there anything I need to keep in mind when learning C, anything to watch out for, etc. Thanks for any input.
*... | [
0.19839534163475037,
-0.0019692976493388414,
-0.23216478526592255,
0.23765906691551208,
-0.23213349282741547,
-0.22082290053367615,
0.19356591999530792,
0.7682278156280518,
-0.05412827804684639,
-0.7202300429344177,
-0.02180924266576767,
0.8159604072570801,
0.15298594534397125,
-0.32764291... | |
tutorials out there for me?
I don't entirely agree with unwind who says "C and Objective-C are different languages". Objective-C is a strict superset of C.
Of course he knows that - his point was that you don't need to completely master C before progressing onto Objective-C. I'll second that (and hopefully have clarif... | [
0.20368921756744385,
0.16134266555309296,
-0.022115685045719147,
0.17786411941051483,
-0.1559455543756485,
-0.4090312421321869,
0.43492668867111206,
0.2755166292190552,
-0.09473808109760284,
-0.3501168489456177,
-0.19989241659641266,
0.757809579372406,
-0.04759172722697258,
-0.224464237689... | |
it at this stage). If you want to take it seriously, then "The C Programming Language" by K&R is the classic text.
When you you can do some basic hello world programs in C, and understand the type system, pointers and stuff - then pick up a copy of "Cocoa Programming for Mac OS X", by Aaron Hillegass. This is a book a... | [
0.3029695153236389,
0.4634400010108948,
-0.182631254196167,
0.2295883744955063,
0.00970897451043129,
-0.14474725723266602,
-0.025640493258833885,
0.33155861496925354,
-0.07714924216270447,
-0.43366366624832153,
-0.26640555262565613,
0.6652151942253113,
-0.39238297939300537,
-0.264130502939... | |
able to follow the pure language stuff using GCC on Windows, but I wouldn't recommend it.
If you're going to be working on a Mac eventually, then best to do it at this stage, IMHO. You say you don't have a Mac "powerful enough for programming", but anything that can run OS X would be fine to get your started. | [
0.15593677759170532,
0.2580638527870178,
-0.042742688208818436,
0.20189028978347778,
0.08655640482902527,
-0.2584399878978729,
0.2923785448074341,
0.5092663764953613,
-0.0072941854596138,
-0.5618925094604492,
-0.061349932104349136,
0.7695791721343994,
0.03770091012120247,
-0.22484169900417... | |
I'm investigating using DbC in our Perl projects, and I'm trying to find the best way to verify contracts in the source (e.g. checking pre/post conditions, invariants, etc.)
[Class::Contract](http://search.cpan.org/~ggoebel/Class-Contract-1.14/lib/Class/Contract/Production.pm) was written by Damian Conway and is now m... | [
0.4556896686553955,
0.2510550618171692,
0.046228326857089996,
-0.14040803909301758,
-0.18621160089969635,
0.13660627603530884,
0.2834027409553528,
-0.19229236245155334,
-0.2718982994556427,
-0.3332582414150238,
-0.09297545999288559,
0.06534305959939957,
-0.44611239433288574,
0.063584469258... | |
modules out there that I haven't been able to find.
Is anyone doing DbC with Perl? Should I just "jump in" to Moose and see what I can get it to do for me?
Moose gives you a lot of the tools (if not all the sugar) to do DbC. Specifically, you can use the before, after and around method hooks ([here's](http://search.c... | [
0.3741658329963684,
0.048757657408714294,
0.17877495288848877,
0.0678822323679924,
-0.357254296541214,
-0.31904277205467224,
0.19639542698860168,
-0.44352811574935913,
-0.12489882111549377,
-0.17649582028388977,
-0.012491351924836636,
0.38434547185897827,
-0.3135719299316406,
-0.1349062025... | |
to a subroutine. These modules don't handle the "post" or "invariant" validations that DbC typically provides, however.
**EDIT:** Motivated by this question, I've hacked together [MooseX::Contract](http://search.cpan.org/perldoc?MooseX::Contract) and uploaded it to the CPAN. I'd be curious to get feedback on the API a... | [
0.6011171936988831,
0.19083459675312042,
0.10452799499034882,
-0.14505892992019653,
-0.15706346929073334,
-0.25309136509895325,
0.5741415619850159,
0.0006158312316983938,
-0.10475338250398636,
-0.4470365345478058,
0.009954947978258133,
0.2393171638250351,
-0.38146281242370605,
0.0196490976... | |
How do I get a random [`decimal.Decimal`](https://docs.python.org/3.6/library/decimal.html#decimal-objects) instance? It appears that the random module only returns floats which are a pita to convert to Decimals.
What's "a random decimal"? Decimals have arbitrary precision, so generating a number with as much randomnes... | [
0.2781791090965271,
-0.004244390409439802,
0.04833841323852539,
0.3944453299045563,
-0.10236576199531555,
-0.0797497108578682,
-0.25301051139831543,
-0.19413800537586212,
-0.13782557845115662,
-0.13162016868591309,
0.24504195153713226,
0.06454787403345108,
0.2423509806394577,
0.46792203187... | |
the fraction (see [randrange here](https://docs.python.org/2/library/random.html#random.randrange)):
```
decimal.Decimal(random.randrange(10000))/100
``` | [
-0.03651106357574463,
-0.04587417095899582,
-0.12154512107372284,
-0.025156939402222633,
-0.20292732119560242,
0.5320605039596558,
-0.45731979608535767,
-0.1480243057012558,
-0.08549311012029648,
0.20451216399669647,
0.02143961749970913,
0.09455296397209167,
0.3230290412902832,
0.238289698... | |
I have a table like this (Oracle, 10)
```
Account Bookdate Amount
1 20080101 100
1 20080102 101
2 20080102 200
1 20080103 -200
...
```
What I need is new table grouped by | [
-0.09759945422410965,
0.5238895416259766,
0.17827510833740234,
-0.01830417849123478,
-0.16933853924274445,
0.03937846049666405,
0.03720053285360336,
-0.12738224864006042,
-0.2409500926733017,
-0.6171709895133972,
0.3134571313858032,
0.38021600246429443,
-0.1694965362548828,
-0.080133877694... | |
Account order by Account asc and Bookdate asc with a running total field, like this:
```
Account Bookdate Amount Running_total
1 20080101 100 100
1 20080102 101 201 | [
-0.008394569158554077,
0.30627766251564026,
0.33862003684043884,
-0.2195817530155182,
-0.10787271708250046,
0.1611412763595581,
0.2301812469959259,
-0.13522925972938538,
-0.30130720138549805,
-0.299353688955307,
-0.12211646139621735,
0.3241223394870758,
0.21467874944210052,
0.1193488538265... | |
1 20080103 -200 1
2 20080102 200 200
...
```
Is there a simple way to do it?
Thanks in advance.
Do you really need the extra table?
You can get that data you need with a simple query, which you can obviously create as a | [
0.211690291762352,
0.1182679831981659,
0.17359669506549835,
0.30920305848121643,
-0.09345801919698715,
-0.4058249592781067,
0.008624915964901447,
-0.20564502477645874,
-0.12757271528244019,
-0.5316985249519348,
0.04073480889201164,
0.5235438346862793,
-0.2652011811733246,
-0.51192849874496... | |
view if you want it to appear like a table.
This will get you the data you are looking for:
```
select
account, bookdate, amount,
sum(amount) over (partition by account order by bookdate) running_total
from t
/
```
This will create a view to show you the data as if it were a table:
```
create or replace ... | [
0.2679494619369507,
-0.2193334698677063,
0.42425379157066345,
-0.07563488930463791,
-0.19713960587978363,
0.34907618165016174,
-0.24638815224170685,
0.08942088484764099,
-0.4301852583885193,
-0.8913889527320862,
0.05420030280947685,
0.5834502577781677,
-0.1828806847333908,
0.20400202274322... | |
Obviously if it's a one off you can just "create table as select" using the above query.
Test data I used is:
```
create table t(account number, bookdate date, amount number);
insert into t(account, bookdate, amount) values (1, to_date('20080101', 'yyyymmdd'), 100);
insert into t(account, bookdate, amount) values (... | [
0.10568029433488846,
-0.08324304968118668,
0.3093089163303375,
-0.031243544071912766,
0.13399046659469604,
0.27596375346183777,
-0.18589447438716888,
-0.24601754546165466,
-0.09615485370159149,
-0.514563262462616,
-0.044624194502830505,
0.3940213620662689,
-0.22439011931419373,
0.148708939... | |
of the query you execute, not something that's inherant in the table (ignoring Index Organised Tables and the like). | [
0.09826062619686127,
0.007577001117169857,
-0.0020091368351131678,
0.2674354314804077,
-0.04578390344977379,
-0.1756300926208496,
-0.2413390576839447,
0.13926199078559875,
-0.2240312248468399,
-0.5361754894256592,
-0.4119037985801697,
0.5356093645095825,
-0.21361063420772552,
0.06534691154... | |
I'm hoping to clear some things up with anonymous delegates and lambda expressions being used to create a method for event handlers in C#, for myself at least.
Suppose we have an event that adds either an anonymous delegate or a lambda expression (for you lucky crowds that can use newer versions of .NET).
```
SomeCl... | [
0.511399507522583,
-0.25483405590057373,
-0.2754666805267334,
0.2327415943145752,
0.10476316511631012,
-0.28349071741104126,
0.09835920482873917,
0.22411496937274933,
-0.4751339852809906,
-0.6317222118377686,
0.04223198816180229,
0.23021671175956726,
-0.23726704716682434,
0.152732491493225... | |
SomeEvent to null within the class. Wouldn't the following be an entirely new handler?
```
SomeClass.SomeEvent -= delegate(object o, EventArg e) { /* do something */ };
```
I could see storing the anonymous delegate or lambda expression in a variable. But that, to me at least, seems to defeat the entire purpose of b... | [
0.31184861063957214,
-0.20956434309482574,
-0.12709468603134155,
-0.24110931158065796,
-0.020941419526934624,
-0.08554480969905853,
0.3077649176120758,
0.10468902438879013,
-0.21947051584720612,
-0.27734145522117615,
-0.10640428960323334,
0.3614702820777893,
-0.3109991252422333,
0.20936477... | |
more interesting with just removing the dynamically created method from the event. Hopefully someone can shed some light onto this for me. Thanks!
If object X has an event handler whose *target* is object Y, then object X being alive means that object Y can't be garbage collected. It doesn't stop object X from being ga... | [
0.3527979254722595,
-0.05650701746344566,
-0.15590089559555054,
0.3335855007171631,
-0.5609214901924133,
-0.44556939601898193,
0.33921611309051514,
0.27928969264030457,
-0.48360514640808105,
-0.5716844201087952,
0.02122272364795208,
0.6519981026649475,
-0.3280491828918457,
0.42034870386123... | |
disposed, but will never be garbage collected because there's still a reference to it from the event in a different object. | [
0.7208847403526306,
-0.09589744359254837,
0.08905894309282303,
0.3774220943450928,
-0.03459356352686882,
-0.17778512835502625,
0.03187568858265877,
0.3245672881603241,
-0.16110579669475555,
-0.361037015914917,
-0.36531922221183777,
0.11785272508859634,
0.020017007365822792,
0.1574472934007... | |
When working with namespaces such as System.Data.Odbc or System.Data.OracleClient the various data reader methods generally require an integer corresponding to a column be provided to the functions (e.g. [OracleDataReader.GetInt32](http://msdn.microsoft.com/en-us/library/system.data.oracleclient.oracledatareader.getint... | [
-0.17170163989067078,
-0.02038170024752617,
0.319916695356369,
-0.034903302788734436,
-0.11602017283439636,
0.33083662390708923,
-0.09619405120611191,
-0.34911537170410156,
-0.014043903909623623,
-0.42108845710754395,
-0.1866355836391449,
0.5463166236877441,
-0.38651129603385925,
-0.023067... | |
value
string myString = Convert.ToString(oraData["Field_Name"]);
```
Each of these techniques seem to have there own pros and cons and I'm curious to see what others think, or if there is a better way to do it.
I agree with Andrew Hare, with the addition that I've enclosed the functionality in an overloaded extension... | [
0.17447522282600403,
0.0983983501791954,
0.17157554626464844,
-0.10431218892335892,
0.030812684446573257,
-0.09384901821613312,
0.03205529972910881,
-0.32335710525512695,
0.08851947635412216,
-0.11747943609952927,
-0.05594264343380928,
0.8665985465049744,
-0.4513351619243622,
0.11397226154... | |
string defaultValue)
{
string result = defaultValue;
int columnIndex = reader.GetOrdinal(columnName);
if(!reader.IsDbNull(columnName)
{
result = (string) reader.GetString(columnIndex);
}
return result;
}
```
Anyway, just a refactoring that helped me tremendously. | [
-0.3271917402744293,
-0.3320784270763397,
0.8700279593467712,
-0.19659914076328278,
0.008827250450849533,
0.07386963814496994,
0.4434318542480469,
-0.18034018576145172,
-0.05040960758924484,
-0.5263391733169556,
-0.1074892207980156,
0.8759559392929077,
-0.22650869190692902,
0.1185700148344... | |
I am having some trouble with [this code](http://pastebin.com/mbd132a7). The problem is when i Request the Server to send me some data and the client just Disconnects when the server tries to send me data, the application Exists.
Here's the lines I think cause the problem
```
int SendBinary(int *byte, int length)
{
... | [
0.06737687438726425,
0.018862877041101456,
0.7414731979370117,
-0.33534982800483704,
-0.044376570731401443,
-0.07825818657875061,
0.40344002842903137,
0.0453764870762825,
-0.13127397000789642,
-0.5718919634819031,
-0.11460480839014053,
0.4229365885257721,
-0.48082083463668823,
0.3981173932... | |
if ( current_char == EOF )
break;
SendBinary(¤t_char, sizeof(char));
}
while(current_char != EOF);
}
```
Any ideas what i should do to prevent this? Revise the whole source for complements to this snippet.
Perhaps your application is receiving SIGPIPE during the write/send and not ... | [
0.22324548661708832,
0.05448053777217865,
0.4434469938278198,
-0.07941747456789017,
0.07163260132074356,
-0.4078528881072998,
0.503507137298584,
0.04871867224574089,
-0.17005977034568787,
-0.49970492720603943,
-0.15505042672157288,
0.6972342729568481,
-0.43705594539642334,
0.21993549168109... | |
I'd like to add a bookmark to a users Mobile Safari bookmarks when they install my iPhone application.
I don't want the user to have to do it manually, i'd like my iphone app to install the bookmark (actually a javascript based bookmark, e.g. `javascript:`)
Does anyone know of anyway to do this?
Not currently possi... | [
0.6100234985351562,
0.3511616587638855,
0.40083572268486023,
-0.014981403946876526,
0.21976380050182343,
-0.0010558274807408452,
0.3010316491127014,
0.1171039417386055,
-0.2707797586917877,
-0.6299379467964172,
0.18821129202842712,
0.6017236113548279,
0.026974640786647797,
-0.2647189199924... | |
I'm thinking about including the Apache POI into my application. Main goal is to output RTF document, but DOC would be nice, too. But the documentation is not very detailed about writing a HWPFDocument and everything I found on the web isn't helpful at all.
I can read DOC files, that's working without any problem. But... | [
0.4465588331222534,
0.04955242946743965,
0.14678236842155457,
0.08468452841043472,
-0.1904228776693344,
-0.15842604637145996,
0.32383421063423157,
-0.1122845783829689,
0.04302116855978966,
-0.7744128108024597,
0.2798953354358673,
0.8715649247169495,
-0.11747268587350845,
-0.161926984786987... | |
can export them the hard way
//-- save as example.doc -------------
```
{
\rtf1
\ansi
\ansicpg1252
\deff0
\deflang1033
{\fonttbl
{\f0
\fswiss
\fcharset0 Arial;
}
}
{
\*
\generator Msftedit 5.41.21.2500;
}
\viewkind4
\uc1
\pard
\f0
\fs20
Hello World
\par
}
``` | [
-0.2948927879333496,
0.24499957263469696,
0.3752877414226532,
0.07937897741794586,
0.1393142193555832,
0.004521658178418875,
0.4132634401321411,
0.497121125459671,
-0.2985384464263916,
-0.8196738362312317,
-0.6322309970855713,
0.29871872067451477,
-0.5001920461654663,
0.37957310676574707,
... | |
Why is my mod\_rewrite doing this?
```
add path info postfix: /home/mobelluk/public_html/about.php -> /home/mobelluk/public_html/about.php/
```
which results in an unwanted trailing slash on EVERYTHING.
I have disabled all my .htaccess rules so they're out of the equation.
Is it possible the new server has [mod\_di... | [
0.02033417299389839,
-0.01831646077334881,
0.5582796335220337,
-0.26718711853027344,
-0.005322451703250408,
-0.4589676260948181,
0.7787581086158752,
-0.18772900104522705,
-0.2674378454685211,
-0.4698253571987152,
-0.15368527173995972,
0.5793398022651672,
-0.5312719345092773,
0.134177550673... | |
Today I had the problem that I couldn't delete a folder because "it was busy".
How can I find out which application to blame for that or can I just delete it with brute force?
Use lsof to find out what has what files are open.
man lsof or have a look [here](http://en.wikipedia.org/wiki/Lsof) | [
0.07105451077222824,
-0.03905431553721428,
0.29208970069885254,
-0.04359361529350281,
-0.06261467188596725,
-0.1978074163198471,
0.2699890434741974,
0.059777311980724335,
-0.5778153538703918,
-0.7787827253341675,
-0.21828356385231018,
0.43358635902404785,
-0.2685137689113617,
0.25096809864... | |
We have a physical machine that runs VMware and hosts a VM we use for SharePoint deployment testing. That machine is old and dying, and my employer's network czars are heavily pushing hosted VMs as a replacement for outdated physical servers. I was curious about whether it's possible to run VMware inside VMware, and if... | [
0.7546161413192749,
0.4637318253517151,
0.23200231790542603,
0.4793960452079773,
0.39316174387931824,
-0.17652475833892822,
-0.03929636627435684,
0.11711005866527557,
-0.127935528755188,
-0.4211076498031616,
0.3544197082519531,
0.5335085391998291,
0.0001343849435215816,
0.4984762966632843,... | |
our testing because we'll want to roll back occasionally and otherwise have more control over it, and getting buy-in for that from the network folks is unlikely. Does anyone have any experience with this?
edit: I know this nesting certainly isn't the preferred option, but (1) we want the flexibility of being able to u... | [
0.5854254364967346,
-0.005896063521504402,
-0.06779053062200546,
0.3407098650932312,
0.28088369965553284,
-0.2458813488483429,
0.17668868601322174,
0.13166329264640808,
-0.3056529462337494,
-0.4044628143310547,
0.14593438804149628,
0.47382673621177673,
-0.018164105713367462,
-0.10484846681... | |
the way to go. The hosted option seems attractive if it will work though since it's less machine maintenance for me to deal with.
I've never run VMware in VMware, but I've run VirtualPC inside VirtualBox without problems, so there's no fundamental reason it shouldn't work I suppose...
It sounds to me more like you hav... | [
0.5682247281074524,
-0.055930450558662415,
0.3105345070362091,
0.509922206401825,
0.2674396336078644,
-0.2460840493440628,
0.3212765157222748,
0.07151608914136887,
-0.13746050000190735,
-0.3633621037006378,
0.056627798825502396,
0.6788911819458008,
0.15044520795345306,
0.2921081483364105,
... | |
company network at risk. | [
-0.36414292454719543,
0.023307064548134804,
0.25570935010910034,
-0.06088321655988693,
0.048407379537820816,
-0.13541726768016815,
-0.08871739357709885,
0.1475735306739807,
-0.6103415489196777,
-0.2688685357570648,
-0.15210749208927155,
0.38287925720214844,
-0.057592131197452545,
0.2315412... | |
I have a solution with 2 projects. In the first project a I have a website with a Logon Control. In the second project I have a WCF project with an AuthenticatonService configured. What is the easiest way to integrate both? In other word, How do I call the Authentication Service from the login control?
EDIT:
OK, what... | [
0.2924053966999054,
0.05049921199679375,
0.3945453464984894,
-0.03018428012728691,
0.13848766684532166,
-0.2943015992641449,
0.3509795069694519,
-0.15259642899036407,
-0.19504113495349884,
-0.667023777961731,
0.16318513453006744,
0.2613644301891327,
-0.2334882766008377,
0.384867787361145,
... | |
WCF authentication service instead. Sorry for not making myself clear.
OK,
Finally I got it working. This is what I did:
* Add a Service Reference to the WCF url:
<http://localhost:8080/servicios/MiServicio.svc>
* Resetted the Membership Provider property of the Login control. This in facts look for the default memb... | [
0.06977188587188721,
0.029060635715723038,
0.7853304743766785,
-0.16380055248737335,
-0.22124257683753967,
-0.4451525807380676,
0.7420489192008972,
-0.4243745803833008,
-0.07426618784666061,
-0.6383183598518372,
0.09784911572933197,
0.5506961941719055,
-0.22859366238117218,
0.2232913970947... | |
AuthenticationServiceClient();
e.Authenticated = client.Login(login.UserName, login.Password, "", true);
}` | [
-0.10114262998104095,
0.058108605444431305,
0.43878376483917236,
-0.18636354804039001,
0.1011912077665329,
-0.30104532837867737,
0.6456273794174194,
-0.34914013743400574,
0.08387245982885361,
-0.13328397274017334,
-0.2938304543495178,
0.6847522854804993,
-0.2885463535785675,
-0.03254352137... | |
According to the FAQ to GoDaddy they support SignTool from Microsoft, but mage.exe isn't mentioned. Mage.exe is used to sign the application, but I haven't been able to figure out if mage.exe uses SignTool. If anyone have used GoDaddy's code signing certificate for ClickOnce a short confirmation would have been appreci... | [
0.4385543763637543,
0.42508944869041443,
0.7149335145950317,
-0.19198524951934814,
-0.07217777520418167,
-0.14654888212680817,
0.28597161173820496,
-0.19144579768180847,
-0.00890332367271185,
-0.7159709334373474,
-0.08938519656658173,
0.6340810656547546,
0.11211013048887253,
-0.19193108379... | |
I've created a javascript function that allows me to validate if one field or the other is filled (called, shockingly enough, `oneortheother`). Essentially, it checks if neither is filled, or both, and throws an error.
One of the fields being validated is a `input type="file"` field. I'm displaying below the field the... | [
0.17498597502708435,
0.19595909118652344,
0.13491664826869965,
0.03339775651693344,
0.10909067094326019,
-0.19716571271419525,
0.06498747318983078,
-0.07428571581840515,
-0.08728290349245071,
-0.5311173796653748,
0.22873683273792267,
0.5445261001586914,
-0.09202823042869568,
-0.04034576937... | |
this functionality, so any help would be greatly appreciated.
**EDIT:**
As requested, here's some examples:
```
<label for="pdf">Upload PDF:
<span class="fieldnote">Files of type .pdf</span>
</label>
<input type="file" name="pdf" id="pdf" class="external_form_field oneortheother_url" value="/downloads/white_papers/H... | [
0.07482459396123886,
0.21529242396354675,
0.6607299447059631,
-0.02074182964861393,
-0.11253672093153,
-0.14409612119197845,
-0.2379198968410492,
-0.6440542340278625,
-0.0571008063852787,
-0.5390826463699341,
-0.02944985404610634,
0.7021173238754272,
0.14520318806171417,
-0.156363844871521... | |
uploaded preview file OR the value in the file input. Then you could just compare the url input with the hidden input.
But it seems likely you'll just need to write a custom validation function. | [
0.41016510128974915,
-0.32579347491264343,
0.16302849352359772,
0.49412333965301514,
-0.48140862584114075,
-0.2637785077095032,
0.03569222614169121,
0.34374409914016724,
-0.19979596138000488,
-0.6436195373535156,
0.31816598773002625,
0.5046485066413879,
-0.16040275990962982,
0.232621133327... | |
Very similar to [this question](https://stackoverflow.com/questions/157646/best-way-to-encode-text-data-for-xml), except for Java.
What is the recommended way of encoding strings for an XML output in Java. The strings might contain characters like "&", "<", etc.
Very simply: use an XML library. That way it will actual... | [
0.1873585283756256,
-0.0777125433087349,
0.10282383859157562,
0.12281464040279388,
-0.18443717062473297,
-0.32542166113853455,
-0.12537996470928192,
-0.10976842790842056,
-0.36320817470550537,
-0.4687921702861786,
-0.07062580436468124,
0.40379610657691956,
-0.09505618363618851,
-0.34184220... | |
I've actually asked about this already in [this post](https://stackoverflow.com/questions/406279/asp-net-web-architecture-design) although we've gone back to the drawing board and found it's much more difficult than we initially thought. We develop a large (and very much relied upon) Intranet system which has evolved t... | [
0.3943159878253937,
-0.13743656873703003,
0.48111051321029663,
0.2649974822998047,
-0.0026250481605529785,
-0.056452907621860504,
-0.053684961050748825,
0.12920960783958435,
-0.3135078549385071,
-0.8245010375976562,
-0.05725111439824104,
0.24513404071331024,
-0.3375513255596161,
0.18179863... | |
page and CSS, but the problem lay in the actual architecture of our web application.
We're wanting to shift to MVC architecture to make our pages more secure and manageable, however there is a major problem with this. Each section of our Intranet system has cross-links to other pages in other sections. So, for example... | [
0.4242400825023651,
0.08172524720430374,
0.35115787386894226,
0.29867538809776306,
-0.14978012442588806,
-0.1417243331670761,
-0.10726160556077957,
-0.02255837246775627,
-0.5641084313392639,
-0.6866080164909363,
0.12984810769557953,
0.280322402715683,
-0.28609994053840637,
0.02024316415190... | |
example). How would the MVC architecture deal with something like that?
We have pages displayed in completely different areas of our Intranet that are in actual fact the same page. So having a URL like <http://mysite/section/category/page> would have to link to <http://mysite/anothersection/differentcategory/page>.
H... | [
0.5637416839599609,
0.06868255883455276,
0.3319537937641144,
0.31297922134399414,
-0.20198261737823486,
-0.04000880941748619,
0.12028185278177261,
-0.07120383530855179,
-0.6512144804000854,
-0.537206768989563,
0.11207367479801178,
0.254850298166275,
-0.3855057954788208,
0.3407049775123596,... | |
MVC the way to go?
Cheers
* You shouldn't have to, just like the idea behind complex types. You can drop in min-views into a full fledged view to separate repetition.
* You can use Html.ActionLink for creating links to pages and you can use Html.RenderPartial or Html.RenderAction to render a whole action into your pag... | [
0.3715229332447052,
-0.15552029013633728,
0.7101350426673889,
0.039452772587537766,
-0.39614221453666687,
-0.0906774252653122,
0.2393757700920105,
-0.10779155790805817,
-0.5780989527702332,
-0.35852518677711487,
0.0643935278058052,
0.8617362976074219,
-0.212555393576622,
-0.053045481443405... | |
was using the same layout for the fields. So I created a MVC User Control and dropped in the fields and did something like this.
For Add..
```
<asp:Content ID="DefaultContent" ContentPlaceHolderID="DefaultContentPlaceHolder" runat="server">
<% Html.BeginForm<CatalogController>(c => c.AddProduct(null), FormMethod.Post... | [
-0.07748420536518097,
-0.13088873028755188,
0.6476858854293823,
-0.216560497879982,
-0.1736050248146057,
0.4410179853439331,
0.0875755324959755,
-0.5507684350013733,
-0.17287395894527435,
-0.4394255578517914,
-0.4630390405654907,
0.442156046628952,
-0.21809594333171844,
0.22415302693843842... | |
<td><%= Html.TextBox("Product.Name", product.Name) %></td>
</tr>
<tr>
<td><%= Html.Label("Product.Price", "Price") %></td>
<td><%= Html.TextBox("Product.Price", product.Price) %></td>
</tr>
<tr>
<td><%= Html.Label("Product.Description", "Description") %></td>
<td><%= Html... | [
0.5184997320175171,
0.13585297763347626,
0.4731614291667938,
-0.46906301379203796,
0.05644397810101509,
0.5023414492607117,
-0.11083836108446121,
-0.5740197896957397,
0.05257543921470642,
-0.5116288661956787,
-0.37557002902030945,
0.8374916911125183,
-0.11771084368228912,
0.372843742370605... | |
</tr>
<tr>
<td><%= Html.Label("Product.IsFeatured", "Is featured") %></td>
<td><%= Html.CheckBox("Product.IsFeatured", product.IsFeatured.HasValue ? product.IsFeatured.Value : false) %></td>
</tr>
<tr>
<td><%= Html.Label("Product.CategoryID", "Category") %></td>
<td><%= Html.... | [
0.41099610924720764,
0.026119669899344444,
0.6584893465042114,
-0.2720045745372772,
0.03407131880521774,
-0.05292307585477829,
-0.01842871494591236,
-0.45775118470191956,
-0.5001973509788513,
-0.8226934671401978,
-0.3950195014476776,
0.3560582995414734,
-0.10814748704433441,
0.276788115501... | |
How can I configure my WCF service to run under the administrator account? (this is not for production, just testing).
Is it simply a web.config tweak?
IIS 7 hosted WCF service.
* You shouldn't have to, just like the idea behind complex types. You can drop in min-views into a full fledged view to separate repetition.... | [
0.5356783866882324,
-0.33008259534835815,
0.42465725541114807,
0.07946007698774338,
-0.2447909563779831,
0.021901505067944527,
0.4751788079738617,
-0.27529972791671753,
-0.5972486138343811,
-0.6591943502426147,
0.17834818363189697,
0.5872408747673035,
-0.3724866211414337,
0.023048173636198... | |
a small storefront application for a friend and I found myself creating a view for Adding and Editing an Product. Problem is -- I was using the same layout for the fields. So I created a MVC User Control and dropped in the fields and did something like this.
For Add..
```
<asp:Content ID="DefaultContent" ContentPlace... | [
-0.2350708544254303,
-0.0694107785820961,
0.6972180604934692,
-0.2685387432575226,
-0.13423894345760345,
0.3372967541217804,
-0.002541809808462858,
-0.39517995715141296,
-0.13641883432865143,
-0.37410861253738403,
-0.3912128210067749,
0.43976834416389465,
-0.3942023813724518,
0.18736605346... | |
= ViewData["Categories"] as IEnumerable<Category>; %>
<table>
<tr>
<td><%= Html.Label("Product.Name", "Name") %></td>
<td><%= Html.TextBox("Product.Name", product.Name) %></td>
</tr>
<tr>
<td><%= Html.Label("Product.Price", "Price") %></td>
<td><%= Html.TextBox("Product.Price... | [
0.19985443353652954,
0.0622330978512764,
0.4670364558696747,
-0.10763725638389587,
-0.06750523298978806,
0.6176918745040894,
-0.1819436401128769,
-0.541744589805603,
-0.024548988789319992,
-0.5408180356025696,
-0.39026594161987305,
0.6732146143913269,
-0.1777968555688858,
0.517389357089996... | |
<td><%= Html.Label("Product.IsActive", "Is active") %></td>
<td><%= Html.CheckBox("Product.IsActive", product.IsActive) %></td>
</tr>
<tr>
<td><%= Html.Label("Product.IsFeatured", "Is featured") %></td>
<td><%= Html.CheckBox("Product.IsFeatured", product.IsFeatured.HasValue ? product.IsF... | [
0.549440324306488,
0.05438229441642761,
0.6364020109176636,
-0.40225932002067566,
0.06255555897951126,
0.029619060456752777,
-0.0018983361078426242,
-0.46954771876335144,
-0.37385714054107666,
-0.6009964346885681,
-0.32453101873397827,
0.6667122840881348,
-0.1750650256872177,
0.32747429609... | |
easily break up your pages as needed and include them and pass data into them very easily with ASP.NET MVC. | [
0.2848917543888092,
-0.03883889317512512,
0.17588713765144348,
0.32409119606018066,
0.02020568586885929,
-0.5179680585861206,
0.21656887233257294,
0.13411681354045868,
-0.4912547171115875,
-0.6735173463821411,
-0.29781702160835266,
0.32912781834602356,
-0.12703756988048553,
-0.073492355644... | |
How to get real image width & height (cross browser) by JavaScript function ?
First of all, you have a greater chance of getting your question answered if you'd just ask it in a more polite way, and supplying as much relevant information as possible.
Anyway...
For as far as I know, you can use the **`.width` property... | [
0.5117760896682739,
-0.27720576524734497,
0.8049286603927612,
0.059447262436151505,
-0.08439022302627563,
-0.04089083895087242,
0.2095232754945755,
-0.4469190537929535,
-0.11943194270133972,
-0.792519211769104,
-0.09797569364309311,
0.887096107006073,
-0.04835035279393196,
-0.25927734375,
... | |
element.width,
height: element.height
};
}
}
<img id="myimage" src="foo.jpg" alt="" />
// using the function on the above image:
var dims = getDimensions('myimage');
alert(dims.width); --> shows width
alert(dims.height); --> shows height
``` | [
0.09610147774219513,
-0.23490184545516968,
0.7579627633094788,
-0.2840104401111603,
0.14814989268779755,
-0.11579538881778717,
0.2758587598800659,
-0.349953293800354,
-0.24396352469921112,
-0.5159916281700134,
-0.39112141728401184,
0.6145386695861816,
-0.286962628364563,
-0.039790179580450... | |
Hi is there away to detect the length of a byte before I get the error message:
Length cannot be less than zero. Parameter name: length
I get the error on this line:
new\_username = new\_username.Substring(0, new\_username.IndexOf(" Joined "))
I am removing the "joined" from the string I get....how can I ignore it ... | [
-0.15653815865516663,
-0.000013217400010034908,
0.9069704413414001,
-0.22611889243125916,
-0.10246073454618454,
-0.1234779953956604,
0.12481741607189178,
-0.36855676770210266,
-0.028905395418405533,
-0.2181948572397232,
0.01407275628298521,
0.4518362283706665,
-0.1882215142250061,
0.420653... | |
I'm triying to find leaks in my project [chibi-ORM](http://code.google.com/p/chibiorm/) using the tool of scan-build as suggested in other threads.
But when run from the terminal:
```
/Users/mamcx/Downloads/checker-0.138/scan-build -k -V xcodebuild
```
I get this:
```
009-01-13 10:33:18.296 xcodebuild[14025:4213]... | [
0.3238976299762726,
0.6074305176734924,
0.21584706008434296,
-0.054156504571437836,
0.12882356345653534,
-0.3757851719856262,
0.5366626977920532,
0.22977487742900848,
-0.06739968806505203,
-0.6983041167259216,
0.026423107832670212,
0.6342065334320068,
-0.47092151641845703,
0.41025736927986... | |
signing reasons
the fix for iphone apps would be to just go to the project’s properties and set the “Base SDK” to “Simulator - iPhone OS 2.1″ rather than “Device”
check in your case what it would be | [
0.5811944007873535,
0.1768956482410431,
0.2889406085014343,
0.35345420241355896,
0.29524528980255127,
-0.10293108224868774,
0.25355809926986694,
-0.3537465035915375,
-0.2320120632648468,
-0.29330629110336304,
-0.009473711252212524,
0.29278191924095154,
-0.050351858139038086,
-0.24031443893... | |
If you can choose a platform to work with, when you build a new application,
would you prefer to build it from scratch or use platform like Community Server?
If we are talking specifically about community server, the answer is custom from scratch.
If we are talking about in generic terms, it depends more on what you ... | [
1.0279594659805298,
-0.23003539443016052,
-0.19318144023418427,
0.36920902132987976,
-0.03768978267908096,
0.2776889503002167,
-0.00005681656693923287,
0.006024955306202173,
-0.5910876989364624,
-0.5526828169822693,
0.2710317075252533,
0.3847183883190155,
0.009087883867323399,
0.2031092941... | |
Is there a difference between single and double quotes in Java?
Use single quotes for literal `char`s, double quotes for literal `String`s, like so:
```
char c = 'a';
String s = "hello";
```
They cannot be used any other way around (like in Python, for example). | [
0.495266318321228,
0.19153207540512085,
0.014297567307949066,
-0.1718023121356964,
-0.3671981394290924,
0.13086947798728943,
0.1804553121328354,
0.07669870555400848,
-0.04152853041887283,
-0.04977801442146301,
-0.14627152681350708,
0.4508778750896454,
-0.39860987663269043,
-0.1059113368391... | |
I am trying to help a client with a problem, but I am running out of ideas. They have a custom, written in house application that runs on a schedule, but it crashes. I don't know how long it has been like this, so I don't think I can trace the crashes back to any particular software updates. The most unfortunate part i... | [
0.48665809631347656,
0.5603733062744141,
-0.010346373543143272,
0.0063157593831419945,
-0.13716450333595276,
0.10834401845932007,
0.38592904806137085,
0.3257708251476288,
-0.338086873292923,
-0.4445728659629822,
0.08473939448595047,
0.43091678619384766,
-0.22692011296749115,
0.447750806808... | |
Script to add error logging, but I'm not having much luck getting quality information to pinpoint the source of the crash. I have put logging messages on either side of all of the function calls and determined which of the calls is causing the crash. However, nothing is ever returned in the err object because the call ... | [
0.22516664862632751,
0.11772039532661438,
0.06291176378726959,
0.10781928896903992,
-0.2685087323188782,
0.0343121737241745,
0.7978270053863525,
0.3036736845970154,
-0.04553801566362381,
-0.5800054669380188,
0.032704584300518036,
0.6699574589729309,
-0.24816669523715973,
-0.050949748605489... | |
etc). I have checked the log file that is created in drwtsn32.log as a result of wscript.exe crashing, and the only information I get is an "Access Violation".
I first tend to think this is something to do with security permissions, but couldn't this also be a memory access violation?
You may consider using one of the... | [
0.48132452368736267,
-0.04667075350880623,
0.39027291536331177,
0.2577110230922699,
0.10592438280582428,
-0.4357289969921112,
0.24474498629570007,
0.11063583195209503,
-0.30451706051826477,
-0.4710181951522827,
0.06397362798452377,
0.7550802230834961,
-0.039183057844638824,
0.3734399378299... | |
check with [Dependency Walker](http://www.dependencywalker.com/) to make sure you are actually loading the DLL files you think you are. I have seen the wrong version of the C runtime being loaded and causing a mysterious crash. | [
0.6987122297286987,
-0.08562728017568588,
0.030491158366203308,
-0.09720851480960846,
0.09098383784294128,
-0.5060946941375732,
0.39967313408851624,
0.4484320282936096,
-0.3820771276950836,
-0.46995511651039124,
0.03898895904421806,
0.8001320362091064,
-0.3179645836353302,
0.16758520901203... | |
I know that R works most efficiently with vectors and looping should be avoided. I am having a hard time teaching myself to actually write code this way. I would like some ideas on how to 'vectorize' my code. Here's an example of creating 10 years of sample data for 10,000 non unique combinations of state (`st`), plan1... | [
-0.010922863148152828,
-0.1614503115415573,
0.3430422246456146,
-0.27658677101135254,
0.17493955790996552,
0.6209424734115601,
0.3245609402656555,
-0.7336081266403198,
-0.14092180132865906,
-0.42140883207321167,
0.07077587395906448,
0.34152185916900635,
-0.03864707052707672,
0.121926739811... | |
year <-c(year,years)
}
i<-i+1
}
Sys.time() - starttime
```
This takes about 8 minutes to run on my laptop. I end up with 4 vectors, each with 100,000 values, as expected. How can I do this faster using vector functions?
As a side note, if I limit the above code to 1000 loops on i it only takes 2 seconds,... | [
0.36315709352493286,
0.22386206686496735,
0.6574238538742065,
-0.007803445216268301,
0.04050132632255554,
0.15550659596920013,
0.33941909670829773,
-0.20295538008213043,
-0.4658534526824951,
-0.42221298813819885,
0.16368505358695984,
0.06186363473534584,
0.19049233198165894,
0.553560674190... | |
retrospect. :)
To use R's vector logic I took out the loop and replaced it with this:
```
st <- sample(c(12,17,24),10000,prob=c(20,30,50),replace=TRUE)
p1 <- sample(c(12,17,24),10000,prob=c(20,30,50),replace=TRUE)
p2 <- sample(c(12,17,24),10000,prob=c(20,30,50),replace=TRUE)
year <- rep(1991:2000,1000)
```
I ... | [
0.19818374514579773,
0.048796914517879486,
0.33522966504096985,
-0.11097346991300583,
-0.15615347027778625,
0.5275385975837708,
0.46224960684776306,
-0.6929752826690674,
-0.43578389286994934,
-0.33336710929870605,
0.31701982021331787,
0.2106989622116089,
-0.16791650652885437,
0.19877491891... | |
over to my Vista 64 desktop with 6GB ram and created vectors of length 10mm in 17 seconds. 100mm made things fall apart as one of the vectors was over 763mb which resulted in an allocation issue with R.
Vectors in R are amazingly fast to me. I guess that's why I am an economist and not a computer scientist. | [
-0.021273111924529076,
0.11977866291999817,
0.41739895939826965,
0.12426996231079102,
-0.20649637281894684,
0.38762685656547546,
-0.00907372497022152,
-0.22081123292446136,
-0.4640185534954071,
-0.6269077658653259,
0.4013032615184784,
0.5216038823127747,
0.025313017889857292,
0.06459140032... | |
As a fairly junior developer, I'm running into a problem that highlights my lack of experience and the holes in my knowledge. Please excuse me if the preamble here is too long.
I find myself on a project that involves my needing to learn a number of new (to me) technologies, including LINQ (to OBJECTS and to XML for p... | [
0.3820364475250244,
0.38589969277381897,
0.2980048358440399,
0.35472485423088074,
0.1485973596572876,
-0.6083447933197021,
-0.14822477102279663,
0.17313188314437866,
-0.36605316400527954,
-0.40094637870788574,
-0.059462178498506546,
0.5691624879837036,
0.31653496623039246,
0.07778026163578... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.