text stringlengths 0 30.5k | title stringclasses 1
value | embeddings listlengths 768 768 |
|---|---|---|
Are there any standalone type conversion libraries?
I have a data storage system that only understands bytes/strings, but I can tag metadata such as the type to be converted to.
I could hack up some naive system of type converters, as every other application has done before me, or I could hopefully use a standalone l... | [
0.7151108980178833,
-0.09185989946126938,
0.27453920245170593,
0.398951917886734,
0.3637818396091461,
-0.046563420444726944,
-0.21755918860435486,
-0.11602529883384705,
-0.5118761658668518,
-0.5735574960708618,
0.0564492829144001,
0.4848136603832245,
-0.024843089282512665,
-0.0830851346254... | |
A little (!) bit of background before I can get to the question :
I have an accordion control loaded with an array of grids, each of which is lazy loaded with arrays of things. I'm using an auto-generated web service proxy to retrieve these lists. I'd like for the user to be able to change the selected child in the ac... | [
0.0809473767876625,
-0.04440869763493538,
0.38884207606315613,
0.04709705337882042,
0.38624727725982666,
0.654692530632019,
-0.17672990262508392,
-0.056251030415296555,
-0.6067931652069092,
-0.7505360245704651,
0.32116252183914185,
0.09797980636358261,
-0.17809900641441345,
0.2061371356248... | |
that shorter arrays return more quickly from the server, so the order the requests were made in becomes irrelevant.
I couldn't find an obvious way to determine the original request when handling a proxy result event so what I ended up with is a function which handles the change event on the accordion, instantiates a n... | [
-0.33507320284843445,
-0.27610284090042114,
0.6179583072662354,
-0.12305478751659393,
0.06428660452365875,
0.34893596172332764,
-0.11139440536499023,
-0.24394537508487701,
-0.14278259873390198,
-0.6087632179260254,
0.09742078185081482,
0.2321862429380417,
-0.32445964217185974,
0.2950965464... | |
grid.things = ArrayCollection(proxyTable[index].getThings_lastResult);
}
private function SendThingRequest(index:int):void
{
var grid:ThingGrid= myAccordion.getChildAt(index) as ThingGrid;
if (grid.things.length == 0)
{
if (proxyTable[index] == null)
{
proxyTable[index] = new My... | [
-0.22147607803344727,
-0.47199925780296326,
0.7352619767189026,
-0.23894160985946655,
-0.07907065749168396,
0.03959500789642334,
0.3092799186706543,
-0.5397617220878601,
-0.2011435478925705,
-0.827711284160614,
-0.08884517848491669,
0.23144495487213135,
-0.28311416506767273,
0.312793791294... | |
= thingLists.getItemAt(index) as ThingList;
proxy.getThings("thinglist", list.ListID);
}
}
private function myAccordion_Change(event:IndexChangedEvent):void
{
SendThingRequest(event.newIndex);
}
```
(I've tried to anonymise this a bit, so I may have missed something, but hopefully you get the idea)
S... | [
-0.03850886970758438,
-0.007822963409125805,
0.5385626554489136,
-0.17306286096572876,
0.08019936084747314,
-0.21075884997844696,
0.44488611817359924,
-0.2887986898422241,
-0.25675687193870544,
-0.49959972500801086,
-0.05520747974514961,
0.49899449944496155,
-0.18501968681812286,
0.2059879... | |
I might not be aware of?
**Update :**
I think the problem may arise because the generated proxy code subclasses the ResultEvents from flash.events.Event, rather than mx.rpc.events.ResultEvent. I'm not entirely sure why it does this - the only way to access the AsyncToken is when it's initially returned by the method c... | [
0.047876257449388504,
-0.03961803764104843,
0.27067655324935913,
-0.07644811272621155,
-0.07035578787326813,
-0.10434379428625107,
0.42269301414489746,
0.08210422098636627,
-0.20469680428504944,
-0.5470320582389832,
-0.06940658390522003,
0.4868863523006439,
-0.20453022420406342,
0.33163377... | |
token.operation = "list";
}
public function update() {
var token:AsyncToken = myService.update(selectedItem);
token.operation = "update";
}
public function create() {
var token:AsyncToken = myService.create(selectedItem);
token.operation = "create";
}
public function delete() {
var token:AsyncTok... | [
-0.13634930551052094,
-0.4279625117778778,
0.06917588412761688,
-0.1383654624223709,
-0.13133864104747772,
0.23023110628128052,
0.024074861779808998,
-0.41204580664634705,
-0.5251556634902954,
-0.3904830813407898,
-0.28520432114601135,
0.29436126351356506,
-0.22643205523490906,
0.147935062... | |
// etc...
```
`operation` is a dynamic property, not a member of AsyncToken, so you can call it whatever you like.
There's a Cookbook article describing it [here](http://www.adobe.com/cfusion/communityengine/index.cfm?event=showdetails&postId=922&productId=2): | [
0.38494911789894104,
0.00823897123336792,
0.18516959249973297,
-0.1663007140159607,
0.07286382466554642,
-0.08198142051696777,
0.18031267821788788,
-0.41917964816093445,
-0.4542524218559265,
-0.15654787421226501,
-0.5136439204216003,
0.3230789303779602,
-0.16224519908428192,
-0.20276045799... | |
The AddComponent method on the IWindsorContainer interface has several overloads, for example:
```
WindsorContainer.AddComponent<I,T>()
```
and
```
WindsorContainer.AddComponent<I,T>(string key)
```
What's the use of the key parameter and why should I use it?
You would use the key parameter if you were registered... | [
0.17400245368480682,
-0.09266223013401031,
0.3973195254802704,
-0.05500223860144615,
-0.07900486141443253,
0.00409719068557024,
-0.08972136676311493,
-0.511444091796875,
-0.19271914660930634,
-0.556756317615509,
-0.03170544654130936,
0.5720652341842651,
-0.6514548063278198,
0.1647546142339... | |
as the key.
```
container.AddComponent<IHandler, FileHandler>();
```
I believe this is registered with a key of "{Namespace}.IHandler". So it could actually be retrieved later using the automatic key as well.
Hope this helps. | [
0.04965514317154884,
0.12649866938591003,
0.5329248905181885,
-0.05744272097945213,
0.26481378078460693,
-0.26074692606925964,
0.013154832646250725,
-0.009508224204182625,
-0.24568909406661987,
-0.5798942446708679,
-0.389382541179657,
0.370199054479599,
-0.2358919084072113,
0.2119554728269... | |
Greetings!
Anyway, My question, If you want to experiment developing for a Windows Mobile device, how would you go about testing your applications? I know there is a emulator but is not really ideal.
Is there anyway, without paying a stupid astronomical cost, to get a development phone? Akin to what Google did with... | [
0.427590548992157,
0.27544575929641724,
0.4099493622779846,
0.7113827466964722,
-0.03285510838031769,
-0.040510669350624084,
-0.03510364145040512,
0.26238885521888733,
-0.10338786989450455,
-0.48146194219589233,
0.08649963140487671,
0.4898732602596283,
0.3022995591163635,
0.042346127331256... | |
WinMobile 6.1 Pro and £160 sim-free in the UK - half the price of the android dev phone.
Sim free phones are ideal, you can use the free PAYG sim cards all the networks give away these days.
EDIT: Even £160 is a lot - try the [BenQ E72](http://www.expansys.com/d.aspx?i=171963&se=1435) (WinMobile 6) for £100 or [Samsu... | [
-0.14369997382164001,
-0.12895157933235168,
0.8180509805679321,
0.02683478221297264,
-0.45567503571510315,
0.586914598941803,
0.1587592512369156,
-0.18047483265399933,
0.013529875315725803,
0.014555939473211765,
-0.07808549702167511,
0.7259377241134644,
-0.06415075808763504,
-0.22811761498... | |
Question is should i use properties for my view controllers?
Consider the following case:
1. I have a view controller object in my parent class: MyViewController \*myVC;
2. I don't release this view controller in parent class's *dealloc* method.
3. I use view controller like this:
```
// Allocate and Initialize view... | [
0.0660739466547966,
-0.2542741298675537,
0.805202305316925,
-0.009776436723768711,
-0.31482505798339844,
-0.063005730509758,
0.05109282582998276,
-0.36361193656921387,
-0.06441421061754227,
-0.5908188223838806,
0.000293733028229326,
0.696079432964325,
-0.0941261425614357,
0.112196311354637... | |
the price of the android dev phone.
Sim free phones are ideal, you can use the free PAYG sim cards all the networks give away these days.
EDIT: Even £160 is a lot - try the [BenQ E72](http://www.expansys.com/d.aspx?i=171963&se=1435) (WinMobile 6) for £100 or [Samsung i300](http://www.expansys.com/d.aspx?i=124197) (Wi... | [
0.029082193970680237,
-0.3514573574066162,
0.6458669900894165,
0.09029000252485275,
-0.3887272775173187,
0.5075309872627258,
0.28779828548431396,
-0.3282860219478607,
-0.11319834738969803,
-0.15700413286685944,
0.1717437356710434,
0.880337119102478,
-0.01570718176662922,
-0.220606148242950... | |
I am developing a small intranet based web application. I have YSlow installed and it suggests I do several things but they don't seem relevant for me.
e.g I do not need a CDN.
My application is slow so I want to reduce the bandwidth of requests.
1. What rules of YSlow should I adhere to?
2. Are there alternative too... | [
0.45202621817588806,
0.006209971848875284,
0.41401374340057373,
0.20036382973194122,
-0.1270529329776764,
-0.20381967723369598,
0.014349131844937801,
0.08690861612558365,
-0.3106314539909363,
-0.9272995591163635,
0.3114832043647766,
0.4787278473377228,
-0.25359344482421875,
0.1394519209861... | |
it's probably something to do with the backend than the front-facing structure.
If you are trying to optimise for remote users, some of the same things apply to try and optimise the whole thing:
* Don't use 30 stylesheets - cat them into one
* Don't use 30 JS files, cat them into one
* Consider compressing both JS an... | [
0.15294604003429413,
-0.5243958830833435,
0.22789113223552704,
0.3692968785762787,
-0.5165441036224365,
-0.050084277987480164,
0.2367098331451416,
-0.26928550004959106,
-0.338715523481369,
-0.6651206612586975,
0.0786580815911293,
0.41600024700164795,
-0.21177168190479279,
-0.01773581281304... | |
a sensible amount of time.
* Make sure your pages aren't ridiculously large. If you're in a controlled environment and you can guarantee JS availability, you might want to page data with AJAX. | [
0.5027547478675842,
-0.018654681742191315,
0.03954887017607689,
0.10815495997667313,
-0.1425723284482956,
-0.2936100959777832,
0.4027542173862457,
0.16769829392433167,
-0.4282497465610504,
-0.703144371509552,
-0.12735581398010254,
0.4826038181781769,
0.22741220891475677,
-0.341398388147354... | |
**Edit:** I apologize everybody. I used the term "jagged array" when I actually meant to say "multi-dimensional array" (as can be seen in my example below). I apologize for using the incorrect name. I actually found jagged arrays to be faster than multi-dimensional ones! I have added my measurements for jagged arrays.
... | [
0.25458988547325134,
0.2683083415031433,
-0.05184546858072281,
0.10049373656511307,
-0.5001899003982544,
-0.16541680693626404,
0.5566587448120117,
0.15245787799358368,
-0.42587241530418396,
-0.8877531290054321,
0.09477243572473526,
0.7138075232505798,
0.007492449600249529,
0.01858563162386... | |
(initialized to random values), for 1000 iterations, and I got the following results on my machine:
```
sum(double[], int): 2738 ms (100%)
sum(double[,]): 5019 ms (183%)
sum(double[][]): 2540 ms ( 93%)
```
This is my test code:
```
public static double sum(double[] d, int l1) {
// assuming the array is r... | [
0.039903223514556885,
-0.21907581388950348,
0.11884913593530655,
-0.28117239475250244,
-0.03042217157781124,
0.7815179824829102,
0.46234309673309326,
-0.6489761471748352,
-0.18864040076732635,
-0.4233984053134918,
-0.060172002762556076,
0.37783491611480713,
-0.13891787827014923,
-0.1026156... | |
sum += d[i * l2 + j];
return sum;
}
public static double sum(double[,] d) {
double sum = 0;
int l1 = d.GetLength(0);
int l2 = d.GetLength(1);
for (int i = 0; i < l1; ++i)
for (int j = 0; j < l2; ++j)
sum += d[i, j];
return sum;
}
public static double sum(double[][] d) { | [
0.030557936057448387,
-0.4441355764865875,
0.4032514989376068,
-0.6029981374740601,
-0.17713138461112976,
0.4703454375267029,
0.3780772089958191,
-0.6008052229881287,
-0.07312364131212234,
-0.08443232625722885,
-0.48395630717277527,
0.3611190915107727,
-0.5660505294799805,
-0.0197701677680... | |
double sum = 0;
for (int i = 0; i < d.Length; ++i)
for (int j = 0; j < d[i].Length; ++j)
sum += d[i][j];
return sum;
}
public static void Main() {
Random random = new Random();
const int l1 = 1024, l2 = 1024;
double[ ] d1 = new double[l1 * l2];
double[,] d2 = new double[l... | [
0.06570383906364441,
-0.661018967628479,
-0.01983303762972355,
-0.40106382966041565,
0.0719558596611023,
0.41420650482177734,
0.2298886775970459,
-0.2697302997112274,
-0.20351211726665497,
-0.13461756706237793,
-0.24631553888320923,
0.17628900706768036,
-0.5836223363876343,
0.1973057836294... | |
l2];
double[][] d3 = new double[l1][];
for (int i = 0; i < l1; ++i) {
d3[i] = new double[l2];
for (int j = 0; j < l2; ++j)
d3[i][j] = d2[i, j] = d1[i * l2 + j] = random.NextDouble();
}
//
const int iterations = 1000;
TestTime(sum, d1, l1, iterations);
TestTime(su... | [
-0.05622989311814308,
-0.5916497707366943,
0.08474364131689072,
-0.276785284280777,
0.3346518576145172,
0.5154114365577698,
0.4583718478679657,
-0.4852076470851898,
-0.009879514575004578,
-0.6952435374259949,
-0.04827497527003288,
0.28741490840911865,
-0.20328117907047272,
0.01144733186811... | |
iterations);
TestTime(sum, d3, iterations);
}
```
Further investigation showed that the IL for the second method is 23% larger than that of the first method. (Code size 68 vs 52.) This is mostly due to calls to `System.Array::GetLength(int)`. The compiler also emits calls to `Array::Get` for the ~~jagged~~ multi-... | [
-0.15960592031478882,
-0.46042299270629883,
0.11875155568122864,
0.016572944819927216,
-0.14801988005638123,
0.25121819972991943,
0.26715439558029175,
-0.5152173042297363,
-0.16922920942306519,
-0.7550203204154968,
0.06870611011981964,
0.4223121106624603,
-0.3301471769809723,
-0.1181652247... | |
plese help me understand why this is happening the way it is?
---
**Update:** Following Henk Holterman's suggestion, here is the implementation of `TestTime`:
```
public static void TestTime<T, TR>(Func<T, TR> action, T obj,
int iterations)
{
Stopwatch stopwatch = Stopwatch.Sta... | [
0.08608374744653702,
-0.4537263810634613,
0.39808136224746704,
-0.14409108459949493,
0.13781508803367615,
0.36393508315086365,
0.010217394679784775,
-0.18844011425971985,
-0.20002977550029755,
-0.3278646767139435,
0.03975439444184303,
0.5116797685623169,
-0.22972603142261505,
-0.1885557323... | |
" + stopwatch.Elapsed);
}
public static void TestTime<T1, T2, TR>(Func<T1, T2, TR> action, T1 obj1,
T2 obj2, int iterations)
{
Stopwatch stopwatch = Stopwatch.StartNew();
for (int i = 0; i < iterations; ++i)
action(obj1, obj2);
Console.WriteLine(action.Method... | [
0.014503538608551025,
-0.4400612413883209,
0.42152872681617737,
-0.24990412592887878,
0.18799248337745667,
0.3011198937892914,
0.37190520763397217,
-0.538465142250061,
-0.21299204230308533,
-0.1857835352420807,
-0.1487729251384735,
0.5746198296546936,
-0.456185907125473,
-0.153540417551994... | |
of 0 are a different type to either multi-dimensional or non-0 lower bound arrays within IL (`vector` vs `array` IIRC). `vector` is simpler to work with - to get to element x, you just do `pointer + size * x`. For an `array`, you have to do `pointer + size * (x-lower bound)` for a single dimensional array, and yet more... | [
-0.25156232714653015,
-0.14578190445899963,
0.525131344795227,
0.05051844194531441,
-0.26103487610816956,
-0.07251524925231934,
-0.41680118441581726,
-0.5918465256690979,
0.024335792288184166,
-0.4787398874759674,
-0.05239309370517731,
0.4400967061519623,
-0.29802581667900085,
0.0351056829... | |
Is there a tool that can analyse my .NET code (C# and [VB.NET](http://en.wikipedia.org/wiki/Visual_Basic_.NET)) and tell me *why* things are not CLS Compliant?
Visual Studio is happy to tell me a parameter is not CLS compliant, but it doesn't get me any closer to fixing the problem as I don't know the cause.
Example ... | [
0.2174675464630127,
0.04930839315056801,
-0.057635195553302765,
0.09984444081783295,
-0.2810998260974884,
-0.19400283694267273,
0.1111375242471695,
0.07890009135007858,
-0.19210030138492584,
-0.44539228081703186,
0.04306578263640404,
0.628629744052887,
-0.29317376017570496,
-0.089768059551... | |
a fair bit of discussion about this some time ago in the blog post *[FxCop and CLS Compliance](http://weblogs.asp.net/psteele/archive/2003/07/21/10358.aspx)*. | [
0.5107895135879517,
-0.14107489585876465,
0.41716858744621277,
-0.007425774820148945,
-0.15683259069919586,
-0.3430083394050598,
0.04629839211702347,
-0.03155830129981041,
-0.4144214689731598,
-0.12130899727344513,
0.11247795075178146,
0.5329614281654358,
0.03872288390994072,
-0.1064331009... | |
Does anyone know how to generate an XSD using LinqToXml? I can't find any examples of this anywhere. The XSD will be of the following fairly low level of complexity:
```
<?xml version="1.0" encoding="utf-8" ?>
<!--Created with Liquid XML Studio 6.1.18.0 - FREE Community Edition (http://www.liquid-technologies.com)-->
... | [
0.17501536011695862,
0.040256645530462265,
0.661198079586029,
0.21262924373149872,
-0.0812840610742569,
-0.3672259449958801,
-0.10987985879182816,
-0.08546473830938339,
-0.16339710354804993,
-0.6226963400840759,
0.0009671199368312955,
0.34397178888320923,
-0.3179469108581543,
0.24938292801... | |
</xs:simpleType>
</xs:element>
<xs:element name="Email" type="xs:string" />
<xs:element name="Selection">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:length value="15" />
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element... | [
0.037398580461740494,
-0.10228125005960464,
0.20980426669120789,
-0.15705879032611847,
-0.20816835761070251,
0.12307526916265488,
-0.14820100367069244,
-0.3071762025356293,
-0.14482381939888,
-0.3679785430431366,
-0.5060874819755554,
0.25836390256881714,
-0.2698325216770172,
-0.07234163582... | |
along with some related artefacts that are out of scope of the question. The tooling XSD will be generated from CLR objects in the application's object model.
The objects are pretty simple - a root object that contains enough information to construct the namespace along with a collection of other objects representing... | [
0.08480575680732727,
0.22559791803359985,
0.6421613693237305,
0.28359362483024597,
-0.2793881893157959,
-0.10221623629331589,
-0.005815154407173395,
-0.1451873481273651,
-0.20924651622772217,
-0.5323493480682373,
-0.1481502503156662,
0.3034081757068634,
-0.3818982243537903,
0.0745833441615... | |
"qualified"),
new XAttribute("targetNamespace", "http://schemas.xxx.yy/CRM/2009/01/DeadAnimalReport"),
new XElement(nsXS + "element",
new XElement(nsXS + "simpleType",
new XElement(nsXS + "restriction",
new XAttribute("base", "xs:string")),
new XElement(nsXS +... | [
0.1927148848772049,
-0.2049347311258316,
0.5099660754203796,
0.13997703790664673,
-0.10443861037492752,
0.22280025482177734,
0.09355431795120239,
-0.292222261428833,
-0.09307821840047836,
-0.6087613105773926,
-0.5499021410942078,
0.41202107071876526,
-0.3195720613002777,
0.0124154714867472... | |
from s in someObjects
select GetXsdDefinition(s)
);
```
where
GetXsdDefinition is a method that takes your object as an argument and returns it's XSD definition | [
0.0028053109999746084,
-0.26554495096206665,
0.5307600498199463,
-0.03581751510500908,
-0.07130315899848938,
-0.15168778598308563,
0.10572417825460434,
-0.27087482810020447,
-0.19273532927036285,
-0.6808680295944214,
-0.4504172205924988,
0.41291964054107666,
-0.47485074400901794,
0.0790922... | |
I'm using a COM object that has a function called GetImage.
<http://www.pdf-tools.com/asp/products.asp?name=P2IA>
When I use it in Visual Studio 2008 it returns byte[], but when I use it in RAD Studio 2007 it returns System.Object. How can I get the data from the System.Object into a byte[]?
There is no data in an in... | [
-0.0032137450762093067,
-0.03382312133908272,
0.35961973667144775,
-0.07350822538137436,
-0.3211802542209625,
0.35669243335723877,
0.06310887634754181,
-0.34063073992729187,
-0.2715145945549011,
-0.7308235168457031,
0.143221914768219,
0.6050611138343811,
-0.2701403796672821,
-0.00728766527... | |
From a COM library (Microsoft Office Document Imaging aka MODI) I receive an image as an IPictureDisp which I would like to convert to a System.Drawing.Image object.
What would be the best way to do that?
Currently I'm using the code below, which however throws an NotImplementedException.
```
internal sealed class ... | [
0.2261601984500885,
-0.10386451333761215,
0.49489179253578186,
0.21460294723510742,
0.00634668068960309,
-0.008871519938111305,
0.005708585027605295,
-0.24439425766468048,
-0.0576467327773571,
-0.9586834907531738,
-0.22916854918003082,
0.5597466826438904,
-0.41156864166259766,
-0.005910122... | |
/// <param name="image">The image instance</param>
/// <returns>The picture dispatch object.</returns>
public new static object GetIPictureDispFromPicture(Image image)
{
return AxHost.GetIPictureDispFromPicture(image);
}
/// <summary>
/// Convert the dispatch interface into an image obje... | [
0.05905526131391525,
-0.3470061719417572,
0.7276975512504578,
0.13951779901981354,
-0.24081407487392426,
0.5436601638793945,
-0.04713008925318718,
-0.6688560843467712,
-0.5282135605812073,
-0.47108882665634155,
-0.29076725244522095,
0.6035341620445251,
-0.4304227828979492,
-0.1433402001857... | |
AxHost.GetPictureFromIPicture(picture);
}
}
...
// somewhere later the conversion gets called
Image image = IPictureDispHost.GetPictureFromIPicture(picture);
```
This is the exception stack trace:
```
System.NotImplementedException: The method or operation is not implemented.
at System.Windows.Forms.UnsafeN... | [
0.11145040392875671,
-0.05112176015973091,
0.4815469980239868,
0.15484267473220825,
0.123753622174263,
-0.1894691288471222,
0.29265639185905457,
-0.4394851326942444,
-0.196555957198143,
-0.583314061164856,
-0.06967495381832123,
0.6882473230361938,
-0.30491533875465393,
-0.08226677775382996... | |
I want log4net to write log files (using RollingFileAppender) to a subfolder of the common application data folder (e.g. C:\Documents and Settings\All Users\Application Data\Company\Product\Logs).
However, on Win XP, there is no environment variable that specifies this folder. We have `%ALLUSERSPROFILE%`, we have `%... | [
0.30987703800201416,
0.3660179674625397,
0.2614063322544098,
-0.15893429517745972,
0.04801429435610771,
-0.028933769091963768,
0.055340323597192764,
0.08723767101764679,
-0.27358683943748474,
-0.6730791330337524,
-0.18226772546768188,
0.6922975182533264,
-0.23517857491970062,
-0.0522351451... | |
you can define your own path replacement variables. | [
0.417077898979187,
-0.28697413206100464,
-0.2848958373069763,
0.48997390270233154,
-0.050556715577840805,
0.005886147730052471,
-0.14212340116500854,
-0.08570782840251923,
-0.18348409235477448,
-0.5563185811042786,
0.1769734025001526,
0.6176167130470276,
-0.2844563126564026,
-0.18036198616... | |
I'm developing a JavaScript application that needs to run on the Google Android Phone OS. Is there a way to enable the JavaScript Error/Debug console within Safari on either the Android Emulator or an actual device? If so any instructions on how to do so would be appreciated.
A quick Google turns up this [blog post](ht... | [
0.24361594021320343,
0.2374473363161087,
-0.02904392220079899,
0.10336464643478394,
-0.13604310154914856,
0.009261836297810078,
0.4537724256515503,
-0.023924782872200012,
0.0658106729388237,
-0.5208280086517334,
0.1838616132736206,
0.4292425513267517,
-0.2658137381076813,
-0.01693822816014... | |
I sometimes have issues with the incremental rebuild on visual C++ (2003 currently ). Some dependencies does not seem correctly checked and some files aren't build when they should. I suppose thoses issues come from the timestamp approach to incremental rebuild.
I don't consider it a huge issue when building debug bui... | [
0.09071033447980881,
0.3157478868961334,
0.3026077151298523,
-0.16948893666267395,
-0.22612056136131287,
-0.050589416176080704,
0.49302345514297485,
0.023139601573348045,
-0.30006417632102966,
-0.5392388105392456,
0.098360076546669,
1.1066361665725708,
-0.03098984807729721,
0.1690058410167... | |
an incremental build. Also, I would always delete all source from the build machine, and fetch it from scratch from the source control system before building a release. This way, you know you can repeat the build process again by fetching the same source code.
If you use an incremental build, the build will build diff... | [
0.37564408779144287,
0.10509433597326279,
0.2270902693271637,
-0.012384547851979733,
-0.018731871619820595,
0.1773628443479538,
0.3975922167301178,
-0.029197538271546364,
-0.18600745499134064,
-0.5824432373046875,
0.041247423738241196,
0.8631114363670349,
-0.18210995197296143,
0.2319301217... | |
mark the versions of each source file in the source control system with the version number of the build. This enables you to keep track of the exact source that went into building the release. With a decent source code control system the labels can be used to track down all the changes that were made to the code betwee... | [
0.6547828316688538,
0.13918346166610718,
0.09725857526063919,
0.21126236021518707,
-0.179301917552948,
-0.10650855302810669,
0.3415265679359436,
0.16716314852237701,
-0.4933873414993286,
-0.6403709650039673,
0.0027327167335897684,
0.7235509157180786,
0.030031761154532433,
0.128197401762008... | |
the build, just for saving time during the code/debug/test/repeat development cycle. | [
0.30466428399086,
0.09828712791204453,
0.06461978703737259,
0.15276655554771423,
-0.0025993443559855223,
0.3007146418094635,
0.29107144474983215,
-0.03743916377425194,
0.06602276116609573,
-0.40756240487098694,
-0.2765803635120392,
0.6916455626487732,
0.2404841184616089,
-0.179115742444992... | |
I want to write a custom class in which whenevr I add a node to treeview it should call an event. so that I can run it recursively.
* [Here's a page](http://web.archive.org/web/20110721191046/http://particletree.com/features/rediscovering-the-button-element/) describing the differences (basically you can put html into ... | [
0.15714587271213531,
-0.3596056401729584,
0.27938318252563477,
-0.08256401866674423,
-0.10255107283592224,
-0.006524157244712114,
0.3735566735267639,
-0.16472077369689941,
-0.33331021666526794,
-0.8331627249717712,
0.2236967235803604,
0.21101757884025574,
-0.2657848000526428,
-0.0964625105... | |
to get things under
> control. | [
0.2530827522277832,
-0.04637681320309639,
-0.13358193635940552,
0.12950842082500458,
-0.204782173037529,
-0.19963595271110535,
0.3406170606613159,
-0.2478097677230835,
0.05831709876656532,
-0.48822516202926636,
-0.14147497713565826,
0.6079493165016174,
-0.5098429918289185,
-0.3776881098747... | |
Now, this might be a very newbie question, but I don't really have experience with multithreaded programming and I haven't fully understood how threads work compared to processes.
When a process on my machine hangs, say it's waiting for some IO that never comes or something similar, I can kill and restart it because o... | [
0.6562744379043579,
-0.21693848073482513,
-0.0536680668592453,
0.2252071052789688,
0.05788228288292885,
0.07153285294771194,
-0.154455304145813,
0.24588291347026825,
-0.516486644744873,
-0.5082689523696899,
0.2925976514816284,
0.41793888807296753,
-0.3296423554420471,
0.2399543672800064,
... | |
supervises the other threads and, for example kill and recreate hanging threads? For example, if I have a threadpool that I don't want to be drained by occasional hangups.
Threads are independent, but there's a difference between a process and a thread, and that is that in the case of processes, the operating system do... | [
0.647086501121521,
-0.05103207007050514,
-0.18067628145217896,
0.33822038769721985,
-0.03330017998814583,
-0.38149213790893555,
-0.06567306816577911,
0.04204832762479782,
-0.6721754670143127,
0.008863965049386024,
0.2465335875749588,
0.502414345741272,
-0.4057081341743469,
0.45797306299209... | |
instance, if you open a file for writing, and start producing data and write it to the file, and this thread now hangs, for whatever reason, killing the thread will leave the file still open, and most likely locked, up until you close the entire program.
So the real answer to your question is: No, you can not kill thr... | [
0.446837842464447,
0.06862705200910568,
-0.2910679876804352,
0.13022536039352417,
0.029328947886824608,
-0.2076985239982605,
0.2761516273021698,
0.03946590796113014,
-0.49112841486930847,
-0.3663809597492218,
0.011729731224477291,
0.4197433292865753,
-0.44539716839790344,
0.312046051025390... | |
I'm looking for websites that showcase screenshots of applications with exceptional UI design. I'm writing an application and am taking my time considering what the UI should look like. My audience is not business but family.
My previous UI-design experience (and comfort) is with Windows Forms so I would typically use... | [
0.6705441474914551,
0.2881384491920471,
0.22571831941604614,
0.10237827152013779,
-0.1183563843369484,
0.07441702485084534,
0.12822431325912476,
0.2480083703994751,
-0.2914489209651947,
-0.8453017473220825,
0.014735919423401356,
0.2931171655654907,
0.16112259030342102,
0.15850694477558136,... | |
also take individual application's that you feel make a great, intuitive design.
For web, check this link:
<http://designingwebinterfaces.com/designing-web-interfaces-12-screen-patterns>
For windows forms, there is no such site (at least to my knowledge). What I do is to mimic the behavior of the applications I like... | [
0.8326612114906311,
-0.0012821779819205403,
0.234449565410614,
0.10119131207466125,
-0.040284205228090286,
-0.0841178297996521,
-0.06349819898605347,
0.11486135423183441,
-0.37675899267196655,
-0.9006668925285339,
0.3593294024467468,
0.9972785711288452,
0.003318610368296504,
-0.01960680447... | |
there. They have some really cool custom controls stuff. | [
0.2647702395915985,
0.2596237063407898,
-0.0009519440936855972,
0.44248560070991516,
0.2723682224750519,
-0.16255946457386017,
0.09149167686700821,
0.604408860206604,
-0.40853479504585266,
-0.11567505449056625,
0.6674389243125916,
0.5391715168952942,
0.08572171628475189,
0.0482948683202266... | |
Im trying to compile a php interface for my linux shared object and i have managed to get it to compile all right using the output from swig, however when i try and load the so it complains of a missing symbol:
```
error: undefined symbol: zend_register_long_constant
```
Now i have had a look at zend and it seems to... | [
0.2072913944721222,
0.2173289954662323,
0.19442415237426758,
-0.00882369838654995,
-0.32594677805900574,
-0.15021638572216034,
0.35446277260780334,
-0.30455470085144043,
-0.02065787836909294,
-0.7770774960517883,
0.30370214581489563,
0.4443293809890747,
-0.35777148604393005,
0.120700933039... | |
/usr/lib/libcurl-gnutls.so.4 (0xb7f0a000)
libboost_date_time-gcc42-1_34_1.so.1.34.1 => /usr/lib/libboost_date_time-gcc42-1_34_1.so.1.34.1 (0xb7efb000)
libboost_thread-gcc42-mt-1_34_1.so.1.34.1 => /usr/lib/libboost_thread-gcc42-mt-1_34_1.so.1.34.1 (0xb7eed000)
libboost_filesystem-gcc42-1_34_1.so.1.34.1 => /u... | [
-0.3172934651374817,
0.24859312176704407,
0.6537327766418457,
0.038494691252708435,
-0.02217714861035347,
-0.12144919484853745,
0.26349231600761414,
-0.2256729006767273,
-0.44682174921035767,
-0.8564141392707825,
-0.47698113322257996,
0.350946843624115,
-0.5649275779724121,
0.4801073968410... | |
libldap_r-2.4.so.2 => /usr/lib/libldap_r-2.4.so.2 (0xb7a41000)
libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0xb79af000)
libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0xb798b000)
libcom_err.so.2 => /lib/libcom_err.so.2 (0xb7987000)
libgssapi_krb5.so.2 => /usr/lib/libgssapi_krb5.so.2 (0xb795c000)
libgnutls... | [
-0.6595261693000793,
0.17084680497646332,
0.5585914254188538,
-0.23671336472034454,
0.025020169094204903,
0.0777139887213707,
0.23766683042049408,
-0.47474807500839233,
-0.30160337686538696,
-0.840832531452179,
-0.5736488103866577,
0.5548080205917358,
-0.4594528079032898,
0.033439602702856... | |
=> /lib/libkeyutils.so.1 (0xb77e1000)
libgpg-error.so.0 => /lib/libgpg-error.so.0 (0xb77dc000)
```
For web, check this link:
<http://designingwebinterfaces.com/designing-web-interfaces-12-screen-patterns>
For windows forms, there is no such site (at least to my knowledge). What I do is to mimic the behavior of ... | [
0.6721869111061096,
0.020097587257623672,
0.2162163406610489,
-0.04190337657928467,
-0.10669991374015808,
0.0646427646279335,
0.2908264398574829,
0.048264410346746445,
-0.31483471393585205,
-1.0737948417663574,
0.2740801274776459,
0.8476468324661255,
-0.2683100700378418,
-0.155052974820137... | |
have some really cool custom controls stuff. | [
0.384551465511322,
0.05127851665019989,
0.188376784324646,
0.5652088522911072,
0.12082920223474503,
-0.3089105784893036,
-0.04439261183142662,
0.34450823068618774,
-0.1310824751853943,
0.013344387523829937,
0.6694377660751343,
0.30542561411857605,
-0.17988570034503937,
-0.1290249526500702,... | |
I've been programming in Java for a while and just got thrown onto a project that's written entirely in C#. I'm trying to come up to speed in C#, and noticed enums used in several places in my new project, but at first glance, C#'s enums seem to be more simplistic than the Java 1.5+ implementation. Can anyone enumerate... | [
0.3778316378593445,
0.23553313314914703,
-0.25600746273994446,
-0.055926259607076645,
-0.3276920020580292,
-0.16929034888744354,
0.25513535737991333,
-0.1082683578133583,
-0.08753450959920883,
-0.6883188486099243,
0.24608923494815826,
0.6566561460494995,
-0.048484932631254196,
-0.106023378... | |
For example, could someone post a C# counterpart to Sun's famous Planet enum example?
```
public enum Planet {
MERCURY (3.303e+23, 2.4397e6),
VENUS (4.869e+24, 6.0518e6),
EARTH (5.976e+24, 6.37814e6),
MARS (6.421e+23, 3.3972e6),
JUPITER (1.9e+27, 7.1492e7),
SATURN (5.688e+26, 6.0268e7),
URANUS ... | [
0.08825584501028061,
0.26415157318115234,
0.45978406071662903,
0.5172150135040283,
-0.24034230411052704,
0.6551240086555481,
-0.0941830724477768,
0.24558499455451965,
-0.46875104308128357,
-0.1943890005350113,
-0.13488638401031494,
0.14986683428287506,
-0.2752845287322998,
0.72701936960220... | |
this.radius = radius;
}
public double mass() { return mass; }
public double radius() { return radius; }
// universal gravitational constant (m3 kg-1 s-2)
public static final double G = 6.67300E-11;
public double surfaceGravity() {
return G * mass / (radius * radius);
}
public double surfaceWe... | [
0.39201563596725464,
0.006698918528854847,
0.6920396089553833,
-0.16504620015621185,
-0.07144244760274887,
0.3717838227748871,
-0.11008843779563904,
-0.1713816225528717,
-0.6242569088935852,
-0.3460869789123535,
-0.15546338260173798,
0.47786757349967957,
-0.3895265460014343,
0.456305593252... | |
double earthRadius = pEarth.radius(); // Just threw it in to show usage
// Argument passed in is earth Weight. Calculate weight on each planet:
double earthWeight = Double.parseDouble(args[0]);
double mass = earthWeight/pEarth.surfaceGravity();
for (Planet p : Planet.values())
System.out.printf... | [
0.3321492671966553,
0.16272154450416565,
0.3855448067188263,
-0.10535410791635513,
-0.07989899814128876,
0.4306117594242096,
-0.04989873245358467,
-0.3541547954082489,
-0.5150686502456665,
-0.31795331835746765,
0.005605714395642281,
0.3525649905204773,
-0.01532800029963255,
0.0146845374256... | |
66.107583
Your weight on VENUS is 158.374842
[etc ...]
```
Enumerations in the CLR are simply named constants. The underlying type must be integral. In Java an enumeration is more like a named instance of a type. That type can be quite complex and - as your example shows - contain multiple fields of various types.
To... | [
0.4520995318889618,
0.1960495561361313,
0.642447829246521,
-0.07122837752103806,
0.1421256810426712,
0.09615073353052139,
-0.27365079522132874,
-0.15732643008232117,
-0.47903087735176086,
-0.08626268059015274,
0.13620740175247192,
0.5432671904563904,
-0.37830692529678345,
-0.01242542173713... | |
{
Planet planetEarth = Planet.MERCURY;
double earthRadius = pEarth.Radius; // Just threw it in to show usage
double earthWeight = double.Parse("123");
double earthMass = earthWeight / pEarth.SurfaceGravity();
foreach (Planet p in Planet.Values) | [
0.333850622177124,
-0.08975084125995636,
0.4492209553718567,
0.2071920484304428,
0.1261233240365982,
0.20226792991161346,
-0.20281982421875,
-0.30948057770729065,
-0.5154918432235718,
-0.22310103476047516,
-0.15119552612304688,
0.3644567131996155,
-0.035134077072143555,
0.10263398289680481... | |
Console.WriteLine($"Your weight on {p} is {p.SurfaceWeight(mass)}");
Console.ReadKey();
}
}
public class Planet
{
public static readonly Planet MERCURY = new Planet("Mercury", 3.303e+23, 2.4397e6);
public static readonly Planet VENUS = new Planet("Venus", 4.869e+24, 6... | [
-0.12210916727781296,
-0.021915020421147346,
0.633590042591095,
0.18130668997764587,
0.4237867295742035,
0.3394547998905182,
-0.27676698565483093,
-0.14867091178894043,
-0.4775569438934326,
-0.6973584890365601,
-0.2979961335659027,
0.5738192796707153,
-0.17189720273017883,
0.19804994761943... | |
new Planet("Earth", 5.976e+24, 6.37814e6);
public static readonly Planet MARS = new Planet("Mars", 6.421e+23, 3.3972e6);
public static readonly Planet JUPITER = new Planet("Jupiter", 1.9e+27, 7.1492e7);
public static readonly Planet SATURN = new Planet("Saturn", 5.688e+26, 6.0268e7);
... | [
-0.3650050759315491,
0.04348486289381981,
0.9063061475753784,
0.454989492893219,
0.01811286062002182,
0.556287944316864,
-0.1388295590877533,
-0.08657623082399368,
-0.68504798412323,
-0.17143093049526215,
-0.5626441836357117,
0.45570436120033264,
-0.2609970271587372,
0.8061816096305847,
... | |
public static readonly Planet PLUTO = new Planet("Pluto", 1.27e+22, 1.137e6);
public static IEnumerable<Planet> Values
{
get
{
yield return MERCURY;
yield return VENUS; | [
0.14547105133533478,
-0.09349137544631958,
0.30544203519821167,
0.13321378827095032,
0.38013866543769836,
0.29812976717948914,
0.10866188257932663,
-0.04881516471505165,
-0.0547390952706337,
-0.31257715821266174,
-0.6120415329933167,
0.6401543617248535,
-0.28197044134140015,
0.257852524518... | |
yield return EARTH;
yield return MARS;
yield return JUPITER;
yield return SATURN;
yield return URANUS;
yield return NEPTUNE; | [
-0.5770002007484436,
0.04552040621638298,
0.42632243037223816,
0.10847444087266922,
0.03170530125498772,
0.8537641167640686,
-0.48918190598487854,
0.5682932734489441,
0.245012104511261,
0.047613829374313354,
-0.7706769704818726,
0.4258546531200409,
0.2634318768978119,
0.5772160887718201,
... | |
yield return PLUTO;
}
}
public string Name { get; private set; }
public double Mass { get; private set; }
public double Radius { get; private set; }
Planet(string name, double mass, double radius) | [
0.2201124131679535,
-0.08270832896232605,
0.11184710264205933,
0.05641862004995346,
0.11766009777784348,
0.4468793570995331,
-0.0664258524775505,
-0.1382623016834259,
-0.23446109890937805,
-0.09149884432554245,
-0.3232983350753784,
0.4387788772583008,
-0.153408482670784,
0.3326437771320343... | |
=>
(Name, Mass, Radius) = (name, mass, radius);
// Wniversal gravitational constant (m3 kg-1 s-2)
public const double G = 6.67300E-11;
public double SurfaceGravity() => G * mass / (radius * radius);
public double SurfaceWeight(double other) => other * SurfaceGra... | [
0.21436811983585358,
-0.10992956906557083,
0.5569508075714111,
0.11651848256587982,
-0.02542187087237835,
0.3041123151779175,
-0.23806232213974,
-0.3315611481666565,
-0.46778208017349243,
-0.3450380861759186,
-0.21217571198940277,
0.4865468144416809,
-0.2715240716934204,
0.2135392278432846... | |
override string ToString() => name;
}
}
``` | [
-0.17883682250976562,
-0.0671197772026062,
0.2120191603899002,
-0.3824547827243805,
0.3578253388404846,
-0.5061416625976562,
0.2738717198371887,
-0.19791828095912933,
0.11290819197893143,
-0.09595419466495514,
-0.3654786944389343,
0.8490939140319824,
-0.5153140425682068,
0.2730743885040283... | |
How can I use RMI with a applet client behind a firewall?
How can I use RMI with a firewalled server and firewalled applet client? (If possible)
I know that the RMI server uses port 1099 (by default, but this is configurable); however after this the communication requires a new socket on a different random port. I al... | [
0.38894784450531006,
0.6337226033210754,
0.2607276141643524,
0.031840890645980835,
-0.0781518965959549,
-0.04920282959938049,
0.7070301175117493,
-0.32992440462112427,
-0.10615181177854538,
-0.6734116077423096,
0.15377412736415863,
0.6505162119865417,
-0.49301981925964355,
0.19423429667949... | |
<http://java.sun.com/javase/6/docs/technotes/guides/rmi/faq.html#firewall> | [
0.4345775544643402,
0.39959895610809326,
0.3717942535877228,
-0.19703565537929535,
-0.050560254603624344,
-0.04072980582714081,
0.4335017800331116,
-0.7137953639030457,
-0.340217649936676,
-0.13004474341869354,
-0.2681782841682434,
0.6858816146850586,
-0.09145395457744598,
-0.2810623645782... | |
I've stumbled across [this great post](http://blog.getpaint.net/2008/12/06/a-fluent-approach-to-c-parameter-validation/) about validating parameters in C#, and now I wonder how to implement something similar in C++. The main thing I like about this stuff is that is does not cost anything until the first validation fail... | [
0.19146762788295746,
0.25046205520629883,
0.46906647086143494,
-0.009291661903262138,
-0.32257744669914246,
-0.040760986506938934,
0.4875388443470001,
-0.1653454303741455,
-0.09621589630842209,
-0.42296233773231506,
0.17567598819732666,
0.6346280574798584,
-0.08677978813648224,
0.228386342... | |
achieve this without temporary objects, until the first validation fails. Though I'd guess that allocating something like a `std::vector` on the stack should be for free (is this actually true? I'd suspect an empty vector does no allocations on the heap, right?)
Other than the fact that C++ does not have extension meth... | [
-0.02717672288417816,
-0.12560050189495087,
0.18920636177062988,
0.007617914117872715,
-0.005437370855361223,
-0.18707388639450073,
0.3864108920097351,
-0.43996360898017883,
-0.31113871932029724,
-0.44735831022262573,
-0.35831084847450256,
0.5455573201179504,
-0.4481922388076782,
-0.165920... | |
errors->push_back(error);
}
public:
Validation() : errors(NULL) {}
~Validation() { delete errors; }
const Validation &operator=(const Validation &rhs)
{
if (errors == NULL && rhs.errors == NULL) return *this;
if (rhs.errors == NULL)
{
delete errors;
... | [
0.054732635617256165,
0.062084831297397614,
0.42019912600517273,
-0.41343921422958374,
0.06324410438537598,
0.40177375078201294,
0.4819302260875702,
-0.4619212746620178,
0.08448881655931473,
-0.295622855424881,
-0.42225325107574463,
0.4887063205242157,
-0.26726314425468445,
0.1080003380775... | |
return *this;
}
vector<string> *temp = new vector<string>(*rhs.errors);
std::swap(temp, errors);
}
void Check()
{
if (errors)
throw exception();
}
template <typename T>
Validation &IsNotNull(T *value)
{ | [
0.3699414134025574,
-0.4126625657081604,
0.1254803091287613,
-0.1279870867729187,
0.008329492062330246,
0.19195930659770966,
0.22257080674171448,
-0.5841419100761414,
-0.07640373706817627,
-0.3825267553329468,
-0.2527649998664856,
0.46096792817115784,
-0.452787846326828,
0.0261655859649181... | |
if (value == NULL) AddError("Cannot be null!");
return *this;
}
template <typename T, typename S>
Validation &IsLessThan(T valueToCheck, S maxValue)
{
if (valueToCheck < maxValue) AddError("Value is too big!");
return *this;
}
// etc..
};
class Validate
{
public:
... | [
0.23798607289791107,
-0.17099127173423767,
0.5649982690811157,
-0.1894426941871643,
0.3003474175930023,
-0.13899266719818115,
0.4899606704711914,
-0.5203782916069031,
-0.1074552908539772,
-0.22260460257530212,
-0.6489882469177246,
0.394418329000473,
-0.2790623903274536,
0.3110136091709137,... | |
im trying to return a string value from a method inside my script tag however it always returns an object and i cant get at the string value.
Here is the code:
i retrieve the object returned from a webservice call;;
```
private function getNameResults(e:ResultEvent):String{
var name:Array = new Array(e.resu... | [
0.1497565060853958,
0.06479139626026154,
0.612075924873352,
-0.3582054078578949,
0.03370007500052452,
0.1605689525604248,
0.5038429498672485,
-0.39420318603515625,
-0.013234291225671768,
-0.6722972393035889,
-0.22281940281391144,
0.728080153465271,
-0.5505259037017822,
0.022850435227155685... | |
getNameResults) i get the object tag
```
private function getInfo(roomName:String):String{
var site:String =userRequest.getRoomZoneInfo(roomName);
return site;
}
```
however the value returned here is [object AsyncToken]
any ideas?
You are setting the result of `getRoomZoneInfo()` to the variable site, but ... | [
0.06089834123849869,
-0.056740667670965195,
0.693498969078064,
0.046021200716495514,
0.1971532106399536,
-0.06876906752586365,
0.14313672482967377,
-0.14316073060035706,
-0.1922464519739151,
-0.7190467715263367,
-0.4264959692955017,
0.4308111369609833,
-0.2613574266433716,
0.27780133485794... | |
back and get the string you are looking for there. Make sense? | [
0.42300236225128174,
-0.00625003594905138,
-0.053637124598026276,
0.1812828779220581,
-0.012855581939220428,
0.058937977999448776,
-0.029736092314124107,
0.23722976446151733,
-0.2486724853515625,
-0.2328770011663437,
-0.2286168932914734,
-0.050807151943445206,
-0.38522258400917053,
0.24931... | |
Given `$displayHeight = "800";`, replace whatever number is at `800` with int value `y_res`.
```
resultString = Regex.Replace(
im_cfg_contents,
@"\$displayHeight[\s]*=[\s]*""(.*)"";",
Convert.ToString(y_res));
```
In Python I'd use re.sub and it would work. In .NET it replaces the whole line, not the m... | [
0.20661576092243195,
-0.04789057374000549,
0.47400423884391785,
-0.1843605786561966,
0.04808003082871437,
-0.04317197576165199,
0.26879221200942993,
-0.4074302911758423,
0.017486494034528732,
-0.48828065395355225,
-0.19937972724437714,
0.7295226454734802,
-0.45538991689682007,
-0.125613272... | |
to be replaced. Then by using a zero-width lookbehind assertion in that group we allow the regular expression to proceed as normal but omit the characters in that group in the match. Similarly, we've placed the last part of the string in a group, and used a zero-width lookahead assertion. [Grouping Constructs on MSDN](... | [
-0.020903069525957108,
0.033296700567007065,
0.30722981691360474,
-0.16722796857357025,
-0.03465426713228226,
-0.09531401842832565,
0.27589350938796997,
-0.538701593875885,
-0.07510136067867279,
-0.47690847516059875,
-0.41840821504592896,
0.6015177965164185,
-0.45803454518318176,
-0.035565... | |
part in a group and the last part in a group. Then in the replace string, we add back in the first and third groups. Not quite as nice as the first approach, but not quite as bad as writing out the $displayHeight part. [Substitutions on MSDN](http://msdn.microsoft.com/en-us/library/ewy2t5e0.aspx "Substitutions on MSDN"... | [
-0.28587183356285095,
-0.2357598841190338,
0.49565011262893677,
-0.0803508460521698,
-0.15047968924045563,
0.23967063426971436,
0.11401131749153137,
-0.4000428318977356,
-0.014782145619392395,
-0.48902568221092224,
-0.33299654722213745,
0.44968321919441223,
-0.4067900478839874,
-0.22590892... | |
I need to load about 60 images, each on a different page, in to PowerPoint.
Does anyone know of an "automated" way to do this. I don't want to go through slide by slide, and have to click "load image" on each one.
If it was a one-time thing, I wouldn't worry about it, but we're summarizing results from some analysi... | [
-0.08089982718229294,
-0.10655978322029114,
0.6479268074035645,
-0.024317767471075058,
-0.4673522710800171,
0.028593147173523903,
-0.21557559072971344,
-0.3294811248779297,
-0.5795888304710388,
-0.43872159719467163,
0.31204575300216675,
0.7248120307922363,
-0.18801166117191315,
-0.26428091... | |
a few Problems in older Versions, because the images are linked, not embedded if you do not choose the right settings.
The site mentioned above also [features a macro](http://www.pptfaq.com/FAQ00352.htm) for doing this. | [
-0.10482963919639587,
-0.02372562140226364,
0.6369935870170593,
0.022190604358911514,
0.2444850504398346,
-0.31504395604133606,
-0.024106182157993317,
0.2640033960342407,
-0.5034022331237793,
-0.7150789499282837,
-0.19308912754058838,
0.3024868965148926,
-0.15318380296230316,
-0.2041931450... | |
A little background:
I'm creating a set of adapters to allow communication with mobile devices over different cellular networks. This will be achieved using a class factory pattern. At least one of the networks requires a service reference to communicate with their devices through a web service.
So far I've got 3 ass... | [
0.4971545934677124,
0.11410828679800034,
0.3673516809940338,
-0.06143615022301674,
0.22196064889431,
0.394467294216156,
0.2712835371494293,
-0.29870036244392395,
-0.2678814232349396,
-0.7605714797973633,
0.015771884471178055,
0.37879958748817444,
-0.2202078104019165,
-0.0393865592777729,
... | |
I don't want to be adding service references and their configuration to the main application assembly [as that's not relevant to the main application], how do I force each assembly's service reference to get its configuration from its own app.config?
If I have the service reference configuration in the main app.config... | [
0.3527776300907135,
0.1888098269701004,
0.6028772592544556,
-0.2528457045555115,
0.24965263903141022,
0.08250956982374191,
0.3276675343513489,
-0.290050745010376,
-0.1609005331993103,
-0.8646368384361267,
-0.2591981291770935,
0.6517853140830994,
-0.48769262433052063,
0.14929181337356567,
... | |
no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element."
In the end, I just removed the service reference and added a web reference [i.e. did it the 2.0 way]. For some reason the web reference will access its own app.config instea... | [
0.3068252503871918,
0.1542525440454483,
0.5150130391120911,
0.16831114888191223,
0.3508140444755554,
-0.1044454276561737,
0.1905156821012497,
-0.10633981227874756,
-0.08095409721136093,
-0.8014476299285889,
-0.036287806928157806,
0.6287873983383179,
-0.4467027485370636,
0.14686332643032074... | |
I have the service name for a windows service in delphi, and I know how to get the handle from that as well. What I need to do is stop a service, and if the stop fails for some reason I need to kill the process associated with the service. The problem is that I have multiple services running from the same executable, s... | [
0.3101103901863098,
0.27856096625328064,
0.21932142972946167,
0.059512633830308914,
0.08002253621816635,
0.013525823131203651,
0.4373953640460968,
0.04772108793258667,
-0.14380350708961487,
-0.431400865316391,
-0.017875662073493004,
0.5646011233329773,
-0.09238225221633911,
0.3581647872924... | |
process from the service name or handle?
Please note I have only accepted this solution so that a full delphi code solution is accepted, all due thanks to Jk though for pointing me on the correct path.
--
Ok, I've been able to figure out how to use the answer by Jk and have come up with this solution in delphi.
For ... | [
0.035347577184438705,
0.007996179163455963,
0.43266087770462036,
-0.011426781304180622,
0.09643113613128662,
0.32866349816322327,
0.267867773771286,
-0.4314524531364441,
-0.15693147480487823,
-0.8240489959716797,
-0.36825528740882874,
0.4857436716556549,
0.0038586624432355165,
0.2423706501... | |
procedure Button1Click(Sender: TObject);
end;
//Record defined for use as return buffer
_SERVICE_STATUS_PROCESS = record
dwServiceType: DWORD;
dwCurrentState: DWORD;
dwControlsAccepted: DWORD;
dwWin32ExitCode: DWORD;
dwServiceSpecificExitCode: DWORD;
dwCheckPoint: DWORD;
dwWaitHint: D... | [
-0.5422112345695496,
-0.3521958887577057,
0.475364089012146,
-0.2347419410943985,
0.22725242376327515,
0.4004841148853302,
0.22452713549137115,
-0.29484885931015015,
-0.3507978618144989,
-0.4810355007648468,
-0.3900030553340912,
0.38476115465164185,
-0.33244192600250244,
0.1602727174758911... | |
String = '') : Cardinal;
var
Form6: TForm6;
implementation
{$R *.dfm}
const
// windows api library
advapi32 = 'advapi32.dll';
//define the api call
function QueryServiceStatusEx; external advapi32 name 'QueryServiceStatusEx';
//for demo usage
procedure TForm6.Button1Click(Sender: TObject);
begin
Memo1.... | [
-0.3327997624874115,
-0.21088232100009918,
0.6149692535400391,
-0.18911278247833252,
0.217915341258049,
0.41037818789482117,
0.4230760931968689,
-0.23175962269306183,
-0.16474908590316772,
-0.6882498264312744,
-0.5884138941764832,
0.5098235607147217,
-0.29191023111343384,
0.428884655237197... | |
buffer size to the size of the record
cbBufSize := sizeof(_SERVICE_STATUS_PROCESS);
if (schm>0) then
begin
//grab the service handle
schs := OpenService(schm, PChar(sService), SERVICE_QUERY_STATUS);
if (schs>0) then
begin
//call the function
QueryServiceStatusEx(
schs,
SC_S... | [
-0.12998588383197784,
0.08215216547250748,
0.8302128911018372,
-0.42034417390823364,
0.27126023173332214,
0.07935606688261032,
0.05748201161623001,
-0.19003093242645264,
-0.3752743601799011,
-0.506494402885437,
-0.4413575530052185,
0.1059148907661438,
-0.45705312490463257,
0.40331339836120... | |
CloseServiceHandle(schm);
end;
Result := lpBuffer.dwProcessId;
end;
end.
```
Please note that not all external naming and other necessities are included. | [
-0.197279691696167,
0.4019271433353424,
0.8546675443649292,
-0.3106801211833954,
0.29429927468299866,
-0.31611037254333496,
-0.004764264449477196,
-0.07429411262273788,
-0.3493848145008087,
-0.3853634297847748,
-0.5410313010215759,
0.29869166016578674,
-0.18573036789894104,
0.3464592397212... | |
(Let me give you some context)
I am currently designing an application that is supposed to generate a printable A4 page based on some data.
Naturally, the device independent pixels of WPF (96 pixels/inch) are not a very natural unit of measurement in the paper world. Something like millimetres would be more appropriate... | [
0.2659296691417694,
-0.0015225757379084826,
0.8831947445869446,
0.028914447873830795,
-0.3998383581638336,
0.5822485685348511,
0.28687286376953125,
-0.12590450048446655,
-0.4977383315563202,
-0.7169362902641296,
0.24428263306617737,
0.044575292617082596,
0.20577554404735565,
0.026829393580... | |
intended. I would like 12pt Arial to render like 12pt Arial would render normally.
Is there any other way to **change the coordinate system without having to call into extensions** or whatever to convert each and every coordinate, length, thickness and so on?
- or -
Is there any way to **map font sizes on-the-fly**, b... | [
0.836148738861084,
-0.3092682957649231,
0.4729751944541931,
0.5222038626670837,
-0.2763099670410156,
0.20515896379947662,
-0.20656977593898773,
-0.32533782720565796,
-0.029319511726498604,
-0.6729262471199036,
0.021149596199393272,
0.2752811312675476,
0.30543577671051025,
-0.15006387233734... | |
nature of WPF device independence allows you to to the following:
```
<Window x:Class="WpfApplication1.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Window1" Height="29.7cm" Width="21cm" FontSize="16pt">
<Grid>
... | [
-0.15329568088054657,
-0.31805625557899475,
0.8687841296195984,
-0.15346843004226685,
0.09952881187200546,
-0.11800479143857956,
-0.1845773607492447,
-0.6628782153129578,
-0.41096261143684387,
-0.16395600140094757,
-0.28113090991973877,
0.43298089504241943,
0.05318896472454071,
-0.30600833... | |
scale properly by whatever transform you might apply additionally, if need be (e.g. via a zoom slider for the users view port), respecting their relative sizes regardless of being specified with different units each (i.e. mixed usage at will).
Available units are `px` (default), `in`, `cm` and `pt`, see for example [F... | [
0.3820207417011261,
-0.19287730753421783,
0.8303759694099426,
0.06360335648059845,
-0.051938191056251526,
0.45584672689437866,
0.05197912082076073,
-0.4068029820919037,
-0.43088382482528687,
-0.6316549777984619,
-0.2967832386493683,
0.1215691864490509,
0.42544135451316833,
-0.0494287200272... | |
The following code generates warning C4250. My question is, what's the best solution to it?
```
class A
{
virtual void func1();
}
class B : public A
{
}
class C : public A
{
virtual void func1();
}
class D : public B, public C
{
}
int main()
{
D d;
d.func1(); // Causes warning
}
```
According to what I'v... | [
0.04790373146533966,
0.18095216155052185,
0.062416139990091324,
-0.005008555483072996,
0.11588457971811295,
-0.24337074160575867,
0.467888742685318,
0.036860644817352295,
-0.3462326228618622,
-0.448927104473114,
-0.003712762612849474,
0.3992365598678589,
-0.45467743277549744,
0.33911362290... | |
for the following code:
```
class Interface
{
public:
virtual void A() = 0;
};
class Implementation : public virtual Interface
{
public:
virtual void A() {};
};
class ExtendedInterface : public virtual Interface
{
virtual void B() = 0;
};
class ExtendedImplementation : public ExtendedInterface , public ... | [
0.17461833357810974,
-0.24667827785015106,
0.45103785395622253,
-0.22102230787277222,
-0.14452217519283295,
0.17219728231430054,
0.202870175242424,
0.07953333854675293,
-0.4037715196609497,
-0.5363901257514954,
0.10728862881660461,
0.6978791952133179,
-0.6228497624397278,
0.120287239551544... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.