unified_texts stringlengths 32 30.1k | OpenStatus_id int64 0 4 | input_ids list | token_type_ids list | attention_mask list |
|---|---|---|---|---|
In Django, how does one use the update_object generic view to edit forms of inherited models?
===
In Django, given excerpts from an application *animals* likeso:
A *animals/models.py* with:
from django.db import models
from django.contrib.contenttypes.models import ContentType
class Animal(models.Model):
content_type = models.ForeignKey(ContentType,editable=False,null=True)
name = models.CharField()
class Dog(Animal):
is_lucky = models.BooleanField()
class Cat(Animal):
lives_left = models.IntegerField()
And an *animals/urls.py*:
from django.conf.urls.default import *
from animals.models import Animal, Dog, Cat
dict = { 'model' : Animal }
urlpatterns = (
url(r'^edit/(?P<object_id>\d+)$', 'create_update.update_object', dict),
)
How can one use generic views to edit Dog and/or Cat using the same form?
I.e. The *form* object that is passed to *animals/animal_form.html* will be Animal, and thus won't contain any of the specifics for the derived classes Dog and Cat. How could I have Django automatically pass a form for the child class to *animal/animals_form.html*?
Incidentally, I'm using [Djangosnippets #1031][1] for ContentType management, so Animal would have a method named *as_leaf_class* that returns the derived class.
Clearly, one could create forms for each derived class, but that's quite a lot of unnecessary duplication (as the templates will all be generic -- essentially {{ form.as_p }}).
Incidentally, it's best to assume that Animal will probably be one of several unrelated base classes with the same problem, so an ideal solution would be generic.
Thank you in advance for the help.
[1]: http://www.djangosnippets.org/snippets/1031/
| 0 | [
2,
19,
3857,
14541,
15,
184,
630,
53,
275,
14,
11100,
1,
23793,
12733,
1418,
20,
9392,
1997,
16,
7179,
2761,
60,
800,
3726,
3726,
19,
3857,
14541,
15,
504,
26370,
37,
40,
3010,
1637,
25480,
18,
2483,
101,
656,
45,
21,
1637,
25480,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Where is the Sliverlight Calendar Control
===
Just playing around with the now released Sliverlight 2.0. I'm trying to put a simple Calendar in a control. However the project doesn't seem to know what I'm talking about:-
<UserControl x:Class="MyFirstSL2.Test"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
>
<Grid Background="#FF5C7590">
<Calendar />
</Grid>
</UserControl>
Visual Studio 2008 just puts blue line under the Calendar saying the type Calendar not found. Do I need to add an assembly? Which one? Do I need to add another namespace to the Xaml?
| 0 | [
2,
113,
25,
14,
27890,
3130,
7036,
569,
800,
3726,
3726,
114,
791,
140,
29,
14,
130,
261,
27890,
3130,
172,
9,
387,
9,
31,
22,
79,
749,
20,
442,
21,
1935,
7036,
19,
21,
569,
9,
207,
14,
669,
1437,
22,
38,
2260,
20,
143,
98,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Parsing of nested tags in a file
===
I am wondering - What's the most effective way of parsing something like:
{{HEADER}}
Hello my name is {{NAME}}
{{#CONTENT}}
This is the content ...
{{#PERSONS}}
<p>My name is {{NAME}}.</p>
{{/PERSONS}}
{{/CONTENT}}
{{FOOTER}}
Of course this is intended to be somewhat of a templating system in the end, so my plan is to create a hashmap to "lay over" the template, as something like this
$hash = array(
'HEADER' => 'This is a header',
'NAME' => 'David',
'CONTENT' => array('PERSONS' => array(array('NAME' => 'Heino'), array('NAME' => 'Sebastian')),
'FOOTER' => 'This is the footer'
);
It's worth noticing that the "sections" (the tags that start with #), can be repeated more than once, and i think this is what trips me up ...
Also, any section can contain any number of other sections, and regular tags...
So.. how'd you do it? | 0 | [
2,
2017,
18,
68,
16,
5618,
69,
3383,
18,
19,
21,
3893,
800,
3726,
3726,
31,
589,
5712,
13,
8,
98,
22,
18,
14,
127,
3140,
161,
16,
2017,
18,
68,
301,
101,
45,
13,
1,
1743,
106,
1,
10975,
51,
204,
25,
13,
1,
7259,
1,
13,
1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Can someone post a well formed crossdomain.xml sample?
===
I've been reading that Adobe has made crossdomain.xml stricter in flash 9-10 and I'm wondering of someone can paste me a copy of one that they know works. Having some trouble finding a recent sample on Adobe's site. | 0 | [
2,
92,
737,
678,
21,
134,
843,
919,
537,
6232,
9,
396,
8184,
5717,
60,
800,
3726,
3726,
31,
22,
195,
74,
1876,
30,
20299,
63,
117,
919,
537,
6232,
9,
396,
8184,
8170,
106,
19,
4433,
561,
8,
1036,
17,
31,
22,
79,
5712,
16,
73... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
In Windows, what is the most reliable way to determine whether an application window is offscreen?
===
I am trying to debug a strange issue with users that have [Logemein][1] installed. After a few days, some of my dialogs that my app opens can end up offscreen. If I could reliable detect that, I could programmatically move the dialogs back where they are visible again.
Note: this has to work for multiple monitors and use the win32 API.
[1]: https://secure.logmein.com/home.asp | 0 | [
2,
19,
1936,
15,
98,
25,
14,
127,
11398,
161,
20,
3746,
1472,
40,
3010,
1463,
25,
168,
7187,
60,
800,
3726,
3726,
31,
589,
749,
20,
121,
16254,
21,
2578,
1513,
29,
3878,
30,
57,
636,
5567,
11025,
108,
500,
2558,
165,
500,
4066,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Manipulating the HTTP header in WCF before HTTP authentication in HttpBinding
===
This is in relation to [this question][1], with hopes of finding an answer.
I am hosting this WCF service in a custom service host. IIS is not an option.
Is there a way to inject an HTTP "Authenticate" header (if it's missing) early on in the request process - such that a "default" user can be passed into the authentication/authorization process that I have in place for anonymous requests?
See linked question for a bit of more clarity if needed.
I'm pretty sure I can do this with a custom BindingElement, or by extending the WebHttpBinding, but any examples or guidance would be greatly appreciated. I can't find any examples of early header manipulation (pre authentication) in WCF.
[1]: http://stackoverflow.com/questions/209795 | 0 | [
2,
27799,
14,
7775,
157,
106,
19,
11801,
410,
115,
7775,
27963,
19,
7775,
22260,
800,
3726,
3726,
48,
25,
19,
5827,
20,
636,
1565,
1301,
500,
2558,
165,
500,
15,
29,
8410,
16,
3007,
40,
1623,
9,
31,
589,
10637,
48,
11801,
410,
3... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do I center a JDialog on screen?
===
How do I go about positioning a JDialog at the center of the screen?
| 0 | [
2,
184,
107,
31,
459,
21,
487,
4286,
5567,
27,
2324,
60,
800,
3726,
3726,
184,
107,
31,
162,
88,
649,
68,
21,
487,
4286,
5567,
35,
14,
459,
16,
14,
2324,
60,
3,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
How do I pass a function as a parameter to in elisp?
===
I'm trying to pass one method to another in elisp, and then
have that method execute it. Here is an example:
(defun t1 ()
"t1")
(defun t2 ()
"t1")
(defun call-t (t)
; how do I execute "t"?
(t))
; How do I pass in method reference?
(call-t 't1)
| 0 | [
2,
184,
107,
31,
1477,
21,
1990,
28,
21,
18906,
20,
19,
8161,
3401,
60,
800,
3726,
3726,
31,
22,
79,
749,
20,
1477,
53,
2109,
20,
226,
19,
8161,
3401,
15,
17,
94,
57,
30,
2109,
15644,
32,
9,
235,
25,
40,
823,
45,
13,
5,
54... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
window.ScrollMaxY or X - How to set in FireFox 3?
===
window.scrollMaxY can be set via that property in IE and older versions of Firefox, but when trying in FF3 it says "Cannot set this property as it only has a getter".
What is my alternative? | 0 | [
2,
1463,
9,
3862,
8694,
8304,
93,
54,
993,
13,
8,
184,
20,
309,
19,
535,
18219,
203,
60,
800,
3726,
3726,
1463,
9,
3862,
8694,
8304,
93,
92,
44,
309,
1197,
30,
1354,
19,
13,
660,
17,
1234,
3281,
16,
535,
18219,
15,
47,
76,
7... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do I create a comma delimited string from an ArrayList?
===
I'm storing an ArrayList of Ids in a processing script that I want to spit out as a comma delimited list for output to the debug log. Is there a way I can get this easily without looping through things? | 0 | [
2,
184,
107,
31,
1600,
21,
11951,
58,
121,
23012,
3724,
37,
40,
7718,
5739,
60,
800,
3726,
3726,
31,
22,
79,
25615,
40,
7718,
5739,
16,
13,
9178,
19,
21,
5511,
3884,
30,
31,
259,
20,
9286,
70,
28,
21,
11951,
58,
121,
23012,
96... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
.NET AJAX 1.0 Aysc Callback Modifies Form Action
===
I have a web form that I am attempting to implement dynamic drop down lists on using the .NET AJAX 1.0 extensions. I have successfully implemented the needed bits, but have an interesting quirk.
When I select a value from my first drop down list, my call back happens and my page is updated correctly. The next value I select, I receive the following error:
> Sys.WebForms.PageRequestManagerServerErrorException:
> An unknown error occurred while
> processing the request on the server.
> The status code returned was: 404
Reguarless of what control I use first, the first request works and the second does not. Looking at my IIS logs, I see the following lines:
> 2008-10-17 14:52:14 W3SVC1 127.0.0.1
> POST
> /Aware/Xtend/mParticipant/NewPlannedService.aspx
> WIN=Participant_1224255079212&Title=Participant
> 80 - 127.0.0.1 200 0 0
> 2008-10-17
> 14:52:20 W3SVC1 127.0.0.1 POST
> /Aware/mParticipant/NewPlannedService.aspx
> WIN=Participant_1224255079212&Title=Participant
> 80 - 127.0.0.1 404 0 0
As you can see my post URL has completely changed. Using Fiddler to watch the request/response, I can see this in the response from the server:
> |formAction||NewPlannedService.aspx|
This is simply the name of the page that is being executed, the relative path and query string has been dropped off.
I can resolve this issue by adding the following to the end of my Async callback method:
this.Form1.Action = Request.Url.PathAndQuery
But this seems incredibly lame and smells somewhat like moldy cheese to me. Can any one point me in the right direction? | 0 | [
2,
13,
9,
2328,
20624,
137,
9,
387,
21,
93,
3862,
645,
1958,
7226,
12970,
505,
1028,
800,
3726,
3726,
31,
57,
21,
2741,
505,
30,
31,
589,
6314,
20,
8713,
7782,
2804,
125,
7227,
27,
568,
14,
13,
9,
2328,
20624,
137,
9,
387,
175... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
MMORPG Client/Server Coding
===
How are the UDP and TCP protocols used in MMORPG client/server communication?
For example:
Does the client broadcast (player position, etc) via UDP to the server? or vice versa?
Or is it more like using TCP where the Client requests that the server move the player. The server receives the request, moves the player and sends back to the client that the player is now at position xyz?
The chat channels must be implemented using TCP?
Are there any good articles/books on this? I've found bits and pieces but it seems the real meat and potatoes are won from experience. | 0 | [
2,
1620,
248,
9623,
6819,
118,
10321,
106,
13,
15458,
800,
3726,
3726,
184,
50,
14,
287,
7431,
17,
13,
38,
7439,
19957,
147,
19,
1620,
248,
9623,
6819,
118,
10321,
106,
3291,
60,
26,
823,
45,
630,
14,
6819,
1992,
13,
5,
14049,
6... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
ASP.NET 2.0 callbacks not working correctly in Firefox
===
I've implemented a .NET Web control that uses the callback structure implemented in ASP.Net 2.0. It's an autodropdown control, and it works correctly in IE 6.0/7.0 and Google Chrome. Here's the relevant callback function:
function ReceiveServerData(args, context)
{
document.getElementById(context).style.zIndex = 300;
document.getElementById(context).style.visibility = 'visible';
document.getElementById(context).innerHTML = args;
fixHover(context);
}
In Firefox, "args" is always the same data, so the innerHTML of the `<div>` that is the display for my dropdown always shows the same items. I've doublechecked my client-side code, and the right information is being sent client->server and in return server-> client.
Of note, in the "WebForm_DoCallback" function created by the .NET framework, the following snippet is getting called:
if (setRequestHeaderMethodExists) {
xmlRequest.onreadystatechange = WebForm_CallbackComplete;
callback.xmlRequest = xmlRequest;
xmlRequest.open("POST", theForm.action, true);
xmlRequest.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xmlRequest.send(postData);
return;
}
and the callback function ReceiveServerData is called both on `xmlRequest.open("POST", theForm.action, true);` and `xmlRequest.send(postData);`. I wonder if this is causing an error, but I'm at the end of my debugging skills. | 0 | [
2,
28,
306,
9,
2328,
172,
9,
387,
645,
1958,
18,
52,
638,
12044,
19,
535,
18219,
800,
3726,
3726,
31,
22,
195,
6807,
21,
13,
9,
2328,
2741,
569,
30,
2027,
14,
645,
1958,
1411,
6807,
19,
28,
306,
9,
2328,
172,
9,
387,
9,
32,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Flash developers: what versions of Flash do you test your stuff with?
===
I'm curious as to what versions of Flash stuff is tested with. How do you manage it across different browsers?
I'm wanting to test things with both swfdec and gnash and hoping maybe there's some way I didn't know about... | 0 | [
2,
4433,
10168,
45,
98,
3281,
16,
4433,
107,
42,
1289,
154,
3217,
29,
60,
800,
3726,
3726,
31,
22,
79,
7686,
28,
20,
98,
3281,
16,
4433,
3217,
25,
7631,
29,
9,
184,
107,
42,
4705,
32,
464,
421,
16495,
18,
60,
31,
22,
79,
463... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Sofware Requirements Analysis
===
There are many tools out there for writing and managing requirements, but are there any good ones out there for reviewing them?
I'm not talking about ***managing*** reviews, but automation tools that look for common requirement blunders (such as using negative requirements, or ones that are worded in a way to make testing difficult). More of a screening tool that someone writing requirements can use to screen their document before distributing to a group of reviewers so that the review process need not be slowed down by everyone commenting on the same easily recognizable issues. | 0 | [
2,
86,
410,
5011,
4786,
2495,
800,
3726,
3726,
80,
50,
151,
4672,
70,
80,
26,
1174,
17,
5616,
4786,
15,
47,
50,
80,
186,
254,
53,
18,
70,
80,
26,
18046,
105,
60,
31,
22,
79,
52,
1582,
88,
8980,
177,
7426,
2483,
1409,
2783,
1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Can Ruby really be used as a functional language?
===
Can Ruby really be used as a functional language? If yes then what are some good tutorials to teach this facet of the language? | 0 | [
2,
92,
10811,
510,
44,
147,
28,
21,
7652,
816,
60,
800,
3726,
3726,
92,
10811,
510,
44,
147,
28,
21,
7652,
816,
60,
100,
1643,
94,
98,
50,
109,
254,
29724,
18,
20,
5348,
48,
276,
38,
16,
14,
816,
60,
3,
0,
0,
0,
0,
0,
0,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
How can I fill in a Sharepoint List edit form offline using Windows Mobile 5.0 Quickly?
===
I need a method for a user to quickly enter info using a Handheld Symbol MC9090 scanner running windows Mobile 5.0 from a power off state
Currently it takes approx 1 min from power off state for user to enter data into a sharepoint list. I need to get the time down to seconds.
It takes approx 30secs for handheld to establish wireless connection and another 30 seconds for user to connect to server
Currently we have Symbol MC9090 scanners running windows Mobile 5.0. The user has to use terminal services to connect to a server were they then enter info. We use terminal services because mobile internet explorer doesn't work well with sharepoint forms we are using and is slow.
I have yet to find an easy method to create custom mobile forms for sharepoint lists.
Is it possible to create an app that would collect data on the mobile and when the wireless connection was active sync the local data with the server?
| 0 | [
2,
184,
92,
31,
3509,
19,
21,
1891,
3132,
968,
9392,
505,
168,
1143,
568,
1936,
3241,
331,
9,
387,
976,
60,
800,
3726,
3726,
31,
376,
21,
2109,
26,
21,
4155,
20,
976,
2830,
15404,
568,
21,
27406,
4678,
1324,
3165,
3165,
23195,
9... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Problem using the C# params keyword in a constructor using generic types.
===
I have a generic class in C# with 2 constructors:
public Houses(params T[] InitialiseElements)
{}
public Houses(int Num, T DefaultValue)
{}
Constructing an object using int as the generic type and passing in two ints as arguments causes the 'incorrect' constructor to be called (from my point of view).
E.g. Houses<int> houses = new Houses<int>(1,2) - calls the 2nd construtor. Passing in any other number of ints into the constructor will call the 1st constructor.
Is there any way around this other than removing the params keyword and forcing users to pass an array of T when using the first constructor? | 0 | [
2,
1448,
568,
14,
272,
5910,
2258,
79,
18,
1246,
9587,
19,
21,
6960,
248,
568,
12733,
2551,
9,
800,
3726,
3726,
31,
57,
21,
12733,
718,
19,
272,
5910,
29,
172,
6960,
248,
18,
45,
317,
1947,
5,
6351,
79,
18,
13,
38,
2558,
500,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do I make an already written concurrent program run on a GPU array?
===
I have a neural network written in Erlang, and I just bought a GeForce GTX 260 card with 240 GPUs on it. Is it trivial to use CUDA as glue to run this on the graphics card? | 0 | [
2,
184,
107,
31,
233,
40,
614,
642,
19513,
625,
485,
27,
21,
489,
4201,
7718,
60,
800,
3726,
3726,
31,
57,
21,
17371,
982,
642,
19,
13,
106,
9949,
15,
17,
31,
114,
2448,
21,
3168,
8774,
9509,
396,
13,
13675,
2056,
29,
13,
1060... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Inter-plugin communication in Eclipse
===
Is it possible to create Eclipse plugins that auto-discover eachother?
I am developing a set of plugins that need to operate in two primary situations:
* individually
* in concert with each other.
When run individually, the plugins should "just work" but when in concert, they will be sharing some of the same model content, and one of the plugins should present the user with a list of other plugins to share content with. eg:
> Foo Plugin detected the following
> plugins it can share ontologies with:
>
> [ ] Bar plugin
>
> [ ] Baz plugin
>
> [ ] Don't share
Does Eclipse offer any internal publication / detection methods that would facilitate this sort of auto-detection of other plugins?
| 0 | [
2,
1480,
8,
18527,
5831,
3291,
19,
11652,
800,
3726,
3726,
25,
32,
938,
20,
1600,
11652,
10922,
108,
18,
30,
3108,
8,
9752,
2549,
206,
9539,
60,
31,
589,
3561,
21,
309,
16,
10922,
108,
18,
30,
376,
20,
4055,
19,
81,
1256,
8329,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How can I reliably discover the full path of the Ruby executable?
===
I want to write a script, to be packaged into a gem, which will modify its parameters and then `exec` a new ruby process with the modified params. In other words, something similar to a shell script which modifies its params and then does an `exec $SHELL $*`. In order to do this, I need a robust way of discovering the path of the ruby executable which is executing the current script. I also need to get the full parameters passed to the current process - both the Ruby parameters and the script arguments. | 0 | [
2,
184,
92,
31,
13,
19003,
4801,
6297,
14,
503,
2013,
16,
14,
10811,
1396,
17194,
5924,
60,
800,
3726,
3726,
31,
259,
20,
2757,
21,
3884,
15,
20,
44,
6030,
43,
77,
21,
8551,
15,
56,
129,
17579,
82,
12905,
17,
94,
13,
1,
1706,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
XtraCharts Panes - Control Axis labels in code.
===
I am adding series and panes to a Developer's Express Chart Control in code on a windows form application. I would like to only show the x-axis labels for the first pane. The showInPanes property is telling me it is read only. How do I set this propert in code? | 0 | [
2,
993,
38,
9676,
13448,
1809,
160,
13,
8,
569,
8577,
13173,
19,
1797,
9,
800,
3726,
3726,
31,
589,
4721,
231,
17,
1809,
160,
20,
21,
10058,
22,
18,
2999,
1795,
569,
19,
1797,
27,
21,
1936,
505,
3010,
9,
31,
83,
101,
20,
104,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do I debug Resharper 4.0 add-ins?
===
Ok, I love Resharper and its addins, but even the best of fanbois have to admit that its API documentation is suboptimal. I'd like to build an addin myself (based on the <a href="http://code.google.com/p/agentjohnsonplugin/">Agent Johnson</a> plugin). Thankfully that plugin works in 4.0, so I can use it as a starting point for my own work.
My question: how do I run and debug the app? The resharper plugins are in the \v4.1\Bin\Plugins\ directory -- do I set my output directory to that folder, run it, then start another instance of Visual Studio? Or is there some other hack/workaround I should try? | 0 | [
2,
184,
107,
31,
121,
16254,
302,
23646,
106,
268,
9,
387,
3547,
8,
108,
18,
60,
800,
3726,
3726,
5854,
15,
31,
339,
302,
23646,
106,
17,
82,
3547,
108,
18,
15,
47,
166,
14,
246,
16,
2514,
14359,
57,
20,
5251,
30,
82,
21,
21... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Excel VBA Load Addins
===
I am trying to create a new instance of Excel using VBA using:
Set XlApp = New Excel.Application
The problem is that this new instance of Excel doesn't load all the addins that load when I open Excel normally...Is there anything in the Excel Application object for loading in all the user-specified addins? | 0 | [
2,
20700,
566,
969,
6305,
3547,
108,
18,
800,
3726,
3726,
31,
589,
749,
20,
1600,
21,
78,
4851,
16,
20700,
568,
566,
969,
568,
45,
309,
993,
531,
3421,
800,
78,
20700,
9,
2552,
20669,
14,
1448,
25,
30,
48,
78,
4851,
16,
20700,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Open-source improvements or replacements for Swing components
===
I develop a number of desktop Java applications using Swing, and while Swing is quite powerful (once you get the hang of it), there are still a lot of cases where I wish some advanced component was available right out of the box.
For example, I'd really like to see easy-to-use components (without writing them myself, which I could do given enough time) like:
* Multi-line label
* Windows File Explorer-like Icons or Thumbnails view
* Drop-down button (like Firefox's old Back button)
* 5-star rating widget
* Combo box with automatic history (like the text field on Google)
* An Outlook-style accordion-style bar
* and so on
I know of a couple of sources of free Swing components, like <a href="http://swinglabs.org">SwingLabs</a>, home of JXTable, JXDatePicker, and a few others.
**Where do you go for Swing components beyond those included with Java itself?**
| 0 | [
2,
368,
8,
12097,
7951,
54,
4610,
18,
26,
5587,
5090,
800,
3726,
3726,
31,
2803,
21,
234,
16,
17404,
8247,
3767,
568,
5587,
15,
17,
133,
5587,
25,
1450,
2177,
13,
5,
13120,
42,
164,
14,
4546,
16,
32,
6,
15,
80,
50,
174,
21,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
The necesity of hiding the salt for a hash
===
At work we have two competing theories for salts. The products I work on use something like a user name or phone number to salt the hash. Essentially something that is different for each user but is readily available to us. The other product randomly generates a salt for each user and changes each time the user changes the password. The salt is then encrypted in the database.
My question is if the second approach is really necessary? I can understand from a purely theoretical perspective that it is more secure than the first approach, but what about from a practicality point of view. Right now to authenticate a user, the salt must be unencrypted and applied to the login information.
After thinking about it, I just don't see a real security gain from this approach. Changing the salt from account to account, still makes it extremely difficult for someone to attempt to brute force the hashing algorithm even if the attacker was aware of how to quickly determine what it was for each account. This is going on the assumption that the passwords are sufficiently strong. (Obviously finding the correct hash for a set of passwords where they are all two digits is significantly easier than finding the correct hash of passwords which are 8 digits). Am I incorrect in my logic, or is there something that I am missing? | 0 | [
2,
14,
19724,
160,
856,
16,
5314,
14,
2693,
26,
21,
19170,
800,
3726,
3726,
35,
170,
95,
57,
81,
5649,
7761,
26,
2693,
18,
9,
14,
1985,
31,
170,
27,
275,
301,
101,
21,
4155,
204,
54,
1132,
234,
20,
2693,
14,
19170,
9,
7398,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
When it says put crossdomain.xml in the root where would that be on IIS?
===
Would it be wwwroot, C, the root virtual directory where the assets are hosted, or the same folder that the assets are in?
Meaning if I have a virtual directory 'virdir' with a sub directory 'swf', which is really like C:\somedir\assets\swf\, where would the crossdomain.xml need to go so that my swf app on a different server can access the swfs? | 0 | [
2,
76,
32,
898,
442,
919,
537,
6232,
9,
396,
8184,
19,
14,
5900,
113,
83,
30,
44,
27,
595,
18,
60,
800,
3726,
3726,
83,
32,
44,
13,
6483,
14032,
15,
272,
15,
14,
5900,
6599,
16755,
113,
14,
6223,
50,
2812,
15,
54,
14,
205,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
What is the Win32 API function to use to delete a folder?
===
What are the Win32 APIs to use to programically delete files and folders? | 0 | [
2,
98,
25,
14,
628,
3125,
21,
2159,
1990,
20,
275,
20,
27448,
21,
19294,
60,
800,
3726,
3726,
98,
50,
14,
628,
3125,
21,
8954,
20,
275,
20,
625,
8438,
27448,
6488,
17,
19294,
18,
60,
3,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
How to export a flat file with different rows using SSIS?
===
I have tree tables, Customer, Invoice and InvoiceRow with the standard relations.
These I have to export in one fixed field length file with the first two characters of each row identifying the row type. The row types have different specifications.
I could probably do it with a nested loop in a script block, but this is my first ever SSIS package and that solution feels wrong.
/johan/ | 0 | [
2,
184,
20,
7487,
21,
1844,
3893,
29,
421,
11295,
568,
13,
18,
4557,
60,
800,
3726,
3726,
31,
57,
1541,
7484,
15,
7705,
15,
19,
13379,
17,
19,
13379,
5417,
29,
14,
1236,
2649,
9,
158,
31,
57,
20,
7487,
19,
53,
3535,
575,
1476,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do you pass an array of string through an event in an Interop User Control to vb6
===
I have a VB.net control that has an event:
Public Event PassNames(ByVal names() as String)
When the event triggered in VB6, I get the following error:
*"Function or interface marked as restriced, or the function uses an Automation type not supported in Visual Basic"*
Here is the event in VB6:
Private Sub IteropControl1_PassNames(ByVal names() As String)
MsgBox "I don't work"
End Sub
**Is there a way to uses arrays with Interop User Controls?**
| 0 | [
2,
184,
107,
42,
1477,
40,
7718,
16,
3724,
120,
40,
807,
19,
40,
1480,
2594,
4155,
569,
20,
13,
20468,
379,
800,
3726,
3726,
31,
57,
21,
13,
20468,
9,
2328,
569,
30,
63,
40,
807,
45,
317,
807,
1477,
7259,
18,
5,
779,
3377,
1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Inject dependencies in methods or in the constructor?
===
Dependency injection seems to be a good thing. In general, should dependencies be injected at the methods that require them, or should they be injected in the contructor of the class?
See the samples below to demonstrate the two ways to inject the same dependency.
//Inject the dependency into the methods that require ImportantClass
Class Something {
public Something()
{
//empty
}
public void A()
{
//do something without x
}
public void B(ImportantClass x)
{
//do something with x
}
public void C(ImportantClass x)
{
//do something with x
}
}
//Inject the dependency into the constructor once
Class Something {
private ImportantClass _x
public Something(ImportantClass x)
{
this._x = x;
}
public void A()
{
//do something without x
}
public void B()
{
//do something with this._x
}
public void C()
{
//do something with this._x
}
}
| 0 | [
2,
20316,
29411,
19,
3195,
54,
19,
14,
6960,
248,
60,
800,
3726,
3726,
26835,
13646,
2206,
20,
44,
21,
254,
584,
9,
19,
297,
15,
378,
29411,
44,
23256,
35,
14,
3195,
30,
4077,
105,
15,
54,
378,
59,
44,
23256,
19,
14,
1065,
898... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Translate C# code into AST?
===
Is it currently possible to translate C# code into an Abstract Syntax Tree? | 0 | [
2,
20628,
272,
5910,
1797,
77,
28,
38,
60,
800,
3726,
3726,
25,
32,
871,
938,
20,
20628,
272,
5910,
1797,
77,
40,
8502,
22649,
1541,
60,
3,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
Programmatically Adding User Controls Inside An UpdatePanel
===
I'm having trouble dynamically adding controls inside an update panel with partial postbacks. I've read many articles on dynamic controls and I understand how to add and maintain them with postbacks but most of that information doesn't apply and won't work for partial postbacks. I can't find any useful information about adding and maintaining them with UpdatePanels. I'd like to do this without creating a web service if it's possible. Does anyone have any ideas or references to some helpful information? | 0 | [
2,
625,
6732,
1326,
4721,
4155,
8671,
572,
40,
11100,
3206,
532,
800,
3726,
3726,
31,
22,
79,
452,
2572,
7782,
1326,
4721,
8671,
572,
40,
11100,
4113,
29,
7284,
678,
1958,
18,
9,
31,
22,
195,
1302,
151,
3376,
27,
7782,
8671,
17,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Selenium RC: Run tests in multiple browsers automatically
===
So, I've started to create some Ruby unit tests that use [Selenium RC][1] to test my web app directly in the browser. I'm using the [Selenum-Client][2] for ruby. I've created a base class for all my other selenium tests to inherit from.
This creates numerous SeleniumDriver instances and all the methods that are missing are called on each instance. This essentially runs the tests in parallel.
**How have other people automated this?**
This is my implementation:
class SeleniumTest < Test::Unit::TestCase
def setup
@seleniums = %w(*firefox *iexplore).map do |browser|
puts 'creating browser ' + browser
Selenium::SeleniumDriver.new("localhost", 4444, browser, "http://localhost:3003", 10000)
end
start
open start_address
end
def teardown
stop
end
#sub-classes should override this if they want to change it
def start_address
"http://localhost:3003/"
end
# Overrides standard "open" method
def open(addr)
method_missing 'open', addr
end
# Overrides standard "type" method
def type(inputLocator, value)
method_missing 'type', inputLocator, value
end
# Overrides standard "select" method
def select(inputLocator, optionLocator)
method_missing 'select', inputLocator, optionLocator
end
def method_missing(method_name, *args)
@seleniums.each do |selenium_driver|
if args.empty?
selenium_driver.send method_name
else
selenium_driver.send method_name, *args
end
end
end
end
This works, but if one browser fails, the whole test fails and there is no way to know which browser it failed on.
[1]: http://selenium-rc.openqa.org/
[2]: http://github.com/ph7/selenium-client/tree/master | 0 | [
2,
23027,
14311,
16462,
45,
485,
4894,
19,
1886,
16495,
18,
7499,
800,
3726,
3726,
86,
15,
31,
22,
195,
373,
20,
1600,
109,
10811,
1237,
4894,
30,
275,
636,
18,
20110,
2187,
16462,
500,
2558,
165,
500,
20,
1289,
51,
2741,
4865,
17... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Outsourcing and your job.
===
Has outsourcing had an impact on your job? Good or bad. I for one have had terrible experiences with having to maintain code that was outsourced. On things that are less than trivial, does it really save money in the long run? | 2 | [
2,
70,
27028,
17,
154,
1205,
9,
800,
3726,
3726,
63,
70,
27028,
41,
40,
2261,
27,
154,
1205,
60,
254,
54,
896,
9,
31,
26,
53,
57,
41,
5803,
5513,
29,
452,
20,
4027,
1797,
30,
23,
70,
12097,
43,
9,
27,
564,
30,
50,
787,
119... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0... |
python threadsafe object cache
===
I have implemented a python webserver. Each http request spawns a new thread.
I have a requirement of caching objects in memory and since its a webserver, I want the cache to be thread safe. Is there a standard implementatin of a thread safe object cache in python? I found the following
http://freshmeat.net/projects/lrucache/
This does not look to be thread safe. Can anybody point me to a good implementation of thread safe cache in python?
Thanks! | 0 | [
2,
20059,
9322,
18166,
3095,
16522,
800,
3726,
3726,
31,
57,
6807,
21,
20059,
2741,
10321,
106,
9,
206,
7775,
3772,
13,
22860,
18,
21,
78,
9322,
9,
31,
57,
21,
8981,
16,
1658,
7192,
3916,
19,
1912,
17,
179,
82,
21,
2741,
10321,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Javascript maximum length of window.returnValue
===
Is there a maximum length when using window.returnValue (variant) in a modal?
I am calling a modal window using showModalDialog() and returning a comma delimited string. After selecting a group of users, I am putting them into a stringbuilder to display in a literal.
Dim strReturn As New StringBuilder
strReturn.Append("<script type=""text/javascript"">window.returnValue='")
Dim strUsers As New StringBuilder
For Each dtRow As DataRow In GetSelectedUserTable.Rows
If strUsers.ToString.Length > 0 Then
strUsers.Append(",")
End If
strUsers.Append(dtRow("UserID"))
Next
strReturn.Append(strUsers.ToString)
strReturn.Append("';window.close();</script>")
litReturnJavascript.Text = strReturn.ToString
So would there be a limit on how many characters can be added to the window.returnValue? | 0 | [
2,
8247,
8741,
2979,
1476,
16,
1463,
9,
24632,
15165,
800,
3726,
3726,
25,
80,
21,
2979,
1476,
76,
568,
1463,
9,
24632,
15165,
13,
5,
18445,
6,
19,
21,
13,
20756,
60,
31,
589,
2555,
21,
13,
20756,
1463,
568,
298,
20756,
4286,
55... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Separating client side logic from server side logic in a reusable way using MVC
===
Before you answer, this question is complicated:
1. We are developing in asp.net / asp.net mvc / jQuery but I'm open to solutions on any platform using any framework
2. I think logic like sorting / hiding columns / re-arranging columns / validation (where it makes sense) should be on the client-side
3. I think logic like searching / updating the db / running workflows should be on the server side (just because of security / debugging reasons)
What we are trying to do is **NOT CREATE A MESS** in our UI by writing a bunch of javascript to deal with the same feature in different contexts. I understand that I can use a javascript file + object oriented javascript, I'm looking for the pattern that makes it all easier.
One solution proposed was to have an MVC model on both the client and server side, where we can encapsulate javascript functionality in client side controllers, then use them in different parts of the site. However, this means that we have 2 MVC implementations!
Is this overkill? How would you expand on this solution? What other solutions are there?
| 0 | [
2,
16880,
6819,
270,
7085,
37,
8128,
270,
7085,
19,
21,
302,
267,
579,
161,
568,
307,
8990,
800,
3726,
3726,
115,
42,
1623,
15,
48,
1301,
25,
8343,
45,
137,
9,
95,
50,
3561,
19,
28,
306,
9,
2328,
13,
118,
28,
306,
9,
2328,
3... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
"Pivoting" a Table in SQL
===
I'm working on trying to generate a report from a couple of database tables. The simplified version looks like this
--------
Table = Campaign
CampaignID
Table = Source
Source_ID | Campaign_ID
Table = Content
Content_ID | Campaign_ID | Content_Row_ID | Content_Value
--------
The report needs to read like this:
CampaignID - SourceID - ContentRowID(Value(A)) - ContentRowID(Value(B))
Where ContentRowID(Value(A)) means "Find a row the has a given CampaignID, and a ContentRowId of "A" and then get the ContentValue for that row"
Essentially, I have to "pivot" (I think that's the correct term) the rows into columns...
It's an Oracle 10g database...
Any suggestions?
| 0 | [
2,
13,
7,
306,
7852,
1203,
7,
21,
859,
19,
4444,
255,
800,
3726,
3726,
31,
22,
79,
638,
27,
749,
20,
7920,
21,
1330,
37,
21,
1335,
16,
6018,
7484,
9,
14,
13,
11268,
615,
1879,
101,
48,
13,
8,
8,
8,
8,
8,
8,
8,
8,
859,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
bring a console window to front in c#
===
How can I bring a console application window to front in C# (especially when running the Visual Studio debugger)? | 0 | [
2,
1499,
21,
8650,
1463,
20,
431,
19,
272,
5910,
800,
3726,
3726,
184,
92,
31,
1499,
21,
8650,
3010,
1463,
20,
431,
19,
272,
5910,
13,
5,
12183,
76,
946,
14,
3458,
1120,
121,
2345,
11356,
6,
60,
3,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
A good multithreaded python webserver?
===
I am looking for a python webserver which is multithreaded instead of being multi-process (as in case of mod_python for apache). I want it to be multithreaded because I want to have an in memory object cache that will be used by various http threads. My webserver does a lot of expensive stuff and computes some large arrays which needs to be cached in memory for future use to avoid recomputing. This is not possible in a multi-process web server environment. Storing this information in memcache is also not a good idea as the arrays are large and storing them in memcache would lead to deserialization of data coming from memcache apart from the additional overhead of IPC.
I implemented a simple webserver using BaseHttpServer, it gives good performance but it gets stuck after a few hours time. I need some more matured webserver. Is it possible to configure apache to use mod_python under a thread model so that I can do some object caching? | 0 | [
2,
21,
254,
1889,
96,
10647,
69,
20059,
2741,
10321,
106,
60,
800,
3726,
3726,
31,
589,
699,
26,
21,
20059,
2741,
10321,
106,
56,
25,
1889,
96,
10647,
69,
700,
16,
142,
1889,
8,
16835,
13,
5,
472,
19,
610,
16,
7226,
1,
6448,
1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
VMWARE ESXi PANIC: Failed to find HD boot partition
===
I've got problems installating the VMWARE ESXi Server.
The Installation finishes without any error messages and prompts me to reboot.
After pressing Enter the System reboots. While booting through the yellow loading-screen it switches to black and displays the following Error-Message:
PANIC: Failed to find HD boot partition
All modules have been loaded without any errors.
After typing unsupported into the console the busybox comes up.
I tooked a look into the /dev/disks directory but no disk devices gets listed in difference to the installation process.
Switching to the system-console during installation both sata disks on MPC51 controller are shown.
The controllers are named vmhba0 and vmhba32.
Does anyone know how to solve the problem?!
Hardware is a ESPRIMO P5615 (nForce4) from Fujitsu-Siemens.
![Error message shown while bootup after installation][1]
![Display after switching to the debug screen ALT+F12][2]
[1]: http://wg1337.de/img/17.10.jpg "Error message shown while bootup after installation"
[2]: http://wg1337.de/img/17.11.jpg "Display after switching to the debug screen ALT+F12" | 0 | [
2,
13,
20147,
5011,
13,
160,
5845,
5083,
45,
1702,
20,
477,
8590,
6801,
10711,
800,
3726,
3726,
31,
22,
195,
330,
1716,
16146,
1880,
14,
13,
20147,
5011,
13,
160,
5845,
8128,
9,
14,
7758,
13625,
366,
186,
7019,
7561,
17,
11443,
13... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Good file management software
===
Currently all our files are stored on a windows network drive and with 15 members of staff and 3 external workers, file control is beggining to get a bit of nightmare. Even though we have a policy in place people still seem to save file to their pcs, make changes copy them back without notifying anyone, send files via email instead of its location and create folders/structures which only make sense to them.
Consequently on a recent project we found that 3 members of staff were using different versions of the same document and when those 3 people are editors and proof readers, you can probably imagine the problem that ensued in the end.
So we are looking for some nice simple file management apps. MS sharepoint has been mentioned but we are looking to get away from being tied to a windows machine, and the cost of setup etc seems expensive particularly for a non profit company. Also it seems sharepoint maybe a little OTT for our needs.
All we need is something that can be used to store and control files, allows different user access, can provide basic versioning and something that can hopefully be accessible through a web-browser so our remote workers can access it. we are not keen on SAAS solution because of the nature of our confidentiality and also because we use these files all day everyday and the internet connection does go down from time to time. We want to be able to install inhouse.
Ideally OSS although we will consider buying software if it meeets our needs.
| 0 | [
2,
254,
3893,
1097,
2306,
800,
3726,
3726,
871,
65,
318,
6488,
50,
8214,
27,
21,
1936,
982,
1493,
17,
29,
357,
443,
16,
1138,
17,
203,
4886,
2004,
15,
3893,
569,
25,
44,
19086,
2981,
20,
164,
21,
1142,
16,
10586,
9,
166,
362,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
how much does facebook denormalize their databases to break things up by network and therefore shrink the tables and speed the system?
===
any bit of info will be helpful here. or does anybody else huge do something interesting here too? | 0 | [
2,
184,
212,
630,
9090,
121,
17462,
2952,
66,
6018,
18,
20,
1442,
564,
71,
34,
982,
17,
1793,
16269,
14,
7484,
17,
1362,
14,
329,
60,
800,
3726,
3726,
186,
1142,
16,
15404,
129,
44,
15600,
235,
9,
54,
630,
11181,
962,
2329,
107,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
What is the alternative to java.net.URLEncoder.encode?
===
I get the following warning when using `java.net.URLEncoder.encode`:
<pre>warning: [deprecation] encode(java.lang.String) in java.net.URLEncoder has been deprecated</pre>
What should I be using instead?
| 0 | [
2,
98,
25,
14,
2676,
20,
8247,
9,
2328,
9,
911,
2284,
716,
1157,
9,
219,
9375,
60,
800,
3726,
3726,
31,
164,
14,
249,
3590,
76,
568,
13,
1,
1004,
1385,
9,
2328,
9,
911,
2284,
716,
1157,
9,
219,
9375,
1,
45,
13,
1,
3515,
1,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Is it possible to pass a App setting in the web.config to a Common C# class
===
Is it possible to pass a App setting "string" in the web.config to a Common C# class? | 0 | [
2,
25,
32,
938,
20,
1477,
21,
4865,
2697,
19,
14,
2741,
9,
14093,
2816,
20,
21,
757,
272,
5910,
718,
800,
3726,
3726,
25,
32,
938,
20,
1477,
21,
4865,
2697,
13,
7,
11130,
7,
19,
14,
2741,
9,
14093,
2816,
20,
21,
757,
272,
59... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
Most memory efficient way for searching within a string in C
===
What is the most memory efficient way to search within a string in ANSI C? (put the code up)
An example where this is needed is in embedded devices that are very short on available memory but nowadays have reasonable clock cycles. | 0 | [
2,
127,
1912,
8243,
161,
26,
5792,
363,
21,
3724,
19,
272,
800,
3726,
3726,
98,
25,
14,
127,
1912,
8243,
161,
20,
2122,
363,
21,
3724,
19,
40,
18,
49,
272,
60,
13,
5,
4881,
14,
1797,
71,
6,
40,
823,
113,
48,
25,
851,
25,
1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
centering text in common lisp
===
I have a string that I would like to print . Is it possible to center it when printing ? | 0 | [
2,
459,
68,
1854,
19,
757,
2093,
3401,
800,
3726,
3726,
31,
57,
21,
3724,
30,
31,
83,
101,
20,
4793,
13,
9,
25,
32,
938,
20,
459,
32,
76,
7312,
13,
60,
3,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
How can I check MySQL engine type for a specific table?
===
My MySQL database contains several tables using different storage engines
(specifically myisam and innodb). How can I find out which tables are
using which engine? | 0 | [
2,
184,
92,
31,
2631,
51,
18,
22402,
1406,
1001,
26,
21,
1903,
859,
60,
800,
3726,
3726,
51,
51,
18,
22402,
6018,
1588,
238,
7484,
568,
421,
4326,
4016,
13,
5,
9219,
1326,
51,
49,
6101,
17,
19,
251,
9007,
6,
9,
184,
92,
31,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0... |
What is the most common mistake you make while writing unit tests?
===
What is the one most common mistake you make while writing unit tests? Coupling? Lack of cohesion? Try to test too much functionality at once? Not testing enough functionality?
Post some example code if you have an example of that mistake | 0 | [
2,
98,
25,
14,
127,
757,
5643,
42,
233,
133,
1174,
1237,
4894,
60,
800,
3726,
3726,
98,
25,
14,
53,
127,
757,
5643,
42,
233,
133,
1174,
1237,
4894,
60,
20920,
60,
1792,
16,
326,
438,
5991,
60,
1131,
20,
1289,
266,
212,
18548,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How can I convert a SSL certificate from PEM to DER and keep the private key?
===
Backstory: I have a PKCS#12 (p12) certificate with a symmetric cipher (password) that I used OpenSSL to convert to a PEM; opening that as text I see it contains both a `BEGIN/END CERTIFICATE` section as well as `BEGIN/END RSA PRIVATE KEY`. The .NET Framework `X509Certificate` class only supports the "ASN.1 DER" format, so I used OpenSSL to convert the PEM to DER. Unfortunately it appears doing this doesn't include the private key which is what I need for making an SSL connection with `SslStream` & `TcpClient`.
X509CertificateCollection certsFromFile = new X509CertificateCollection();
X509Certificate2 cert = new X509Certificate2("my.der.crt");
if (!cert.HasPrivateKey)
throw new Exception("No private key");
certsFromFile.Add(cert);
TcpClient tcpclient = new TcpClient(hostname, port);
SslStream sslstream = new SslStream(tcpclient.GetStream(), false,
null, null);
sslstream.AuthenticateAsClient(hostname, certsFromFile,
SslProtocols.Ssl3, false);
sslstream.Close();
tcpclient.Close();
How do I take this PEM file and make it into a DER while retaining the private key information so I can use it in .NET for signing? | 0 | [
2,
184,
92,
31,
8406,
21,
13,
18,
18,
255,
6259,
37,
24800,
20,
2223,
17,
643,
14,
932,
1246,
60,
800,
3726,
3726,
97,
4416,
45,
31,
57,
21,
13,
17244,
6824,
5910,
918,
13,
5,
306,
918,
6,
6259,
29,
21,
13,
16367,
23525,
13,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Which is better for a rails site? /{login} or /user/{login}
===
Which is better (for the user, for longevity, for performance, for whatever) to have:
http://{site}/{login} e.g. http://wildobs.com/adam_jack
or
http://{site}/user/{login}
Pros of former:
- User feels more special.
- URLs are shorter.
Cons of former:
- Cannot have users w/ logins matching keywords, and keywords likely grow over time.
Clearly this is important to get right (or get wrong and stick to) since all user define URLs are based off it. Changing it would seem site suicide.
Do the cons (especially over time) outweigh the pros? | 0 | [
2,
56,
25,
574,
26,
21,
2240,
18,
689,
60,
13,
118,
1,
5567,
108,
1,
54,
13,
118,
16704,
118,
1,
5567,
108,
1,
800,
3726,
3726,
56,
25,
574,
13,
5,
1106,
14,
4155,
15,
26,
28089,
15,
26,
956,
15,
26,
2099,
6,
20,
57,
45,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Relative instead of Absolute paths in Excel VBA
===
I have written an Excel VBA macro which imports data from a HTML file (stored locally) before performing calculations on the data.
At the moment the HTML file is referred to with an absolute path:
Workbooks.Open FileName:="C:\Documents and Settings\Senior Caterer\My Documents\Endurance Calculation\TRICATEndurance Summary.html"
However I want to use a relative path to refer to it as opposed to absolute (this is because I want to distribute the spreadsheet to colleagues who might not use the same folder structure). As the html file and the excel spreadsheet sit in the same folder I would not have thought this would be difficult, however I am just completely unable to do it. I have searched on the web and the suggested solutions have all appeared very complicated.
I am using Excel 2000 and 2002 at work, but as I plan to distribute it I would want it to work with as many versions of Excel as possible.
Any suggestions gratefully received. | 0 | [
2,
4543,
700,
16,
7070,
12074,
19,
20700,
566,
969,
800,
3726,
3726,
31,
57,
642,
40,
20700,
566,
969,
9069,
56,
20617,
1054,
37,
21,
13,
15895,
3893,
13,
5,
16828,
43,
6680,
6,
115,
2955,
19186,
27,
14,
1054,
9,
35,
14,
688,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Retrieving Attribute name's of an Entity in MS CRM 4.0
===
I am back again with another question on ms crm.
The latest thing i am trying to do is retrieve the attribute name and type that exist in an entity, Dynamic Entity to be precise. I have the following code.
DynamicEntity contactEntity = new DynamicEntity();
contactEntity.Name = EntityName.contact.ToString();
Property t = null;
foreach (Property prop_Test in contactEntity.Properties)
{
Response.Write("<br/>Name : " + prop_Test.Name.ToString());
}
I am getting the properties count as 0. Is it mandatory for me to pass an id to the contact entity. Because i am trying to map attributes from the entity to the attributes i get from an excel file. The end user themselves would be doing the mapping so all i need are the attribute name and type and nothing else. For instance in SQL we have the query
SELECT * FROM TABLE_NAME WHERE 1 <> 1
This query basically returns and empty resultset with only the fieldnames. That is what i am looking for here. Is it even possible ? | 0 | [
2,
13,
6239,
3272,
8397,
35,
14755,
204,
22,
18,
16,
40,
9252,
19,
4235,
6186,
79,
268,
9,
387,
800,
3726,
3726,
31,
589,
97,
188,
29,
226,
1301,
27,
4235,
6186,
79,
9,
14,
5736,
584,
31,
589,
749,
20,
107,
25,
11917,
14,
35... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
What are some good open source MySQL GUI's for the PC?
===
I mainly use CocoaMySQL and YourSQL on the Mac, but I am looking for suggestions for the PC, in which I can connect to the database and manage it using the interface. | 4 | [
2,
98,
50,
109,
254,
368,
1267,
51,
18,
22402,
9457,
22,
18,
26,
14,
5168,
60,
800,
3726,
3726,
31,
2011,
275,
24507,
915,
18,
22402,
17,
154,
18,
22402,
27,
14,
1572,
15,
47,
31,
589,
699,
26,
18389,
26,
14,
5168,
15,
19,
5... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... |
Buffered Multipart Form Posts in Ruby
===
I am currently using `Net::HTTP` in a Ruby script to post files to a website via a multipart form post. It works great for small files, but I frequently have to send very large files using this script, and `HTTP#post` only seems to accept post data as a `String` object, which means that the file I'm sending has to be read into memory before anything can be sent. This script is running on a busy production server, so it's unacceptable to gobble up hundreds of megabytes of RAM just to send a file.
Ideally, there'd be a method that could be given a buffer size and an `IO` object, and would send off buffer-sized chunks of data, reading from the `IO` object only as required. What would be the best way to make this happen? Did I miss something relevant in `Net::HTTP`? | 0 | [
2,
17497,
69,
1889,
3091,
505,
9868,
19,
10811,
800,
3726,
3726,
31,
589,
871,
568,
13,
1,
2328,
45,
45,
21127,
1,
19,
21,
10811,
3884,
20,
678,
6488,
20,
21,
2271,
1197,
21,
1889,
3091,
505,
678,
9,
32,
693,
374,
26,
284,
648... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Can the working set of a managed app be reduced by unloading unmanaged libraries with AfxFreeLibrary?
===
I have a managed Windows application that loads a managed C++ component that uses AfxLoadLibrary to load a third party component if present on the client machine. Once detected, I'm unloading the component using AfxFreeLibrary in an attempt to lower the working set of the managed parent application.
The call to AfxFreeLibrary is successful (verified using Process Explorer), but no memory is freed up. Is this due to the nature of a managed application, or is there a way to free up this process space?
I'm not looking for alternative ways to tackle this problem in general, since the code is already in production, rather I would like to find out if the approach of unloading is worthwhile. | 0 | [
2,
92,
14,
638,
309,
16,
21,
1471,
4865,
44,
2736,
34,
367,
16866,
367,
177,
8030,
8649,
29,
21,
16488,
4639,
1210,
2559,
622,
60,
800,
3726,
3726,
31,
57,
21,
1471,
1936,
3010,
30,
19069,
21,
1471,
272,
20512,
5912,
30,
2027,
2... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How to convert a C string (char *) into a Python string?
===
I have embedded a Python interpreter in a C program. Suppose the C program reads ISO 8859-1 encoded text from a file into a char * buffer. How do I obtain a Python string (of type str or unicode) from the char *?
I have attempted to use PyString_Decode, but it always fails when there are non-ASCII characters in the string. Here is an example that fails:
#include <Python.h>
#include <stdio.h>
int main(int argc, char *argv[])
{
char c_string[] = { (char)0xf8, 0 };
PyObject *py_string;
Py_Initialize();
py_string = PyString_Decode(c_string, 1, "latin_1", "replace");
if (!py_string) {
printf("PyString_Decode failed.\n");
return 1;
}
return 0;
}
| 0 | [
2,
184,
20,
8406,
21,
272,
3724,
13,
5,
5433,
1637,
6,
77,
21,
20059,
3724,
60,
800,
3726,
3726,
31,
57,
12138,
21,
20059,
19336,
19,
21,
272,
625,
9,
5787,
14,
272,
625,
11137,
11899,
8746,
3902,
8,
165,
13665,
1854,
37,
21,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Where do I plug in into WCF to be notified when a message arrives?
===
I'm writing a sample console service host and I want to plug into WCF stack to be able to print a message to console when new message arrives, even if it won't get processed by the service at the moment (because service is working on previous calls).
This is based on my assumption that messages arriving get queued by the WCF, is that correct?
Additionally, I'm using netTcpBinding if this is important. | 0 | [
2,
113,
107,
31,
10922,
19,
77,
11801,
410,
20,
44,
22904,
76,
21,
2802,
8394,
60,
800,
3726,
3726,
31,
22,
79,
1174,
21,
5717,
8650,
365,
2015,
17,
31,
259,
20,
10922,
77,
11801,
410,
7566,
20,
44,
777,
20,
4793,
21,
2802,
20... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Where is the best place to locate enum types?
===
I have found that there is generally a singe type or namespace that takes in any particular enum as a parameter and as a result I have always defined those enums there. Recently though, I had a co-worker make a big deal about how that was a stupid thing to do, and you should always have an enum namespace at the root of your project where you define everyone of your enum types.
Where is the best place to locate enum types? | 0 | [
2,
113,
25,
14,
246,
209,
20,
12717,
1957,
723,
2551,
60,
800,
3726,
3726,
31,
57,
216,
30,
80,
25,
1469,
21,
4481,
62,
1001,
54,
204,
5582,
30,
1384,
19,
186,
1498,
1957,
723,
28,
21,
18906,
17,
28,
21,
829,
31,
57,
550,
28... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do C# Events work behind the scenes?
===
I'm using C#, .NET 3.5. I understand how to utilize events, how to declare them in my class, how to hook them from somewhere else, etc. A contrived example:
public class MyList
{
private List<string> m_Strings = new List<string>();
public EventHandler<EventArgs> ElementAddedEvent;
public void Add(string value)
{
m_Strings.Add(value);
if (ElementAddedEvent != null)
ElementAddedEvent(value, EventArgs.Empty);
}
}
[TestClass]
public class TestMyList
{
private bool m_Fired = false;
[TestMethod]
public void TestEvents()
{
MyList tmp = new MyList();
tmp.ElementAddedEvent += new EventHandler<EventArgs>(Fired);
tmp.Add("test");
Assert.IsTrue(m_Fired);
}
private void Fired(object sender, EventArgs args)
{
m_Fired = true;
}
}
However, what I do *not* understand, is when one declares an event handler
public EventHandler<EventArgs> ElementAddedEvent;
It's never initialized - so what, exactly, is ElementAddedEvent? What does it point to? The following won't work, because the EventHandler is never initialized:
[TestClass]
public class TestMyList
{
private bool m_Fired = false;
[TestMethod]
public void TestEvents()
{
EventHandler<EventArgs> somethingHappend;
somethingHappend += new EventHandler<EventArgs>(Fired);
somethingHappend(this, EventArgs.Empty);
Assert.IsTrue(m_Fired);
}
private void Fired(object sender, EventArgs args)
{
m_Fired = true;
}
}
I notice that there is an EventHandler.CreateDelegate(...), but all the method signatures suggest this is only used for attaching Delegates to an already existing EventHandler through the typical ElementAddedEvent += new EventHandler(MyMethod).
I'm not sure if *what* I am trying to do will help... but ultimately I'd like to come up with an abstract parent DataContext in LINQ whose children can register which table Types they want "observed" so I can have events such as BeforeUpdate and AfterUpdate, but specific to types. Something like this:
public class BaseDataContext : DataContext
{
private static Dictionary<Type, Dictionary<ChangeAction, EventHandler>> m_ObservedTypes = new Dictionary<Type, Dictionary<ChangeAction, EventHandler>>();
public static void Observe(Type type)
{
if (m_ObservedTypes.ContainsKey(type) == false)
{
m_ObservedTypes.Add(type, new Dictionary<ChangeAction, EventHandler>());
EventHandler eventHandler = EventHandler.CreateDelegate(typeof(EventHandler), null, null) as EventHandler;
m_ObservedTypes[type].Add(ChangeAction.Insert, eventHandler);
eventHandler = EventHandler.CreateDelegate(typeof(EventHandler), null, null) as EventHandler;
m_ObservedTypes[type].Add(ChangeAction.Update, eventHandler);
eventHandler = EventHandler.CreateDelegate(typeof(EventHandler), null, null) as EventHandler;
m_ObservedTypes[type].Add(ChangeAction.Delete, eventHandler);
}
}
public static Dictionary<Type, Dictionary<ChangeAction, EventHandler>> Events
{
get { return m_ObservedTypes; }
}
}
public class MyClass
{
public MyClass()
{
BaseDataContext.Events[typeof(User)][ChangeAction.Update] += new EventHandler(OnUserUpdate);
}
public void OnUserUpdated(object sender, EventArgs args)
{
// do something
}
}
Thinking about this made me realize I don't really understand what's happening under the hod with events - and I would like to understand :) | 0 | [
2,
184,
107,
272,
5910,
963,
170,
439,
14,
3918,
60,
800,
3726,
3726,
31,
22,
79,
568,
272,
5910,
15,
13,
9,
2328,
203,
9,
264,
9,
31,
1369,
184,
20,
13151,
963,
15,
184,
20,
10123,
105,
19,
51,
718,
15,
184,
20,
5559,
105,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Should my unit tests be touching an API directly when testing a wrapper for that API?
===
I have some written a number of unit tests that test a wrapper around an FTP server API.
Both the unit tests and the FTP server are on the same machine.
The wrapper API gets deployed to our platform and are used in both remoting and web service scenarios. The wrapper API essentially takes XML messages to perform tasks such as adding/deleting/updating users, changing passwords, modifying permissions...that kinda thing.
In a unit test, say to add a user to a virtual domain, I create the XML message to send to the API. The API does it's work and returns a response with status information about whether the operation was successful or failed (error codes, validation failures etc).
To verify whether the API wrapper code really did do the right thing (if the response indicated success), I invoke the FTP server's COM API and query its store directly to see if, for example when creating a user account, the user account really did get created.
Does this smell bad?
Cheers
Kev
| 0 | [
2,
378,
51,
1237,
4894,
44,
6652,
40,
21,
2159,
1703,
76,
4431,
21,
28051,
26,
30,
21,
2159,
60,
800,
3726,
3726,
31,
57,
109,
642,
21,
234,
16,
1237,
4894,
30,
1289,
21,
28051,
140,
40,
1187,
306,
8128,
21,
2159,
9,
156,
14,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do you specify a custom location for crossdomain.xml in actionscript?
===
We are hosting the swf assets on a media hosting server and can't get a file to the root, anyone know what the code looks like to specify a custom location for crossdomain.xml? Sample code if you have it. | 0 | [
2,
184,
107,
42,
19077,
21,
5816,
1474,
26,
919,
537,
6232,
9,
396,
8184,
19,
1028,
8741,
60,
800,
3726,
3726,
95,
50,
10637,
14,
13,
18,
15263,
6223,
27,
21,
941,
10637,
8128,
17,
92,
22,
38,
164,
21,
3893,
20,
14,
5900,
15,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Can I get the behavior of setting my WinForms form's owner using an hwnd / NativeWindow?
===
My application is a vb6 executable, but some newer forms in the system are written in C#. I would like to be able to set the C# form's Owner property using a handle to the main application window, so that the dialogs remain on top when tabbing back and forth between my app and other apps.
I can get the hwnd of the main application window. I'm not sure what I can do from there? | 0 | [
2,
92,
31,
164,
14,
3257,
16,
2697,
51,
628,
4190,
18,
505,
22,
18,
2410,
568,
40,
746,
6156,
43,
13,
118,
1275,
27508,
60,
800,
3726,
3726,
51,
3010,
25,
21,
13,
20468,
379,
1396,
17194,
5924,
15,
47,
109,
12372,
1997,
19,
14... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Import legacy project (dated series of folders) into Subversion
===
Does anyone know of an easy way to import a legacy project, whose "version control system" is a series of dated folders, into SVN, so that the history of the revisions is preserved?
The project I inherited was not under version control, and there are hundreds of folders, each dated like: 2006-11-26, 2006-11-27, etc... Thankfully it appears they did a pretty good job of diligently creating the folders, even when (for weeks) nothing changed.
What I'd love is a script/tool that will create a new repository with the oldest folder, and then sequentially & automatically apply all the subversion commands to transform each later folder into a new revision.
I hope that makes sense. The old shell scripter in me is tempted to try to tackle this myself, but a) I'm sure it's more work than I'd initially imagine, b) it's not the best use of my time (I'm not an expert in writing shell scripts), and c) I bet someone's already done this.
Extra Credit: have the script/tool also modify the timestamp properties, based on the folder names, so that the history in subversion was closer to reality.
I hope that all makes sense.
Thanks a lot for any help.
P.S. I'd prefer to do this all under Linux, but if there is a (gasp!) Windows solution, beggars can't be choosers, can they? | 0 | [
2,
9010,
7780,
669,
13,
5,
43,
1669,
231,
16,
19294,
18,
6,
77,
972,
10898,
800,
3726,
3726,
630,
1276,
143,
16,
40,
2010,
161,
20,
9010,
21,
7780,
669,
15,
1196,
13,
7,
10898,
569,
329,
7,
25,
21,
231,
16,
5210,
19294,
18,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Multiple rows with jcarousel
===
I'm trying to use jcarousel to build a container with multiple rows, I've tried a few things but have had no luck. Can anyone make any suggestions on how to create it?
| 0 | [
2,
1886,
11295,
29,
487,
1367,
1291,
532,
800,
3726,
3726,
31,
22,
79,
749,
20,
275,
487,
1367,
1291,
532,
20,
1895,
21,
12147,
29,
1886,
11295,
15,
31,
22,
195,
794,
21,
310,
564,
47,
57,
41,
90,
5419,
9,
92,
1276,
233,
186,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
Maintenance teams vs. not-so-focused development teams
===
My organization is doing a lot of new development using Scrum, while maintaining a lot of old code. While we try to keep each development team focused on the task at hand, it is difficult because many team members "own" a piece of historic code that needs to be maintained.
Some organizations solve this problem with a separate maintenance department, but I don't think that sounds right, because nobody wants to be a maintenance programmer, and the developers need to be confronted with their own less-than-perfect judgements.
How do other organizations solve this problem? How can a company be productive at all beyond the startup phase? | 0 | [
2,
5010,
952,
4611,
9,
52,
8,
656,
8,
20986,
522,
952,
800,
3726,
3726,
51,
1165,
25,
845,
21,
865,
16,
78,
522,
568,
26562,
15,
133,
8215,
21,
865,
16,
315,
1797,
9,
133,
95,
1131,
20,
643,
206,
522,
173,
2604,
27,
14,
3005... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
SQL Server 2005 Pivot on Unknown Number of Columns
===
I am working with a set of data that looks something like the following.
> StudentName | AssignmentName | Grade
> ---------------------------------------
> StudentA | Assignment 1 | 100
> StudentA | Assignment 2 | 80
> StudentA | Total | 180
> StudentB | Assignment 1 | 100
> StudentB | Assignment 2 | 80
> StudentB | Assignment 3 | 100
> StudentB | Total | 280
The name and number of assignments are dynamic, I need to get results simlilar to the following.
> Student | Assignment 1 | Assignment 2 | Assignment 3 | Total
> --------------------------------------------------------------------
> Student A | 100 | 80 | null | 180
> Student B | 100 | 80 | 100 | 280
Now ideally I would like to sort the column based on a "due date" that could be included/associated with each assignment. The total should be at the end if possible (It can be calculated and removed from the query if possible.)
I know how to do it for the 3 assignments using pivot with simply naming the columns, it is trying to do it in a dynamic fashion that I haven't found a GOOD solution for yet. I am trying to do this on SQL Server 2005 | 0 | [
2,
4444,
255,
8128,
812,
20670,
27,
2562,
234,
16,
7498,
800,
3726,
3726,
31,
589,
638,
29,
21,
309,
16,
1054,
30,
1879,
301,
101,
14,
249,
9,
13,
1,
1209,
7259,
13,
1,
8427,
7259,
13,
1,
2044,
13,
1,
13,
8,
8,
8,
8,
8,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Does Visual Studio 2008 support windows 98?
===
We're looking at upgrading from Visual Studio 2005 to Visual Studio 2008. I discovered the following disturbing comment:
http://msdn.microsoft.com/en-us/library/6sehtctf.aspx
"Beginning with Visual C++ 2008, Visual C++ does not support targeting Windows 95, Windows 98, Windows ME, or Windows NT."
Does this mean that if we rebuild our products with visual C++ 2008, they will stop working on Windows 98 machines? It sounds like it, but I have trouble believing they'd make that big a change.
Thanks for your help. | 0 | [
2,
630,
3458,
1120,
570,
555,
1936,
8737,
60,
800,
3726,
3726,
95,
22,
99,
699,
35,
26939,
37,
3458,
1120,
812,
20,
3458,
1120,
570,
9,
31,
1848,
14,
249,
16804,
6484,
45,
7775,
6903,
79,
18,
43,
103,
9,
22019,
12980,
9,
960,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do you create a Visual Studio Solutio File (.sln) in the same directory as the web project
===
I'm using VisualSVN client and server and one of the requirements for web projects to work as expected is to have the .sln in the same directory (root) as the other files.
I thought it was as simple as removing all the extra parent paths ../ and other relative paths and saving it. However when I try to open it just locks up Visual Studio.
Is there a standard way to create this type of solution file or a solution file tool to help make sure it is valid? Or am I just missing something very obvious?
/
/MyWebsite.org.sln
/Images
/App_Data
/default.aspx
/default.aspx.cs
Here is the one made by Visual Studio 2008 and placed in the Visual Studio/Projects folder
Project("{E24SG5DC-7377-472B-9ABA-BC803SG3C61A}") = "MyWebsite.org", "..\..\..\..\..\..\Websites\MyWebsite.org\", "{69D190B7-813A-4SF6-B194-A9DC5SGC3FE0}"
ProjectSection(WebsiteProperties) = preProject
TargetFramework = "2.0"
Debug.AspNetCompiler.VirtualPath = "/MyWebsite.org"
Debug.AspNetCompiler.PhysicalPath = "..\..\..\..\..\..\Websites\MyWebsite.org\"
Debug.AspNetCompiler.TargetPath = "PrecompiledWeb\MyWebsite.org\"
Debug.AspNetCompiler.Updateable = "true"
Debug.AspNetCompiler.ForceOverwrite = "true"
Debug.AspNetCompiler.FixedNames = "false"
Debug.AspNetCompiler.Debug = "True"
Release.AspNetCompiler.VirtualPath = "/MyWebsite.org"
Release.AspNetCompiler.PhysicalPath = "..\..\..\..\..\..\Websites\MyWebsite.org\"
Release.AspNetCompiler.TargetPath = "PrecompiledWeb\MyWebsite.org\"
Release.AspNetCompiler.Updateable = "true"
Release.AspNetCompiler.ForceOverwrite = "true"
Release.AspNetCompiler.FixedNames = "false"
Release.AspNetCompiler.Debug = "False"
VWDPort = "3561"
EndProjectSection
EndProject
Here is the same section after I modified it to what I thought would be the same folder reference.
Project("{E24C65DC-7377-472B-9ABA-BCSG3B73C61A}") = "MyWebsite.org", "\", "{F8F4E96F-40BF-4374-B8BA-968D0SGG4A9E}"
ProjectSection(WebsiteProperties) = preProject
TargetFramework = "2.0"
Debug.AspNetCompiler.VirtualPath = "/"
Debug.AspNetCompiler.PhysicalPath = "\"
Debug.AspNetCompiler.TargetPath = "\PrecompiledWeb\MyWebsite.org\"
Debug.AspNetCompiler.Updateable = "true"
Debug.AspNetCompiler.ForceOverwrite = "true"
Debug.AspNetCompiler.FixedNames = "false"
Debug.AspNetCompiler.Debug = "True"
Release.AspNetCompiler.VirtualPath = "/"
Release.AspNetCompiler.PhysicalPath = "\"
Release.AspNetCompiler.TargetPath = "\PrecompiledWeb\MyWebsite.org\"
Release.AspNetCompiler.Updateable = "true"
Release.AspNetCompiler.ForceOverwrite = "true"
Release.AspNetCompiler.FixedNames = "false"
Release.AspNetCompiler.Debug = "False"
VWDPort = "3561"
EndProjectSection
EndProject
| 0 | [
2,
184,
107,
42,
1600,
21,
3458,
1120,
86,
2377,
15752,
3893,
13,
5,
9,
18,
16600,
6,
19,
14,
205,
16755,
28,
14,
2741,
669,
800,
3726,
3726,
31,
22,
79,
568,
3458,
18,
16578,
6819,
17,
8128,
17,
53,
16,
14,
4786,
26,
2741,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Is there a plugin--omnicomplete or other-- that will suggest python modules to import?
===
For example:
from datetime import <c-x><c-o>{list of modules inside datetime package} | 0 | [
2,
25,
80,
21,
10922,
108,
8,
8,
2636,
889,
15990,
54,
89,
8,
8,
30,
129,
5601,
20059,
17113,
20,
9010,
60,
800,
3726,
3726,
26,
823,
45,
37,
1231,
891,
9010,
13,
1,
150,
8,
396,
1,
150,
8,
111,
1,
5739,
16,
17113,
572,
12... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
Storing arrays in databases
===
What is the most efficient way to store large arrays (10000x100) in a database, say, hsqldb? I need to do this for a certain math program that I'm writing in java. Please help. | 0 | [
2,
25615,
7718,
18,
19,
6018,
18,
800,
3726,
3726,
98,
25,
14,
127,
8243,
161,
20,
1718,
370,
7718,
18,
13,
5,
1036,
3993,
396,
4031,
6,
19,
21,
6018,
15,
395,
15,
746,
18,
22402,
9007,
60,
31,
376,
20,
107,
48,
26,
21,
1200... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... |
Gradient colors in Internet Explorer
===
I know that Internet Explorer has some proprietary extensions so that you can do things like create divs with a gradient background. I can't remember the element name or it's usage. Does anyone have some examples or links? | 0 | [
2,
17442,
5268,
19,
2620,
8520,
800,
3726,
3726,
31,
143,
30,
2620,
8520,
63,
109,
18856,
17529,
86,
30,
42,
92,
107,
564,
101,
1600,
13,
12916,
18,
29,
21,
17442,
2395,
9,
31,
92,
22,
38,
1518,
14,
4520,
204,
54,
32,
22,
18,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0... |
Why do people use Java?
===
I've become very curious lately, what is it about Java that made it so popular? I've avoided learning it in detail because it seems like a very poor language at a very basic level. A good language should make simple operations simple (not too much boilerplate to do something simple and common like loop over a collection, create a helper function, or read in a file, plenty of syntactic sugar) and provide lots of powerful abstractions for when complexity has to go somewhere (think real macros, templates, dynamic typing, good support for multiple paradigms). Obviously, there are some tradeoffs between these two, since they basically boil down to doing a few things well vs. handling the general but more complex case gracefully, but it seems Java does neither. Simple operations aren't simple because it's so verbose, generally avoids syntactic sugar, and adopts OOP as a one-size-fits-all paradigm. It's also not very expressive when complexity has to go somewhere, again because it insists on a very one-size-fits-all approach to programming, namely class-based OOP.
I'm honestly not trying to start a flame war here. I'm just very curious what the other side of the story is. What are Java's virtues, other than inertia and the wide IDE/library/etc. support that comes with it? When you make the tradeoff of using a language that neither makes simple operations particularly simple, nor gives many powerful and versatile abstractions for complexity has to go somewhere, what do you get in return? | 4 | [
2,
483,
107,
148,
275,
8247,
60,
800,
3726,
3726,
31,
22,
195,
533,
253,
7686,
10434,
15,
98,
25,
32,
88,
8247,
30,
117,
32,
86,
844,
60,
31,
22,
195,
9460,
2477,
32,
19,
6110,
185,
32,
2206,
101,
21,
253,
1696,
816,
35,
21,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
What are some uses of template template parameters in C++?
===
I've seen some examples of C++ using template template parameters (that is templates which take templates as parameters) to do policy-based class design. What other uses does this technique have? | 0 | [
2,
98,
50,
109,
2027,
16,
22894,
22894,
12905,
19,
272,
20512,
60,
800,
3726,
3726,
31,
22,
195,
541,
109,
3770,
16,
272,
20512,
568,
22894,
22894,
12905,
13,
5,
887,
25,
22894,
18,
56,
247,
22894,
18,
28,
12905,
6,
20,
107,
148... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... |
iis7 / asp.net mvc deployment problem
===
I am having trouble deploying an asp.net MVC app to IIS7.
I have an MVC project created with asp.net mvc beta 1. It consists of nothing more than the default template unmodified.
The app runs just fine within VS2008, but when I publish it to a local IIS7 website (http://localhost), I get the following server error:
> The incoming request does not match any route
I have also tried unsuccessfully to access http://localhost/Home/About (a route to a specific page within the template). This returns a 404 error.
I have recreated the website in IIS several times and ensured the pipeline mode is set to integrated. My IIS7 server is running on my Vista Home Premium machine.
I am assuming this is an IIS configuration issue any suggestions as to configuration issues with asp.net mvc apps would be appreciated.
Any thoughts? | 0 | [
2,
595,
18,
465,
13,
118,
28,
306,
9,
2328,
307,
8990,
10475,
1448,
800,
3726,
3726,
31,
589,
452,
2572,
17617,
68,
40,
28,
306,
9,
2328,
307,
8990,
4865,
20,
595,
18,
465,
9,
31,
57,
40,
307,
8990,
669,
679,
29,
28,
306,
9,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
In my codebehind class, how do I retrieve the authorized roles?
===
I have the following in my web.config:
<location path="RestrictedPage.aspx">
<system.web>
<authorization>
<allow roles="Group1Admin, Group3Admin, Group7Admin"/>
<deny users="*"/>
</authorization>
</system.web>
</location>
Within RestrictedPage.aspx.cs, how do I retrieve the allowed roles collection that contains Group1Admin, Group3Admin, and Group7Admin? | 0 | [
2,
19,
51,
1797,
24878,
718,
15,
184,
107,
31,
11917,
14,
9401,
2954,
60,
800,
3726,
3726,
31,
57,
14,
249,
19,
51,
2741,
9,
14093,
2816,
45,
13,
1,
19032,
2013,
3726,
7,
99,
27245,
69,
6486,
9,
472,
306,
396,
7,
1,
13,
1,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
SVN: Dealing with "dead" files.
===
I have an SVN repository. Over time, as I edit, modify, change, etc, some files are made redundant/unwanted.
What's the best practice: to delete the files from SVN, or just to zero the files out?
Or is there a third option that I'm missing?
Thanks. | 0 | [
2,
13,
18,
16578,
45,
5746,
29,
13,
7,
14260,
7,
6488,
9,
800,
3726,
3726,
31,
57,
40,
13,
18,
16578,
24869,
9,
84,
85,
15,
28,
31,
9392,
15,
17579,
15,
753,
15,
2722,
15,
109,
6488,
50,
117,
24295,
118,
1020,
14876,
69,
9,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Would python make a good substitute for the windows command line/batch scripts?
===
I've got some experience with bash, which I don't mind, but now that I'm doing a lot of windows development I'm needing to do basic stuff/write basic scripts using the windows command line language. For some reason said language really irritates me, so I was considering learning Python and using that instead.
So my question is is Python suitable for such things... moving files around, creating scripts to do things like unzipping a backup and restoring a SQL database, etc. | 0 | [
2,
83,
20059,
233,
21,
254,
6558,
26,
14,
1936,
1202,
293,
118,
4900,
673,
17505,
60,
800,
3726,
3726,
31,
22,
195,
330,
109,
1496,
29,
13158,
15,
56,
31,
221,
22,
38,
594,
15,
47,
130,
30,
31,
22,
79,
845,
21,
865,
16,
1936... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
SharePoint 2007 - SQL Query to find a list of documents in site collection
===
I need to get a list of all documents in a site collection, which I believe I can do with either the alldocs table or the alluserdata table (MOSS 2007 SP1) but do not see how I can get the author information for the document. I do not need the contents of the document (e.g. AllDocStreams content)
**Something like this:**
SELECT tp_DirName, tp_LeafName, tp_Version, tp_Modified, tp_Created
FROM AllUserData
WHERE (tp_ContentType = 'Document')
AND (tp_LeafName NOT LIKE '%.css')
AND (tp_LeafName NOT LIKE '%.jpg')
AND (tp_LeafName NOT LIKE '%.png')
AND (tp_LeafName NOT LIKE '%.wmf')
AND (tp_LeafName NOT LIKE '%.gif')
AND (tp_DirName NOT LIKE '%Template%')
AND (tp_IsCurrentVersion = 1)
AND (tp_LeafName NOT LIKE '%.xsl')
ORDER BY tp_SiteId, tp_ListId, tp_DirName, tp_LeafName, tp_IsCurrentVersion DESC
**Is there a better way to go about this?** | 0 | [
2,
1891,
3132,
624,
13,
8,
4444,
255,
25597,
20,
477,
21,
968,
16,
4374,
19,
689,
1206,
800,
3726,
3726,
31,
376,
20,
164,
21,
968,
16,
65,
4374,
19,
21,
689,
1206,
15,
56,
31,
985,
31,
92,
107,
29,
694,
14,
65,
13799,
18,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
What is the best way to store a reference to an AD group?
===
I'm writing an intranet application for a client and I want to give them the ability to configure through an admin interface, which users and user groups can access certain areas. What I'd like to know is the best way of storing the reference to the user or group that is assigned to an area of the intranet.
Should I be using the **domain\username** and **domain\groupname** strings or should i perhaps be using the fully qualified ad name ie **ou=computer room;cn=blah** etc?
I will be storing the reference in SQL. | 0 | [
2,
98,
25,
14,
246,
161,
20,
1718,
21,
2801,
20,
40,
21,
43,
214,
60,
800,
3726,
3726,
31,
22,
79,
1174,
40,
14369,
2328,
3010,
26,
21,
6819,
17,
31,
259,
20,
590,
105,
14,
2165,
20,
1065,
15951,
120,
40,
21,
43,
2160,
6573,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Regex for repeated words with punctuation
===
What I want to do is check for duplicated words right next to each other but even if there is punctuation in between.
For example:
Vivamus Vivamus diam, diam, Vivamus Vivamus diam, diam Vivamus
there should be 4 distinct hits here.
I can't figure out why this isn't working; can someone explain why and show me what the correct code should be?
thanks.
(\w*(?:[ ,\.])*?)\1
----------
*PS: due to the confusion it causes, I'm not going to say that I'm using the Perl engine.* | 0 | [
2,
7953,
1706,
26,
4251,
715,
29,
13,
17359,
291,
857,
800,
3726,
3726,
98,
31,
259,
20,
107,
25,
2631,
26,
19429,
43,
715,
193,
328,
20,
206,
89,
47,
166,
100,
80,
25,
13,
17359,
291,
857,
19,
128,
9,
26,
823,
45,
1790,
138... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How to improve Trac's performance
===
I have noticed that my particular instance of Trac is not running quickly and has big lags. This is at the very onset of a project, so not much is in Trac (except for plugins and code loaded into SVN).
Are there any recommend ways to improve the performance of Trac? | 0 | [
2,
184,
20,
3545,
13,
38,
5797,
22,
18,
956,
800,
3726,
3726,
31,
57,
2711,
30,
51,
1498,
4851,
16,
13,
38,
5797,
25,
52,
946,
976,
17,
63,
580,
13,
6828,
18,
9,
48,
25,
35,
14,
253,
16848,
16,
21,
669,
15,
86,
52,
212,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
A good Code snippet tool or plugin for word documents?
===
Does anyone know of a good tool or plugin that enables MS Word or OpenOffice Writer to add code snippets to a document in a clean manner?
I'm not sure if such a plug-in even exists, so redirecting me to any other tool that can help me would be appreciated. | 0 | [
2,
21,
254,
1797,
13,
29061,
5607,
54,
10922,
108,
26,
833,
4374,
60,
800,
3726,
3726,
630,
1276,
143,
16,
21,
254,
5607,
54,
10922,
108,
30,
14645,
4235,
833,
54,
368,
17047,
1462,
20,
3547,
1797,
13,
29061,
18,
20,
21,
4492,
1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Javascript Removing Whitespace When It Shouldn't?
===
I have a HTML file that has code similar to the following.
<table>
<tr>
<td id="MyCell">Hello World</td>
</tr>
</table>
I am using javascript like the following to get the value
document.getElementById(cell2.Element.id).innerText
This returns the text "Hello World" with only 1 space between hello and world. I MUST keep the same number of spaces, is there any way for that to be done?
I've tried using innerHTML, outerHTML and similar items, but I'm having no luck. | 0 | [
2,
8247,
8741,
9096,
359,
5582,
76,
32,
5714,
22,
38,
60,
800,
3726,
3726,
31,
57,
21,
13,
15895,
3893,
30,
63,
1797,
835,
20,
14,
249,
9,
13,
1,
5924,
1,
13,
1,
6384,
1,
13,
1,
38,
43,
4924,
3726,
7,
915,
9725,
7,
1,
11... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
SQL Query - Using Order By in UNION
===
How can one programmatically sort a union query when pulling data from two tables? For example,
SELECT table1.field1 FROM table1 ORDER BY table1.field1
UNION
SELECT table2.field1 FROM table2 ORDER BY table2.field1
Throws an exception
Note: this is be attempted on MS Access Jet database engine
| 0 | [
2,
4444,
255,
25597,
13,
8,
568,
389,
34,
19,
667,
800,
3726,
3726,
184,
92,
53,
625,
6732,
1326,
2058,
21,
667,
25597,
76,
3303,
1054,
37,
81,
7484,
60,
26,
823,
15,
5407,
859,
165,
9,
1109,
165,
37,
859,
165,
389,
34,
859,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
How do I print a field from a pipe-separated file?
===
I have a file with fields separated by pipe characters and I want to print only the second field. This attempt fails:
$ echo file | awk -F| '{print $2}'
awk: syntax error near line 1
awk: bailing out near line 1
bash: {print $2}: command not found
Is there a way to do this?
| 0 | [
2,
184,
107,
31,
4793,
21,
575,
37,
21,
7642,
8,
18,
14189,
7432,
3893,
60,
800,
3726,
3726,
31,
57,
21,
3893,
29,
2861,
4196,
34,
7642,
1766,
17,
31,
259,
20,
4793,
104,
14,
153,
575,
9,
48,
1735,
13614,
45,
5579,
8117,
3893,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
AIX: IBM Java: java.net.SocketException: Connection timed out:could be due to invalid address
===
We have seen the following exceptions very frequently on IBM AIX when attempting to make an SSL connection to our server:
java.net.SocketException: Socket closed
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA6275(Compiled Code))
at com.sun.net.ssl.internal.ssl.AppOutputStream.write(DashoA6275(Compiled Code))
at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java(Inlined Compiled Code))
at java.io.BufferedOutputStream.flush(BufferedOutputStream.java(Compiled Code))
at java.io.FilterOutputStream.flush(FilterOutputStream.java(Compiled Code))
at org.apache.commons.httpclient.methods.EntityEnclosingMethod.writeRequestBody(EntityEnclosingMethod.java(Compiled Code))
at org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java(Compiled Code))
at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java(Compiled Code))
at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java(Compiled Code))
at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java(Compiled Code))
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java(Compiled Code))
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java(Inlined Compiled Code))
at com.eximtechnologies.httptransport.client.ClientTransport.receiveMessages(ClientTransport.java(Compiled Code))
at com.eximtechnologies.httptransport.client.ClientTransport.receiveMessages(ClientTransport.java(Inlined Compiled Code))
at com.eximtechnologies.ecserver.connection.XMSHTTPConnection.checkForNewMessages(XMSHTTPConnection.java(Compiled Code))
at com.eximtechnologies.ecserver.connection.XMSHTTPConnection.timeoutExpired(XMSHTTPConnection.java(Compiled Code))
at com.eximtechnologies.xmd.timer.TimerEvent$1.run(TimerEvent.java(Compiled Code))
From the error, you would think this was just a network problem, but the client had never experienced the problem before about 2 months ago, and AFAIK, there haven't been any changes to the network layout.
We also receive this fairly frequently:
java.net.SocketException: Connection timed out:could be due to invalid address
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:336)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:201)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:188)
at java.net.Socket.connect(Socket.java:478)
at java.net.Socket.connect(Socket.java:428)
at java.net.Socket.<init>(Socket.java:335)
at java.net.Socket.<init>(Socket.java:210)
at javax.net.ssl.SSLSocket.<init>(Unknown Source)
I'm suspecting that this is an AIX problem, but I guess it could be a firewall issue? I also saw some people in google searches hinting at a problem with commons http, but I couldn't see how that would be related.
Is this something that others have seen with AIX recently? | 0 | [
2,
21,
4028,
45,
10233,
8247,
45,
8247,
9,
2328,
9,
18,
5668,
1198,
10066,
872,
45,
2760,
85,
43,
70,
45,
13431,
44,
397,
20,
16671,
3218,
800,
3726,
3726,
95,
57,
541,
14,
249,
13392,
253,
3086,
27,
10233,
21,
4028,
76,
6314,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Learning j2ee, jboss, etc.
===
I've been doing "plain old java objects" programming for 10 years now, with Swing and JDBC, and I consider myself pretty good at it. But I start a new job in two weeks where they use JBoss, and I'd like to get a heads up and start learning all this stuff before I start. What are good resources? On-line tutorials, books, e-books, anything you can suggest, especially ones that don't try to teach you the basics of plain Java first. | 0 | [
2,
2477,
487,
135,
2851,
15,
487,
10349,
18,
15,
2722,
9,
800,
3726,
3726,
31,
22,
195,
74,
845,
13,
7,
9897,
108,
315,
8247,
3916,
7,
3143,
26,
332,
122,
130,
15,
29,
5587,
17,
487,
43,
7229,
15,
17,
31,
3563,
992,
1772,
25... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Forcing a TFS checkin of a file via C#
===
How can I specify that I ALWAYS want the local file to replace the server copy even if the TFS copy is newer?
<pre><code>
if (pendingChanges.GetUpperBound(0)>-1)
ChangeSetNumber = workspace.CheckIn(pendingChanges, filename);
</code></pre>
I can see from the intelisense that I can specify **checkinoptions** as a parameter of the CheckIn method, I just cannot find what I need to put in to have it always check in and ignore any conflict I might come up with.
Thanks in advance.
| 0 | [
2,
6135,
21,
13,
11720,
18,
2631,
108,
16,
21,
3893,
1197,
272,
5910,
800,
3726,
3726,
184,
92,
31,
19077,
30,
31,
550,
259,
14,
375,
3893,
20,
3934,
14,
8128,
4344,
166,
100,
14,
13,
11720,
18,
4344,
25,
12372,
60,
13,
1,
351... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
vswprintf crashes
===
using the Symbian S60 5th edition SDK released on October 2nd, I am compiling/running(on sim) the following code snippet:
void test(wchar_t *dest, int size, const wchar_t *fmt, ...) {
va_list vl;
va_start(vl, fmt);
vswprintf(dest, size, fmt, vl);
va_end(vl);
}
...
wchar_t str[1024];
// this crashes (2nd string 123 characters (+ \0) equals 248 bytes)
test(str, 1024, L"msg: %S", L"this is a test messagethis is a test messagethis is a test messagethis is a test messagethis is a test messagethis is a tes");
// this works (2nd string 122 characters (+ \0) equals 246 bytes)
test(str, 1024, L"msg: %S", L"this is a test messagethis is a test messagethis is a test messagethis is a test messagethis is a test messagethis is a te");
For no reason obvious to me (even after having read the [vswprintf][1] man page a hundred times) can I figure out why this code is crashing on me in the vswprintf call for long strings :-( The exact same code works fine on a Linux box. There is sufficient memory allocated for str, plus vswprintf is checking for buffer overruns anyway. Unfortunately the ... S60 debugger does not break on this crash, so I have no details :-(
Does anybody have any ideas?
Assuming a bug in Symbian's vswprintf routine, what would be possible replacement functions using POSIX compliant code? (this is supposed to be a cross-platform library)
Thanks.
[1]: http://www.forum.nokia.com/document/CDL_Extension_S60_3rd_Ed_FP2/GUID-719955DA-415B-420E-9F9B-F6DB37615EC5/html/wprintf.html | 0 | [
2,
4611,
499,
10299,
410,
21563,
800,
3726,
3726,
568,
14,
13,
7261,
10035,
13,
18,
3374,
331,
96,
1322,
13,
18,
43,
197,
261,
27,
311,
172,
706,
15,
31,
589,
24378,
118,
11325,
5,
218,
4861,
6,
14,
249,
1797,
13,
29061,
45,
1... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Best Pattern for AllowUnsafeUpdates
===
So far, in my research I have seen that it is unwise to set AllowUnsafeUpdates on GET request operation to avoid cross site scripting. But, if it is required to allow this, what is the proper way to handle the situation to mitigate any exposure?
Here is my best first guess on a reliable pattern if you absolutely need to allow web or site updates on a GET request.
Best Practice?
protected override void OnLoad(System.EventArgs e)
{
if(Request.HttpMethod == "POST")
{
SPUtility.ValidateFormDigest(); //will automatically set AllowSafeUpdates to true
}
If not a POST then AllowUnsafeUpdates should be used only at the point of update and reset immediately after finished
NOTE: Is this true? How is cross-site scripting used on GET and what mitigates the vulnerability?
}
//point of item update
SPSecurity.RunWithElevatedPrivledges(delegate()
{
using(SPSite site = new SPSite(SPContext.Current.Site.Url))
{
using (SPWeb web = site.RootWeb)
{
bool allowUpdates = web.AllowUnsafeUpdates; //store original value
web.AllowUnsafeUpdates = true;
... Do something and call Update() ...
web.AllowUnsafeUpdates = allowUpdates; //restore original value
}
}
});
Feedback on the best pattern is appreciated. | 0 | [
2,
246,
3732,
26,
1655,
1020,
18166,
576,
8209,
18,
800,
3726,
3726,
86,
463,
15,
19,
51,
527,
31,
57,
541,
30,
32,
25,
367,
10474,
20,
309,
1655,
1020,
18166,
576,
8209,
18,
27,
164,
3772,
1453,
20,
2658,
919,
689,
3884,
68,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
passing variables to .load(html) in jQuery
===
Say I have jquery code like this:
html += '<div class="index">' + item.index + '</div>';
// many more similar html += statements
// load items
$('div').append(html);
This html is getting too unmanageable, so I'd like to move it to an external file. What's the best way to pass variables to the HTML as i load it? Do i just have to load it and then put jquery commands in the first JS file? That's what it seems like, but I'd rather use a more template-like method. | 0 | [
2,
2848,
12157,
20,
13,
9,
8294,
5,
15895,
6,
19,
487,
8190,
93,
800,
3726,
3726,
395,
31,
57,
487,
8190,
93,
1797,
101,
48,
45,
13,
15895,
2754,
3726,
13,
22,
1,
12916,
718,
3726,
7,
25671,
7,
1,
22,
2754,
9101,
9,
25671,
2... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
In Perl, how do I process input as soon as it arrives, instead of waiting for newline?
===
I'd like to run a subcommand from Perl and have the script process the command's output immediately, rather than waiting for a timeout, a newline, or a certain number of blocks. For example, let's say I want to surround each chunk of input with square brackets. When I run the script like this:
$ ( echo -n foo ; sleep 5 ; echo -n bar ; sleep 5; echo baz) | my_script.pl
I'd like the output to be this, with each line appearing five seconds after the previous one:
[foo]
[bar]
[baz]
How do I do that? | 0 | [
2,
19,
416,
255,
15,
184,
107,
31,
953,
6367,
28,
651,
28,
32,
8394,
15,
700,
16,
1672,
26,
78,
1143,
60,
800,
3726,
3726,
31,
22,
43,
101,
20,
485,
21,
972,
16239,
37,
416,
255,
17,
57,
14,
3884,
953,
14,
1202,
22,
18,
51... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Modify Spotlight metadata for a file outside Spotlight importer?
===
I would like to modify a Spotlight metadata attribute of a file within my application (i.e. not in a Spotlight importer) but I can't find any API for doing so. Is it possible? Pointers to the relevant docs would be ideal.
In case it's helpful, here's my use case:
> I want to store a reference to a file
> system path in a Core Data store.
> Ideally, I should be able to find the
> file even if is moved, potentially
> across mounted volumes. My understanding is that
> an archived FSRef or AliasRecord will not do the trick because they
> are not invariant wrt to moves across mounted
> volumes. So my plan was to store a URL
> and also to add a UUID (also stored in
> the data store) to the file's
> Spotlight metadata so that I could
> perform a Spotlight query for that
> UUID if the URL no longer pointed to
> the file when the app goes back to
> look for the file. | 0 | [
2,
17579,
19135,
28057,
26,
21,
3893,
719,
19135,
9010,
106,
60,
800,
3726,
3726,
31,
83,
101,
20,
17579,
21,
19135,
28057,
35,
14755,
16,
21,
3893,
363,
51,
3010,
13,
5,
49,
9,
62,
9,
52,
19,
21,
19135,
9010,
106,
6,
47,
31,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
C++: "std::endl" vs "\n"
===
Many C++ books contain example code like this...
std::cout << "Test line" << std::endl;
...so I've always done that too. But I've seen a lot of code from working developers like this instead:
std::cout << "Test line\n";
Is there a technical reason to prefer one over the other, or is it just a matter of coding style? | 0 | [
2,
272,
20512,
45,
13,
7,
384,
43,
45,
45,
2451,
255,
7,
4611,
13,
7,
1,
103,
7,
800,
3726,
3726,
151,
272,
20512,
964,
3717,
823,
1797,
101,
48,
9,
9,
9,
354,
43,
45,
45,
150,
1320,
13,
1,
13,
7,
10543,
293,
7,
13,
1,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
c# query ms access against sql server
===
I have been asked to setup a course leaflet system for a college. For whatever reason in the past their current system is not linked to their actual course file, they wish to close this link so course leaflets are related to actual course codes. Unfortunately their course file is a ms access database linked to many of their existing systems (cannot easily be upgraded/moved). Since the course leaflets are going on the web it is a requirement with their hosting to use a sql server database.
This means I need to query between the two internally so they can work out what courses they have without a leaflet, I would not like to add ad hoc queries to the access database to do this.
What is the best way to do this in C#, I think LINQ can do it but have not learnt it yet, should I learn it for this project or is there an easier way?
I thought about a linked server to the ms access db but this would require moving the db to the sql server. Another difficult task as from what I can tell links to the database are hard coded. | 0 | [
2,
272,
5910,
25597,
4235,
1381,
149,
4444,
255,
8128,
800,
3726,
3726,
31,
57,
74,
411,
20,
18161,
21,
674,
5164,
1336,
329,
26,
21,
314,
9,
26,
2099,
1215,
19,
14,
640,
66,
866,
329,
25,
52,
4727,
20,
66,
3463,
674,
3893,
15... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Usage of inline closures / function delegates in Actionscript
===
Why are inline closures so rarely used in Actionscript? They are very powerful and I think quite readable. I hardly ever see anyone using them so maybe I'm just looking at the wrong code. Google uses them in their Google Maps API for Flash samples, but I think thats the only place I've seen them.
I favor them because you have access to local variables in the scope that defines them and you keep the logic in one method and dont end up with lots of functions for which you have to come up with a name.
Are there any catches of using them? Do they work pretty much the same way as in C#.
I actually only just discovered that AS3 supports them, and I'm quite annoyed becasue I had thought I read that they were deprecated in AS#. So I'm back to using them!
private function showPanel(index:int):void {
_timer = new Timer(1000, 1);
_timer.addEventListener(TimerEvent.TIMER, function(event:Event):void
{
// show the next panel
showPanel(index++);
});
| 0 | [
2,
7514,
16,
19,
1143,
7790,
18,
13,
118,
1990,
10845,
19,
1028,
8741,
800,
3726,
3726,
483,
50,
19,
1143,
7790,
18,
86,
5664,
147,
19,
1028,
8741,
60,
59,
50,
253,
2177,
17,
31,
277,
1450,
1302,
579,
9,
31,
5943,
462,
196,
12... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Javascript Postback in Grails
===
Does anyone know how to initiate a POST request in a Grails applications using javascript. Specifically, I would like to be able to POST when a the selected item in a drop-down box is changed.
I've tried using jQuery and the $.post() method. It successfully calls my controller action, but I'm not sure how to get the page to refresh with the response contents. The screen is not updated. Any ideas? This does not need to be asynchronous.
I'm not tied to using jQuery, I'm just trying to figure out how to do a POST from a javascript.
Andrew
My client-side javascript
<script type="text/javascript" language="javascript">
$(document).ready( function() {
$("#ownerId").change(function() {
$.post("/holidayCards/clientContact/ownerSelected", {ownerId: this.value});
});
}); | 0 | [
2,
8247,
8741,
678,
1958,
19,
489,
7301,
18,
800,
3726,
3726,
630,
1276,
143,
184,
20,
17014,
21,
678,
3772,
19,
21,
489,
7301,
18,
3767,
568,
8247,
8741,
9,
3524,
15,
31,
83,
101,
20,
44,
777,
20,
678,
76,
21,
14,
1704,
9101,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
how to change silverlight hosting from "test page" to "web project"?
===
I have a project with two silverlight apps (foo1 and foo2) and an ASP.NET web service (foo.web). When I created foo1, I configured it to be hosted in my web app by selecting "Link this Silverlight control into an existing web site" and then choosing foo.web as the site. However when I created foo2, I chose "Automatically generate a test page to host Silverlight at build time instead".
I originally did this because I was not using the ASP.NET functionality for anything except hosting the page, and I thought I could save some mess. However after doing a bit of development, I learn that I will get a security error if I try to use a WebClient when my application is hosted on a plain HTML page. So it turns out I must host it through the ASP.NET application after all.
When I look at the projects' property pages, I don't see any difference that corresponds to my hosting choice. I thought it would be under the "Silverlight" or "Debug" tabs, but those look the same in both projects.
What do need to change in project foo2 so that it will be hosted by an ASP.NET page in the web application (foo.web) instead of being hosted on a generated HTML page?
| 0 | [
2,
184,
20,
753,
1172,
3130,
10637,
37,
13,
7,
10543,
2478,
7,
20,
13,
7,
14113,
669,
7,
60,
800,
3726,
3726,
31,
57,
21,
669,
29,
81,
1172,
3130,
4865,
18,
13,
5,
4120,
111,
165,
17,
4310,
111,
135,
6,
17,
40,
28,
306,
9,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.