qid int64 4 19.1M | question stringlengths 18 48.3k | answers list | date stringlengths 10 10 | metadata list |
|---|---|---|---|---|
310,518 | <p>I'm digging into Reflection for the first time and I'm truely stuck. I've googled everything I can think of. I'm 90% where I wanna be now.</p>
<p>I'm trying to return the value of a Property in a custom class through Reflection.</p>
<p>Here's my class declaration:</p>
<pre><code>Public Class Class2
Private ne... | [
{
"answer_id": 310639,
"author": "tvanfosson",
"author_id": 12950,
"author_profile": "https://Stackoverflow.com/users/12950",
"pm_score": 5,
"selected": true,
"text": "Me ObjectCompare PropertyInfo Class2 PropertyInfo Public Sub CompareObjects(ByVal It as Object)\n Dim property_value ... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310518",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/38595/"
] |
310,540 | <p>Are there any good references for best practices for storing postal addresses in an RDBMS? It seems there are lots of tradeoffs that can be made and lots of pros and cons to each to be evaluated -- surely this has been done time and time again? Maybe someone has at least written done some lessons learned somewhere... | [
{
"answer_id": 310605,
"author": "Ken Gentle",
"author_id": 8709,
"author_profile": "https://Stackoverflow.com/users/8709",
"pm_score": 3,
"selected": false,
"text": "postal-code"
},
{
"answer_id": 14954313,
"author": "GWed",
"author_id": 1085343,
"author_profile": "h... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310540",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2168/"
] |
310,548 | <p>I have a thread that, when its function exits its loop (the exit is triggered by an event), it does some cleanup and then sets a different event to let a master thread know that it is done.</p>
<p>However, under some circumstances, SetEvent() seems not to return after it sets the thread's 'I'm done' event.</p>
<p>... | [
{
"answer_id": 310585,
"author": "MSN",
"author_id": 6210,
"author_profile": "https://Stackoverflow.com/users/6210",
"pm_score": 2,
"selected": false,
"text": "HANDLE * SetEvent"
},
{
"answer_id": 310860,
"author": "titanae",
"author_id": 2387,
"author_profile": "http... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310548",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/35305/"
] |
310,551 | <p>Omnicompletion is working, but it automatically inserts the first result.</p>
<p>What I'd like to do is open the omnicomplete menu, then be able to type to narrow down the results, then hit enter or tab or space or something to insert the selected menu item.</p>
<p>Is this possible?</p>
| [
{
"answer_id": 310567,
"author": "Ali Afshar",
"author_id": 28380,
"author_profile": "https://Stackoverflow.com/users/28380",
"pm_score": 0,
"selected": false,
"text": ":he compl-current\n compl<C-X><C-P><BS>letion\n"
},
{
"answer_id": 311607,
"author": "orestis",
"author... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310551",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1367022/"
] |
310,557 | <p>I am trying to declare and use a class B inside of a class A
and define B outside A.<br>
I know for a fact that this is possible because Bjarne Stroustrup<br>
uses this in his book "The C++ programming language"<br>
(page 293,for example the String and Srep classes).</p>
<p>So this is my minimal piece of code that ... | [
{
"answer_id": 310562,
"author": "CB Bailey",
"author_id": 19563,
"author_profile": "https://Stackoverflow.com/users/19563",
"pm_score": 4,
"selected": false,
"text": "c->i struct A::B A struct A::B"
},
{
"answer_id": 310578,
"author": "e.James",
"author_id": 33686,
"... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310557",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/34051/"
] |
310,558 | <p>I have a RVDS project for a certain video decoder (its all C code),
created for ARM926EJ-S target, executed using the RVDS 2.2 simulator.
I am not using any scatterload / <configuration file> / <map file> to
mention the various memory segments in the code like Stack segment,
Heap, Data segment, Code Segment fo... | [
{
"answer_id": 310562,
"author": "CB Bailey",
"author_id": 19563,
"author_profile": "https://Stackoverflow.com/users/19563",
"pm_score": 4,
"selected": false,
"text": "c->i struct A::B A struct A::B"
},
{
"answer_id": 310578,
"author": "e.James",
"author_id": 33686,
"... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310558",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2759376/"
] |
310,561 | <p>I'm looking at the MySQL docs <a href="http://dev.mysql.com/doc/refman/5.0/en/innodb-foreign-key-constraints.html" rel="noreferrer">here</a> and trying to sort out the distinction between FOREIGN KEYs and CONSTRAINTs. I thought an FK <strong>was</strong> a constraint, but the docs seem to talk about them like they'r... | [
{
"answer_id": 310586,
"author": "Bill Karwin",
"author_id": 20860,
"author_profile": "https://Stackoverflow.com/users/20860",
"pm_score": 7,
"selected": true,
"text": "PRIMARY KEY FOREIGN KEY CHECK UNIQUE NOT NULL DEFERRABLE CONSTRAINT CONSTRAINT"
},
{
"answer_id": 34298305,
... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310561",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,572 | <p>Here's the goal: to replace all standalone ampersands with &amp; but NOT replace those that are already part of an HTML entity such as &nbsp;.</p>
<p>I think I need a regular expression for PHP (preferably for preg_ functions) that will match only standalone ampersands. I just don't know how to do that with... | [
{
"answer_id": 310577,
"author": "Ross",
"author_id": 2025,
"author_profile": "https://Stackoverflow.com/users/2025",
"pm_score": 4,
"selected": true,
"text": "html_entity_decode htmlentities"
},
{
"answer_id": 310632,
"author": "Doug Kaye",
"author_id": 17307,
"autho... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310572",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17307/"
] |
310,576 | <p>What win32 calls can be used to detect key press events globally (not just for 1 window, I'd like to get a message EVERY time a key is pressed), from a windows service?</p>
| [
{
"answer_id": 310602,
"author": "Brian R. Bondy",
"author_id": 3153,
"author_profile": "https://Stackoverflow.com/users/3153",
"pm_score": 4,
"selected": true,
"text": "LRESULT CALLBACK KeyboardProc( \n int code,\n WPARAM wParam,\n LPARAM lParam\n);\n"
},
{
"answer... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310576",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3886/"
] |
310,580 | <p>Is it possible to create a final route that catches all .. and bounces the user to a 404 view in ASP.NET MVC?</p>
<p>NOTE: I don't want to set this up in my IIS settings.</p>
| [
{
"answer_id": 310636,
"author": "Pure.Krome",
"author_id": 30674,
"author_profile": "https://Stackoverflow.com/users/30674",
"pm_score": 7,
"selected": true,
"text": "routes.MapRoute(\n \"404-PageNotFound\",\n \"{*url}\",\n new { controller = \"StaticContent\", action = \"PageN... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310580",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/30674/"
] |
310,583 | <p>I'm sure there are different approaches to this problem, and I can think of some. But I'd like to hear other people's opinion on this. To be more specific I've built a widget that allows users to choose their location from a google maps map. This widget is displayed on demand and will probably be used every 1 out of... | [
{
"answer_id": 310588,
"author": "miceuz",
"author_id": 24443,
"author_profile": "https://Stackoverflow.com/users/24443",
"pm_score": -1,
"selected": false,
"text": "<script src=\"...\">"
},
{
"answer_id": 310590,
"author": "FlySwat",
"author_id": 1965,
"author_profil... | 2008/11/21 | [
"https://Stackoverflow.com/questions/310583",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7883/"
] |
310,589 | <p>In our MOSS '07 site we have a page that contains just a Page Viewer web part in it that points to a site on another server. However, I've noticed that on that page (and any others that have a Page Viewer web part on it) our drop down menus and hover effects are <strong>super slow</strong> and completely max out th... | [
{
"answer_id": 310588,
"author": "miceuz",
"author_id": 24443,
"author_profile": "https://Stackoverflow.com/users/24443",
"pm_score": -1,
"selected": false,
"text": "<script src=\"...\">"
},
{
"answer_id": 310590,
"author": "FlySwat",
"author_id": 1965,
"author_profil... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310589",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/30866/"
] |
310,595 | <p>I need to test if a file is a shortcut. I'm still trying to figure out how stuff will be set up, but I might only have it's path, I might only have the actual contents of the file (as a byte[]) or I might have both.</p>
<p>A few complications include that I it could be in a zip file (in this cases the path will be ... | [
{
"answer_id": 310625,
"author": "Mitch Wheat",
"author_id": 16076,
"author_profile": "https://Stackoverflow.com/users/16076",
"pm_score": 5,
"selected": true,
"text": "/// <summary>\n/// Returns whether the given path/file is a link\n/// </summary>\n/// <param name=\"shortcutFilename\">... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310595",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1343/"
] |
310,599 | <p>It's simple enough to code up a class to store/validate something like <code>192.168.0.0/16</code>, but I was curious if a native type for this already existed in .NET? I would imagine it would work a lot like <code>IPAddress</code>:</p>
<pre><code>CIDR subnet = CIDR.Parse("192.168.0.0/16");
</code></pre>
<p>Basi... | [
{
"answer_id": 2239906,
"author": "Koen Zomers",
"author_id": 1271303,
"author_profile": "https://Stackoverflow.com/users/1271303",
"pm_score": 5,
"selected": false,
"text": "IPNetwork ipnetwork = IPNetwork.Parse(\"192.168.168.100/24\");\n\nConsole.WriteLine(\"Network : {0}\", ipnetwork.... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310599",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9642/"
] |
310,629 | <p>I need to write some methods for loading/saving some classes to and from a binary file. However I also want to be able to accept the binary data from other places, such as a binary string.</p>
<p>In c++ I could do this by simply making my class methods use std::istream and std::ostream which could be a file, a stri... | [
{
"answer_id": 310635,
"author": "Ned Batchelder",
"author_id": 14343,
"author_profile": "https://Stackoverflow.com/users/14343",
"pm_score": 4,
"selected": true,
"text": "from cStringIO import StringIO\n\ns = \"My very long string I want to read like a file\"\nfile_like_string = StringI... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310629",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6266/"
] |
310,634 | <p>PHP, for all its warts, is pretty good on this count. There's no difference between an array and a hash (maybe I'm naive, but this seems obviously right to me), and to iterate through either you just do</p>
<pre><code>foreach (array/hash as $key => $value)
</code></pre>
<p>In Ruby there are a bunch of ways to d... | [
{
"answer_id": 310638,
"author": "Robert Gamble",
"author_id": 25222,
"author_profile": "https://Stackoverflow.com/users/25222",
"pm_score": 10,
"selected": true,
"text": "array = [1, 2, 3, 4, 5, 6]\narray.each { |x| puts x }\n\n# Output:\n\n1\n2\n3\n4\n5\n6\n array = [\"A\", \"B\", \"C\... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310634",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/25068/"
] |
310,642 | <p>I'm creating a list of the Slices in my Merb app, like this:</p>
<blockquote>
<p>Merb::Slices.each_slice do |slice|</p>
</blockquote>
<p>I'd like to get the list of dependencies for each of this slice, any idea how to access it?</p>
<p>I'm still reading merb code, solution might come soon ;)</p>
| [
{
"answer_id": 310671,
"author": "dylanfm",
"author_id": 38795,
"author_profile": "https://Stackoverflow.com/users/38795",
"pm_score": 0,
"selected": false,
"text": "/config/dependencies.rb merb -i >> Merb.methods.sort\n=> [\"<\", \"<=\", \"<=>\", \"==\", \"===\", \"=~\", \">\", \">=\", ... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310642",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16974/"
] |
310,650 | <p>I'm retrieving a gzipped web page via curl, but when I output the retrieved content to the browser I just get the raw gzipped data. How can I decode the data in PHP?</p>
<p>One method I found was to write the content to a tmp file and then ...</p>
<pre><code>$f = gzopen($filename,"r");
$content = gzread($filename,... | [
{
"answer_id": 2849331,
"author": "Jonas Lejon",
"author_id": 117283,
"author_profile": "https://Stackoverflow.com/users/117283",
"pm_score": 8,
"selected": true,
"text": "curl_setopt($ch, CURLOPT_ENCODING , \"gzip\");\n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/310650",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39539/"
] |
310,652 | <p>I am using the functions strpos(string, string) in javascript. In Firefox, Opera and IE the page loads fine, but in Chrome I get the error: Uncaught ReferenceError: strpos is not defined. The page I am working on is <a href="http://seniorproject.korykirk.com/0xpi2.php" rel="nofollow noreferrer">http://seniorproject.... | [
{
"answer_id": 310665,
"author": "Artelius",
"author_id": 31945,
"author_profile": "https://Stackoverflow.com/users/31945",
"pm_score": 4,
"selected": false,
"text": "haystack.indexOf(needle)"
},
{
"answer_id": 3839607,
"author": "TRiG",
"author_id": 209139,
"author_p... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310652",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,664 | <p>I'm having some trouble with ASP.NET MVC Beta, and the idea of making routes, controller actions, parameters on those controller actions and Html.ActionLinks all work together. I have an application that I'm working on where I have a model object called a Plot, and a corresponding PlotController. When a user creates... | [
{
"answer_id": 310709,
"author": "Timothy Khouri",
"author_id": 11917,
"author_profile": "https://Stackoverflow.com/users/11917",
"pm_score": 2,
"selected": true,
"text": "<%= Html.ActionLink(\"Click Here\", \"ViewDetails\", \"Plot\", new { name=\"my-plot-name\" }, null)%>\n"
},
{
... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310664",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18831/"
] |
310,669 | <p>Does anyone have any idea why the following code sample fails with an XmlException "Data at the root level is invalid. Line 1, position 1."</p>
<pre><code>var body = "<?xml version="1.0" encoding="utf-16"?><Report> ......"
XmlDocument bodyDoc = new XmlDocument();
bodyDoc.LoadXml(body);
</cod... | [
{
"answer_id": 310708,
"author": "Community",
"author_id": -1,
"author_profile": "https://Stackoverflow.com/users/-1",
"pm_score": 3,
"selected": false,
"text": "MemoryStream stream = new MemoryStream();\n byte[] data = body.PayloadEncoding.GetBytes(body.Payload);\n ... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310669",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,685 | <p>Can someone explain the main benefits of different types of references in C#?</p>
<ul>
<li>Weak references</li>
<li>Soft references</li>
<li>Phantom references</li>
<li>Strong references.</li>
</ul>
<p>We have an application that is consuming a lot of memory and we are trying to determine if this is an area to foc... | [
{
"answer_id": 21441743,
"author": "Artur A",
"author_id": 304371,
"author_profile": "https://Stackoverflow.com/users/304371",
"pm_score": 3,
"selected": false,
"text": "class BitmapWorkerTask extends AsyncTask<Integer, Void, Bitmap> {\n private final WeakReference<ImageView> imageVie... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310685",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4653/"
] |
310,691 | <p>can anyone provide/refer a proper OO type helper class for managing a singleton of the SessionFactory and then also for managing Sessions?</p>
| [
{
"answer_id": 310824,
"author": "George Stocker",
"author_id": 16587,
"author_profile": "https://Stackoverflow.com/users/16587",
"pm_score": 2,
"selected": false,
"text": "public class BaseDataAccess\n{\n\n protected ISession m_session;\n\n public BaseDataAccess()\n {\n m_session ... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310691",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/38574/"
] |
310,699 | <p>I'm using Emma in my ant build to perform coverage reporting. For those that have used Emma, is there a way to get the build to fail if the line coverage (or any type of coverage stat) does not meet a particular threshold? e.g. if the line coverage is not 100%</p>
| [
{
"answer_id": 310710,
"author": "Ken Gentle",
"author_id": 8709,
"author_profile": "https://Stackoverflow.com/users/8709",
"pm_score": 2,
"selected": true,
"text": "report.metrics <report></report> name, class, method, block line"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/310699",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/30563/"
] |
310,700 | <p>Does anyone know what this means. Getting this in C# winforms applications:</p>
<blockquote>
<p>Not a legal OleAut date</p>
</blockquote>
| [
{
"answer_id": 362910,
"author": "lc.",
"author_id": 44853,
"author_profile": "https://Stackoverflow.com/users/44853",
"pm_score": 0,
"selected": false,
"text": "try\n{\n if (folderItem.ModifyDate.Year != 1899)\n {\n this.FileModifiedDate = folderItem.ModifyDate.ToShortDateS... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310700",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4653/"
] |
310,714 | <p>On the PHP website, the only real checking they suggest is using <code>is_uploaded_file()</code> or <code>move_uploaded_file()</code>, <a href="http://ca.php.net/manual/en/features.file-upload.php" rel="noreferrer">here</a>. Of course you usually don't want user's uploading any type of file, for a variety of reasons... | [
{
"answer_id": 310740,
"author": "davr",
"author_id": 14569,
"author_profile": "https://Stackoverflow.com/users/14569",
"pm_score": 6,
"selected": true,
"text": "system(\"file -bi $uploadedfile\")"
},
{
"answer_id": 370679,
"author": "Sudden Def",
"author_id": 28121,
... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310714",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5441/"
] |
310,720 | <p>I am using Maven (and the Maven Eclipse Integration) to manage the dependencies for my Java projects in Eclipse. The automatic download feature for JAR files from the Maven repositories is a real time saver. Unfortunately, it does not include API documentation and source code.</p>
<p>How can I set up Maven to autom... | [
{
"answer_id": 311229,
"author": "Stephen Denne",
"author_id": 11721,
"author_profile": "https://Stackoverflow.com/users/11721",
"pm_score": 7,
"selected": false,
"text": "mvn eclipse:eclipse -DdownloadSources=true\n mvn eclipse:eclipse -DdownloadJavadocs=true\n =true mvn eclipse:eclipse... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310720",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14955/"
] |
310,729 | <p>For loading time considerations I am using a runtime css file in my Flex Application.</p>
<p>I am having a problem with a multi line text control :</p>
<pre><code><mx:Text id="txtDescription" selectable="false"
styleName="imageRolloverButtonTextDark" width="100%" textAlign="center"
text="{_rolloverText}"/>
<... | [
{
"answer_id": 1112649,
"author": "verveguy",
"author_id": 66753,
"author_profile": "https://Stackoverflow.com/users/66753",
"pm_score": 2,
"selected": false,
"text": "<mx:Canvas id=\"box\" width=\"100%\" backgroundColor=\"Red\">\n <mx:Text width=\"{box.width}\" text=\"{someReallyLong... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310729",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16940/"
] |
310,732 | <p>Given a class:</p>
<pre><code>from django.db import models
class Person(models.Model):
name = models.CharField(max_length=20)
</code></pre>
<p>Is it possible, and if so how, to have a QuerySet that filters based on dynamic arguments? For example:</p>
<pre><code> # Instead of:
Person.objects.filter(name__st... | [
{
"answer_id": 310775,
"author": "S.Lott",
"author_id": 10661,
"author_profile": "https://Stackoverflow.com/users/10661",
"pm_score": -1,
"selected": false,
"text": "'name' 'startswith' filter_by = '%s__%s' % ('name', 'startswith')\n"
},
{
"answer_id": 310785,
"author": "Dan... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310732",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19212/"
] |
310,749 | <p>I'm having a problem with the WPF Tab View control that I was hoping someone here might be able to help me with.</p>
<p>I want my tab view control to use rounded corners for the tab headers, because I think rounded tabs look better.</p>
<p>To do this I modified the default control template for the tab by using the... | [
{
"answer_id": 317965,
"author": "Micah",
"author_id": 17744,
"author_profile": "https://Stackoverflow.com/users/17744",
"pm_score": 2,
"selected": true,
"text": "Color=\"{DynamicResource {x:Static SystemColors.XXXX}\"\n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/310749",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1737192/"
] |
310,753 | <p>Mac OS X stores some files with resource forks. I need to create a file with a resource fork. The trouble is, I need to create this file on the command line. Is anyone aware of how you can create a file with a resource fork on the command line in Mac OS X?</p>
| [
{
"answer_id": 310774,
"author": "Jason Coco",
"author_id": 34218,
"author_profile": "https://Stackoverflow.com/users/34218",
"pm_score": 3,
"selected": false,
"text": "man Rez\n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/310753",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,770 | <p>This one is a bit tedious in as far as explaining, so here goes. I'm essentially populating a tableView on the iPhone with multiple sections, and potentially multiple rows per section. To my understanding, it's best to have an array of arrays so that you can simply determine how many sections one has by sending a me... | [
{
"answer_id": 310969,
"author": "e.James",
"author_id": 33686,
"author_profile": "https://Stackoverflow.com/users/33686",
"pm_score": 4,
"selected": true,
"text": "NSArray * arrayOfRecords = [NSArray arrayWithObjects:\n\n [NSDictionary dictionaryWithObjectsAndKeys:\n @\"bob\", @\... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310770",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,786 | <p>Does anyone know how to change the color of a row (or row background) in the UIPickerView control from the iPhone SDK? Similiar to the below title for row, however I would also like to change the color of the row:</p>
<pre><code>- (NSString *)pickerView:(UIPickerView *)pickerView titleForRow:(NSInteger)row forCompo... | [
{
"answer_id": 310863,
"author": "Sean",
"author_id": 29941,
"author_profile": "https://Stackoverflow.com/users/29941",
"pm_score": 4,
"selected": false,
"text": "- (UIView *)pickerView:(UIPickerView *)pickerView viewForRow:(NSInteger)row forComponent:(NSInteger)component reusingView:(UI... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310786",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/29941/"
] |
310,787 | <p>I have an array (<code>arr</code>) of elements, and a function (<code>f</code>) that takes 2 elements and returns a number.</p>
<p>I need a permutation of the array, such that <code>f(arr[i], arr[i+1])</code> is as little as possible for each <code>i</code> in <code>arr</code>. (and it should loop, ie. it should al... | [
{
"answer_id": 310811,
"author": "Purfideas",
"author_id": 4615,
"author_profile": "https://Stackoverflow.com/users/4615",
"pm_score": 0,
"selected": false,
"text": "g_i(p) = f(a^p[i], a^p[i+1]), and wrap around when i+1 > n\n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/310787",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1815/"
] |
310,801 | <p>When using a subdomain and trying to view anything related to current_user. user is sent to a new session page, the page shows the session is created and gives the option to logout. I can use no subdomain and it works fine.</p>
| [
{
"answer_id": 310830,
"author": "Kevin H",
"author_id": 20116,
"author_profile": "https://Stackoverflow.com/users/20116",
"pm_score": 1,
"selected": false,
"text": "ActionController::CgiRequest::DEFAULT_SESSION_OPTIONS.update( :session_domain => '.domain.com')\n"
},
{
"answer_id... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310801",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,805 | <p>I've been knocking my head against this for some time now. I'm not really sure why it isn't working. I'm still pretty new to this whole WPF business. </p>
<p>Here's my XAML for the combobox</p>
<pre><code><ComboBox
SelectedValuePath="Type.FullName"
SelectedItem="{Binding Path=Type}"
Name="cmoBox" /... | [
{
"answer_id": 310812,
"author": "Timothy Khouri",
"author_id": 11917,
"author_profile": "https://Stackoverflow.com/users/11917",
"pm_score": 5,
"selected": true,
"text": "ItemsSource=\"{Binding}\" DataContext myAssembly.PossibleTypes"
},
{
"answer_id": 1866317,
"author": "Ta... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310805",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13688/"
] |
310,820 | <p>I want to do this in Actionscript:</p>
<pre><code>typeof(control1) != typeof(control2)
</code></pre>
<p>to test if two objects are of the same type. This would work just fine in C#, but in Actionscript it doesnt. In fact it returns <code>'object'</code> for both <code>typeof()</code> expressions because thats the ... | [
{
"answer_id": 310879,
"author": "enobrev",
"author_id": 14651,
"author_profile": "https://Stackoverflow.com/users/14651",
"pm_score": 2,
"selected": false,
"text": " dynamic class A {}\n trace(A.prototype.constructor); // [class A]\n trace(A.prototype.constructor == A); // true\n... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310820",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16940/"
] |
310,826 | <p>I am building a small device with its own CPU (AVR Mega8) that is supposed to connect to a PC. Assuming that the physical connection and passing of bytes has been accomplished, what would be the best protocol to use on top of those bytes? The computer needs to be able to set certain voltages on the device, and read ... | [
{
"answer_id": 310848,
"author": "Adam Liss",
"author_id": 29157,
"author_profile": "https://Stackoverflow.com/users/29157",
"pm_score": 3,
"selected": false,
"text": "Host --> [V02?] // Request voltage #2\nAVR --> [V02=2.34] // Reply with voltage #2\nHost --> [V06=3.12] // Se... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310826",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,833 | <p>In my views.py, i have a snippit of code like this:</p>
<pre><code>def clean_post_data(form):
for i in form.cleaned_data:
form.cleaned_data[i] = form.cleaned_data[i].rstrip()
def add_product(request):
form = ProductForm(request.POST, request.FILES or None)
image = Image.objects.all()
act... | [
{
"answer_id": 311304,
"author": "S.Lott",
"author_id": 10661,
"author_profile": "https://Stackoverflow.com/users/10661",
"pm_score": 2,
"selected": true,
"text": "clean_post_data clean"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/310833",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2592/"
] |
310,870 | <p>What's the difference between</p>
<pre><code>var A = function () {
this.x = function () {
//do something
};
};
</code></pre>
<p>and</p>
<pre><code>var A = function () { };
A.prototype.x = function () {
//do something
};
</code></pre>
| [
{
"answer_id": 310895,
"author": "Matthew Crumley",
"author_id": 2214,
"author_profile": "https://Stackoverflow.com/users/2214",
"pm_score": 6,
"selected": false,
"text": "var A = function () {\n var private_var = ...;\n\n this.x = function () {\n return private_var;\n };... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310870",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39864/"
] |
310,888 | <p>Today I ran XtUnit at a part of my unit testing framework to to rollback database changes created while running a test case. This is a skeleton of how I have used it. The Test case ran successfully but the database state changed as a result. </p>
<pre><code>using NUnit.Framework;
using TeamAgile.ApplicationBlocks.... | [
{
"answer_id": 354237,
"author": "Tom Lianza",
"author_id": 26624,
"author_profile": "https://Stackoverflow.com/users/26624",
"pm_score": 3,
"selected": true,
"text": "ExtensibleFixture InterceptableObject ExtensibleFixture InterceptableObject"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/310888",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/22039/"
] |
310,889 | <p>I am taking my first foray into PHP programming and need to configure the environment for the first time. Can I use PHP with the built in VS web server or do I need to (and I hope not) use IIS locally?</p>
<p>In addition, any pointers on pitfalls to be avoided would be great.</p>
<p>Many thanks.</p>
<p><b>Update:... | [
{
"answer_id": 311491,
"author": "Dan Herbert",
"author_id": 392,
"author_profile": "https://Stackoverflow.com/users/392",
"pm_score": 2,
"selected": true,
"text": "string mailTo = Request.Form[\"emailTo\"];\nstring mailFrom = Request.Form[\"emailFrom\"];\nstring subject = Request.Form[\... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310889",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13139/"
] |
310,911 | <p>Any good reason why $("p").html(0) makes all paragraphs empty as opposed to contain the character '0'?</p>
<p>Instead of assuming I found a bug in jQuery, it's probably a misunderstanding on my part.</p>
| [
{
"answer_id": 310918,
"author": "nickf",
"author_id": 9021,
"author_profile": "https://Stackoverflow.com/users/9021",
"pm_score": 0,
"selected": false,
"text": "if (newContent == false) var myNum = 0;\n$('p').html('' + myNum);\n"
},
{
"answer_id": 310920,
"author": "Eric Sch... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310911",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2443/"
] |
310,919 | <p>I've never liked wrapping the </p>
<pre><code>mysql_real_escape_string
</code></pre>
<p>function around input I expect to be integer for inclusion in a MySQL query.
Recently I came across the </p>
<pre><code>filter_var
</code></pre>
<p>function. Nice!</p>
<p>I'm currently using the code:</p>
<pre><code>if (i... | [
{
"answer_id": 310930,
"author": "Paige Ruten",
"author_id": 813,
"author_profile": "https://Stackoverflow.com/users/813",
"pm_score": 1,
"selected": false,
"text": "$sql = 'SELECT * FROM TABLE_NAME WHERE idUser = ' . intval($idUser);\n $idUserIN_filtered = filter_var($idUserIN, FILTER_V... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310919",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10648/"
] |
310,946 | <p>I want to send an email from my iPhone application. I have heard that the iOS SDK doesn't have an email API. I don't want to use the following code because it will exit my application:</p>
<pre><code>NSString *url = [NSString stringWithString: @"mailto:foo@example.com?cc=bar@example.com&subject=Greetings%20from... | [
{
"answer_id": 1513433,
"author": "PeyloW",
"author_id": 165059,
"author_profile": "https://Stackoverflow.com/users/165059",
"pm_score": 9,
"selected": false,
"text": "MFMailComposeViewController MFMailComposeViewControllerDelegate #import <MessageUI/MFMailComposeViewController.h>\n MFMa... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310946",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39599/"
] |
310,947 | <p>Accepting the possibility of extreme ridicule, I must admit that I really miss sun Teamware's filemerge tool. I have switched from solaris to red hat linux, and find myself regularly missing filemerge (not to be confused with the Apple tool of the same name), as well as the solaris version of pstack (which worked on... | [
{
"answer_id": 6963805,
"author": "alvinabad",
"author_id": 293593,
"author_profile": "https://Stackoverflow.com/users/293593",
"pm_score": 1,
"selected": false,
"text": "kdiff3 x.A.cpp x.C.cpp x.P.cpp -o x.M.cpp\n x.A.cpp - ancestor version of x.cpp\nx.C.cpp - child verion of x.cpp\nx.P... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310947",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39870/"
] |
310,964 | <p>I'm learning functional programming, and have tried to solve a couple problems in a functional style. One thing I experienced, while dividing up my problem into functions, was it seemed I had two options: use several disparate functions with similar parameter lists, or using nested functions which, as closures, can ... | [
{
"answer_id": 310971,
"author": "Kyle Cronin",
"author_id": 658,
"author_profile": "https://Stackoverflow.com/users/658",
"pm_score": 2,
"selected": false,
"text": "(define (foo a)\n (define (bar b)\n (+ a b)) ; getting a from outer scope, not purely functional\n (bar 3))\n\n(... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310964",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/38803/"
] |
310,974 | <p>Very simply, what is tail-call optimization?</p>
<p>More specifically, what are some small code snippets where it could be applied, and where not, with an explanation of why?</p>
| [
{
"answer_id": 310980,
"author": "Kyle Cronin",
"author_id": 658,
"author_profile": "https://Stackoverflow.com/users/658",
"pm_score": 11,
"selected": true,
"text": "(define (fact x)\n (if (= x 0) 1\n (* x (fact (- x 1)))))\n\n(define (fact x)\n (define (fact-tail x accum)\n (i... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310974",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/38812/"
] |
310,981 | <p>I am working on lock free structure with g++ compiler. It seems that with -o1 switch, g++ will change the execution order of my code. How can I forbid g++'s optimization on certain part of my code while maintain the optimization to other part? I know I can split it to two files and link them, but it looks ugly.</p>
| [
{
"answer_id": 310980,
"author": "Kyle Cronin",
"author_id": 658,
"author_profile": "https://Stackoverflow.com/users/658",
"pm_score": 11,
"selected": true,
"text": "(define (fact x)\n (if (= x 0) 1\n (* x (fact (- x 1)))))\n\n(define (fact x)\n (define (fact-tail x accum)\n (i... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310981",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
310,996 | <p>I am calling a batch file from Javascript in this fashion:</p>
<pre><code>function runBatch(){
var exe = Components.classes['@mozilla.org/file/local;1'].createInstance(Components.interfaces.nsILocalFile);
exe.initWithPath("C:\\test.bat");
var run = Components.classes['@mozilla.org/process/util;1'].creat... | [
{
"answer_id": 311940,
"author": "ng.mangine",
"author_id": 37784,
"author_profile": "https://Stackoverflow.com/users/37784",
"pm_score": 1,
"selected": false,
"text": "function runBatch(){\n var exe = Components.classes['@mozilla.org/file/local;1'].createInstance(Components.interface... | 2008/11/22 | [
"https://Stackoverflow.com/questions/310996",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/525/"
] |
311,043 | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="https://stackoverflow.com/questions/311054/how-do-i-select-last-5-rows-in-a-table-without-sorting">How do I select last 5 rows in a table without sorting?</a> </p>
</blockquote>
<p>I want to select the top 10 records from a table in SQL Server wi... | [
{
"answer_id": 311056,
"author": "smoothdeveloper",
"author_id": 17049,
"author_profile": "https://Stackoverflow.com/users/17049",
"pm_score": 4,
"selected": false,
"text": "select top 10 * from [tablename] order by newid()\n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311043",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,050 | <p>I have a scrolling div with Three linkbuttons and three differents divs. I need to apply CSS to active linkbutton as soon as button is clicked.The codes used by me are:</p>
<pre><code>protected void btnNetwork_Click(object sender, EventArgs e)
{
this.btnForecast.CssClass = "li_1";
this.btnBlog.... | [
{
"answer_id": 311233,
"author": "Pradeep Kumar Mishra",
"author_id": 22710,
"author_profile": "https://Stackoverflow.com/users/22710",
"pm_score": 2,
"selected": false,
"text": "$get('btnId').setAttribute(\"class\", \"some_class_name\");\n"
},
{
"answer_id": 3167645,
"author... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311050",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39599/"
] |
311,051 | <p>I'm converting some Actionscript code from AS2 tp AS3, and I've eventually managed to get most of it to work again (it's allmost a totally different language, sharing just a little syntax similarity). One of the last things that still doesn't work, is the code for loading an external image.</p>
<p>Perhaps this has ... | [
{
"answer_id": 311157,
"author": "Stein G. Strindhaug",
"author_id": 26115,
"author_profile": "https://Stackoverflow.com/users/26115",
"pm_score": 0,
"selected": false,
"text": "for (i = 0; i<imgHolders.length; i++) {\n var loader:Loader = imgHolders[i].getChildByName(\"imgloader\"+i)... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311051",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/26115/"
] |
311,052 | <p>I'm looking for a way to change the CSS rules for pseudo-class selectors (such as :link, :hover, etc.) from JavaScript.</p>
<p>So an analogue of the CSS code: <code>a:hover { color: red }</code> in JS.</p>
<p>I couldn't find the answer anywhere else; if anyone knows that this is something browsers do not support, ... | [
{
"answer_id": 311437,
"author": "bobince",
"author_id": 18936,
"author_profile": "https://Stackoverflow.com/users/18936",
"pm_score": 8,
"selected": false,
"text": "#elid:hover { background: red; }\n document.styleSheets[0].insertRule('#elid:hover { background-color: red; }', 0);\ndocum... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311052",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39882/"
] |
311,054 | <p>I want to select the last 5 records from a table in SQL Server without arranging the table in ascending or descending order.</p>
| [
{
"answer_id": 311059,
"author": "Stefan Mai",
"author_id": 13257,
"author_profile": "https://Stackoverflow.com/users/13257",
"pm_score": 2,
"selected": false,
"text": "SELECT TOP 5 * FROM [TableName]"
},
{
"answer_id": 311067,
"author": "Matt Hamilton",
"author_id": 615,... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311054",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,062 | <p>Which is the best method to make the browser use cached versions of js files (from the serverside)?</p>
| [
{
"answer_id": 311073,
"author": "Ken",
"author_id": 20074,
"author_profile": "https://Stackoverflow.com/users/20074",
"pm_score": 3,
"selected": false,
"text": "function OutputJs($Content) \n{ \n ob_start();\n echo $Content;\n $expires = DAY_IN_S; // 60 * 60 * 24 ... defined ... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311062",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7883/"
] |
311,068 | <p>This is pretty trivial, but I noticed on SO that instead of an offset they are using page numbers. I know the difference is minor (multiply the page number by rows on a page or divide offset by rows on a page), but I'm wondering if one is recommended over the other.</p>
<p>Some sites, like Google, of course use a m... | [
{
"answer_id": 597684,
"author": "thomasrutter",
"author_id": 53212,
"author_profile": "https://Stackoverflow.com/users/53212",
"pm_score": 3,
"selected": false,
"text": "WHERE my_sortorder >= (some offset)\nLIMIT 10\n LIMIT 10 OFFSET 880\n"
},
{
"answer_id": 45788241,
"autho... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311068",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5441/"
] |
311,070 | <p>How to filter my datagridview by the value of my label.text on click event? That value is from my linq query:</p>
<pre><code>dataSet.Tables[0].AsEnumerable().Where(c => c.Field<int>("ageColumn") > 3 &&
c.Field<int>("ageColumn") < 5).Count();
</code></pre>
<p>Let's just say the abo... | [
{
"answer_id": 311139,
"author": "Rob Cooper",
"author_id": 832,
"author_profile": "https://Stackoverflow.com/users/832",
"pm_score": 0,
"selected": false,
"text": "dataSet.Tables[0].AsEnumerable().Where(c => c.Field<int>(\"ageColumn\") > 3 &&\n c.Field<int>(\"ageColumn\") < 5)\n"
},
... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311070",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10385/"
] |
311,074 | <p>In my application I have a <code>Customer</code> class and an <code>Address</code> class. The <code>Customer</code> class has three instances of the <code>Address</code> class: <code>customerAddress</code>, <code>deliveryAddress</code>, <code>invoiceAddress</code>.</p>
<p><strong>Whats the best way to reflect this ... | [
{
"answer_id": 311091,
"author": "Mitch Wheat",
"author_id": 16076,
"author_profile": "https://Stackoverflow.com/users/16076",
"pm_score": 5,
"selected": true,
"text": "CREATE TABLE Customer\n(\n ID int not null IDENTITY(1,1) PRIMARY KEY,\n Name varchar(60) not null,\n customerA... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311074",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/23368/"
] |
311,092 | <p>I am working on an app with an NSTextView. When I paste random bytes into it (say, from a compiled C program) it displays gibberish, as it should. However, when I -setShowsControlCharacters:YES, the same causes a crash and gives the following error multiple times:</p>
<p><code>2008-11-22 00:27:22.671 MyAppName[61... | [
{
"answer_id": 312204,
"author": "Ashley Clark",
"author_id": 4556,
"author_profile": "https://Stackoverflow.com/users/4556",
"pm_score": 4,
"selected": true,
"text": "objc_exception_throw -[NSException raise] objc_exception_throw"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311092",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18091/"
] |
311,094 | <p>Some background: In Germany (at least) invoice numbers have to follow certain rules:</p>
<ol>
<li>The have to be ordered</li>
<li>They have to be continuous (may not have gaps)</li>
</ol>
<p>Since a few months they are allowed to contain characters. Some customers want to use that possibility and customers don't k... | [
{
"answer_id": 311107,
"author": "Frode Lillerud",
"author_id": 33431,
"author_profile": "https://Stackoverflow.com/users/33431",
"pm_score": 4,
"selected": true,
"text": "static object _invoiceNumberLock = new object();\npublic static string GetInvoiceNumber()\n{\n lock(_invoiceNumbe... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311094",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/23368/"
] |
311,102 | <p>For a system I need to convert a pointer to a long then the long back to the pointer type. As you can guess this is very unsafe. What I wanted to do is use dynamic_cast to do the conversion so if I mixed them I'll get a null pointer. This page says <a href="http://publib.boulder.ibm.com/infocenter/lnxpcomp/v7v91/ind... | [
{
"answer_id": 311106,
"author": "amit kumar",
"author_id": 19501,
"author_profile": "https://Stackoverflow.com/users/19501",
"pm_score": 2,
"selected": false,
"text": "dynamic_cast reinterpret_cast assert(ptr != 0) reinterpret_cast union U { \nint* i_ptr_;\nlong l;\n}\n"
},
{
"... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311102",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,103 | <p>I need a map that has two keys, e.g.</p>
<pre><code>Map2<String /*ssn*/, String /*empId*/, Employee> _employees;
</code></pre>
<p>So that I can</p>
<pre><code>_employees.put(e.ssn(), e.empId(), e)
</code></pre>
<p>And later</p>
<pre><code>_employees.get1(someSsn);
_employees.get2(someImpId);
</code></pre>... | [
{
"answer_id": 311110,
"author": "Stefan Mai",
"author_id": 13257,
"author_profile": "https://Stackoverflow.com/users/13257",
"pm_score": 2,
"selected": false,
"text": "Map< String, Map< String,Employee> > _employees;\n"
},
{
"answer_id": 311248,
"author": "Zach Scrivena",
... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311103",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18573/"
] |
311,117 | <p>I need a type which can contain a position of an object in a 3D environment - my house.</p>
<p>I need to know the floor it is on, and the x and Y coordinates on that floor.</p>
<p>The System.Windows.Point(int, int) only represent a two-dimensional space, but does .NET have a type for three-dimensional space?</p>
... | [
{
"answer_id": 311129,
"author": "Rune Grimstad",
"author_id": 30366,
"author_profile": "https://Stackoverflow.com/users/30366",
"pm_score": 3,
"selected": true,
"text": "public struct Vector3\n{\n public float x;\n public float y;\n public float z;\n} \n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311117",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/33431/"
] |
311,131 | <p>I've written a WPF UserControl, and want to add one or more of it to my Window at runtime when I click a button. How can I do that?</p>
<p>Edit: Further specification
I want to add the usercontrols to a Canvas, and put in a absolute position. The canvas is a drawing of the floors in my house, and each usercontrol h... | [
{
"answer_id": 311136,
"author": "Jobi Joy",
"author_id": 8091,
"author_profile": "https://Stackoverflow.com/users/8091",
"pm_score": 2,
"selected": false,
"text": " _stackPanel.Children.Add(new YourControl()); \n"
},
{
"answer_id": 311815,
"author": "Ian Oakes",
"author... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311131",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/33431/"
] |
311,154 | <p>I have a .fla file with some text that I want to get at. Is there a free app than you can use to open .fla files, or just a tool to dump strings and pics?</p>
| [
{
"answer_id": 311170,
"author": "PhiLho",
"author_id": 15459,
"author_profile": "https://Stackoverflow.com/users/15459",
"pm_score": 3,
"selected": false,
"text": "strings -n 10 \"D:\\Archives\\scrolling flash gallery with preloader.fla\" > str\n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311154",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2942/"
] |
311,165 | <p>How can you convert a byte array to a hexadecimal string and vice versa?</p>
| [
{
"answer_id": 311179,
"author": "Tomalak",
"author_id": 18771,
"author_profile": "https://Stackoverflow.com/users/18771",
"pm_score": 12,
"selected": true,
"text": "Convert.ToHexString Convert.FromHexString public static string ByteArrayToString(byte[] ba)\n{\n StringBuilder hex = new ... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311165",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19582/"
] |
311,166 | <p>When using the <a href="http://en.wikipedia.org/wiki/Pimpl_idiom" rel="nofollow noreferrer">pImpl idiom</a> is it preferable to use a <code>boost:shared_ptr</code> instead of a <code>std::auto_ptr</code>? I'm sure I once read that the boost version is more exception friendly?</p>
<pre><code>class Foo
{
public:
... | [
{
"answer_id": 311182,
"author": "fizzer",
"author_id": 18167,
"author_profile": "https://Stackoverflow.com/users/18167",
"pm_score": 4,
"selected": false,
"text": "auto_ptr boost::noncopyable auto_ptr impl delete impl_ auto_ptr"
},
{
"answer_id": 311185,
"author": "kshahar",... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311166",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9236/"
] |
311,181 | <p>I'm looking for a open source .Net HTTP proxy library. Basically I want to develop something like Fiddler (so much lighter with less features).</p>
| [
{
"answer_id": 311200,
"author": "splattne",
"author_id": 6461,
"author_profile": "https://Stackoverflow.com/users/6461",
"pm_score": 1,
"selected": false,
"text": "RewriteRule ^(.*) http://www.testsiteXY.com$1 [P]\n"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311181",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,184 | <p>I'm using Oracle 10g and I'm trying to "stack" the conditions in a CASE statement, like I would do in C++ :</p>
<pre><code>case 1:
case 2:
// instructions
break;
</code></pre>
<p>i.e. having the same code block executed for two different successful conditions.</p>
<p>I've tried :</p>
<pre><code>WHEN 1, 2... | [
{
"answer_id": 311208,
"author": "WW.",
"author_id": 14663,
"author_profile": "https://Stackoverflow.com/users/14663",
"pm_score": 6,
"selected": true,
"text": "CASE\n WHEN v_n = 1 OR v_n = 2 THEN\n dbms_output.put_line('Case 1 or 2');\n WHEN v_n = 3 THEN\n dbms_output.put_line('... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311184",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/77004/"
] |
311,188 | <p>I am using django 1.0 and I have created my models using the example in the Django book. I am able to perform the basic function of adding data; now I need a way of retrieving that data, loading it into a form (change_form?! or something), <b>EDIT</b> it and save it back to the DB. Secondly how do I <b>DELETE</b> t... | [
{
"answer_id": 311191,
"author": "Vasil",
"author_id": 7883,
"author_profile": "https://Stackoverflow.com/users/7883",
"pm_score": 5,
"selected": false,
"text": "emp = Employee.objects.get(pk = emp_id)\nemp.name = 'Somename'\nemp.save()\n emp.delete()\n def update(request, id):\n emp =... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311188",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20894/"
] |
311,193 | <p>I am migrating an application from .NET 1.1 to .NET 2.0. Should I remove all uses of CollectionBase? If so, what is the best strategy for migration?</p>
| [
{
"answer_id": 311195,
"author": "Mark Ingram",
"author_id": 986,
"author_profile": "https://Stackoverflow.com/users/986",
"pm_score": 6,
"selected": true,
"text": "public class MyClass\n{\n public List<MyItem> Items;\n}\n public class MyItemCollection : List<MyItem>\n{\n}\n\npublic cla... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311193",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4653/"
] |
311,202 | <p>I'm looking for a production quality bloom filter implementation in Python to handle fairly large numbers of items (say 100M to 1B items with 0.01% false positive rate). </p>
<p><a href="http://www.imperialviolet.org/pybloom.html" rel="noreferrer">Pybloom</a> is one option but it seems to be showing its age as it t... | [
{
"answer_id": 311360,
"author": "S.Lott",
"author_id": 10661,
"author_profile": "https://Stackoverflow.com/users/10661",
"pm_score": 3,
"selected": false,
"text": "class Bit( object ):\n def __init__( self, size ):\n self.bits= array.array('B',[0 for i in range((size+7)//8)] )... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311202",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13055/"
] |
311,206 | <p>I have these 2 vectors:</p>
<pre><code>alpha =
1 1 1 1 1 1 1 1 1
f_uv =
193 193 194 192 193 193 190 189 191
</code></pre>
<p>And when I do this:</p>
<pre><code>alphaf_uv = alpha * f_uv'
</code></pre>
<p>I get the error message:</p>
<pre><code>"??? Error using ==> mtim... | [
{
"answer_id": 311209,
"author": "paxdiablo",
"author_id": 14860,
"author_profile": "https://Stackoverflow.com/users/14860",
"pm_score": 5,
"selected": true,
"text": "f_uv' alphaf_uv = double(alpha) * double(f_uv')\n alphaf_uv"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311206",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/38721/"
] |
311,221 | <p>If you had a 10 minute hands-on session to teach someone Emacs, what would you show them?</p>
<pre>
Start emacs: emacs
...
Quit emacs: C-x C-c
</pre>
<p>What else would you have them do between starting and quitting Emacs, while you stood behind them?</p>
| [
{
"answer_id": 311226,
"author": "Johannes Schaub - litb",
"author_id": 34509,
"author_profile": "https://Stackoverflow.com/users/34509",
"pm_score": 2,
"selected": false,
"text": "M-x"
},
{
"answer_id": 311239,
"author": "Miserable Variable",
"author_id": 18573,
"aut... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311221",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,242 | <p>I'm new to PHP and I'm trying to do something that may be bad practise and may well be impossible. I'm basically just hacking something together to test my knowledge and see what PHP can do.</p>
<p>I have one webpage with a form that collects data. That is submited to a PHP script that does a bunch of processing - ... | [
{
"answer_id": 311269,
"author": "Tom Haigh",
"author_id": 22224,
"author_profile": "https://Stackoverflow.com/users/22224",
"pm_score": 4,
"selected": false,
"text": "session_start();\n$_SESSION['formdata'] = $_POST; //or whatever\n session_start();\nprint_r($_SESSION['formdata']);\n he... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311242",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39905/"
] |
311,243 | <p>I have a Java application and I would like to make it extensible. To create an extension, developers within our company will write a Java class that implements a certain interface. They may also wish to write associated helper classes. I would like to load these extensions into the application without an outage.<... | [
{
"answer_id": 312001,
"author": "erickson",
"author_id": 3474,
"author_profile": "https://Stackoverflow.com/users/3474",
"pm_score": 4,
"selected": true,
"text": "grant codeBase \"file:/path/to/app/lib/*\" {\n permission java.io.FilePermission \"/path/to/app/-\", \"read\";\n permissio... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311243",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14663/"
] |
311,249 | <p>What are the hidden features of Maven2?</p>
| [
{
"answer_id": 311254,
"author": "Kuukage",
"author_id": 39907,
"author_profile": "https://Stackoverflow.com/users/39907",
"pm_score": 1,
"selected": false,
"text": "<plugin>\n <groupId>org.apache.maven.plugins</groupId>\n <artifactId>maven-dependency-plugin</artifactId>\n</plugin>\n... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311249",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39907/"
] |
311,250 | <p>Okay, I have a FormView with a couple of child controls in an InsertItemTemplate. One of them is a DropDownList, called DdlAssigned. I reference it in the Page's OnLoad method like so:</p>
<pre><code>protected void Page_Load(object sender, EventArgs e)
{
((DropDownList)FrmAdd.FindControl("DdlAssigned")).Selecte... | [
{
"answer_id": 312196,
"author": "Dusda",
"author_id": 36411,
"author_profile": "https://Stackoverflow.com/users/36411",
"pm_score": 3,
"selected": true,
"text": "protected void FrmAdd_DataBound(object sender, EventArgs e)\n{\n // This is the same code as before, but done in the FormV... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311250",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/36411/"
] |
311,253 | <p>I have a .NET dll which needs to read it's config settings from it's config file. Usually, the config file is placed in the same directory as the DLL. But how do i read the config file if the DLL is GAC'ed, because I can put only the DLLs in the GAC, and not it's config files.</p>
| [
{
"answer_id": 311423,
"author": "netadictos",
"author_id": 31791,
"author_profile": "https://Stackoverflow.com/users/31791",
"pm_score": 4,
"selected": false,
"text": "System.Configuration.ExeConfigurationFileMap fileMap = new System.Configuration.ExeConfigurationFileMap();\nfileMap.Exe... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311253",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1909/"
] |
311,268 | <p>In short: I want to monitor selected calls from an application to a DLL.</p>
<p>We have an old VB6 application for which we lost the source code (the company wasn't using source control back then..). This application uses a 3rd party DLL.</p>
<p>I want to use this DLL in a new C++ application. Unfortunately the DL... | [
{
"answer_id": 311349,
"author": "kshahar",
"author_id": 33982,
"author_profile": "https://Stackoverflow.com/users/33982",
"pm_score": 5,
"selected": true,
"text": "CustomApi.dll|void NameOfFunction(long param1, double& param2);\n NameOfFunction"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311268",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/33982/"
] |
311,274 | <p>If have a set of classes that all implement an interface. </p>
<pre><code>interface IMyinterface<T>
{
int foo(T Bar);
}
</code></pre>
<p>I want to shove them all in a list and enumerate through them. </p>
<pre><code> List<IMyinterface> list
foreach(IMyinterface in list)
// etc...
</code></pre... | [
{
"answer_id": 311288,
"author": "AnthonyWJones",
"author_id": 17516,
"author_profile": "https://Stackoverflow.com/users/17516",
"pm_score": 4,
"selected": true,
"text": "interface IMyinterface { ... }\n interface IMyinterface<T> : IMyinterface { ... }\n"
},
{
"answer_id": 311333... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311274",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1116/"
] |
311,276 | <p>Just could not get this one and googling did not help much either.. </p>
<p>First something that I know: Given a string and a regex, how to replace all the occurrences of strings that matches this regular expression by a replacement string ? Use the <a href="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.... | [
{
"answer_id": 311286,
"author": "VonC",
"author_id": 6309,
"author_profile": "https://Stackoverflow.com/users/6309",
"pm_score": 4,
"selected": true,
"text": "[^a-zA-Z]+\n [^a-zA-Z]+? [^a-zA-Z]"
},
{
"answer_id": 311290,
"author": "The Archetypal Paul",
"author_id": 2175... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311276",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/27474/"
] |
311,297 | <p>I need a fast container with only two operations. Inserting keys on from a very sparse domain (all 32bit integers, and approx. 100 are set at a given time), and iterating over the inserted keys. It should deal with <em>a lot of</em> insertions which hit the same entries (like, 500k, but only 100 different ones).</p>... | [
{
"answer_id": 311396,
"author": "Steve Jessop",
"author_id": 13005,
"author_profile": "https://Stackoverflow.com/users/13005",
"pm_score": 2,
"selected": false,
"text": "array[hash(value)] = 1; array[hash(value)] = 0;"
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311297",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39912/"
] |
311,299 | <p>I need to extract multiple text/dropdown list fields from an asp.net form and format appropriately ready for sending to recipient via email.</p>
<p>What's the best way of reading those fields without having to hard code each item such as: </p>
<pre><code>item1 = InputField1.Text;
item2 = InputField2.Text;
</code... | [
{
"answer_id": 311312,
"author": "Chris",
"author_id": 34942,
"author_profile": "https://Stackoverflow.com/users/34942",
"pm_score": 0,
"selected": false,
"text": "foreach (string key in Request.Form.Keys) {\n string value = Request.Form[key];\n // format and use value here\n}\n Di... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311299",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/26809/"
] |
311,307 | <p>Is there an alternative to history.go(-1) for FireFox and Safari. Any Help would be greatly appreciated. </p>
| [
{
"answer_id": 311311,
"author": "Anteru",
"author_id": 39912,
"author_profile": "https://Stackoverflow.com/users/39912",
"pm_score": 4,
"selected": true,
"text": "history.back()"
},
{
"answer_id": 311319,
"author": "VonC",
"author_id": 6309,
"author_profile": "https:... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311307",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,332 | <p>I have an idea about what it is. My question is :-</p>
<p>1.) If i program my code which is amenable to Tail Call optimization(Last statement in a function[recursive function] being a function call only, no other operation there) then do i need to set any optimization level so that compiler does TCO. In what mode o... | [
{
"answer_id": 311340,
"author": "Robert Gamble",
"author_id": 25222,
"author_profile": "https://Stackoverflow.com/users/25222",
"pm_score": 2,
"selected": false,
"text": "-foptimize-sibling-calls gcc -S"
},
{
"answer_id": 313057,
"author": "orcmid",
"author_id": 33810,
... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311332",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2759376/"
] |
311,346 | <p>Is there any reason to start a GUI program (application for Windows) written in VB.NET in the Sub Main of a module rather than directly in a form?</p>
<p>EDIT: The program won't take any command line parameters and it will be executed as a GUI program always.</p>
| [
{
"answer_id": 311352,
"author": "bugmagnet",
"author_id": 426,
"author_profile": "https://Stackoverflow.com/users/426",
"pm_score": 2,
"selected": false,
"text": "Sub Main()\n If App.StartMode = vbSModeAutomation Then\n ...\n Else\n ...\n End If\nEnd Sub\n Sub Mai... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311346",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/38561/"
] |
311,363 | <p>NDoc has an XML element <strong>inheritdoc</strong> which allows you to inherit documentation of a member from the parent class (or an implemented interface). However, Visual Studio (i.e. the C# compiler) does not understand this tag and complains about the documentation not being present or complete. So does StyleC... | [
{
"answer_id": 1080418,
"author": "Alex Yakunin",
"author_id": 106042,
"author_profile": "https://Stackoverflow.com/users/106042",
"pm_score": 5,
"selected": false,
"text": "<see cref=\"Instance\" /> <CurrentType> <inheritdoc />, <inherited /> <see cref=\"...\" copy=\"...\" /> <see/> <in... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311363",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15497/"
] |
311,389 | <p>I've created a login submit form in HTML but for some reason autocompletion does not work in firefox.</p>
<p>This is what happens in Firefox:
- I give username and password and click on the login button
- Firefox prompts me if I would like to remember the password. I press 'remember' and login works.
- I log out an... | [
{
"answer_id": 342520,
"author": "Már Örlygsson",
"author_id": 16271,
"author_profile": "https://Stackoverflow.com/users/16271",
"pm_score": 0,
"selected": false,
"text": "onsubmit=\"\" onsubmit=\"\""
}
] | 2008/11/22 | [
"https://Stackoverflow.com/questions/311389",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,399 | <p>Does anyone know where I can find an example of how to determine if the Maximize and/or Minimize buttons on a window are available and/or disabled?</p>
<p>The window will not be in the same process as my application. I have the hWnd and I have tried using GetMenuItemInfo, but I can't find any good samples for how ... | [
{
"answer_id": 311409,
"author": "Asher",
"author_id": 38265,
"author_profile": "https://Stackoverflow.com/users/38265",
"pm_score": 0,
"selected": false,
"text": "WINDOWINFO.dwStyle & WS_MAXIMIZEBOX != 0\n"
},
{
"answer_id": 311410,
"author": "splattne",
"author_id": 646... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311399",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39171/"
] |
311,408 | <p>I'm using hibernate 3 and want to stop it from dumping all the startup messages to the console. I tried commenting out the stdout lines in log4j.properties but no luck. I've pasted my log file below. Also I'm using eclipse with the standard project structure and have a copy of log4j.properties in both the root of th... | [
{
"answer_id": 311445,
"author": "Juha Syrjälä",
"author_id": 1431,
"author_profile": "https://Stackoverflow.com/users/1431",
"pm_score": 7,
"selected": true,
"text": "info info warn error fatal debug log4j.logger.org.hibernate=info\n <logger name=\"org.hibernate\">\n <level value=\"inf... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311408",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14744/"
] |
311,432 | <p>With generics, is there ever a reason to create specific derived EventArg classes</p>
<p>It seems like now you can simply use them on the fly with a generic implementation.</p>
<p>Should i go thorugh all of my examples and remove my eventArg classes (StringEventArgs, MyFooEventArgs, etc . .)</p>
<pre><code>public... | [
{
"answer_id": 311442,
"author": "Jonas Oberschweiber",
"author_id": 1522,
"author_profile": "https://Stackoverflow.com/users/1522",
"pm_score": 0,
"selected": false,
"text": "EventArgs<T> EventArgs EventArgs<T>"
},
{
"answer_id": 311519,
"author": "dalle",
"author_id": 1... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311432",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4653/"
] |
311,438 | <p>I have a simple web app, with a few jsp pages, servlets and pojo's. I want to initialise the connection pool before any requests are made. What is the best way to do this? Can it be done when the app is first deployed or do you have to wait till the first request comes in?</p>
| [
{
"answer_id": 311482,
"author": "Yoni",
"author_id": 36071,
"author_profile": "https://Stackoverflow.com/users/36071",
"pm_score": 3,
"selected": false,
"text": "<listener>\n <listener-class>\n com...ApplicationListener\n </listener-class>\n</listener>\n public class ApplicationLis... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311438",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16684/"
] |
311,439 | <p>I am making a Color class, and provide a standard constructor like</p>
<pre><code>Color(int red, int green, int blue)
</code></pre>
<p>And then I want to provide an easy way to get the most common colors, like
Color.Blue, Color.Red. I see two possible options:</p>
<pre><code>public static readonly Color Red = new... | [
{
"answer_id": 311470,
"author": "Nidonocu",
"author_id": 483,
"author_profile": "https://Stackoverflow.com/users/483",
"pm_score": 1,
"selected": false,
"text": "Application.Current"
},
{
"answer_id": 311489,
"author": "Spoike",
"author_id": 3713,
"author_profile": "... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311439",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/364245/"
] |
311,454 | <p>How would you format/indent this piece of code?</p>
<pre><code>int ID = Blahs.Add( new Blah( -1, -2, -3) );
</code></pre>
<p>or</p>
<pre><code>int ID = Blahs.Add( new Blah(
1,2,3,55
)
);
</code></pre>
<hr />
<h3>Edit:</h3>
<p>My class has lots of parameters actually, so that might effect your response.</p... | [
{
"answer_id": 311459,
"author": "bugmagnet",
"author_id": 426,
"author_profile": "https://Stackoverflow.com/users/426",
"pm_score": 2,
"selected": false,
"text": "int ID = Blahs.Add( \n new Blah( 1, 2, 3, 55 ) \n );\n"
},
{
"answer_id": 311468,
"a... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311454",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,460 | <p>I'm trying to read data from a.csv file to ouput it on a webpage as text.</p>
<p>It's the first time I'm doing this and I've run into a nasty little problem.</p>
<p>My .csv file(which gets openened by Excel by default), has multiple rows and I read the entire thing as one long string.</p>
<p>like this:</p>
<pre>... | [
{
"answer_id": 311467,
"author": "Davide Gualano",
"author_id": 28582,
"author_profile": "https://Stackoverflow.com/users/28582",
"pm_score": 1,
"selected": false,
"text": "$rows = array();\n$name = array();\n$street = array();\n$country = array();\n\n$rows = file(\"file.csv\");\nforeach... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311460",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11795/"
] |
311,463 | <p>I can follow most of Apple's WiTap sample, but am sort of stumped on this bit in the send method:</p>
<pre><code>- (void) send:(const uint8_t)message
{
if (_outStream && [_outStream hasSpaceAvailable])
if([_outStream write:(const uint8_t *)&message maxLength:sizeof(const uint8_t)] == -1)
[se... | [
{
"answer_id": 311487,
"author": "Ben Gottlieb",
"author_id": 6694,
"author_profile": "https://Stackoverflow.com/users/6694",
"pm_score": 3,
"selected": true,
"text": "[view tag] | 0x80 [view tag] & 0x7f [AppController stream:handleEvent:] //We received a remote tap update, forwa... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311463",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/39932/"
] |
311,479 | <p>Is there a less resource intensive / faster way of performing this query (which is partly based upon: <a href="https://stackoverflow.com/questions/311390/mysql-a-search-a-select-of-multiple-rows-joining-and-all-in-one-query">This StackOverflow question</a> ). Currently it takes 0.008 seconds searching through only a... | [
{
"answer_id": 311506,
"author": "tvanfosson",
"author_id": 12950,
"author_profile": "https://Stackoverflow.com/users/12950",
"pm_score": 2,
"selected": false,
"text": "SELECT DISTINCT *\nFROM (\n (SELECT ta.auto_id, li.address, li.title, GROUP_CONCAT( ta.tag ),\n li.descript... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311479",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
311,501 | <p>If tan(x) = y and atan(y) = x why Math.Atan(Math.Tan(x)) != x?</p>
<p>I´m trying to calculate x in something like: </p>
<pre><code>tan(2/x +3) = 5
</code></pre>
<p>so </p>
<pre><code>atan(tan(2/x + 3) = atan(5)
</code></pre>
<p>and so on... but I´ve tried this: </p>
<pre><code>double d = Math.Atan(Math.Tan(10... | [
{
"answer_id": 311513,
"author": "Federico A. Ramponi",
"author_id": 18770,
"author_profile": "https://Stackoverflow.com/users/18770",
"pm_score": 5,
"selected": false,
"text": "math.tan(math.atan(x)) == x abs(number1 - number2) < epsilon // ==\nabs(number1 - number2) >= epsilon //... | 2008/11/22 | [
"https://Stackoverflow.com/questions/311501",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.