Id int64 4 8.51M | PostTypeId int64 1 7 | AcceptedAnswerId int64 7 75.5M ⌀ | ParentId int64 4 41.8M ⌀ | Score int64 -208 27.7k | ViewCount int64 11 12.4M ⌀ | Body stringlengths 0 45k | Title stringlengths 2 150 ⌀ | ContentLicense stringclasses 3
values | FavoriteCount int64 0 225 ⌀ | CreationDate stringdate 2008-07-31 21:42:52 2011-12-14 18:48:47 | LastActivityDate stringdate 2008-08-01 12:19:17 2023-03-05 04:40:26 | LastEditDate stringdate 2008-08-01 13:54:25 2023-03-05 03:12:45 ⌀ | LastEditorUserId int64 -1 21.3M ⌀ | OwnerUserId int64 -1 21.1M ⌀ | Tags listlengths 1 6 ⌀ |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
37,048 | 1 | null | null | 5 | 4,530 | Can anyone advise on how to crop an image, let's say jpeg, without using any .NET framework constructs, just raw bytes? Since this is the only* way in Silverlight...
Or point to a library?
I'm not concerned with rendering i'm wanting to manipulate a jpg before uploading.
*There are no GDI+(System.Drawing) or WPF(Sy... | Image cropping C# without .net library | CC BY-SA 2.5 | null | 2008-08-31T19:35:31.737 | 2018-10-15T13:11:25.090 | 2008-09-18T22:30:44.203 | 2,257 | 580 | [
"c#",
"silverlight",
"image-manipulation"
] |
37,052 | 2 | null | 37,048 | 2 | null | [ImageMagick](http://www.imagemagick.org/script/index.php) does a pretty good job. If you're ok with handing off editing tasks to your server...
(Seriously? The recommended way of manipulating images in Silverlight is to work with ? That's... incredibly lame.)
| null | CC BY-SA 2.5 | null | 2008-08-31T19:44:03.477 | 2008-08-31T19:44:03.477 | null | null | 811 | null |
37,054 | 2 | null | 2,968 | 4 | null | Try [JavaCC](https://java.net/projects/javacc) a parser generator for Java.
It has a lot of features for interpreting languages, and it's well supported on Eclipse.
| null | CC BY-SA 3.0 | null | 2008-08-31T19:45:45.020 | 2015-01-21T17:44:55.173 | 2015-01-21T17:44:55.173 | 1,421,925 | 2,937 | null |
37,053 | 1 | 37,055 | null | 3 | 1,917 | I'm trying to find out the 'correct' windows API for finding out the localized name of 'special' folders, specifically the Recycle Bin. I want to be able to prompt the user with a suitably localized dialog box asking them if they want to send files to the recycle bin or delete them directly.
I've found lots on the int... | How can I get the localized name of a 'special' windows folder (Recycle bin etc.)? | CC BY-SA 2.5 | null | 2008-08-31T19:44:47.907 | 2011-09-14T14:06:46.963 | null | null | 1,849 | [
"winapi",
"localization",
"recycle-bin"
] |
37,055 | 2 | null | 37,053 | 2 | null | Read this article for code samples and usage:
[http://www.codeproject.com/KB/winsdk/SpecialFolders.aspx](http://www.codeproject.com/KB/winsdk/SpecialFolders.aspx)
Also there is an article on MSDN that helps you [Identify the Location of Special Folders with API Calls](http://msdn.microsoft.com/en-us/library/aa140088(... | null | CC BY-SA 2.5 | null | 2008-08-31T19:47:14.267 | 2008-08-31T19:52:56.593 | 2008-08-31T19:52:56.593 | 2,257 | 2,257 | null |
37,056 | 1 | 37,083 | null | 11 | 9,437 | I'm setting up a web application with a FreeBSD PostgreSQL back-end. I'm looking for some database performance optimization tool/technique.
| PostgreSQL performance monitoring tool | CC BY-SA 3.0 | 0 | 2008-08-31T19:47:35.340 | 2017-08-02T13:27:45.530 | 2017-08-02T13:27:45.530 | 1,033,581 | 2,313 | [
"sql",
"database",
"optimization",
"postgresql",
"freebsd"
] |
37,058 | 2 | null | 37,026 | 4 | null | All the above answers are correct, as far as I can tell, so I'm going to tell you something else. For production code you really should use the classes in java.util.concurrent. There is very little they cannot do for you, in the area of concurrency in java.
| null | CC BY-SA 2.5 | null | 2008-08-31T19:50:58.530 | 2008-08-31T19:50:58.530 | null | null | null | null |
37,046 | 2 | null | 37,026 | 268 | null | > However (if I do understand the difference between these methods right), only one thread is always selected for further monitor acquisition.
That is not correct. `o.notifyAll()` wakes of the threads that are blocked in `o.wait()` calls. The threads are only allowed to return from `o.wait()` one-by-one, but they e... | null | CC BY-SA 4.0 | null | 2008-08-31T19:25:22.790 | 2018-10-25T15:19:41.923 | 2018-10-25T15:19:41.923 | 801,894 | 890 | null |
37,059 | 1 | 37,173 | null | 60 | 26,142 | Has anyone used Lucene.NET rather than using the full text search that comes with sql server?
If so I would be interested on how you implemented it.
Did you for example write a windows service that queried the database every hour then saved the results to the lucene.net index?
| Configure Lucene.Net with SQL Server | CC BY-SA 3.0 | 0 | 2008-08-31T19:53:14.797 | 2017-11-28T18:25:19.210 | 2017-11-28T18:25:19.210 | 5,251,104 | 2,041 | [
"sql-server",
"lucene.net"
] |
37,064 | 2 | null | 36,889 | 0 | null | > If all you need to do is to be able to flush the cache from a web-application, you could create a simple php-page and then use the system() call...
Cache flushing is part of what we're looking for, but also a way to monitor what scripts are currently in there, how much data is in there, etc - basically the same stuf... | null | CC BY-SA 2.5 | null | 2008-08-31T20:11:40.260 | 2008-08-31T20:11:40.260 | null | null | 2,287 | null |
37,041 | 1 | 37,093 | null | 2 | 533 | I have a question on the best way of exposing an asynchronous remote interface.
The conditions are as follows:
- - - - -
As a means of improving my lacking skills in this area (and brush up my Java in general), I have started a [project](http://Telharmonium.devjavu.com/) to create an Eclipse-based front-end for [xm... | Exposing a remote interface or object model | CC BY-SA 2.5 | null | 2008-08-31T19:21:27.200 | 2015-04-16T12:03:32.050 | 2008-08-31T20:01:31.097 | 2,010 | 2,010 | [
"java",
"eclipse",
"osgi",
"oop"
] |
37,066 | 2 | null | 36,889 | 7 | null | [memcache.php](http://livebookmark.net/journal/2008/05/21/memcachephp-stats-like-apcphp/) may be what you're looking for.
> memcache.php that you can get stats and dump from multiple memcache servers.
Can [delete keys](http://livebookmark.net/journal/2008/07/30/memcachephp-can-delete-keys-now/) and [flush servers](ht... | null | CC BY-SA 2.5 | null | 2008-08-31T20:13:51.083 | 2008-08-31T20:13:51.083 | null | null | 2,183 | null |
37,067 | 1 | 37,314 | null | 4 | 736 | I've created a model for executing worker tasks in a server application using a thread pool associated with an IO completion port such as shown in the posts below:
[http://weblogs.asp.net/kennykerr/archive/2008/01/03/parallel-programming-with-c-part-4-i-o-completion-ports.aspx](http://weblogs.asp.net/kennykerr/archive... | Task oriented thread pooling | CC BY-SA 2.5 | 0 | 2008-08-31T20:13:52.673 | 2010-10-04T11:16:31.120 | null | null | 3,146 | [
"c++",
"multithreading",
"boost"
] |
37,071 | 2 | null | 36,825 | 1 | null | This [Introduction to Oracle Advanced Queuing](http://www.stanford.edu/dept/itss/docs/oracle/9i/appdev.920/a96587/qintro.htm#65422) states that you can interface to it through "Internet access using HTTP, HTTPS, and SMTP" so it should be straightforward to do that using a Perl script.
| null | CC BY-SA 2.5 | null | 2008-08-31T20:18:43.973 | 2008-08-31T20:18:43.973 | null | null | 381 | null |
37,072 | 2 | null | 37,059 | 3 | null | I have not done it against database yet, your question is kinda open.
If you want to search an db, and can choose to use Lucene, I also guess that you can control when data is inserted to the database.
If so, there is little reason to poll the db to find out if you need to reindex, just index as you insert, or create ... | null | CC BY-SA 2.5 | null | 2008-08-31T20:19:19.883 | 2008-08-31T20:19:19.883 | null | null | 3,308 | null |
37,069 | 1 | 37,111 | null | 13 | 22,944 | On Mac OS X 10.5 I downloaded the latest version of Apache 2.2.9. After the usual configure, make, make install dance I had a build of apache without mod_rewrite. This wasn't statically linked and the module was not built in the /modules folder either.
I had to do the following to build Apache and mod_rewrite:
```
./... | Apache - how do I build individual and/or all modules as shared modules | CC BY-SA 2.5 | 0 | 2008-08-31T20:18:13.833 | 2012-02-01T11:18:57.030 | 2008-09-03T16:12:59.763 | -1 | 636 | [
"apache",
"unix",
"configuration",
"mod-rewrite",
"build"
] |
37,075 | 2 | null | 37,048 | 0 | null | where is silverlight executed?
Is there any reason at all to send an complete picture to the client to make the client crop it?
Do it on the server... (if you are not creating an image editor that is..)
| null | CC BY-SA 2.5 | null | 2008-08-31T20:21:58.597 | 2008-08-31T20:21:58.597 | null | null | 3,308 | null |
37,070 | 1 | 37,092 | null | 154 | 48,243 | This is a somewhat low-level question. In x86 assembly there are two SSE instructions:
> `MOVDQA xmmi, m128`
and
> `MOVNTDQA xmmi, m128`
The IA-32 Software Developer's Manual says that the in MOVNTDQA stands for , and that otherwise it's the same as MOVDQA.
My question is, what does mean?
| What is the meaning of "non temporal" memory accesses in x86 | CC BY-SA 2.5 | 0 | 2008-08-31T20:18:34.113 | 2018-11-08T23:12:05.790 | 2012-05-02T11:10:05.043 | 192,221 | 1,084 | [
"x86",
"sse",
"assembly"
] |
37,073 | 1 | 37,321 | null | 83 | 42,252 | What is currently the best way to get a favicon to display in all browsers that currently support it?
Please include:
1. Which image formats are supported by which browsers.
2. Which lines are needed in what places for the various browsers.
| What is currently the best way to get a favicon to display in all browsers that support Favicons? | CC BY-SA 2.5 | 0 | 2008-08-31T20:20:46.527 | 2021-08-29T08:04:40.290 | 2021-08-29T08:04:40.290 | 100,297 | 177 | [
"html",
"standards",
"favicon"
] |
37,078 | 2 | null | 37,073 | 5 | null | [Wikipedia to the rescue](http://en.wikipedia.org/wiki/Favicon)
| null | CC BY-SA 2.5 | null | 2008-08-31T20:26:55.637 | 2008-08-31T20:26:55.637 | null | null | 3,333 | null |
37,076 | 2 | null | 37,073 | 2 | null | Having a `favicon.*` in your root directory is automatically detected by most browsers. You can ensure it's detected by using:
```
<link rel="icon" type="image/png" href="/path/image.png" />
```
Personally I use .png images but most formats should work.
| null | CC BY-SA 2.5 | null | 2008-08-31T20:22:39.487 | 2008-08-31T20:22:39.487 | null | null | 2,025 | null |
37,083 | 2 | null | 37,056 | 5 | null | [pgfouine](http://pgfouine.projects.postgresql.org/) works fairly well for me. And it looks like there's a [FreeBSD port](http://portsmon.freebsd.org/portoverview.py?category=databases&portname=pgfouine) for it.
| null | CC BY-SA 2.5 | null | 2008-08-31T20:34:02.623 | 2008-08-31T20:34:02.623 | null | null | 2,147 | null |
37,081 | 2 | null | 36,932 | 221 | null | If you need the numeric values, here's the quickest way:
```
dog, cat, rabbit = range(3)
```
In Python 3.x you can also add a starred placeholder at the end, which will soak up all the remaining values of the range in case you don't mind wasting memory and cannot count:
```
dog, cat, rabbit, horse, *_ = range(100)
... | null | CC BY-SA 3.0 | null | 2008-08-31T20:31:22.693 | 2017-05-05T08:48:49.063 | 2017-05-05T08:48:49.063 | 1,148,661 | 116 | null |
37,084 | 2 | null | 36,906 | 7 | null | You are optimizing the wrong thing, both of those should be so fast that you'll have to run them billions of times just to get any measurable difference.
And just about anything will have much greater effect on your performance, for example, if the values you are swapping are close in memory to the last value you touc... | null | CC BY-SA 2.5 | null | 2008-08-31T20:34:11.407 | 2008-08-31T20:34:11.407 | null | null | 3,509 | null |
37,086 | 2 | null | 37,056 | 1 | null | Well, the first thing to do is try all your queries from psql using "explain" and see if there are sequential scans that can be converted to index scans by adding indexes or rewriting the query.
Other than that, I'm as interested in the answers to this question as you are.
| null | CC BY-SA 2.5 | null | 2008-08-31T20:34:45.337 | 2008-08-31T20:34:45.337 | null | null | 3,333 | null |
37,087 | 2 | null | 24,045 | 6 | null | For me, VisualSVN is pretty, but useless. AnkhSvn on the other hand, after it came in v2 as an scc provider, it works very good.
VisualSVN tries to think for you, which is not an good thing, the user should be the controller, not the software.
| null | CC BY-SA 2.5 | null | 2008-08-31T20:36:42.180 | 2008-08-31T20:36:42.180 | null | null | 3,308 | null |
37,085 | 2 | null | 28,757 | -1 | null | With Appliance, we normally think about something like this:
[http://www.garghouti.co.uk/vmTrac/](http://www.garghouti.co.uk/vmTrac/)
There is not much info about versions and such though.
But as others have pointed out, it is dead easy to install svn and svndeamon on an server that already exists, Svn takes very lit... | null | CC BY-SA 2.5 | null | 2008-08-31T20:34:43.450 | 2008-08-31T20:34:43.450 | null | null | 3,308 | null |
37,090 | 2 | null | 37,089 | 7 | null | If you're using multiple threads, the operating system will automatically take care of using multiple cores.
| null | CC BY-SA 2.5 | null | 2008-08-31T20:45:34.873 | 2008-08-31T20:45:34.873 | null | null | 1,595 | null |
37,089 | 1 | 37,090 | null | 10 | 14,555 | When launching a thread or a process in .NET or Java, is there a way to choose which processor or core it is launched on? How does the shared memory model work in such cases?
| How can an application use multiple cores or CPUs in .NET or Java? | CC BY-SA 3.0 | null | 2008-08-31T20:42:43.650 | 2012-03-11T13:21:52.713 | 2012-03-11T13:21:52.713 | 63,550 | 646 | [
"c#",
"java",
"multithreading"
] |
37,091 | 2 | null | 37,073 | 10 | null | I use .ico format and put the following two lines within the `<head>` element:
```
<link rel="icon" href="/favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
```
| null | CC BY-SA 2.5 | null | 2008-08-31T20:46:21.237 | 2008-08-31T20:46:21.237 | null | null | 1,450 | null |
37,026 | 1 | 37,046 | null | 421 | 231,086 | If one Googles for "difference between `notify()` and `notifyAll()`" then a lot of explanations will pop up (leaving apart the javadoc paragraphs). It all boils down to the number of waiting threads being waken up: one in `notify()` and all in `notifyAll()`.
However (if I do understand the difference between these met... | Java: notify() vs. notifyAll() all over again | CC BY-SA 3.0 | 0 | 2008-08-31T18:47:12.850 | 2020-10-28T01:32:58.620 | 2011-12-29T18:49:44.047 | 592,746 | 3,894 | [
"java",
"multithreading"
] |
37,050 | 2 | null | 37,026 | 50 | null | Useful differences:
- Use if all your waiting threads are interchangeable (the order they wake up doesn't matter), or if you only ever have one waiting thread. A common example is a thread pool used to execute jobs from a queue--when a job is added, one of threads is notified to wake up, execute the next job and go b... | null | CC BY-SA 2.5 | null | 2008-08-31T19:41:28.740 | 2008-08-31T19:41:28.740 | null | null | 2,783 | null |
37,095 | 1 | 37,118 | null | 6 | 5,309 | How do I avoid read locks in my database?
Answers for multiple databases welcome!
| How do I avoid read locks in my database? | CC BY-SA 3.0 | 0 | 2008-08-31T20:54:19.003 | 2013-12-02T12:58:45.977 | 2013-12-02T12:58:45.977 | 2,432,317 | 116 | [
"sql",
"database",
"performance",
"locking"
] |
37,099 | 2 | null | 37,095 | 3 | null | In SQL Server you can use the with(nolock) keyword in your select statements. For example:
```
Select table1.columna, table2.columna
from table1 with(nolock), table2 with(nolock)
```
Make sure to specify with(nolock) for each table/view in the query.
| null | CC BY-SA 2.5 | null | 2008-08-31T21:01:20.623 | 2008-08-31T21:01:20.623 | null | null | 3,452 | null |
37,096 | 2 | null | 37,089 | 1 | null | The operating system takes care of multi-threading when the virtual machine is using native threads (as opposed to green-threads), and you can't specify low level details, like choosing a processor for a certain thread. It is better that way because you usually have many more threads than you have processors available,... | null | CC BY-SA 2.5 | null | 2008-08-31T20:59:04.733 | 2008-08-31T20:59:04.733 | null | null | 3,280 | null |
37,092 | 2 | null | 37,070 | 182 | null | Non-Temporal SSE instructions (MOVNTI, MOVNTQ, etc.), don't follow the normal cache-coherency rules. Therefore non-temporal stores must be followed by an SFENCE instruction in order for their results to be seen by other processors in a timely fashion.
When data is produced and not (immediately) consumed again, the fac... | null | CC BY-SA 2.5 | null | 2008-08-31T20:50:00.200 | 2008-08-31T20:50:00.200 | null | null | 2,257 | null |
37,101 | 1 | 37,167 | null | 11 | 8,972 | Is there a way clear or reset the outputcache for an entire website without a restart?
I'm just starting to use outputcache on a site and when I make a mistake in setting it up I need a page I can browse to that will reset it.
| How to Clear OutputCache for Website without Restarting App | CC BY-SA 2.5 | 0 | 2008-08-31T21:03:14.693 | 2012-10-13T21:51:31.527 | 2010-06-01T05:55:25.223 | 30,674 | 3,747 | [
"asp.net",
"outputcache"
] |
37,093 | 2 | null | 37,041 | 2 | null | For the asynchronous bit, I would suggest checking into `java.util.concurrent`, and especially the `Future<T>` interface. The future interface is used to represent objects which are not ready yet, but are being created in a separate thread. You say that objects can be modified at any time by a third party, but I would ... | null | CC BY-SA 3.0 | null | 2008-08-31T20:52:01.193 | 2015-04-16T12:03:32.050 | 2015-04-16T12:03:32.050 | 725,306 | 3,355 | null |
37,114 | 2 | null | 37,073 | 3 | null | Favicon must be an [.ico file](http://en.wikipedia.org/wiki/ICO_%28icon_image_file_format%29) to work properly on all browsers.
Modern browsers also support PNG and GIF images.
I've found that in general the easiest way to create one is to use a freely available web service such as [favicon.cc](http://favicon.cc/).
| null | CC BY-SA 2.5 | null | 2008-08-31T21:15:54.520 | 2008-08-31T21:43:39.463 | 2008-08-31T21:43:39.463 | 2,948 | 2,948 | null |
37,111 | 2 | null | 37,069 | 15 | null | Try the `./configure` option `--enable-mods-shared="all"`, or `--enable-mods-shared="<list of modules>"` to compile modules as shared objects. See further [details in Apache 2.2 docs](http://httpd.apache.org/docs/2.2/programs/configure.html#otheroptfeat)
To just compile Apache with the ability to load shared objects ... | null | CC BY-SA 2.5 | null | 2008-08-31T21:14:05.197 | 2008-08-31T21:22:56.657 | 2008-08-31T21:22:56.657 | 199 | 199 | null |
37,118 | 2 | null | 37,095 | 3 | null | In Oracle the default mode of operation is the isolation level where a select statement is not blocked by another transaction modifying the data it's reading.
From [Data Concurrency and Consistency](http://download.oracle.com/docs/cd/B10501_01/server.920/a96524/c21cnsis.htm):
> Each query executed by a transaction se... | null | CC BY-SA 2.5 | null | 2008-08-31T21:21:44.507 | 2008-08-31T21:21:44.507 | null | null | 3,511 | null |
37,103 | 1 | 37,131 | null | 88 | 240,573 | I have a container div with a fixed `width` and `height`, with `overflow: hidden`.
I want a horizontal row of float: left divs within this container. Divs which are floated left will naturally push onto the 'line' below after they read the right bound of their parent. This will happen even if the `height` of the parent... | CSS - Make divs align horizontally | CC BY-SA 4.0 | 0 | 2008-08-31T21:05:41.830 | 2021-07-10T22:02:48.067 | 2021-07-10T22:02:48.067 | 446,106 | 1,349,865 | [
"html",
"css",
"alignment"
] |
37,122 | 1 | 156,274 | null | 106 | 115,489 | How do I make a user's browser blink/flash/highlight in the task bar using JavaScript? For example, if I make an AJAX request every 10 seconds to see if the user has any new messages on the server, I want the user to know it right away, even if he is using another application at the time.
| Make browser window blink in task Bar | CC BY-SA 3.0 | 0 | 2008-08-31T21:22:51.930 | 2023-01-03T01:27:33.023 | 2015-04-17T21:19:22.247 | 3,889,449 | 1,191 | [
"javascript",
"browser"
] |
37,124 | 2 | null | 36,106 | 1 | null | One more compression thought:
If the bit array is not crazy long, you could try applying the [Burrows-Wheeler transform](http://en.wikipedia.org/wiki/Burrows-Wheeler) before using any repetition encoding, such as Huffman. A naive implementation would take O(n^2) memory during (de)compression and O(n^2 log n) time to ... | null | CC BY-SA 2.5 | null | 2008-08-31T21:23:45.487 | 2008-08-31T21:23:45.487 | null | null | 3,561 | null |
37,123 | 2 | null | 37,041 | 0 | null | @[Staale](https://stackoverflow.com/questions/37041/exposing-a-remote-interface-or-object-model#37093): Thanks a bunch!
Using Future for the async operations is interesting. The only drawback being that it is doesn't provide callbacks. But then again, I tried that approach, and look where that got me :)
I'm currently... | null | CC BY-SA 2.5 | null | 2008-08-31T21:23:35.440 | 2008-09-01T13:20:22.987 | 2017-05-23T12:18:33.227 | -1 | 2,010 | null |
37,127 | 2 | null | 37,089 | 0 | null | I have used this in a couple of programs because my core 0 was kind of messed up.
```
// Programmatically set process affinity
var process = System.Diagnostics.Process.GetCurrentProcess();
// Set Core 0
process.ProcessorAffinity = new IntPtr(0x0001);
```
or
```
// Set Core 1
process.ProcessorAffinity = new IntPtr(... | null | CC BY-SA 2.5 | null | 2008-08-31T21:26:33.747 | 2010-04-24T22:29:25.253 | 2010-04-24T22:29:25.253 | 63,550 | 1,147 | null |
37,129 | 2 | null | 37,103 | 4 | null | you can use the `clip` property:
```
#container {
position: absolute;
clip: rect(0px,200px,100px,0px);
overflow: hidden;
background: red;
}
```
note the `position: absolute` and `overflow: hidden` needed in order to get `clip` to work.
| null | CC BY-SA 3.0 | null | 2008-08-31T21:28:31.213 | 2016-01-14T19:15:01.123 | 2016-01-14T19:15:01.123 | 2,678,454 | 3,914 | null |
37,134 | 2 | null | 37,122 | 2 | null | The only way I can think of doing this is by doing something like alert('you have a new message') when the message is received. This will flash the taskbar if the window is minimized, but it will also open a dialog box, which you may not want.
| null | CC BY-SA 2.5 | null | 2008-08-31T21:34:47.800 | 2008-08-31T21:34:47.800 | null | null | 1,349,865 | null |
37,117 | 2 | null | 37,089 | 4 | null | > is there a way to choose which processor or core it is launched on?
You can use the task manager to tell windows what CPU(s) your program should be allowed to run on. Normally this is only useful for troubleshooting legacy programs which have broken implementations of multi-threading. To do this,
- - `Processes`- ... | null | CC BY-SA 2.5 | null | 2008-08-31T21:20:38.160 | 2008-08-31T21:20:38.160 | null | null | 234 | null |
37,132 | 2 | null | 37,104 | 5 | null | Firstly you can - and should - use a revision control system, most will handle binary files although unlike text files you can't merge two different set of changes so you may want to set the system up to lock these files whilst they are being changed (assuming that that's not the default mode of operation for you rcs i... | null | CC BY-SA 2.5 | null | 2008-08-31T21:30:06.623 | 2008-08-31T21:30:06.623 | null | null | 1,070 | null |
37,136 | 2 | null | 6,184 | 9 | null | I use anonymous methods a lot in this scenario:
```
void SomethingHappened(object sender, EventArgs ea)
{
MethodInvoker del = delegate{ textBox1.Text = "Something happened"; };
InvokeRequired ? Invoke( del ) : del();
}
```
| null | CC BY-SA 2.5 | null | 2008-08-31T21:35:33.897 | 2008-10-21T18:31:58.593 | 2008-10-21T18:31:58.593 | 2,187 | 2,187 | null |
37,131 | 2 | null | 37,103 | 104 | null | You may put an inner div in the container that is enough wide to hold all the floated divs.
```
#container {
background-color: red;
overflow: hidden;
width: 200px;
}
#inner {
overflow: hidden;
width: 2000px;
}
.child {
float: left;
background-color: blue;
width: 50px;
height: 50px;
... | null | CC BY-SA 3.0 | null | 2008-08-31T21:29:59.510 | 2016-12-03T18:35:30.150 | 2016-12-03T18:35:30.150 | 2,571,493 | 3,511 | null |
37,116 | 2 | null | 28,353 | 2 | null | Right,
The two answers and a little thought got me to something approaching an answer.
First a little more clarification:
The app is written in C# (2.0+) and uses ADO.NET to talk to SQL Server 2005.
The mirror setup is two W2k3 servers hosting the Principal and the Mirror plus a third server hosting an express inst... | null | CC BY-SA 2.5 | null | 2008-08-31T21:18:40.210 | 2008-08-31T21:18:40.210 | null | null | 1,070 | null |
37,144 | 2 | null | 37,095 | 2 | null | In Firebird writers never block readers and there are no dirty-reads. Only read-commited and snapshot isolation levels.
It uses a multi-generational engine (like oracle i believe) instead of simple page or record locking.
| null | CC BY-SA 2.5 | null | 2008-08-31T21:43:03.987 | 2008-08-31T21:43:03.987 | null | null | 626 | null |
37,146 | 2 | null | 37,142 | 1 | null | Use an interface that runs each response in a separate interpreter, such as `mod_wsgi` for Python. This lets multi-threading be used without encountering the GIL.
EDIT: Apparently, `mod_wsgi` no longer supports multiple interpreters per process because idiots couldn't figure out how to properly implement extension mod... | null | CC BY-SA 2.5 | null | 2008-08-31T21:43:58.480 | 2008-08-31T21:43:58.480 | null | null | 3,560 | null |
37,149 | 2 | null | 4,689 | 7 | null | I use a proportional font too. They seem good for the same reasons they work in books and magazines: the more variation between characters, the easier it is for the brain to distinguish them; and you can fit more on the screen. Indentation still works fine: 6 leading spaces is still twice as wide as 3 leading spaces.... | null | CC BY-SA 2.5 | null | 2008-08-31T21:48:57.670 | 2008-08-31T21:48:57.670 | null | null | 3,917 | null |
37,125 | 2 | null | 37,103 | 5 | null | This seems close to what you want:
```
#foo {
background: red;
max-height: 100px;
overflow-y: hidden;
}
.bar {
background: blue;
width: 100px;
height: 100px;
float: left;
margin: 1em;
}
```
```
<div id="foo">
<div class="bar"></div>
<div class="bar"></div>
<div class="bar"></div>
... | null | CC BY-SA 3.0 | null | 2008-08-31T21:24:05.907 | 2016-12-03T18:36:33.483 | 2016-12-03T18:36:33.483 | 2,571,493 | 1,600 | null |
37,142 | 1 | null | null | 6 | 2,053 | Even though [Python](http://twistedmatrix.com/pipermail/twisted-python/2004-May/007896.html) and [Ruby](http://www.reddit.com/comments/6wmum/thread_safe_ruby_on_rails_in_22_release/) have one kernel thread per interpreter thread, they have a global interpreter lock (GIL) that is used to protect potentially shared data ... | How to make Ruby or Python web sites to use multiple cores? | CC BY-SA 2.5 | 0 | 2008-08-31T21:41:24.537 | 2008-10-10T13:24:31.713 | null | null | 3,855 | [
"python",
"ruby",
"multithreading",
"multicore"
] |
37,147 | 2 | null | 37,104 | 2 | null | I use [Subversion](http://svnbook.red-bean.com/).
As an easy way to reference the website version (production, testing, development), I use a very simple trick. I add the revision number somewhere on the site (eg in the admin footer). Something like this:
```
<?php print("$Revision: 1 $"); ?>
```
Each time you check... | null | CC BY-SA 2.5 | null | 2008-08-31T21:45:18.320 | 2008-08-31T21:45:18.320 | null | null | 341 | null |
37,153 | 2 | null | 37,142 | 4 | null | I'm not totally sure which problem you want so solve, but if you deploy your python/django application via an apache prefork MPM using mod_python apache will start several worker processes for handling different requests.
If one request needs so much resources, that you want to use multiple cores have a look at [pypro... | null | CC BY-SA 2.5 | null | 2008-08-31T21:53:30.797 | 2008-08-31T21:53:30.797 | null | null | 720 | null |
37,157 | 1 | 37,160 | null | 7 | 10,724 | Is there a simple way to cache `MySQL queries` in `PHP` or failing that, is there a small class set that someone has written and made available that will do it? I can cache a whole page but that won't work as some data changes but some do not, I want to cache the part that does not.
| Caching MySQL queries | CC BY-SA 4.0 | 0 | 2008-08-31T21:55:35.580 | 2019-01-18T10:59:48.340 | 2019-01-18T10:59:48.340 | 567,854 | 1,384,652 | [
"php",
"mysql",
"caching"
] |
37,108 | 2 | null | 33,103 | 2 | null | Even if it is somewhat possible to intercept the paste event in many browsers (but not all as shown at the link on the previous answer), that is quite unreliable and posible not complete (depending on the browser / OS it may be possible to do the paste operation in different ways that may not be trappable by javascript... | null | CC BY-SA 2.5 | null | 2008-08-31T21:10:44.190 | 2008-08-31T21:10:44.190 | null | null | 3,511 | null |
37,162 | 1 | 37,183 | null | 8 | 4,951 | We generate web pages that should always be printed in landscape mode. Web browser print dialogs default to portrait, so for every print job the user has to manually select landscape. It's minor, but would be nice for the user if we can remove this unnecessary step.
Thanks in advance to all respondents.
| How do I make an HTML page print in landscape when the user selects 'print'? | CC BY-SA 4.0 | 0 | 2008-08-31T22:00:25.180 | 2019-04-02T22:41:03.307 | 2019-04-02T22:41:03.307 | 3,915 | 3,915 | [
"html",
"printing",
"landscape",
"portrait"
] |
37,163 | 2 | null | 37,122 | 2 | null | Why not take the approach that GMail uses and show the number of messages in the page title?
Sometimes users don't want to be distracted when a new message arrives.
| null | CC BY-SA 2.5 | null | 2008-08-31T22:00:47.237 | 2008-08-31T22:00:47.237 | null | null | 2,108 | null |
37,161 | 2 | null | 4,418 | 48 | null | I've been using cntlm ([http://cntlm.sourceforge.net/](http://cntlm.sourceforge.net/)) at work. Configuration is very similar to ntlmaps.
- [http://localhost:3128](http://localhost:3128)
Works great, and also allows me to connect my Ubuntu box to the ISA proxy.
Check out [http://cntlm.wiki.sourceforge.net/](http://... | null | CC BY-SA 2.5 | null | 2008-08-31T21:59:45.087 | 2008-08-31T21:59:45.087 | null | null | 3,920 | null |
37,165 | 2 | null | 30,170 | 1 | null | Personally, I just use comma-separed selector, but there some solution for writing css programmatically. Maybe this is a little overkill for you simpler needs, but take a look at [CleverCSS](http://pypi.python.org/pypi/CleverCSS/) (Python)
| null | CC BY-SA 2.5 | null | 2008-08-31T22:01:30.120 | 2008-08-31T22:01:30.120 | null | null | 3,914 | null |
37,168 | 2 | null | 37,162 | 1 | null | The `@page` rule is supposed to allow this, but is only implemented in Opera.
| null | CC BY-SA 2.5 | null | 2008-08-31T22:03:58.430 | 2008-08-31T22:03:58.430 | null | null | 3,560 | null |
37,167 | 2 | null | 37,101 | 9 | null | This should do the trick:
```
Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs)
Dim path As String
path="/AbosoluteVirtualPath/OutputCached.aspx"
HttpResponse.RemoveOutputCacheItem(path)
End Sub
```
| null | CC BY-SA 3.0 | null | 2008-08-31T22:02:53.800 | 2012-01-08T02:44:47.397 | 2012-01-08T02:44:47.397 | 31,532 | 2,066 | null |
37,175 | 2 | null | 37,041 | 0 | null | Iterable only has the method Iterator get() or somesuch. So no need to build any query or execute any code until you actually start iterating. It does make the execute in your example redundant. However, the thread will be locked until the first result is available, so you might consider using an Executor to run the co... | null | CC BY-SA 2.5 | null | 2008-08-31T22:13:33.727 | 2008-08-31T22:13:33.727 | null | null | 3,355 | null |
37,170 | 2 | null | 30,170 | 0 | null | [CSS Variables](http://disruptive-innovations.com/zoo/cssvariables/), if it ever becomes implemented in all major browsers, may one day resolve this issue.
Until then, you'll either have to copy and paste, or use a preprocessor of whatever sort, like others have suggested (typically using server-sider scripting).
| null | CC BY-SA 2.5 | null | 2008-08-31T22:05:26.977 | 2008-08-31T22:05:26.977 | null | null | 1,600 | null |
37,176 | 2 | null | 37,029 | 1 | null | People avoid cursor because they generally are more difficult to write than a simple while loops, however, a while loop can be expensive because your constantly selecting data from a table, temporary or otherwise.
With a cursor, which is readonly fast forward, the data is kept in memory and has been specifically desig... | null | CC BY-SA 2.5 | null | 2008-08-31T22:16:31.567 | 2008-08-31T22:16:31.567 | null | null | 383 | null |
37,182 | 2 | null | 622 | 20 | null | This isn't strictly against the hardcoding restriction, but comes terribly close. Why not programatically download this list and print it out, instead?
[http://primes.utm.edu/lists/small/10000.txt](http://primes.utm.edu/lists/small/10000.txt)
| null | CC BY-SA 2.5 | null | 2008-08-31T22:20:44.647 | 2008-08-31T22:20:44.647 | null | null | 279 | null |
37,180 | 2 | null | 37,059 | 1 | null | I used Lucene.NET along with MySQL. My approach was to store primary key of db record in Lucene document along with indexed text. In pseudo code it looks like:
- Store record: insert text, other data to the table
get latest inserted ID
create lucene document
put (ID, text) into lucene document
update lucene index- Que... | null | CC BY-SA 2.5 | null | 2008-08-31T22:20:01.013 | 2008-08-31T22:20:01.013 | null | null | 1,196 | null |
37,173 | 2 | null | 37,059 | 59 | null | Yes, I've used it for exactly what you are describing. We had two services - one for read, and one for write, but only because we had multiple readers. I'm sure we could have done it with just one service (the writer) and embedded the reader in the web app and services.
I've used lucene.net as a general database index... | null | CC BY-SA 3.0 | null | 2008-08-31T22:11:33.950 | 2013-07-13T21:46:43.493 | 2013-07-13T21:46:43.493 | 635,634 | 2,947 | null |
37,141 | 1 | 37,309 | null | 1 | 3,210 | Taking Jeff Atwood's [advice](https://blog.codinghorror.com/secrets-of-the-javascript-ninjas/), I decided to use a JavaScript library for the very basic to-do list application I'm writing. I picked the [Dojo toolkit](http://dojotoolkit.org/), version 1.1.1. At first, all was fine: the drag-and-drop code I wrote worked ... | Event handling in Dojo | CC BY-SA 4.0 | null | 2008-08-31T21:40:39.720 | 2018-10-21T13:04:35.867 | 2018-10-21T13:04:35.867 | 1,033,581 | 3,653 | [
"javascript",
"dojo"
] |
37,160 | 2 | null | 37,157 | 11 | null | This is a great overview of how to cache queries in MySQL:
- [The MySQL Query Cache](http://www.petefreitag.com/item/390.cfm)
| null | CC BY-SA 2.5 | null | 2008-08-31T21:59:03.043 | 2008-08-31T21:59:03.043 | null | null | 383 | null |
37,186 | 2 | null | 33,349 | 1 | null | I really don't have much experience with Sharepoint, but I thought I could at least provide answer - even if it's the wrong one.
From another dev I've spoken to it sounds like it's tough to get into any subfolders, so you might need to look at making your own custom workflow.
Maybe something like LINQ to Sharepoint ... | null | CC BY-SA 2.5 | null | 2008-08-31T22:24:05.760 | 2008-08-31T22:24:05.760 | null | null | 3,717 | null |
37,185 | 1 | 53,369 | null | 10 | 6,394 | What is the normal way people writing network code in Delphi use Windows-style overlapped asynchronous socket I/O?
Here's my prior research into this question:
The [Indy](http://indyproject.org/) components seem entirely synchronous. On the other hand, while ScktComp unit does use WSAAsyncSelect, it basically only as... | What's the idiomatic way to do async socket programming in Delphi? | CC BY-SA 2.5 | 0 | 2008-08-31T22:22:58.823 | 2009-01-13T00:40:49.473 | null | null | 3,712 | [
"delphi",
"winapi",
"sockets",
"asynchronous",
"networking"
] |
37,190 | 2 | null | 35,948 | 0 | null | shouldn't this:
```
{{ user.item }}
```
be this?
```
{{ item }}
```
there is no user object in the context within that loop....?
| null | CC BY-SA 3.0 | null | 2008-08-31T22:29:14.453 | 2012-11-14T11:01:56.877 | 2012-11-14T11:01:56.877 | 100,297 | 2,947 | null |
37,199 | 2 | null | 37,189 | 0 | null | Check that you set correct working directory for your task
| null | CC BY-SA 2.5 | null | 2008-08-31T22:38:19.660 | 2008-08-31T22:38:19.660 | null | null | 1,196 | null |
37,189 | 1 | 37,202 | null | 0 | 1,859 | I have a console program written in C# that I am using to send faxes. When I step through the program in Visual Studio it works fine. When I double click on the program in Windows Explorer it works fine. When I setup a Windows scheduled task to run the program it fails with this in the event log.
```
EventType clr2... | C# console program can't send fax when run as a scheduled task | CC BY-SA 2.5 | 0 | 2008-08-31T22:28:22.927 | 2009-04-09T10:39:06.010 | null | null | 1,203 | [
"c#",
"console",
"fax"
] |
37,200 | 2 | null | 37,189 | 0 | null | Is the scheduled task running on the same computer you're developing on, or is it on a dedicated olp server? It's quite common for paths to change when you change environments, so is the path to the document you're trying to send the same?
| null | CC BY-SA 2.5 | null | 2008-08-31T22:39:49.220 | 2008-08-31T22:39:49.220 | null | null | 2,975 | null |
37,202 | 2 | null | 37,189 | 5 | null | I can't explain it - but I have a few ideas.
Most of the times, when a program works fine testing it, and doesn't when scheduling it - security is the case. In the context of which user is your program scheduled? Maybe that user isn't granted enough access.
Is the resource your programm is trying to access a network ... | null | CC BY-SA 2.5 | null | 2008-08-31T22:40:42.273 | 2008-08-31T22:40:42.273 | null | null | 2,972 | null |
37,198 | 1 | null | null | 4 | 1,679 |
1. Specifically getting on Windows the "..\Documents & Settings\All Users, basicaly any path that needs the front end to be dynamically derived based on the OS your software is running on. (Now I need the answer to this)
2. the current users My Documents dirctory (okay this has been answered) and basicaly any path tha... | What is the best way to get OS specific information in Java? | CC BY-SA 2.5 | 0 | 2008-08-31T22:37:32.640 | 2019-01-26T18:32:44.810 | 2014-01-30T07:15:49.987 | 1,737,819 | 3,576 | [
"java",
"environment-variables"
] |
37,203 | 2 | null | 37,142 | 4 | null | The 'standard' way to do this with rails is to run a "pack" of Mongrel instances (ie: 4 copies of the rails application) and then use apache or nginx or some other piece of software to sit in front of them and act as a load balancer.
This is probably how it's done with other ruby frameworks such as merb etc, but I ha... | null | CC BY-SA 2.5 | null | 2008-08-31T22:41:55.827 | 2008-08-31T22:41:55.827 | null | null | 234 | null |
37,215 | 2 | null | 37,189 | 0 | null | I agree with MartinNH.
Many of these problems root from the fact that you develop while logged in as an administrator in Visual Studio (so the program has all the permissions for execution set properly) but you deploy as a user with lesser privileges.
Try setting the priveleges of the task scheduler user higher.
| null | CC BY-SA 2.5 | null | 2008-08-31T22:49:28.120 | 2008-08-31T22:49:28.120 | null | null | 372 | null |
37,211 | 2 | null | 30,529 | 4 | null | Native Delphi enumerations are already type-safe. Java enumerations were an innovation for that language, because before it didn't have enumerations at all. However, perhaps you mean a different feature - enumeration values prefixed by their type name.
Upcoming Delphi 2009, and the last version of the Delphi for .NET ... | null | CC BY-SA 2.5 | null | 2008-08-31T22:46:32.603 | 2008-08-31T22:46:32.603 | null | null | 3,712 | null |
37,208 | 2 | null | 23,640 | 2 | null | I have used DimDim a few times as part of an educational project.
You can use it as part of a hosted service from [DimDim](http://www.dimdim.com) themselves, and also has an open source version that you can download and run yourself.
I have not used it in the last six months or so, but we did find it very useful for ... | null | CC BY-SA 2.5 | null | 2008-08-31T22:45:37.583 | 2009-01-29T03:24:24.327 | 2009-01-29T03:24:24.327 | 277 | 277 | null |
37,194 | 2 | null | 20,059 | 25 | null | My day job is in a school, and over the past few years I've seen or taught (or attempted to teach) various children, in various numbers, programming lessons.
Children are all different - some are quick learners, some aren't. In particular, some have better literacy skills than others, and that definitely makes a diffe... | null | CC BY-SA 2.5 | null | 2008-08-31T22:33:49.170 | 2009-01-17T13:40:54.243 | 2009-01-17T13:40:54.243 | 24,874 | 3,653 | null |
37,219 | 1 | 37,267 | null | 244 | 130,158 | Suppose your git history looks like this:
1
2
3
4
5
1–5 are separate revisions. You need to remove 3 while still keeping 1, 2, 4 and 5. How can this be done?
Is there an efficient method when there are hundreds of revisions after the one to be deleted?
| How do you remove a specific revision in the git history? | CC BY-SA 3.0 | 0 | 2008-08-31T22:51:21.327 | 2018-07-08T12:44:03.817 | 2017-03-01T04:32:52.900 | 224,479 | 3,146 | [
"git"
] |
37,204 | 2 | null | 36,568 | 4 | null | As other's have mentioned we use CCNET here, which we don't usually work on a nightly build, but instead go with a Continuous Integration strategy (every check-in).
I would advise doing the same, whether it be by yourself or within a team, because you can very easily set up unit testing to run on every checkin as well... | null | CC BY-SA 2.5 | null | 2008-08-31T22:42:02.973 | 2008-08-31T22:42:02.973 | null | null | 3,717 | null |
37,218 | 2 | null | 36,806 | 5 | null | > It works. I have no idea why, but it does.
For future reference:
It works because Apache processes alias directives in order, and uses the first match. It was always hitting `Alias /`, which will match anything, before `WSGIScriptAlias`.
From the [mod_alias documentation](http://httpd.apache.org/docs/2.2/mod/mod_a... | null | CC BY-SA 2.5 | null | 2008-08-31T22:51:15.820 | 2008-08-31T22:51:15.820 | null | null | 3,560 | null |
37,227 | 2 | null | 36,568 | 0 | null | We use CruiseControl.NET with both NAnt and MsBuild for our build server. We configured it so that it would have builds everytime we check code in, as well as nightly builds.
| null | CC BY-SA 2.5 | null | 2008-08-31T22:57:06.510 | 2008-08-31T22:57:06.510 | null | null | 372 | null |
37,236 | 2 | null | 37,073 | 4 | null | IE6 cannot handle PNGs correctly, be warned.
| null | CC BY-SA 3.0 | null | 2008-08-31T23:05:54.227 | 2014-04-05T21:59:48.007 | 2014-04-05T21:59:48.007 | 282,848 | 3,926 | null |
37,226 | 2 | null | 37,041 | 0 | null | @[Staale](https://stackoverflow.com/questions/37041/exposing-a-remote-interface-or-object-model#37175)
It is certainly possibly, but as you note, that would make it blocking (at home for something like 10 seconds due to sleeping disks), meaning I can't use it to update the UI directly.
I could use the iterator to cre... | null | CC BY-SA 2.5 | null | 2008-08-31T22:57:06.073 | 2008-08-31T22:57:06.073 | 2017-05-23T10:32:50.377 | -1 | 2,010 | null |
37,239 | 2 | null | 20,587 | 0 | null | Script from the FTP server, and just call the stored proc.
| null | CC BY-SA 2.5 | null | 2008-08-31T23:08:07.013 | 2008-08-31T23:08:07.013 | null | null | 2,199 | null |
37,233 | 2 | null | 37,122 | -1 | null | >
It sounds like you're writing an app for an internal company project.
You might want to investigate writing a small windows app in .net which adds a notify icon and can then do fancy popups or balloon popups or whatever, when they get new messages.
This isn't overly hard and I'm sure if you ask SO 'how do I show... | null | CC BY-SA 2.5 | null | 2008-08-31T23:03:56.383 | 2008-08-31T23:03:56.383 | null | null | 234 | null |
37,231 | 2 | null | 36,831 | 13 | null | ```
var ipuint32 = BitConverter.ToUInt32(IPAddress.Parse("some.ip.address.ipv4").GetAddressBytes(), 0);`
```
This solution is easier to read than manual bit shifting.
See [How to convert an IPv4 address into a integer in C#?](https://stackoverflow.com/questions/461742/how-to-convert-an-ipv4-address-into-a-integer-in... | null | CC BY-SA 3.0 | null | 2008-08-31T23:01:31.820 | 2016-06-07T12:08:21.787 | 2017-05-23T12:13:34.533 | -1 | 3,926 | null |
37,235 | 2 | null | 10,499 | 2 | null | By default, tnsnames.ora is located in the $ORACLE_HOME/network/admin directory on UNIX operating systems and in the ORACLE_HOME\network\admin directory on Windows operating systems. tnsnames.ora can also be stored the following locations:
The directory specified by the TNS_ADMIN environment variable (or registry valu... | null | CC BY-SA 2.5 | null | 2008-08-31T23:05:25.133 | 2008-08-31T23:05:25.133 | null | null | null | null |
37,249 | 2 | null | 37,248 | 6 | null | > Should I build a C# pre-processor? Is there one available that does the simple things I want to do?
You can always use the C pre-processor -- C# is close enough, syntax-wise. M4 is also an option.
| null | CC BY-SA 2.5 | null | 2008-08-31T23:20:02.087 | 2008-08-31T23:20:02.087 | null | null | 3,560 | null |