unified_texts stringlengths 32 30.1k | OpenStatus_id int64 0 4 | input_ids list | token_type_ids list | attention_mask list |
|---|---|---|---|---|
Managing Cisco programatically; Telnet vs SNMP?
===
I was recently approached by a network-engineer, co-worker who would like to offload his minor network admin duties to a junior-level helpdesk tech. The specific location in need of management acts as an ISP for tenants on its single-site property, so there's a lot of small adjustments being made on a daily basis.
I am thinking it would be helpful to write him a winform app to manage the 32 Cisco devices, on-site. I'd like to initially provide functionality which could modify access control lists, port VLAN assignments, and bandwidth limitations per VLAN... adding more to the list as its deemed valuable.
**My initial thought was to emulate a telnet session** with the network device; utilizing my network-engineer's familiarity with the command-line / IOS interaction. Minimal time would be required to learn Cisco IOS conventions, myself.
**Though while searching for solutions, it appears that most people favor SNMP.** That, or, their specific circumstances pushed them in the direction of SNMP.
I wanted to know if I've overlooked an obvious benefit of SNMP. **Should I be using SNMP? Why or why not?** | 0 | [
2,
5616,
28184,
625,
721,
8438,
73,
6757,
2328,
4611,
8912,
2554,
60,
800,
3726,
3726,
31,
23,
1989,
4132,
34,
21,
982,
8,
19153,
15,
326,
8,
22560,
72,
83,
101,
20,
168,
8294,
33,
1689,
982,
21,
43,
2160,
4419,
20,
21,
1630,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Tabbing behavior in WebForms
===
In WinForms, I can design a form and have a TabValue to control which control is selected each time the user hits 'Tab'. My question, in a webform, is there a mechanism for doing the same thing?
Edit: Does the same apply to an Ajax heavy application? | 0 | [
2,
6523,
8136,
3257,
19,
2741,
4190,
18,
800,
3726,
3726,
19,
628,
4190,
18,
15,
31,
92,
704,
21,
505,
17,
57,
21,
6523,
15165,
20,
569,
56,
569,
25,
1704,
206,
85,
14,
4155,
3858,
13,
22,
15783,
22,
9,
51,
1301,
15,
19,
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... |
Obligatory Python Vs Ruby Question
===
Since this doesn't seem to be directly addressed in any previous question.
Which language do you think is a better overall package, meaning: Including libraries, frameworks, job prospects, Python or Ruby?
I've been learning Ruby but...
It seems that a lot of pretty smart people really like python, what's the draw?
Objective answers encourage, religious answers not. | 4 | [
2,
13,
27849,
20059,
4611,
10811,
1301,
800,
3726,
3726,
179,
48,
1437,
22,
38,
2260,
20,
44,
1703,
7832,
19,
186,
1158,
1301,
9,
56,
816,
107,
42,
277,
25,
21,
574,
1677,
6030,
15,
1813,
45,
215,
8649,
15,
6596,
18,
15,
1205,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Generic htaccess redirect www to non-www
===
I would like to redirect www.example.com to example.com.
The following htaccess code makes this happen:
RewriteCond %{HTTP_HOST} ^www\.example\.com [NC]
RewriteRule ^(.*)$ http://example.com/$1 [L,R=301]
But, is there a way to do this in a generic fashion without specifying the domain name? | 0 | [
2,
12733,
13,
9020,
20604,
302,
14706,
13,
6483,
20,
538,
8,
6483,
800,
3726,
3726,
31,
83,
101,
20,
302,
14706,
13,
6483,
9,
29041,
9,
960,
20,
823,
9,
960,
9,
14,
249,
13,
9020,
20604,
1797,
1364,
48,
2384,
45,
27891,
1126,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 serialize in c++ ?
===
Using java for 3 years and serialization / deserialization is something trivial. I would like to know whether c + + is also well?
**It is possible to serialize / deserialize a class in c + +?**
If someone can leave me an example would be a great help to me.
| 0 | [
2,
184,
20,
5956,
2952,
19,
272,
20512,
13,
60,
800,
3726,
3726,
568,
8247,
26,
203,
122,
17,
5956,
1829,
13,
118,
1746,
106,
2815,
1829,
25,
301,
13,
19712,
9,
31,
83,
101,
20,
143,
1472,
272,
2754,
2754,
25,
67,
134,
60,
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... |
Use OCX without registering it
===
Is it possible to use an ocx (ActiveX Control) on a winform (probably adding it programatically) without first having the ocx registered with regsrv32?
What I'm trying to achieve is to enable xcopy installation. I've had the "AxInterop.*.dll" and "Interop.*.dll" file generated from my dev machine.
I've seen the possibility of calling a COM dll without first registering it ([ProSysLib][1], according to the author, but I haven't tested it yet), since ocx is also COM based, thus I assume that there must me some way to do that as well.
[1]: http://www.codeproject.com/KB/library/ProSysLib2.aspx?fid=1524721&df=90&mpp=25&noise=3&sort=Position&view=Quick&select=2659721&fr=28#xx2659721xx | 0 | [
2,
275,
13,
2499,
396,
366,
2243,
68,
32,
800,
3726,
3726,
25,
32,
938,
20,
275,
40,
13,
2499,
396,
13,
5,
7889,
396,
569,
6,
27,
21,
628,
4190,
13,
5,
14097,
4721,
32,
625,
721,
8438,
6,
366,
64,
452,
14,
13,
2499,
396,
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... |
Games that teach Programming Fundamentals
===
Can anybody recommend games that teach programming fundamentals?
I've personally found that [Magic: The Gathering][1] and [Robo Rally][2] (both designed by [Richard Garfield][3]) are excellent for developing early programming skills. I used to toy around with Logo on a TRS-80 as a kid and Robo Rally reminds me of that ([here's a similar Flash game][4] that's not bad). MtG is good at stressing creative thinking and learning to see past seemingly obvious situations.
[1]: http://www.wizards.com/magic/
[2]: http://www.roborally.com/
[3]: http://en.wikipedia.org/wiki/Richard_Garfield
[4]: http://www.newgrounds.com/portal/view/459508
| 4 | [
2,
466,
30,
5348,
3143,
6377,
18,
800,
3726,
3726,
92,
11181,
12360,
466,
30,
5348,
3143,
6377,
18,
60,
31,
22,
195,
7200,
216,
30,
636,
21200,
45,
14,
5822,
500,
2558,
165,
500,
17,
636,
661,
1192,
6950,
500,
2558,
135,
500,
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... |
setting environment variables in linux using bash
===
In tcsh, I have the following simple script working:
#!/bin/tcsh
setenv X_ROOT /some/specified/path
setenv XDB ${X_ROOT}/db
setenv PATH ${X_ROOT}/bin:${PATH}
xrun -d xdb1 -i $1 > $2
My question is, what is the equivalent to the `tcsh setenv` function in `bash`? Is there a direct analog? The environment variables are for locating the executable.
| 0 | [
2,
2697,
2307,
12157,
19,
13024,
568,
13158,
800,
3726,
3726,
19,
13,
6668,
1635,
15,
31,
57,
14,
249,
1935,
3884,
638,
45,
6926,
187,
118,
4772,
118,
6668,
1635,
309,
219,
710,
993,
1,
14032,
13,
118,
3220,
118,
18,
12610,
4462,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 IIS Setup
===
Good afternoon,
This should be an easy one. I've done the cookie-cutter default ASP.NET 2.0 installation, but I have a couple of programming errors in my application.
When I access the webpage on the server itself, I get a detailed ASP error message. However, when i try to run the same thing from a client machine, I just get a no-descriptive 500 error without any exception details.
How do I make it so detailed exception messages are sent to remote clients?
Regards,
Alan. | 0 | [
2,
28,
306,
9,
2328,
172,
9,
387,
595,
18,
18161,
800,
3726,
3726,
254,
3435,
15,
48,
378,
44,
40,
2010,
53,
9,
31,
22,
195,
677,
14,
19980,
8,
150,
13274,
12838,
28,
306,
9,
2328,
172,
9,
387,
7758,
15,
47,
31,
57,
21,
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... |
custom button captions in .net messagebox?
===
Is there an easy way to display a messagebox in VB.Net with custom button captions? I came across this, in the SO archives, but it's for managed C++
http://stackoverflow.com/questions/77293/what-is-an-easy-way-to-create-a-messagebox-with-custom-button-text-in-managed-c | 0 | [
2,
5816,
5167,
26622,
18,
19,
13,
9,
2328,
2802,
5309,
60,
800,
3726,
3726,
25,
80,
40,
2010,
161,
20,
3042,
21,
2802,
5309,
19,
13,
20468,
9,
2328,
29,
5816,
5167,
26622,
18,
60,
31,
281,
464,
48,
15,
19,
14,
86,
8111,
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... |
What does '^' do in c# (Enums)?
===
I was reading some 3rd party code and I found this:
x.Flags = x.Flags ^ Flags.Hidden;
What does it do?
I've used '&' and '|' for bitwise 'and' and 'or' with enums, but it's the first time I see the hat symbol... | 0 | [
2,
98,
630,
13,
22,
1,
22,
107,
19,
272,
5910,
13,
5,
219,
723,
18,
6,
60,
800,
3726,
3726,
31,
23,
1876,
109,
203,
897,
346,
1797,
17,
31,
216,
48,
45,
993,
9,
22868,
18,
800,
993,
9,
22868,
18,
13,
1,
9318,
9,
1822,
43... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 should the client do while the TIBCO EMS server attempts failover?
===
The TIBCO EMS user's guide (pg 292) says that the backup server **will work indefinitely** to either A) become the primary server or B) reconnect to the primary server. It also says **clients may receive fail-over notification** when the switch is successful (see also TIBCO EMS .NET reference pg 220). I have some questions spinning off of these facts...
1. What kind of errors occur on the client side while the servers are attempting fail-over/reconnect?
2. What is the appropriate response from the client?
* Get new Connection objects from the ConnectionFactory until one works?
* Wait for fail-over notification? (are current Connection instances fixed at this time? or do I need to get a new instance?)
I hope the scenario is clear, any related information or advice would be appreciated too. | 0 | [
2,
98,
378,
14,
6819,
107,
133,
14,
4174,
220,
716,
3579,
18,
8128,
3265,
7476,
2549,
60,
800,
3726,
3726,
14,
4174,
220,
716,
3579,
18,
4155,
22,
18,
3378,
13,
5,
9623,
13,
25204,
6,
898,
30,
14,
10119,
8128,
13,
1409,
5580,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 software shop to TDD?
===
I would really love to push for TDD development inside the shop I'm working in. Lots of the seniors over there didn't work with unit testing or did unit testing that was hitting the database.
I would love to bring some good arguments, books for training, possible coach to ease the transition. | 0 | [
2,
184,
20,
8406,
21,
2306,
2546,
20,
15596,
43,
60,
800,
3726,
3726,
31,
83,
510,
339,
20,
3250,
26,
15596,
43,
522,
572,
14,
2546,
31,
22,
79,
638,
19,
9,
7503,
16,
14,
1101,
18,
84,
80,
223,
22,
38,
170,
29,
1237,
4431,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Automatically joining tables without breaking default behaviour in Zend Framework
===
The situation is as follows: I've got 2 models: 'Action' and 'User'. These models refer to the tables 'actions' and 'users', respectively.
My action table contains a column 'user_id'. At this moment, I need an overview of all actions, and the users to which they are assigned to. When i use $action->fetchAll(), I only have the user ID, so I want to be able to join the data from the user model, preferably without making a call to findDependentRowset().
I thought about creating custom fetchAll(), fetchRow() and find() methods in my model, but this would break default behaviour.
What is the best way to solve this issue? Any help would be greatly appreciated. | 0 | [
2,
7499,
3765,
7484,
366,
3892,
12838,
7727,
19,
10526,
43,
6596,
800,
3726,
3726,
14,
1858,
25,
28,
2415,
45,
31,
22,
195,
330,
172,
2761,
45,
13,
22,
8645,
22,
17,
13,
22,
16704,
22,
9,
158,
2761,
5017,
20,
14,
7484,
13,
22,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Product Development on .NET
===
Would it make good business sense to create web based software on the .net framework. Microsoft comes out with a new version of .net every 10 months or so... The support for the older versions of .net will be fading away gradually ... | 0 | [
2,
2374,
522,
27,
13,
9,
2328,
800,
3726,
3726,
83,
32,
233,
254,
508,
1259,
20,
1600,
2741,
432,
2306,
27,
14,
13,
9,
2328,
6596,
9,
7099,
1624,
70,
29,
21,
78,
615,
16,
13,
9,
2328,
352,
332,
818,
54,
86,
9,
9,
9,
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... |
Has anyone used TIBCO GI?
===
I was checking out the [TIBCO GI](http://www.tibco.com/devnet/gi/) the other day and I was impressed.
- Has anyone used it extensively?
- What are your thoughts?
- What drawbacks did you encounter?
- Is it suitable for Internet or only Intranet apps?
I appreciate any input you can shed on this. | 0 | [
2,
63,
1276,
147,
4174,
220,
716,
4100,
60,
800,
3726,
3726,
31,
23,
9886,
70,
14,
636,
38,
4598,
716,
4100,
500,
5,
21127,
6903,
6483,
9,
38,
4598,
716,
9,
960,
118,
14438,
2328,
118,
2234,
118,
6,
14,
89,
208,
17,
31,
23,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Change local administrator password in C#
===
I am looking for a way to change the password of a local user account (local Administrator) on a Windows (XP in this case) machine. I have read the [CodeProject article][1] about one way to do this, but this just doesn't seem 'clean'.
I can see that this is [possible to do with WMI][2], so that might be the answer, but I can't figure out how to use the WinNT WMI namespace with ManagementObject. When I try the following code it throws an "Invalid Parameter" exception.
public static void ResetPassword(string computerName, string username, string newPassword){
ManagementObject managementObject = new ManagementObject("WinNT://" + computerName + "/" + username); // Throws Exception
object[] newpasswordObj = {newPassword};
managementObject.InvokeMethod("SetPassword", newpasswordObj);
}
Is there a better way to do this? (I'm using .NET 3.5)
[1]: http://www.codeproject.com/KB/threads/Reset-Administrator-Pass.aspx
[2]: http://www.microsoft.com/technet/scriptcenter/resources/qanda/oct04/hey1015.mspx | 0 | [
2,
753,
375,
8890,
20884,
19,
272,
5910,
800,
3726,
3726,
31,
589,
699,
26,
21,
161,
20,
753,
14,
20884,
16,
21,
375,
4155,
2176,
13,
5,
15580,
8890,
6,
27,
21,
1936,
13,
5,
396,
306,
19,
48,
610,
6,
1940,
9,
31,
57,
1302,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 'greatest' function in db2?
===
I found in MYSQL and apparently other database engines that there is a "greatest" function that can be used like: greatest(1, 2, 3, 4), and it would return 4. I need this, but I am using IBM's DB2. Does anybody know of such an equivalent function, even if it only accepts 2 parameters?
I found somewhere that MAX should do it, but it doesn't work... it only works on selecting the MAX of a column.
If there is no such function, does anybody have an idea what a stored procedure to do this might look like? (I have no stored procedure experience, so I have no clue what DB2 would be capable of). | 0 | [
2,
25,
80,
21,
13,
22,
6894,
1430,
22,
1990,
19,
13,
9007,
135,
60,
800,
3726,
3726,
31,
216,
19,
51,
18,
22402,
17,
3083,
89,
6018,
4016,
30,
80,
25,
21,
13,
7,
6894,
1430,
7,
1990,
30,
92,
44,
147,
101,
45,
3023,
5,
165,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Replacing a message in a jms queue
===
I am using activemq to pass requests between different processes. In some cases, I have multiple, duplicate message (which are requests) in the queue. I would like to have only one. Is there a way to send a message in a way that it will replace an older message with similar attributes? If there isn't, is there a way to inspect the queue and check for a message with specific attributes (in this case I will not send the new message if an older one exists).
Thanks. | 0 | [
2,
5496,
21,
2802,
19,
21,
487,
79,
18,
22521,
800,
3726,
3726,
31,
589,
568,
1348,
79,
1251,
20,
1477,
12279,
128,
421,
5102,
9,
19,
109,
1871,
15,
31,
57,
1886,
15,
19429,
2802,
13,
5,
2140,
50,
12279,
6,
19,
14,
22521,
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... |
What was your experience with a Lead Programmer Team Structure?
===
In the 60s and 70s, Harlan Mills of IBM promoted the idea of Lead Programmer teams, which he compared to a surgical team -- a highly trained and talented individual as the person who was actually "hands on the patient" and who was, in turn, supported by others who provided him or her with tools and routine procedures. He contrasted this structure with the more common non-hierarchical structure in which everyone was assumed to be more-or-less equal in talent and duties (his loaded metaphor for the latter structure was a "hog-butchering team").
The Lead Programmer structure seems to rest on the belief that there is a great disparity in the potential contribution of team members and that the benefits of restricting the influence of relatively inexperienced or untried developers outweighed the potential benefits of what we'd now call collective code ownership.
Lead Programmer teams were studied, a little, and didn't seem to show clear benefit. They fell out of favor and today "Lead Programmer" generally just indicates seniority, not structural responsibilities. Today, with a culture more attuned to the Agile Manifesto, the very idea of a structural hierarchy within the development team is probably distasteful to many. On the other hand, the development industry is far more heterogeneous than it was in the early 1970s and I think that there may well be a greater gap in potential contribution between team members, especially when working with distributed teams or teams involving both part-time and full-time workers.
Have you worked on a team with a Lead Programmer-style hierarchy? If so, was it effective?
While this question obviously *relates* to general questions of how talent is distributed and whether meritocracies are good or bad, I'm hoping to hear experiences, whether good or bad, with those who've actually tried the Lead Programmer structure. | 0 | [
2,
98,
23,
154,
1496,
29,
21,
672,
17968,
173,
1411,
60,
800,
3726,
3726,
19,
14,
2083,
18,
17,
3201,
18,
15,
24695,
5324,
16,
10233,
2033,
14,
882,
16,
672,
17968,
952,
15,
56,
24,
2428,
20,
21,
12569,
173,
13,
8,
8,
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... |
Variable Naming Conventions in C++
===
I come from a .NET world and I'm new to writting C++. I'm just wondering what are the preferred naming conventions when it comes to naming local variables and struct members.
For example, the legacy code that I've inheritted has alot of these:
struct MyStruct
{
TCHAR szMyChar[STRING_SIZE];
bool bMyBool;
unsigned long ulMyLong;
void* pMyPointer;
MyObject** ppMyObjects;
}
Coming from a C# background I was shocked to see the variables with hungarian notation (I couldn't stop laughing at the pp prefix the first time I saw it).
I would much rather name my variables this way instead (although I'm not sure if capitalizing the first letter is a good convention. I've seen other ways (see links below)):
struct MyStruct
{
TCHAR MyChar[STRING_SIZE];
bool MyBool;
unsigned long MyLong;
void* MyPointer;
MyObject** MyObjects;
}
My question: Is this (the former way) still a preferred way to name variables in C++?
References:
<http://geosoft.no/development/cppstyle.html>
<http://www.syntext.com/books/syntext-cpp-conventions.htm>
<http://ootips.org/hungarian-notation.html>
Thanks!
| 0 | [
2,
7612,
10929,
15117,
19,
272,
20512,
800,
3726,
3726,
31,
340,
37,
21,
13,
9,
2328,
126,
17,
31,
22,
79,
78,
20,
20127,
1203,
272,
20512,
9,
31,
22,
79,
114,
5712,
98,
50,
14,
5981,
10929,
15117,
76,
32,
1624,
20,
10929,
375... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 basicHttpBinding the only option for connecting a .Net 2.0 client to a WCF Service?
===
This is a follow on to this [question][1]. I am trying to avoid using the x509 certificate method as that makes my client installs more complex. If basicHttpBinding is not the only option, where are some samples of other binding methods.
My clients are on .Net 2.0, I don't have access to System.ServiceModel namespace as that didn't come out until 3.0.
[1]: http://stackoverflow.com/questions/232500/how-to-configure-security-when-calling-wcf-service-from-net-20-client | 0 | [
2,
25,
2125,
21127,
22260,
14,
104,
4255,
26,
6440,
21,
13,
9,
2328,
172,
9,
387,
6819,
20,
21,
11801,
410,
365,
60,
800,
3726,
3726,
48,
25,
21,
1740,
27,
20,
48,
636,
24652,
500,
2558,
165,
500,
9,
31,
589,
749,
20,
2658,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Chaning security permisions on the common app data folder
===
My application stores some common user data in %CSIDL_COMMON_APPDATA%\Company\Product. I want to make sure the Users group has write privileges to this folder which on Vista it does not. How would do I do this? What are the Win32 APIs I need to call from C++ code? | 0 | [
2,
6122,
68,
1221,
416,
5858,
5757,
27,
14,
757,
4865,
1054,
19294,
800,
3726,
3726,
51,
3010,
4134,
109,
757,
4155,
1054,
19,
13,
11881,
16166,
8643,
1,
17130,
1,
7753,
18768,
11881,
1,
28359,
1,
14086,
9,
31,
259,
20,
233,
562,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Abstracting data connection layers and presentation layers in an enterprise application
===
We are building an enterprise application in which we will incorporate multiple platforms for user interfaces (i.e. ASP.net webapp, Windows Application, and someday, Mobile Apps) and multiple platforms for back-end databases (i.e. SQL Server, XML, Oracle). An additional neccesity is that these back-end DBs either be centralized and accessed via the web or localized on the client computer and occasionally synchronized to the central server.
Can anyone give advice on how we can abstract the user-interface layer & the data layer so that we can more simply create plug-and-play adaptability between the various UIs and the various choices for DBs? For example: in one case, we may have a web-app running on a centralized server via the internet, and we may have remote machines running localized copies via a windows app. At scheduled intervals, we'd want all machines synchronized so that they can all have near-real-time data.
We also need advice on handling the various connection strings involved so that the only setting that would need changing on any one app would be "local" or "remote", which would then determine the necessary connection string.
| 0 | [
2,
8502,
68,
1054,
2760,
9124,
17,
6364,
9124,
19,
40,
6002,
3010,
800,
3726,
3726,
95,
50,
353,
40,
6002,
3010,
19,
56,
95,
129,
14710,
1886,
6843,
26,
4155,
6573,
18,
13,
5,
49,
9,
62,
9,
28,
306,
9,
2328,
2741,
7753,
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... |
CSLA for web based software
===
I have been using the CSla framework for couple of years now for windows applications. With ASP .NET MVC / AJAX / JQuery out now, would there be any use for the CSLA framework (which is strongly Object Oriented ) in web apps? | 0 | [
2,
272,
18,
531,
26,
2741,
432,
2306,
800,
3726,
3726,
31,
57,
74,
568,
14,
272,
18,
531,
6596,
26,
1335,
16,
122,
130,
26,
1936,
3767,
9,
29,
28,
306,
13,
9,
2328,
307,
8990,
13,
118,
20624,
13,
118,
487,
8190,
93,
70,
130,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 practice for naming database tables to provide natural organization?
===
We put common prefixes on related tables to assure they display next to each other in our DB management software (Toad, Enterprise Manager, etc).
So for example, all user tables start with the word User:
- User
- UserEvent
- UserPurchase
Ideally, in honor of the [three great virtues of a programmer][1] these tables should be named User, Event, Purchase respectively to save some typing, agreed?
Is this naming convention the best (only?) practice for grouping related tables together naturally?
[1]: http://c2.com/cgi/wiki?LazinessImpatienceHubris | 0 | [
2,
98,
25,
14,
246,
1345,
26,
10929,
6018,
7484,
20,
1181,
1112,
1165,
60,
800,
3726,
3726,
95,
442,
757,
14315,
160,
27,
1597,
7484,
20,
13421,
59,
3042,
328,
20,
206,
89,
19,
318,
13,
9007,
1097,
2306,
13,
5,
262,
1283,
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... |
What's the purpose of the nop opcode?
===
I'm going through MSIL and noticing there are a lot of [nop][1] instructions. The MSDN article says they take no action and are used to fill space if the opcode is patched. They're used a lot more in debug builds than release builds. I know that these kinds of statements are used in assembly languages to make sure an opcode fits on a word boundary, but why is it needed in MSIL?
[1]: http://msdn.microsoft.com/en-us/library/system.reflection.emit.opcodes.nop.aspx | 0 | [
2,
98,
22,
18,
14,
2131,
16,
14,
90,
306,
3088,
9375,
60,
800,
3726,
3726,
31,
22,
79,
228,
120,
307,
8556,
17,
18130,
80,
50,
21,
865,
16,
636,
251,
306,
500,
2558,
165,
500,
7650,
9,
14,
4235,
43,
103,
2002,
898,
59,
247,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
PL/SQL for parsing EDI (X12, NCPDP, HL7)
===
I have some EDI messages (X12, HL7, etc ...) stored in an Oracle database. I sometimes want to pull out individual fields (e.g. ISA-03). Currently, I have some really ugly sql. I'd like to create a PL/SQL package to make it easier and was wondering if anybody had already done this.
I imagine something like:
select
edi.x12.extract_field( clob_column, 'ISA', 4)
from
edi_table
| 0 | [
2,
12443,
118,
18,
22402,
26,
2017,
18,
68,
13,
69,
49,
13,
5,
396,
918,
15,
9276,
306,
7431,
15,
13,
3712,
465,
6,
800,
3726,
3726,
31,
57,
109,
13,
69,
49,
7561,
13,
5,
396,
918,
15,
13,
3712,
465,
15,
2722,
13,
9,
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... |
Looking for a "Universal" Document viewer implemented as a Java Applet or with a Java SDK.
===
I am looking for an Applet with similar functionality to the Oracle/Stellent OutsideIn ActiveX control or the Autonomy KeyView technology that act as a browser plug-in allowing the rendering/display of a large number of file formats (Word processing, spreadhseet, graphics, etc.) I currently use the Stellent solution, but due to some restrictions of some of our clients would prefer something that either exists as a Java Applet or has a Java API that I could build an applet on top of (neither of the two I mentioned do).
Any suggestions? | 0 | [
2,
699,
26,
21,
13,
7,
20748,
7,
4492,
16812,
6807,
28,
21,
8247,
4037,
38,
54,
29,
21,
8247,
13,
18,
43,
197,
9,
800,
3726,
3726,
31,
589,
699,
26,
40,
4037,
38,
29,
835,
18548,
20,
14,
15759,
118,
18,
4213,
2291,
719,
108,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Editable WPF GridView Row
===
I am trying to create a databound WPF GridView whose rows can either be read-only or editable (by double-clicking or through a context menu). I would like for the row to return to a read-only state if any of its editable controls loses focus. The functionality I am looking for is very similar to [this example][1] but with an entire row being editted simultaneously (rather than a single cell). Does anyone know how to implement this?
[1]: http://blogs.msdn.com/atc_avalon_team/archive/2006/03/14/550934.aspx | 0 | [
2,
9392,
579,
619,
7721,
7354,
4725,
3131,
800,
3726,
3726,
31,
589,
749,
20,
1600,
21,
1054,
7410,
619,
7721,
7354,
4725,
1196,
11295,
92,
694,
44,
1302,
8,
4965,
54,
9392,
579,
13,
5,
779,
1494,
8,
150,
10129,
68,
54,
120,
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... |
Which method name fits in best with Objective-C/Cocoa conventions?
===
Here's a quicky question. Which method name makes the most sense for an Objective-C Cocoa application?
-(void) doSomethingWithAnimation:(BOOL)animated
or:
-(void) doSomething:(BOOL)animated
or even:
-(void) doSomethingAnimated:(BOOL)animated
| 0 | [
2,
56,
2109,
204,
2742,
18,
19,
246,
29,
7038,
8,
150,
118,
716,
716,
58,
15117,
60,
800,
3726,
3726,
235,
22,
18,
21,
2231,
93,
1301,
9,
56,
2109,
204,
1364,
14,
127,
1259,
26,
40,
7038,
8,
150,
24507,
3010,
60,
13,
8,
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,
1,
1,
1... |
How to create an installer out of an installer?
===
I have an old legacy application around for which I only have the installer. it doesn't do anything more than uncompress and register itself and his library's.
As i don't have the source-code it gives me a lot of headaches in maintenance problems. In some particular computers (Acer Aspire One with Windows) just do not run.
I would like to extract the files and re-create this installer with NSIS. Is this possible or I'm nuts?
The original installer has been created with Ghost Installer Studio. | 0 | [
2,
184,
20,
1600,
40,
16146,
106,
70,
16,
40,
16146,
106,
60,
800,
3726,
3726,
31,
57,
40,
315,
7780,
3010,
140,
26,
56,
31,
104,
57,
14,
16146,
106,
9,
32,
1437,
22,
38,
107,
602,
91,
119,
367,
960,
5890,
17,
2243,
1145,
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... |
Problem adding dynamic columns to an ASP.NET Gridview
===
I'm having a problem dynamically adding columns to a GridView. I need to change the layout -- i.e. the included columns -- based on the value in a DropDownList. When the user changes the selection in this list, I need to remove all but the first column and dynamically add additional columns based on the selection.
I have only one column defined in my markup -- column 0, a template column, in which I declare a Select link and another application specific LinkButton. That column needs to always be there. When the ListBoxSelection is made, I remove all but the first column and then re-add the desired columns (in this sample, I've simplified it to always add a "Title" column). Here is a portion of the code:
RemoveVariableColumnsFromGrid();
BoundField b = new BoundField();
b.DataField = "Title";
this.gvPrimaryListView.Columns.Add(b);
this.gvPrimaryListView.DataBind();
private void RemoveVariableColumnsFromGrid() {
int ColCount = this.gvPrimaryListView.Columns.Count;
//Leave column 0 -- our select and view template column
while (ColCount > 1) {
this.gvPrimaryListView.Columns.RemoveAt(ColCount - 1);
--ColCount;
}
}
The first time this code runs through, I see both the static column and the dynamically added "Title" column. However, the next time a selection is made, the first column is generated empty (nothing in it). I see the title column, and I see the first column to its left -- but there's nothing generated within it. In the debugger, I can see that gvPrimaryListView does indeed still have two columns and the first one (index 0) is indeed a template column. In fact, the column even retains it's width which is set as 165px in the markup below (for debugging purposes).
Any ideas? TIA.
<asp:GridView ID="gvPrimaryListView" runat="server" Width="100%" AutoGenerateColumns="false"
DataKeyNames="Document_ID" EnableViewState="true" DataSourceID="odsPrimaryDataSource"
AllowPaging="true" AllowSorting="true" PageSize="10" OnPageIndexChanging="activeListView_PageIndexChanging"
AutoGenerateSelectButton="False" OnSelectedIndexChanged="activeListView_SelectedIndexChanged"
Visible="true" OnRowDataBound="CtlDocList_RowDataBound" Font-Size="8pt" Font-Names="Helvetica">
<Columns>
<asp:TemplateField ShowHeader="false">
<ItemTemplate>
<asp:LinkButton EnableTheming="false" ID="CtlSelectDocRowBtn" runat="server" Text="Select"
CommandName="Select" CssClass="gridbutton" OnClick="RowSelectBtn_Click" />
<asp:ImageButton EnableTheming="false" ID="DocViewBtn" runat="server" ImageUrl="../../images/ViewDoc3.png"
CssClass="gridbutton" CommandName="Select" OnClick="DocViewBtn_Click" />
</ItemTemplate>
<ItemStyle Width="165px" />
</asp:TemplateField>
</Columns>
<EmptyDataTemplate>
<asp:Label ID="Label6" runat="server" Text="No rows found." SkinID="LabelHeader"></asp:Label>
</EmptyDataTemplate>
</asp:GridView>
| 0 | [
2,
1448,
4721,
7782,
7498,
20,
40,
28,
306,
9,
2328,
7354,
4725,
800,
3726,
3726,
31,
22,
79,
452,
21,
1448,
7782,
1326,
4721,
7498,
20,
21,
7354,
4725,
9,
31,
376,
20,
753,
14,
9106,
13,
8,
8,
31,
9,
62,
9,
14,
506,
7498,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 way to generate a mock web service from a WSDL file?
===
I've inherited a WSDL file for a web service on a system that I don't have access to for development and testing.
I need to generate a web service that adheres to that WSDL. The wrapper is .NET, but if there's an easy way to do this with another platform, we might be able to look at that. The production web service is Java-based.
What's the best way to go about doing this?
For clarity's sake, I understand that I can easily create a .NET wrapper class from the WSDL file, but that's not what I need. It's like this:
![Diagram of system showing unavailable web service and mock web service][1]
[1]: http://paulw.us/blog/uploads/SO-WSDL-Question1.gif | 0 | [
2,
246,
161,
20,
7920,
21,
10506,
2741,
365,
37,
21,
619,
18,
8643,
3893,
60,
800,
3726,
3726,
31,
22,
195,
7179,
21,
619,
18,
8643,
3893,
26,
21,
2741,
365,
27,
21,
329,
30,
31,
221,
22,
38,
57,
1381,
20,
26,
522,
17,
4431,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
CakePHP - Parameters?
===
I'm new to CakePHP but I've been though their FAQs and guides to no avail. This is so simple that I just must not be thinking straight:
How can I access a parameter sent through the URL within my view files?
Example: http://example.com/view/6
How would I take that parameter ("6") and cycle it through the controller to another view page?
If that's too complex for a quick answer, how can I reference the 6 within the view page itself? The 6 in this situation is the "Id" value in my database, and I need to set it as the "parent" -
Thanks | 0 | [
2,
8390,
26120,
13,
8,
12905,
60,
800,
3726,
3726,
31,
22,
79,
78,
20,
8390,
26120,
47,
31,
22,
195,
74,
362,
66,
1399,
1251,
18,
17,
14838,
20,
90,
24240,
9,
48,
25,
86,
1935,
30,
31,
114,
491,
52,
44,
1440,
1599,
45,
184,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Re-open *scratch* buffer in emacs?
===
If I accidentally closed the *scratch* buffer in Emacs, how do I create a new *scratch* buffer? | 0 | [
2,
302,
8,
10157,
1637,
18,
7519,
9744,
2483,
17497,
19,
13,
62,
6893,
18,
60,
800,
3726,
3726,
100,
31,
9746,
827,
14,
1637,
18,
7519,
9744,
2483,
17497,
19,
13,
62,
6893,
18,
15,
184,
107,
31,
1600,
21,
78,
1637,
18,
7519,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
Best way to implement file access in C#
===
Scenario - I need to access a HTML template to generate a e-mail from my Business Logic Layer. It is a class library contains a sub folder that contains the file. When I tried the following code in a unit test:
string FilePath = string.Format(@"{0}\templates\MyFile.htm", Environment.CurrentDirectory);
string FilePath1 = string.Format(@"{0}\templates\MyFile.htm", System.AppDomain.CurrentDomain.BaseDirectory);
It was using the C:\WINNT\system32\ or the ASP.NET Temporary Folder directory.
What is the best to access this file with have to use an app,config or web.config file? | 0 | [
2,
246,
161,
20,
8713,
3893,
1381,
19,
272,
5910,
800,
3726,
3726,
12705,
13,
8,
31,
376,
20,
1381,
21,
13,
15895,
22894,
20,
7920,
21,
13,
62,
8,
8079,
37,
51,
508,
7085,
5385,
9,
32,
25,
21,
718,
1248,
1588,
21,
972,
19294,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Weird case sensitivity bug in Class.getResource?
===
I was loading an image resource with the following code and it works fine from my dev environment (netbeans) but threw an exception as soon as it ran from the desktop.
new ImageIcon(Images.class.getResource("images/highlighter24.gif"));
I traced it down to my file having different case than in the code.
Fine, my bad, but why the inconsistent behavior?
Gremlins?
Note: I'm running on windows before you ask.
| 0 | [
2,
5455,
610,
17018,
6256,
19,
718,
9,
3060,
99,
12097,
60,
800,
3726,
3726,
31,
23,
12797,
40,
1961,
6577,
29,
14,
249,
1797,
17,
32,
693,
1123,
37,
51,
9664,
2307,
13,
5,
2328,
863,
5950,
6,
47,
3144,
40,
5391,
28,
651,
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 to change item size and gap between them in Custom Drown CListCtrl
===
As far as I know ON_WM_MEASUREITEM does not get called in Custom Draw list control. It is only used if control is Owner Drawn.
I have found a way to do that, but it is somewhat a HACK and I still can not control gaps between items they are set up somehow automatically.
The trick is that you can create CImageList with the unused images of the size you need and if you assign such image list to the list control, items get resized to the dimensions close to the size of the images. After that you can use Custom Draw to paint whatever inside those enlarged items.
CImageList m_imageList1;
m_imageList1.Create(176, 144, ILC_COLOR32 | ILC_MASK, 5, 1);
GetListCtrl().SetImageList(&m_imageList1, LVSIL_NORMAL);
So the question is how do you change items size and spacing between them in Custom Drown control?
Or a fully Owner Drawn control with LVS_OWNERDRAWFIXED is my only option here?
| 0 | [
2,
184,
20,
753,
9101,
1072,
17,
4127,
128,
105,
19,
5816,
20380,
272,
5739,
4812,
6362,
800,
3726,
3726,
28,
463,
28,
31,
143,
27,
1,
499,
79,
1,
24493,
2119,
79,
630,
52,
164,
227,
19,
5816,
2003,
968,
569,
9,
32,
25,
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... |
What is the best way to compare .NET performance vs. VB 6 performance at a customer site?
===
Two questions:
1. Can someone point me to unbiased data that compares .NET performance to VB 6 performance? I have searched but it is surprisingly difficult to find.
2. What is the best way to compare .NET performance to VB 6 performance as an app behaves at a customer's site?
We have a WindowsForms, client-server app (written for 2.0, upgrading to 3.5 SP 1 soon) about which certain customers complain of "slow performance" as compared to the previous VB 6 version. I know, "slow performance" is very vague and general, but is it true to assume .NET code might be slower than VB 6 code because .NET runs in a VM? I wrote 100% of the code in C#, so it was not ported by some third person or wizard.
Not all customers make this complaint, so we suspect something environmental. Is our only option to measure performance at a customer site? Some of our customers use SQL Server 2005 on Windows Server 2003 on a Novell network. Would they see dramatically different data access performance than a similar machine on a Windows network? | 0 | [
2,
98,
25,
14,
246,
161,
20,
11590,
13,
9,
2328,
956,
4611,
9,
13,
20468,
400,
956,
35,
21,
7705,
689,
60,
800,
3726,
3726,
81,
2346,
45,
137,
9,
92,
737,
454,
55,
20,
367,
5732,
18,
69,
1054,
30,
11590,
18,
13,
9,
2328,
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... |
ACM Problem: Coin-Flipping, help me identify the type of problem this is. Recursive?
===
**I'm practicing for the upcoming ACM programming competition in a week and I've gotten stumped on this programming problem. I think it might be a recursive problem but if someone can give me a nudge in the right direction I would appreciate it.**
**The problem is as follows:**
----------
You have a puzzle consisting of a square grid of size 4. Each grid square holds a single coin; each coin is showing either heads (H) and tails (T). One such puzzle is shown here:
> H H H H
> T T T T
> H T H T
> T T H T
Any coin that is current showing Tails (T) can be flipped to Heads (H). However, any time we flip a coin, we must also flip the adjacent coins direct above, below and to the left and right in the same row. Thus if we flip the second coin in the second row we must also flip 4 other coins, giving us this arrangment (coins that changed are shown in bold).
> H **T** H H
> **H** **H** **H** T
> H **H** H T
> T T H T
If a coin is at the edge of the puzzle, so there is no coin on one side or the other, then we flip fewer coins. We do not "wrap around" to the other side. For example, if we flipped the bottom right coin of the arragnement above we would get:
> H T H H
> H H H T
> H H H **H**
> T T **T** **H**
Note: Only coins showing (T) tails can be selected for flipping. However, anytime we flip such a coin, adjacent coins are also flipped, regardless of their state.
The goal of the puzzle is to have all coins show heads. While it is possible for some arragnements to not have solutions, all the problems given will have solutions. The answer we are looking for is, for any given 4x4 grid of coins what is the least number of flips in order to make the grid entirely heads.
For Example the grid:
H T H H
T T T H
H T H T
H H T T
The answer to this grid is: 2 flips.
----------
What I have done so far:
I'm storing our grids as two-dimensional array of booleans. Heads = true, tails = false.
I have a **flip(int row, int col)** method that will flip the adjacent coins according the rules above and I have a **isSolved()** method that will determine if the puzzle is in a solved state (all heads). So we have our "mechanics" in place.
The part we are having problems with is how should we loop through? You might have to go several layers deep before you have found the correct solution with the least number of flips. I can easily grasp how we would do the first iteration by flipping() each tails, check if solved, if not flip them back and try the next one. But after that it gets a little hazy.
Is this a problem where we should use recursion? If so, can you point is in the right direction with a little pseudo-code (assuming we already have isSolved() and flip(col, row))?
| 0 | [
2,
21,
9095,
1448,
45,
8646,
8,
4372,
49,
5574,
15,
448,
55,
5808,
14,
1001,
16,
1448,
48,
25,
9,
302,
24244,
60,
800,
3726,
3726,
13,
1409,
49,
22,
79,
13640,
26,
14,
9078,
21,
9095,
3143,
1076,
19,
21,
877,
17,
31,
22,
195... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Why should unit test test only one thing?
===
[What Makes a Good Unit Test?][1] says that a test should test only one thing. What is the benefit from that?
Wouldn't it be better to write a bit bigger tests that test bigger block of code? Investigating a test failure is anyway hard and I don't see help to it from smaller tests.
[1]: /questions/61400/what-makes-a-good-unit-test | 0 | [
2,
483,
378,
1237,
1289,
1289,
104,
53,
584,
60,
800,
3726,
3726,
636,
608,
1364,
21,
254,
1237,
1289,
60,
500,
2558,
165,
500,
898,
30,
21,
1289,
378,
1289,
104,
53,
584,
9,
98,
25,
14,
4234,
37,
30,
60,
1265,
22,
38,
32,
4... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Why are Delphi objects assigned even after calling .Free?
===
In Delphi, why does the Assigned() function still return True after I call the destructor?
The below example code will write "sl is still assigned" to the console.
However, I can call FreeAndNil(sl); and it won't be assigned.
I've been programming in Delphi for a while, but this never made sense to me.
Can someone explain?
program Project1;
{$APPTYPE CONSOLE}
uses SysUtils, Classes;
var
sl : TStringList;
begin
sl := TStringList.Create;
sl.Free;
if Assigned(sl) then
WriteLn('sl is still assigned')
else
WriteLn('sl is not assigned');
end.
I tried comparing the VCL operations... FreeAndNil is short and sweet and makes sense:
procedure FreeAndNil(var Obj);
var
P: TObject;
begin
P := TObject(Obj);
TObject(Obj) := nil; // clear the reference before destroying the object
P.Free;
end;
But TObject.Free is in mysterious assembler, which I don't understand:
procedure TObject.Free;
asm
TEST EAX,EAX
JE @@exit
MOV ECX,[EAX]
MOV DL,1
CALL dword ptr [ECX].vmtDestroy
@@exit:
end; | 0 | [
2,
483,
50,
23030,
3916,
2467,
166,
75,
2555,
13,
9,
4639,
60,
800,
3726,
3726,
19,
23030,
15,
483,
630,
14,
2467,
5,
6,
1990,
174,
788,
1151,
75,
31,
645,
14,
13,
20137,
248,
60,
14,
1021,
823,
1797,
129,
2757,
13,
7,
18,
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... |
Why do I get an OutOfMemoryError when inserting 50,000 objects into HashMap?
===
I am trying to insert about 50,000 objects (and therefore 50,000 keys) into a `java.util.HashMap<java.awt.Point, Segment>`. However, I keep getting an OutOfMemory exception. (`Segment` is my own class - very light weight - one `String` field, and 3 `int` fields).
<pre>Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
at java.util.HashMap.resize(HashMap.java:508)
at java.util.HashMap.addEntry(HashMap.java:799)
at java.util.HashMap.put(HashMap.java:431)
at bus.tools.UpdateMap.putSegment(UpdateMap.java:168)</pre>
This seems quite ridiculous since I see that there is plenty of memory available on the machine - both in free RAM and HD space for virtual memory.
Is it possible Java is running with some stringent memory requirements? Can I increase these?
Is there some weird limitation with `HashMap`? Am I going to have to implement my own? Are there any other classes worth looking at?
(I am running Java 5 under OS X 10.5 on an Intel machine with 2GB RAM.)
| 0 | [
2,
483,
107,
31,
164,
40,
70,
1041,
790,
5171,
93,
29992,
76,
14692,
68,
14522,
3916,
77,
19170,
15022,
60,
800,
3726,
3726,
31,
589,
749,
20,
14692,
88,
14522,
3916,
13,
5,
290,
1793,
14522,
5534,
6,
77,
21,
13,
1,
1004,
1385,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
set window text on the taskbar
===
const char* title = "old title";
HWND hwnd = FindWindow(title, title);
SetWindowText(hwnd, "new title");
this sets the title bar to "new title", but the caption in the task bar is still "old title". how do I set both?
if relevant, this is being done in a DLL loaded in the process which owns the window. | 0 | [
2,
309,
1463,
1854,
27,
14,
3005,
1850,
800,
3726,
3726,
11608,
38,
4892,
2483,
581,
800,
13,
7,
1218,
581,
7,
73,
746,
6156,
43,
746,
6156,
43,
800,
477,
27508,
5,
22235,
15,
581,
6,
73,
309,
27508,
11969,
5,
252,
6156,
43,
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... |
Does modern compilers optimize the x * 2 operation to x << 1?
===
Does the C++ compiler optimize this operation?
I would love to believe that yes. | 0 | [
2,
630,
773,
21486,
18,
22864,
14,
993,
1637,
172,
1453,
20,
993,
13,
1,
137,
60,
800,
3726,
3726,
630,
14,
272,
20512,
21486,
22864,
48,
1453,
60,
31,
83,
339,
20,
985,
30,
1643,
9,
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... |
ASP.NET, UserControls, and Styles... oh my...
===
We primarily use an ASP.NET environment at work. Right now I'm building an application which uses "Modules", which is just a UserControl, with its' Javascript right in the control, and a link element to the stylesheet for that control. I want to keep it modular, and would like the style of this control to be independent from the markup/javascript.
So I'm wondering what the preferred method of doing this is? Obviously if I didn't want the "theme" functionality I'm after, I could just use style tags at the top of the control. Right now I have a link element, as I said, and this isn't proper I don't think.
Does anyone have any preferred methods, and if so, what and why? | 0 | [
2,
28,
306,
9,
2328,
15,
4155,
12898,
18,
15,
17,
6443,
9,
9,
9,
1962,
51,
9,
9,
9,
800,
3726,
3726,
95,
2257,
275,
40,
28,
306,
9,
2328,
2307,
35,
170,
9,
193,
130,
31,
22,
79,
353,
40,
3010,
56,
2027,
13,
7,
19673,
160... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 would you approach, in .NET, allowing the tenants of a multi-tenant SaaS app to arbitrarily add properties to the entities of the model?
===
So, we're building a multi-tenant system to run as a service. We're starting from the ground up. We're following DDD; the domain has (at the moment) ~20 entities in it, and later there will be more. It is to be hosted by us, geographically redundant (n+1 of everything except SQL queries ;-) ), and of flexible design (well, that last is our own requirement, not the business', though they want us to be able to change it easily on demand of course). We're .NET based, and will be using a relational database for our backing store. We're not against using open-source tools and libraries (at all).
One of the must-have features from the business is that certain entities be extensible by the tenants of the system. For example, client A may want entity Foo to have Title and Abstract properties, whereas client B may want entity Foo to have Publish Date and Directed-By properties - and not Title Abstract.
It may also be the case that it should support data in multiple languages for tenants that want this - for example, one tenant may be interested in translating their whole account into two (or more) languages; both the "static" strings, and the strings attached to the entities as data.
So. Arbitrary number of fields (on top of some common baseline; there are certain things about these entities that all tenants will get), definable by the client (where they can define the data-type too). Possibility of translation of the data (without duplicating the entities - as in, without setting up one set in English, and then setting up the same set in French). Strongly typed, searchable, queryable backing storage, too (so, no extra-stuff-goes-in-an-XML-field, unless there's a way for it to come out strongly-typed and searchable). Performant (but as a secondary requirement; the feature is important enough to buy hardware for if necessary).
Data volumes? In our current system, an "average" client has hundreds of entities, a "big" client has thousands of entities. Requests will usually filter those lists for display to between 10-200ish, and the most common thing to want to do will involve maybe half-a-dozen entities (that in the new system, should be extensible).
Other points? Each Entity has a direct link to the tenant that owns it.
How does one go about this, in .NET-land? It's been suggested that we chuck our entities into an IoC container, and glob them together on the fly at run-time - but how does one map that to a relational database?
I also remember reading [Ayende's post](http://ayende.com/Blog/archive/2007/10/16/Lucene-as-a-data-repository.aspx) on this with Lucene.NET from some significant time ago that sounds good, but we haven't got any experience with Lucene.NET or nHibernate at present. (We're currently going to use Linq2Sql for our ORM but if we need to change that to support this, I'd personally be happy, frankly).
I read [this Castle dev list thread](http://groups.google.com/group/castle-project-users/browse_thread/thread/35c08000eb8f06d6/1145442775fd96e4) which is linked from Ayende, and it seems like nHibernate has something called an IUserType that might help - I wonder whether we might apply that, pulling the appropriate one our of IoC for each tenant? So one IUserType per tenant per extensible-entity, and store the data itself in an XML column inside of SQL Server (our most likely RDBMS).
Lastly, I've just read one suggestion around dynamically changing a DB-table per entity per tenant - but this sounds pretty... Fraught, honestly! I mean, it _could_ work, but it sounds like not such a great idea to give out the ability to do this to tenants (who may be less than tech-savvy). I suppose it could restricted to administrator-employees only... | 0 | [
2,
184,
83,
42,
2141,
15,
19,
13,
9,
2328,
15,
2719,
14,
16126,
16,
21,
1889,
8,
1316,
1830,
18194,
18,
4865,
20,
13,
25267,
18966,
3547,
3704,
20,
14,
12549,
16,
14,
1061,
60,
800,
3726,
3726,
86,
15,
95,
22,
99,
353,
21,
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... |
Programmatically Creating a IIS6 Website/App Pool in Nant
===
I'm relatively new to Nant, what i'd like to do is have a task that creates a new Website and AppPool in IIS6
is there a way to do this in Nant?
Essentially the task would need to set all the appropriate properties including the correct version of the .net Framework
Ideally i'd also like to check if the site is already present in IIS.
| 0 | [
2,
625,
6732,
1326,
2936,
21,
595,
18,
379,
2271,
118,
7753,
3067,
19,
13,
11028,
800,
3726,
3726,
31,
22,
79,
3109,
78,
20,
13,
11028,
15,
98,
31,
22,
43,
101,
20,
107,
25,
57,
21,
3005,
30,
9695,
21,
78,
2271,
17,
4865,
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... |
ASP.Net MVC Route to Username
===
Note: I am just now getting started with MVC so if this is easy, be kind.
I am trying to create a route with a Username...
So the URL would be mydomain.com/abrudtkhul (abrudtkhul being the username)
My application will have public profiles based on usernames (Ex: http://delicious.com/abrudtkuhl). I want to replicate this URL scheme.
How can I structure this in ASP.Net MVC? I am using Membership/Roles Providers too.
Thanks | 0 | [
2,
28,
306,
9,
2328,
307,
8990,
858,
20,
4155,
7259,
800,
3726,
3726,
1945,
45,
31,
589,
114,
130,
1017,
373,
29,
307,
8990,
86,
100,
48,
25,
2010,
15,
44,
825,
9,
31,
589,
749,
20,
1600,
21,
858,
29,
21,
4155,
7259,
9,
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... |
Can you programmatically change session time out in ASP.NET?
===
Can it be done or the only way is to configure it on IIS? | 0 | [
2,
92,
42,
625,
6732,
1326,
753,
3723,
85,
70,
19,
28,
306,
9,
2328,
60,
800,
3726,
3726,
92,
32,
44,
677,
54,
14,
104,
161,
25,
20,
1065,
15951,
32,
27,
595,
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,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
What's the UITableView index magnifying glass character?
===
In Apple's iPhone apps (like Contacts), they have a nice magnifying glass icon at the top of the table view index. Since the table view index API is character-based, I assume that this magnifying glass is a Unicode character. So far I've resorted to placing a question mark character there, but that looks lame.
Can anyone tell me what character the magnifying glass is? | 0 | [
2,
98,
22,
18,
14,
13,
11193,
579,
4725,
4348,
4723,
103,
10874,
1350,
925,
60,
800,
3726,
3726,
19,
4037,
22,
18,
21024,
4865,
18,
13,
5,
1403,
11894,
6,
15,
59,
57,
21,
2210,
4723,
103,
10874,
1350,
9801,
35,
14,
371,
16,
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 can I know when .aspx call is finished?
===
I am building a Flex Application that calls a .aspx page on the same webserver which builds a PDF report using SQL Reporting Services. When the report is built it prompts the user to open or save the PDF.
We are trying to find a way to display a Progress Bar to let the user know that the report they requested is being built, and then destroy the Progress Bar once the report is finished being built.
I've tried opening a new window using JavaScript and trying to catch when the window closes, as well as trying XMLHTTPRequest, but nothing to seems to work.
Does anyone have any suggestions? | 0 | [
2,
184,
92,
31,
143,
76,
13,
9,
472,
306,
396,
645,
25,
842,
60,
800,
3726,
3726,
31,
589,
353,
21,
14409,
3010,
30,
3029,
21,
13,
9,
472,
306,
396,
2478,
27,
14,
205,
2741,
10321,
106,
56,
1895,
18,
21,
13,
11124,
1330,
568... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
ToolStrip Overflow
===
I need to replace the standard Overflow function in a ToolStrip to a "More..." button which would then pop up a menu with the overflowed items. Does anyone have any ideas about how to accomplish this? | 0 | [
2,
4672,
17851,
20285,
800,
3726,
3726,
31,
376,
20,
3934,
14,
1236,
20285,
1990,
19,
21,
4672,
17851,
20,
21,
13,
7,
1995,
9,
9,
9,
7,
5167,
56,
83,
94,
1675,
71,
21,
11379,
29,
14,
20285,
69,
3755,
9,
630,
1276,
57,
186,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... |
Where should caching occur in an ASP.NET MVC application?
===
I'm needing to cache some data using **System.Web.Caching.Cache**. Not sure if it matters, but the data does not come from a database, but a plethora of custom objects.
The APS.NET MVC is fairly new to me and I'm wondering where it makes sense for this caching to occur?
###Model or Controller?
At some level this makes sense to cache at the **Model** level but I don't necessarily know the implications of doing this (if any). If caching were to be done at the **Controller** level, will that affect all requests, or just for the current **HttpContext**?
####So... where should application data caching be done, and what's a good way of actually doing it?
| 0 | [
2,
113,
378,
1658,
7192,
3744,
19,
40,
28,
306,
9,
2328,
307,
8990,
3010,
60,
800,
3726,
3726,
31,
22,
79,
12210,
20,
16522,
109,
1054,
568,
13,
1409,
10724,
9,
14113,
9,
793,
7192,
9,
793,
2569,
1409,
9,
52,
562,
100,
32,
455... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
implement zip using foldr
===
I'm currently on chapter 4 of Real World Haskell, and I'm trying to wrap my head around [implementing foldl in terms of foldr][1].
(Here's their code:)
myFoldl :: (a -> b -> a) -> a -> [b] -> a
myFoldl f z xs = foldr step id xs z
where step x g a = g (f a x)
I thought I'd try to implement `zip` using the same technique, but I don't seem to be making any progress. Is it even possible?
[1]: http://book.realworldhaskell.org/read/functional-programming.html#x_E9 | 0 | [
2,
8713,
12133,
568,
14629,
139,
800,
3726,
3726,
31,
22,
79,
871,
27,
1260,
268,
16,
683,
126,
63,
16507,
15,
17,
31,
22,
79,
749,
20,
8118,
51,
157,
140,
636,
8983,
413,
1130,
68,
14629,
255,
19,
1663,
16,
14629,
139,
500,
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... |
Game programming - How to avoid reinventing the wheel
===
Summary:
> **Can I program a "thick
> client" game in C without reinventing
> wheels**, or should I just bite the
> bullet and use some library or SDK?
> I'm a moderate C programmer and am not
> afraid to work with pointers, data
> structures, memory locations, etc. if
> it will give me the control I need to
> make a great "thick-client" game.
> However, I'm thinking of eschewing
> high-level languages & frameworks for
> the sake of power and control, *not*
> ease of use.
I'm interesting in tinkering with a 2D fighting/platforming game as a side project sometime. I'm primarily a Linux server-side programmer with experience in Python, Ruby and PHP. I know that there are excellent frameworks in some of these languages, like [PyGame][1]. I am also aware of the success people have had with stuff like Air and .NET... but I have some concerns:
- **Performance**: Scripting languages are notoriously slow. If I'm making a real-time game, I want it to be as snappy as possible.
- **Huge binaries**: Using frameworks like .NET or scripting languages like Ruby often result in big CLRs or libraries that you wouldn't otherwise need. The game I want to make will be small and simple--I don't want its CLR to be bigger than the game itself!
- **Extra stuff**: Honestly, I just don't like the idea of inheriting some big game library's baggage if I can wrap my head around my own code better.
I'm asking this question because I know I'm very susceptible to Not Invented Here Syndrome. I always want to program it myself, and I'm sure it wastes a lot of time. However, this works out for me remarkably often--for example, instead of using [Rails][2] (a very big web project framework with an ORM and GUI toolkit baked in), I used an array of smaller Ruby tools like [rack][3] and [sequel][4] that fit together beautifully.
So, I turn to you, SO experts. Am I being naive? Here's how I see it:
- **Use C**
- **Cons**
- Will probably make me hate programming
- High risk of reinventing wheels
- High risk of it taking so long that I lose interest
- **Pros**
- Tried & true - most A-list games are done in C (is this still true today?)
- High level of control over memory management, speed, asset management, etc., which I trust myself to learn to handle
- No cruft
- **Use framework or SDK**
- **Cons**
- Risk of oversized deliverable
- Dependent on original library authors for all facets of game development--what if there isn't a feature I want? I'll have to program it myself, which isn't bad, but partially defeats the purpose of using a high-level framework in the first place
- High risk of performance issues
- **Pros**
- MUCH faster development time
- Might be easier to maintain
- No time wasted reinventing common paradigms
What else can I add to this list? Is it a pure judgment call, or can someone seal the deal for me? Book suggestions welcome.
[1]: http://www.pygame.org/news.html
[2]: http://www.rubyonrails.org/
[3]: http://rack.rubyforge.org/
[4]: http://sequel.rubyforge.org/ | 0 | [
2,
250,
3143,
13,
8,
184,
20,
2658,
7102,
6645,
68,
14,
3556,
800,
3726,
3726,
14740,
45,
13,
1,
13,
1409,
1245,
31,
625,
21,
13,
7,
38,
15477,
13,
1,
6819,
7,
250,
19,
272,
366,
7102,
6645,
68,
13,
1,
7384,
1409,
15,
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... |
Best website reference for Regex information and references?
===
My applications frequently use Regex for input validation.
Most of the Regex values that I need are pretty common (email address, basic types, etc).
What is a good place to both learn about Regex creation and find common Regex patterns? | 0 | [
2,
246,
2271,
2801,
26,
7953,
1706,
676,
17,
7231,
60,
800,
3726,
3726,
51,
3767,
3086,
275,
7953,
1706,
26,
6367,
27999,
9,
127,
16,
14,
7953,
1706,
4070,
30,
31,
376,
50,
1772,
757,
13,
5,
62,
8079,
3218,
15,
2125,
2551,
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... |
Redirect .NET StreamWriter output to a String variable
===
I'd like to know if it is possible to redirect StreamWriter output to a variable
Something like
String^ myString;
StreamWriter sw = gcnew StreamWriter([somehow specify myString])
sw->WriteLine("Foo");
then myString will contain Foo.
The reason I would like to do this is to reuse a complex function. I should probably refactor it into a String returning function but it still would be a nice hack to know
| 0 | [
2,
302,
14706,
13,
9,
2328,
3766,
9657,
5196,
20,
21,
3724,
7612,
800,
3726,
3726,
31,
22,
43,
101,
20,
143,
100,
32,
25,
938,
20,
302,
14706,
3766,
9657,
5196,
20,
21,
7612,
301,
101,
3724,
1,
51,
11130,
73,
3766,
9657,
8783,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 set up ObjectDataSource select parameters at runtime
===
I'm trying to add parameters to an objectDataSource at runtime like this:
Parameter objCustomerParameter = new Parameter("CustomerID", DbType.String, customerID);
Parameter objGPDatabaseParameter = new Parameter("Database", DbType.String, gpDatabase);
//set up object data source parameters
objCustomer.SelectParameters["CustomerID"] = objCustomerParameter;
objCustomer.SelectParameters["Database"] = objGPDatabaseParameter;
At what point in the objectDataSource lifecycle should these parameters be added (what event)? | 0 | [
2,
184,
107,
31,
309,
71,
3095,
18768,
12097,
5407,
12905,
35,
485,
891,
800,
3726,
3726,
31,
22,
79,
749,
20,
3547,
12905,
20,
40,
3095,
18768,
12097,
35,
485,
891,
101,
48,
45,
18906,
5122,
728,
4636,
262,
1263,
6351,
7307,
800,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Managing third party components in .net project.
===
How do you manage the third party components that is used in a .net project. I currently add a folder called references that contains all the dlls used and all the projects refer those from there. This folder in checked in along with the source code to source control. I wanted to know if there was a better approach that others were following.
| 0 | [
2,
5616,
422,
346,
5090,
19,
13,
9,
2328,
669,
9,
800,
3726,
3726,
184,
107,
42,
4705,
14,
422,
346,
5090,
30,
25,
147,
19,
21,
13,
9,
2328,
669,
9,
31,
871,
3547,
21,
19294,
227,
7231,
30,
1588,
65,
14,
13,
43,
211,
18,
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... |
Where to find the best user story template?
===
I want to implement user stories in a new project where can i find a good template or other ones user in agile development? | 0 | [
2,
113,
20,
477,
14,
246,
4155,
609,
22894,
60,
800,
3726,
3726,
31,
259,
20,
8713,
4155,
1650,
19,
21,
78,
669,
113,
92,
31,
477,
21,
254,
22894,
54,
89,
53,
18,
4155,
19,
27475,
522,
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... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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... |
Trailing slashes in Pylons Routes
===
What is the best way to make trailing slashes not matter in the latest version of Routes (1.10)? I currently am using the clearly non-DRY:
map.connect('/logs/', controller='logs', action='logs')
map.connect('/logs', controller='logs', action='logs')
I think that turning minimization on would do the trick, but am under the impression that it was disabled in the newer versions of Routes for a reason. Unfortunately documentation doesn't seem to have caught up with Routes development, so I can't find any good resources to go to. Any ideas? | 0 | [
2,
14323,
14098,
160,
19,
29262,
18,
5050,
800,
3726,
3726,
98,
25,
14,
246,
161,
20,
233,
14323,
14098,
160,
52,
1161,
19,
14,
5736,
615,
16,
5050,
13,
5,
165,
9,
1036,
6,
60,
31,
871,
589,
568,
14,
2885,
538,
8,
12611,
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... |
Convert HTML back to Markdown for editing in wmd
===
I am curious to do what happens when you edit a post on this site.
I am using wmd for my markdown editor, of course when I goto edit, I get the HTML it generated not the markdown like on stackoverflow. Now, is there a way I can store both? or is it reliable enough to simply convert the HTML back to markdown to show in the wmd editor?
Thanks! | 0 | [
2,
8406,
13,
15895,
97,
20,
943,
2968,
26,
9510,
19,
19312,
43,
800,
3726,
3726,
31,
589,
7686,
20,
107,
98,
5531,
76,
42,
9392,
21,
678,
27,
48,
689,
9,
31,
589,
568,
19312,
43,
26,
51,
943,
2968,
1835,
15,
16,
674,
76,
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... |
Problem with editing Template Monster .fla file
===
I am having the worst luck with this. We bought a template to update our own website (don't have enough time to start our own from scratch!) but when I make simple changes in the Flash CS4 native file and re-export the swf, it doesn't work correctly!
I am wondering if anyone has run across the same problems with a Template Monster Flash website template.
Thanks. | 0 | [
2,
1448,
29,
9510,
22894,
5100,
13,
9,
9165,
3893,
800,
3726,
3726,
31,
589,
452,
14,
4126,
5419,
29,
48,
9,
95,
2448,
21,
22894,
20,
11100,
318,
258,
2271,
13,
5,
804,
22,
38,
57,
511,
85,
20,
799,
318,
258,
37,
12395,
187,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 add a form to a view with drupal 6.x views 2?
===
I want to add a drupal form to the top of a view. The view does not need to receive the results of the form but the _submit hook of the form should be able to read the first argument of the view that the form was on.
Where is the best place to add this? Custom module or template file and what are the necessary filenames/hooks? | 0 | [
2,
184,
107,
31,
3547,
21,
505,
20,
21,
1418,
29,
15708,
6720,
400,
9,
396,
4146,
172,
60,
800,
3726,
3726,
31,
259,
20,
3547,
21,
15708,
6720,
505,
20,
14,
371,
16,
21,
1418,
9,
14,
1418,
630,
52,
376,
20,
2588,
14,
1736,
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... |
How to avoid Outlook security alert when reading outlook message from C# program
===
I have a requirement of reading subject, sender address and message body of new message in my Outlook inbox from a C# program. But I am getting security alert 'A Program is trying to access e-mail addresses you have stored in Outlook. Do you want to allow this'.
By some googling I found few third party COM libraries to avoid this. But I am looking for a solution which don't require any third party COM library. | 0 | [
2,
184,
20,
2658,
19837,
1221,
7863,
76,
1876,
19837,
2802,
37,
272,
5910,
625,
800,
3726,
3726,
31,
57,
21,
8981,
16,
1876,
1550,
15,
2660,
106,
3218,
17,
2802,
358,
16,
78,
2802,
19,
51,
19837,
19,
5309,
37,
21,
272,
5910,
625... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 MVC - Should business logic exist in controllers?
===
Derik Whitaker posted an [article][1] a couple of days ago that hit a point that I've been curious about for some time: **should business logic exist in controllers?**
So far all the ASP.NET MVC demos I've seen put repository access and business logic in the controller. Some even throw validation in there as well. This results in fairly large, bloated controllers. Is this really the way to use the MVC framework? It seems that this is just going to end up with a lot of duplicated code and logic spread out across different controllers.
[1]: http://devlicio.us/blogs/derik_whittaker/archive/2008/10/22/how-is-interacting-with-your-data-repository-in-your-controller-different-or-better-than-doing-it-in-your-code-behind.aspx | 0 | [
2,
28,
306,
9,
2328,
307,
8990,
13,
8,
378,
508,
7085,
3182,
19,
9919,
18,
60,
800,
3726,
3726,
121,
6639,
27960,
6054,
40,
636,
20360,
500,
2558,
165,
500,
21,
1335,
16,
509,
1464,
30,
770,
21,
454,
30,
31,
22,
195,
74,
7686,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
General Business Object Practices (and exception errors - redux)
===
Recently, [I made a post about the developers I'm working with not using try catch blocks properly][1], and unfortuantely using try... catch blocks in critical situations and ignoring the exception error all together. causing me major heart ache. Here is an example of one of the several thousand sections of code that they did this (some code left out that doesn't particuarly matter:
public void AddLocations(BOLocation objBllLocations)
{
try
{
dbManager.Open();
if (objBllLocations.StateID != 0)
{
// about 20 Paramters added to dbManager here
}
else
{
// about 19 Paramters added here
}
dbManager.ExecuteNonQuery(CommandType.StoredProcedure, "ULOCATIONS.AddLocations");
}
catch (Exception ex)
{
}
finally
{
dbManager.Dispose();
}
}
This is absolutely discusting, in my eyes, and does not notify the user in case some potential problem occurred. I know many people say that OOP is evil, and that adding multiple layers adds to the number of lines of code and to the complexity of the program, leading to possible issues with code maintainence. Much of my programming background, I personally, have taken almost the same approach in this area. Below I have listed out a basic structure of the way I normally code in such a situation, and I've been doing this accross many languages in my career, but this particular code is in C#. But the code below is a good basic idea of how I use the Objects, it seems to work for me, but since this is a good source of some fairly inteligent programming mines, I'd like to know If I should re-evaluate this technique that I've used for so many years. Mainly, because, in the next few weeks, i'm going to be plunging into the not so good code from the outsourced developers and modifying huge sections of code. i'd like to do it as well as possible. sorry for the long code reference.
// *******************************************************************************************
/// <summary>
/// Summary description for BaseBusinessObject
/// </summary>
/// <remarks>
/// Base Class allowing me to do basic function on a Busines Object
/// </remarks>
public class BaseBusinessObject : Object, System.Runtime.Serialization.ISerializable
{
public enum DBCode
{ DBUnknownError,
DBNotSaved,
DBOK
}
// private fields, public properties
public int m_id = -1;
public int ID { get { return m_id; } set { m_id = value; } }
private int m_errorCode = 0;
public int ErrorCode { get { return m_errorCode; } set { m_errorCode = value; } }
private string m_errorMsg = "";
public string ErrorMessage { get { return m_errorMsg; } set { m_errorMsg = value; } }
private Exception m_LastException = null;
public Exception LastException { get { return m_LastException; } set { m_LastException = value;} }
//Constructors
public BaseBusinessObject()
{
Initialize();
}
public BaseBusinessObject(int iID)
{
Initialize();
FillByID(iID);
}
// methods
protected void Initialize()
{
Clear();
Object_OnInit();
// Other Initializable code here
}
public void ClearErrors()
{
m_errorCode = 0; m_errorMsg = ""; m_LastException = null;
}
void System.Runtime.Serialization.ISerializable.GetObjectData(
System.Runtime.Serialization.SerializationInfo info,
System.Runtime.Serialization.StreamingContext context)
{
//Serialization code for Object must be implemented here
}
// overrideable methods
protected virtual void Object_OnInit()
{
// User can override to add additional initialization stuff.
}
public virtual BaseBusinessObject FillByID(int iID)
{
throw new NotImplementedException("method FillByID Must be implemented");
}
public virtual void Clear()
{
throw new NotImplementedException("method Clear Must be implemented");
}
public virtual DBCode Save()
{
throw new NotImplementedException("method Save Must be implemented");
}
}
// *******************************************************************************************
/// <summary>
/// Example Class that might be based off of a Base Business Object
/// </summary>
/// <remarks>
/// Class for holding all the information about a Customer
/// </remarks>
public class BLLCustomer : BaseBusinessObject
{
// ***************************************
// put field members here other than the ID
private string m_name = "";
public string Name { get { return m_name; } set { m_name = value; } }
public override void Clear()
{
m_id = -1;
m_name = "";
}
public override BaseBusinessObject FillByID(int iID)
{
Clear();
try
{
// usually accessing a DataLayerObject,
//to select a database record
}
catch (Exception Ex)
{
Clear();
LastException = Ex;
// I can have many different exception, this is usually an enum
ErrorCode = 3;
ErrorMessage = "Customer couldn't be loaded";
}
return this;
}
public override DBCode Save()
{
DBCode ret = DBCode.DBUnknownError;
try
{
// usually accessing a DataLayerObject,
//to save a database record
ret = DBCode.DBOK;
}
catch (Exception Ex)
{
LastException = Ex;
// I can have many different exception, this is usually an enum
// i do not usually use just a General Exeption
ErrorCode = 3;
ErrorMessage = "some really weird error happened, customer not saved";
ret = DBCode.DBNotSaved;
}
return ret;
}
}
// *******************************************************************************************
// Example of how it's used on an asp page..
protected void Page_Load(object sender, EventArgs e)
{
// Simplifying this a bit, normally, I'd use something like,
// using some sort of static "factory" method
// BaseObject.NewBusinessObject(typeof(BLLCustomer)).FillByID(34);
BLLCustomer cust = ((BLLCustomer)new BLLCustomer()).FillByID(34);
if (cust.ErrorCode != 0)
{
// There was an error.. Error message is in
//cust.ErrorMessage
// some sort of internal error code is in
//cust.ErrorCode
// Give the users some sort of message through and asp:Label..
// probably based off of cust.ErrorMessage
//log can be handled in the data, business layer... or whatever
lab.ErrorText = cust.ErrorMessage;
}
else
{
// continue using the object, to fill in text boxes,
// literals or whatever.
this.labID = cust.ID.toString();
this.labCompName = cust.Name;
}
}
Bottom line, my question is, Am I over complicating things with the muliple layers, and the inherited classes or is my old concept illustrated still working good and stable? Is there a better way now a days to accomplish these things? Should I go to just making straight SQL calls from the asp.net page code behind pages as fellow work associate developer suggested (though that last solution makes me feel icky), instead of going through a business object, and data layer (data layer not shown, but basically holds all the stored proc calls). Yeah, another developer did ask me why i go through the effort of layering things, when you can just type what you need straight in a *.aspx.cs code behind page, and then I can have the joys of over 1k lines of code behind. What is some advice here?
[1]: http://stackoverflow.com/questions/204814/is-there-any-valid-reason-to-ever-ignore-a-caught-exception | 0 | [
2,
297,
508,
3095,
5242,
13,
5,
290,
5391,
11908,
13,
8,
402,
7147,
6,
800,
3726,
3726,
1989,
15,
636,
49,
117,
21,
678,
88,
14,
10168,
31,
22,
79,
638,
29,
52,
568,
1131,
2949,
5198,
7428,
500,
2558,
165,
500,
15,
17,
367,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
from Silverlight, how to launch / navigate to another page
===
An easy question obviously -- but the first couple things that came up on Google seem to be out of date, so I thought I'd drop the version I eventually tracked down here to save somebody a minute or two later...
| 0 | [
2,
37,
1172,
3130,
15,
184,
20,
3394,
13,
118,
20782,
20,
226,
2478,
800,
3726,
3726,
40,
2010,
1301,
4409,
13,
8,
8,
47,
14,
64,
1335,
564,
30,
281,
71,
27,
8144,
2260,
20,
44,
70,
16,
1231,
15,
86,
31,
289,
31,
22,
43,
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... |
Are you obsessed with redundant "Using" statements?
===
I know VS2008 has the remove and sort function for cleaning up using statements, as does Resharper. Apart from your code being "clean" and removing the problem of referencing namespaces which might not exist in the future, what are the benefits of maintaining a "clean" list of using statements?
Less code?
Faster compilation times?
| 0 | [
2,
50,
42,
19262,
29,
24295,
13,
7,
12655,
7,
9015,
60,
800,
3726,
3726,
31,
143,
4611,
2753,
63,
14,
4681,
17,
2058,
1990,
26,
9724,
71,
568,
9015,
15,
28,
630,
302,
23646,
106,
9,
2629,
37,
154,
1797,
142,
13,
7,
20254,
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 can I run Cygwin Bash Shell from within Emacs?
===
I am running GNU Emacs on Windows so entering:
M-x shell
launches the Windows command-line DOS shell. However, I would like to instead be able to run the Cygwin Bash Shell (or any other non-Windows shell) from within Emacs. How can this be easily done?
| 0 | [
2,
184,
92,
31,
485,
6728,
263,
4181,
13158,
3593,
37,
363,
13,
62,
6893,
18,
60,
800,
3726,
3726,
31,
589,
946,
26092,
13,
62,
6893,
18,
27,
1936,
86,
4604,
45,
307,
8,
396,
3593,
22933,
14,
1936,
1202,
8,
1143,
107,
18,
3593... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
JFileChooser use within JApplet
===
Can a `JApplet` use a `JFileChooser` so that the user can select a file on his hard-drive? Or would this violate Java applet security? (I'm assuming that the default security settings are being used. I don't want to ask my users to grant me extra permissions.)
| 0 | [
2,
487,
16877,
2613,
759,
106,
275,
363,
487,
24212,
38,
800,
3726,
3726,
92,
21,
13,
1,
728,
24212,
38,
1,
275,
21,
13,
1,
728,
16877,
2613,
759,
106,
1,
86,
30,
14,
4155,
92,
5407,
21,
3893,
27,
33,
552,
8,
14573,
60,
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... |
How to connect to 2 databases at the same time in PHP
===
I am trying to connect to 2 databases on the same instance of MySQL from 1 PHP script.
At the moment the only way I've figured out is to connect to both databases with a different user for each.
I am using this in a migration script where I am grabbing data from the original database and inserting it into the new one, so I am looping through large lists of results.
Connecting to 1 database and then trying to initiate a second connection with the same user just changes the current database to the new one.
Any other ideas? | 0 | [
2,
184,
20,
6379,
20,
172,
6018,
18,
35,
14,
205,
85,
19,
13,
26120,
800,
3726,
3726,
31,
589,
749,
20,
6379,
20,
172,
6018,
18,
27,
14,
205,
4851,
16,
51,
18,
22402,
37,
137,
13,
26120,
3884,
9,
35,
14,
688,
14,
104,
161,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 make my regexp match first pattern instead of last?
===
I'm probably doing this all wrong. I have a text file full of data and I want to match and replace patterns of "item" and "catalog number" that are in the file. But the order of each element in the file is very important, so I want to match/replace starting from the top of the file and then work my way down.
The code snippet below actually works, but when I execute it, it replaces the third instance of the "SeaMonkey" & "SMKY-1978" pattern and then it replaces the second instance of that pattern. What I'd like it to do is replace the first instance of the pattern and then the second.
So I'd like the output to say "Found **Kurt's** SMKY-1978 SeaMonkeys" and then "Found **Shane's** SMKY-1978 SeaMonkeys" and then leave Mick's SMKY-1978 SeaMonkeys alone since I only want to find and replace the first 2 instances of the pattern. Right now it says "Found **Shane's** SMKY-1978 SeaMonkeys" and "Found **Mick's** SMKY-1978 SeaMonkeys" because it is matching the last pattern each time the for loop is executed.
So am I missing a subtle little known regexp character or am I just doing what I want to do completely and utterly wrong?
Here is the working code:
# my regexp matches from the bottom to the top but I'd like it to replace from the top down
local $/=undef;
my $DataToParse = <DATA>;
my $item = "SeaMonkeys";
my $catNum = "SMKY-1978";
my $maxInstancesToReplace = 2;
parseData();
exit();
sub parseData {
for (my $counter = 0; $counter < $maxInstancesToReplace; $counter++) {
# Stick in a temporary text placeholder that I will replace later after more processing
$DataToParse =~ s/(.+)\sELEMENT\s(.+?)\s\(Item := \"$item\".+?CatalogNumber := \"$catNum.+?END_ELEMENT(.+)/$1 ***** Found $2\'s $catNum $item. (counter: $counter) *****$3/s;
}
print("Here's the result:\n$DataToParse\n");
}
__DATA__
ELEMENT Kurt (Item := "BrightLite",
ItemID := 29,
CatalogNumber := "BTLT-9274",
Vendor := 100,
END_ELEMENT
ELEMENT Mick (Item := "PetRock",
ItemID := 36,
CatalogNumber := "PTRK-3475/A",
Vendor := 82,
END_ELEMENT
ELEMENT Kurt (Item := "SeaMonkeys",
ItemID := 12,
CatalogNumber := "SMKY-1978/E",
Vendor := 77,
END_ELEMENT
ELEMENT Joe (Item := "Pong",
ItemID := 24,
CatalogNumber := "PONG-1482",
Vendor := 5,
END_ELEMENT
ELEMENT Shane (Item := "SeaMonkeys",
ItemID := 1032,
CatalogNumber := "SMKY-1978/E",
Vendor := 77,
END_ELEMENT
ELEMENT Kurt (Item := "Battleship",
ItemID := 99,
CatalogNumber := "BTLS-5234",
Vendor := 529,
END_ELEMENT
ELEMENT Mick (Item := "SeaMonkeys",
ItemID := 8,
CatalogNumber := "SMKY-1978/F",
Vendor := 77,
END_ELEMENT
ELEMENT Frank (Item := "PetRock",
ItemID := 42,
CatalogNumber := "PTRK-3475/B",
Vendor := 82,
END_ELEMENT
ELEMENT Joe (Item := "SeaMonkeys",
ItemID := 8,
CatalogNumber := "SMKY-1979/A",
Vendor := 77,
END_ELEMENT
And here is what it currently outputs:
Here's the result:
ELEMENT Kurt (Item := "BrightLite",
ItemID := 29,
CatalogNumber := "BTLT-9274",
Vendor := 100,
END_ELEMENT
ELEMENT Mick (Item := "PetRock",
ItemID := 36,
CatalogNumber := "PTRK-3475/A",
Vendor := 82,
END_ELEMENT
ELEMENT Kurt (Item := "SeaMonkeys",
ItemID := 12,
CatalogNumber := "SMKY-1978/E",
Vendor := 77,
END_ELEMENT
ELEMENT Joe (Item := "Pong",
ItemID := 24,
CatalogNumber := "PONG-1482",
Vendor := 5,
END_ELEMENT
***** Found Shane's SMKY-1978 SeaMonkeys. (counter: 1) *****
ELEMENT Kurt (Item := "Battleship",
ItemID := 99,
CatalogNumber := "BTLS-5234",
Vendor := 529,
END_ELEMENT
***** Found Mick's SMKY-1978 SeaMonkeys. (counter: 0) *****
ELEMENT Frank (Item := "PetRock",
ItemID := 42,
CatalogNumber := "PTRK-3475/B",
Vendor := 82,
END_ELEMENT
ELEMENT Joe (Item := "SeaMonkeys",
ItemID := 8,
CatalogNumber := "SMKY-1979/A",
Vendor := 77,
END_ELEMENT | 0 | [
2,
92,
31,
233,
51,
7953,
6899,
730,
64,
3732,
700,
16,
236,
60,
800,
3726,
3726,
31,
22,
79,
910,
845,
48,
65,
1389,
9,
31,
57,
21,
1854,
3893,
503,
16,
1054,
17,
31,
259,
20,
730,
17,
3934,
6282,
16,
13,
7,
2119,
79,
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... |
Touchscreen-Oriented Website Development Recommendations for Non-Microsoft Platform
===
We are currently designing a website that will be accessed from kiosks in a museum. Users will need to be able to browse through a number of different web pages that will currently contain static HTML content as well as go through various interactive presentations that will be based on flash and run in flash player. Users may need to input some information into a simple registration form from the kiosk as well.
One reason that we are currently designing this to run in a browser is because the same site and interactive presentations that are being accessed from the kiosks will also be available on the web.
Does anyone have recommendations on whether this design will even work or whether we should simply build two versions of the content, one for web and one for kiosk? What experiences has anyone had with building a website that is available on touchscreen and via the web?
This is a first time effort both for myself and for my company so any warning, suggestions, recommendations at all would be greatly appreciated.
<em>Note:</em> We are currently working with Flash to build our interactive content and a LAMPP stack for the server-side everything. | 0 | [
2,
1723,
7187,
8,
6800,
2271,
522,
12121,
26,
538,
8,
22019,
12980,
2452,
800,
3726,
3726,
95,
50,
871,
15026,
21,
2271,
30,
129,
44,
12904,
37,
28092,
18,
19,
21,
774,
9,
3878,
129,
376,
20,
44,
777,
20,
10175,
62,
120,
21,
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... |
With Spring Webflow 2, what request parameters, if any, are necessary to trigger "submit" transition from view-state?
===
My view-state to action-state transition does not appear to be happening. In the following example, I want the view-state to transition to the action-state when the user submits the form. Pretty basic stuff. But the <code>setA()</code> method does not get called.
In the jsp, does the <code> submit input</code> element need to have a name of "`_`eventId", or "`_`eventId`_`submit", or is no name necessary? Or is something else wrong? What is webflow checking against when evaluating the <code>on</code> attribute of <code>transition</code> element?
<flow ... start-state="stateA">
<var name="flowBean" class="demo.webflow.WebFlowBean" />
<view-state id="stateA" view="fooView">
<transition on="submit" to="changeA" />
</view-state>
<action-state id="changeA">
<evaluate expression="flowScope.flowBean.setA(requestParameters.value)" />
...
</action-state>
JSP:
<form action="demo.htm" name="myform" id="myform" method="post">
<input type="hidden" name="_flowExecutionKey" value='<c:out value="${flowExecutionKey}"/>'/>
<input type="submit" name="????" value="Continue"/> | 0 | [
2,
29,
1573,
2741,
9990,
172,
15,
98,
3772,
12905,
15,
100,
186,
15,
50,
2378,
20,
7286,
13,
7,
7563,
5130,
7,
4513,
37,
1418,
8,
3859,
60,
800,
3726,
3726,
51,
1418,
8,
3859,
20,
1028,
8,
3859,
4513,
630,
52,
1893,
20,
44,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Why do browser not have a file upload progress bar?
===
I wonder why no browser out there has such simple but essential feature. Am I missing something? Is there a technical reason?
I'm tired of all those javascript/flash/java hacks out there ...
| 0 | [
2,
483,
107,
16495,
52,
57,
21,
3893,
71,
8294,
3455,
748,
60,
800,
3726,
3726,
31,
2666,
483,
90,
16495,
70,
80,
63,
145,
1935,
47,
5832,
1580,
9,
589,
31,
2863,
301,
60,
25,
80,
21,
2447,
1215,
60,
31,
22,
79,
4117,
16,
65... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 list the member functions of a javascript object in the Visual Studio command window without gettin the ellipses {...}?
===
When debugging javascript in Visual Studio 2008 and I use the ? command in the command window to list a javascript object's members I always get that elllipses {...}. Example:
>? Page_Validators
{...}
[0]: {object}
[1]: {object}
[2]: {object}
[3]: {object}
[4]: {object}
[5]: {object}
length: 6
I'm assuming these are the object's member functions. Is there a way to list the members in that {...} ? A one-liner command would be ideal.
Thanks.
| 0 | [
2,
184,
107,
31,
968,
14,
322,
3719,
16,
21,
8247,
8741,
3095,
19,
14,
3458,
1120,
1202,
1463,
366,
164,
2864,
14,
13,
4223,
1919,
160,
13,
1,
9,
9,
9,
1,
60,
800,
3726,
3726,
76,
121,
16254,
2762,
8247,
8741,
19,
3458,
1120,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
One-to-many relationship in the same table
===
Im trying to use to define a one-to-many relationship in a single table. For example lets say I have a Groups table with these entries:
<pre>
Group:
Group_1:
name: Atlantic Records
Group_2:
name: Capital Records
Group_3:
name: Gnarls Barkley
Group_4:
name: Death Cab For Cutie
Group_5:
name: Coldplay
Group_6:
name: Management Company
</pre>
The group Coldplay could be a child of the group Capital Records and a child of the group Management Company and Gnarls Barkley could only be a child of Atlantic Records.
What is the best way to represent this relationship. I am using PHP and mySQL. Also I am using PHP-Doctrine as my ORM if that helps.
I was thinking that I would need to create a linking table called group_groups that would have 2 columns. owner_id and group_id. However i'm not sure if that is best way to do this.
Any insight would be appreciated. Let me know if I explained my problem good enough. | 0 | [
2,
53,
8,
262,
8,
14842,
1429,
19,
14,
205,
859,
800,
3726,
3726,
797,
749,
20,
275,
20,
9267,
21,
53,
8,
262,
8,
14842,
1429,
19,
21,
345,
859,
9,
26,
823,
6884,
395,
31,
57,
21,
1170,
859,
29,
158,
11399,
45,
13,
1,
3515... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Whats a good process for writing story cards?
===
We are just going through defining our story cards for the next project.
- We have a good idea what the customer want through workshops
- We have a business requirement document that will be signed off by them.
Our proces of defining storys is as follows
1. We take a feature the customer wants and write a story
2. We have a brief design discussion amognst the team
3. We then determine an estimation for the card
4. If the card is longer than 3 days we break it down further and we reapeat from step 2
Unfortunately the customer wants an estimate of how long it will take for the entire project so we need to define all the stories up front.
This takes a while and can be quite draining
What other methods can be used to define thr story cards?
This can take What other ways to you gather requirements onto story cards? | 0 | [
2,
98,
18,
21,
254,
953,
26,
1174,
609,
4092,
60,
800,
3726,
3726,
95,
50,
114,
228,
120,
14684,
318,
609,
4092,
26,
14,
328,
669,
9,
13,
8,
95,
57,
21,
254,
882,
98,
14,
7705,
259,
120,
10010,
13,
8,
95,
57,
21,
508,
8981... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Are there better clients for viewing System Monitor logs?
===
Does anyone know of a better GUI client for displaying Windows [System Monitor](http://support.microsoft.com/kb/248345) log files? (System Monitor is sometimes called [Performance Monitor](http://support.microsoft.com/?kbid=330138).) I'm trying to track a long-term memory leak in a C# application running on Windows XP or 2K3 by comparing memory usages to run logs.
Specifically I want a client that will allow me to see the following (because System Monitor is unable or difficult):
- Specify exact date time ranges for viewing data (or at least finer granularity than hours)
- Show time intervals along the horizontal axis
- Show max, min, average for the time range
- Somewhere show the interval on which source data was captured (1 sec, 5 min, etc.)
(If no such thing exists I'm willing to hear recommendations for better long term performance/memory capturing tools.)
**Edit:** I've done Google searches and haven't found anything except tutorials on how to create System Monitor logs.
| 0 | [
2,
50,
80,
574,
7421,
26,
11244,
329,
7626,
18893,
60,
800,
3726,
3726,
630,
1276,
143,
16,
21,
574,
9457,
6819,
26,
17418,
1936,
636,
10724,
7626,
500,
5,
21127,
6903,
24168,
9,
22019,
12980,
9,
960,
118,
18167,
118,
24135,
21997,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 lightest Java Virtual Machine ever, except KVM?
===
I'd like to install Java on a GNU/Linux 16MB RAM machine, will it be possible?
Unfortunatly, <a href="http://www.java.com/en/download/faq/5000080100.xml">"KVM must be installed by the manufacturer"</a>. | 0 | [
2,
98,
25,
14,
471,
1430,
8247,
6599,
1940,
462,
15,
1613,
13571,
79,
60,
800,
3726,
3726,
31,
22,
43,
101,
20,
16146,
8247,
27,
21,
26092,
118,
1226,
7147,
347,
5024,
2843,
1940,
15,
129,
32,
44,
938,
60,
367,
6469,
4140,
38,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Simplest, safest way of holding a bunch of const char* in a set?
===
I want to hold a bunch of const char pointers into an std::set container [1]. std::set template requires a comparator functor, and the standard C++ library offers std::less, but its implementation is based on comparing the two keys directly, which is not standard for pointers.
I know I can define my own functor and implement the operator() by casting the pointers to integers and comparing them, but is there a cleaner, 'standard' way of doing it?
1: The pointers are to static strings, so there is no problem with their lifetimes - they won't go away. | 0 | [
2,
24384,
15,
1834,
384,
161,
16,
1337,
21,
7653,
16,
11608,
38,
4892,
2483,
19,
21,
309,
60,
800,
3726,
3726,
31,
259,
20,
1027,
21,
7653,
16,
11608,
38,
4892,
454,
445,
77,
40,
354,
43,
45,
45,
3554,
12147,
636,
165,
500,
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... |
Why is the http auth UI so poor in browsers?
===
Why isn't there a logout button? Why no list of "websites you're logged into"? Is it because of some issue with the HTTP specs?
Life would be much easier for web developers if they could actually rely on HTTP auth ... | 0 | [
2,
483,
25,
14,
7775,
10343,
96,
13,
5661,
86,
1696,
19,
16495,
18,
60,
800,
3726,
3726,
483,
2532,
22,
38,
80,
21,
6738,
1320,
5167,
60,
483,
90,
968,
16,
13,
7,
14113,
18,
6359,
42,
22,
99,
13,
19287,
77,
7,
60,
25,
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... |
Looking for pattern/approach/suggestions for handling long-running operation tied to web app
===
I'm working on a consumer web app that needs to do a long running background process that is tied to each customer request. By long running, I mean anywhere between 1 and 3 minutes.
Here is an example flow. The object/widget doesn't really matter.
1. Customer comes to the site and specifies object/widget they are looking for.
2. We search/clean/filter for widgets matching some initial criteria. <-- long running process
3. Customer further configures more detail about the widget they are looking for.
4. When the long running process is complete the customer is able to complete the last few steps before conversion.
Steps 3 and 4 aren't really important. I just mention them because we can buy some time while we are doing the long running process.
The environment we are working in is a LAMP stack-- currently using PHP. It doesn't seem like a good design to have the long running process take up an apache thread in mod_php (or fastcgi process). The apache layer of our app *should* be focused on serving up content and not data processing IMO.
A few questions:
1. Is our thinking right in that we should separate this "long running" part out of the apache/web app layer?
2. Is there a *standard/typical* way to break this out under Linux/Apache/MySQL/PHP (we're open to using a different language for the processing if appropriate)?
3. Any suggestions on how to go about breaking it out? E.g. do we create a deamon that churns through a FIFO queue?
Thanks! | 0 | [
2,
699,
26,
3732,
118,
7753,
661,
3211,
118,
18,
21606,
1430,
5757,
26,
7988,
175,
8,
11325,
1453,
3802,
20,
2741,
4865,
800,
3726,
3726,
31,
22,
79,
638,
27,
21,
6461,
2741,
4865,
30,
2274,
20,
107,
21,
175,
946,
2395,
953,
30,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 save outline toggles between restarts of VS2008?
===
Does anyone know a trick in Visual Studio 2008 to make it remember the outline toggles you have in place on aspx files between restarts? (the little plus or minus symbol on the left for code blocks)
In the code behind cs file it remembers the toggle on the #region tags... hoping for something like that I can do on the aspx HTML side.
So far I am forced to either re-close them when I open it, or do a Edit -> Outlining -> Toggle all Outlining to close them all when opening. Nothing happy in the middle. | 0 | [
2,
184,
107,
42,
2079,
11160,
20,
4572,
1355,
128,
22767,
18,
16,
4611,
2753,
60,
800,
3726,
3726,
630,
1276,
143,
21,
5514,
19,
3458,
1120,
570,
20,
233,
32,
1518,
14,
11160,
20,
4572,
1355,
42,
57,
19,
209,
27,
28,
306,
396,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Newsletter slow sending - delay between 2 mails to the same server / max e-mails per hour?
===
i have to make a newsletter sending utility application which will collect the list of subscriber from our central database and send out the newsletter. i've considered the possibility to be blacklisted due to flodding if i just flush out all emails at once, so i decided to go on a desktop-based softwer which will email those slowly.
my question is
- what is the max emails per hour that may be addressed to the same email domain (recipient/incoming server)?
- or what should be delay between 2 e-mails to the same server for it doesn't consider it flooding?
whichever of the above applies more appropriate to the real-world of mail servers configuration...
thanks | 0 | [
2,
17782,
2276,
4907,
13,
8,
7255,
128,
172,
4216,
18,
20,
14,
205,
8128,
13,
118,
2049,
13,
62,
8,
8079,
18,
416,
1671,
60,
800,
3726,
3726,
31,
57,
20,
233,
21,
17782,
4907,
10082,
3010,
56,
129,
5543,
14,
968,
16,
13,
20330... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
scope of function created with function statement in Javascript/ECMAScript
===
Today I had a discussion with a colleague about nested functions in Javascript:
function a() {
function b() {
alert('boo')
}
var c = 'Bound to local call object.'
d = 'Bound to global object.'
}
In this example, trials point out that b is not reachable outside the body of a, much like c is. However, d is - after executing a(). Looking for the exact definition of this behaviour in the <a href="http://www.ecma-international.org/publications/files/ECMA-ST/Ecma-262.pdf">ECMAScript v.3 standard </a>, I didn't find the exact wording I was looking for; what Sec.13 p.71 does not say, is which object the function object created by the function declaration statement is to be bound to. Am I missing something? | 0 | [
2,
9914,
16,
1990,
679,
29,
1990,
3331,
19,
8247,
8741,
118,
3319,
540,
8741,
800,
3726,
3726,
786,
31,
41,
21,
5460,
29,
21,
12321,
88,
5618,
69,
3719,
19,
8247,
8741,
45,
1990,
21,
5,
6,
13,
1,
1990,
334,
5,
6,
13,
1,
7863... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
ANT: Override the compiler attribute in an Ant javac task
===
I'm trying to override ant's compiler attribute via the command line so that all javac tasks occur using my specified compiler. The problem I've run into is that any target that sets its own value for compiler overrides the one that I set at the commmand line. So, even though I'm entering the following command.
> ant -Dbuild.compiler=mycompiler
Any target that has the following is going to use the modern compiler instead of mycompiler
because of that compiler="modern" attribute
> <javac srcdir="."
destdir="${classes.dir}/core"
compiler="modern"
encoding="UTF-8">
<include name="org/**" />
<include name="com/**" />
<compilerarg line="${config.build.compilerarg}" />
</javac>
Is there any way to override this from the command line or am I stuck editing the build file? | 0 | [
2,
40,
38,
45,
84,
11891,
14,
21486,
35,
14755,
19,
40,
40,
38,
8247,
150,
3005,
800,
3726,
3726,
31,
22,
79,
749,
20,
84,
11891,
40,
38,
22,
18,
21486,
35,
14755,
1197,
14,
1202,
293,
86,
30,
65,
8247,
150,
8674,
3744,
568,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 an application find out information about currently playing song on iPhone/iPod Touch?
===
I've searched around a bit in the small amount of iPhone/iPod Touch development information available and couldn't find anything for or against. Can an application find out information about currently playing song on iPhone/iPod Touch? Since the music can continue to play while you are in 3rd party applications, is there a function or library that will give you information about what is playing? (Track, Artist, Album, etc.) I know generally that applications are sand-boxed but thought maybe there was a way. | 0 | [
2,
92,
40,
3010,
477,
70,
676,
88,
871,
791,
338,
27,
21024,
118,
49,
10670,
1723,
60,
800,
3726,
3726,
31,
22,
195,
9036,
140,
21,
1142,
19,
14,
284,
2006,
16,
21024,
118,
49,
10670,
1723,
522,
676,
904,
17,
711,
22,
38,
477,... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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++ dynamic class ( dynamic hack )
===
Is there any way to add a field to a class at runtime ( a field that didn't exist before ) ? Something like this snippet :
<pre><code>
Myobject *ob; // create an object
ob->addField("newField",44); // we add the field to the class and we assign an initial value to it
printf("%d",ob->newField); // now we can access that field
</code></pre>
I don't really care how it would be done , I don't care if it's an ugly hack or not , I would like to know if it could be done , and a small example , if possible .
Thank you ! | 0 | [
2,
272,
20512,
7782,
718,
13,
5,
7782,
11835,
13,
6,
800,
3726,
3726,
25,
80,
186,
161,
20,
3547,
21,
575,
20,
21,
718,
35,
485,
891,
13,
5,
21,
575,
30,
223,
22,
38,
3182,
115,
13,
6,
13,
60,
301,
101,
48,
13,
29061,
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... |
General question, what do you want from a web framework?
===
In a MVC application, what are some of the components that make up the application. What tools and functionality is missing that you would like to have. Regardless of the server-side language, what would you want?
I see a lot in my code where I code some much functionality that it seems should already be there. I looked at Google web toolkit and they seem to get it right. Widgets are widgets and you simply add them to your application.
For example. I work with J2EE apps but in other languages, the components are the same.
1. Controller Objects
2. Controller handlers, defined by methods in the controller objects.
3. Configuration files defining the URL mapping and settings.
4. Template server page files (E.g. jsp / asp files).
5. Configuration files defining ORM mapping between application objects and the database.
6. Configuration files defining the database connection properties.
7. Javascript libraries (e.g. jquery)
8. Logging configuration files
9. Resource message bundle files
10. Validation configuration files or code
11. Middleware components and objects (EJB configurations, JMS/Messaging configurations, etc).
12. Credit Card or other middleware connectivity APIs and libraries.
Anything else you can think of? | 0 | [
2,
297,
1301,
15,
98,
107,
42,
259,
37,
21,
2741,
6596,
60,
800,
3726,
3726,
19,
21,
307,
8990,
3010,
15,
98,
50,
109,
16,
14,
5090,
30,
233,
71,
14,
3010,
9,
98,
4672,
17,
18548,
25,
2863,
30,
42,
83,
101,
20,
57,
9,
7148... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Functional Spec & Agile Processes
===
In traditional Waterfall, requirements were gathered - typically in a MS-Word document - following an esoteric template. In a "strict" waterfall model, this document is frozen after the requirement phase and a Change Control / Change Management process is responsible for introducing controlled changes. (**) [Typically, the document is turned into a "living document" and eventually a "living nightmare"]
Currently, I've to lead a project that is a rewrite of an existing desktop application to web (from VB 6.0 to ASP.Net). The client has a baselined version of the application that he wants rewritten. [So requirments are frozen... No scope creep]. The data model to be reused as is. Only the front end/Business rules to be migrated. Looking at the application, I feel it's a at most 3/4 major screens and that's it.
Some of the team members want to document (old school of thought, in my opinion) the entire thing before they start on the new development. I & and some others feel, it shoud be relatively easy translate the UI to Web, to look up old code, write the business logic, do automated unit tests, proceed to integration tests and deliver screen by screen (or business function by function)
My question is:
In an Agile development how I do I remain "agile" if I were not to optimize this. My opinion is writing detailed documentation is anti-agile. What do you think? How would an agile guru approach the above problem (of rewriting an existing VB 6.0 app to ASP.Net)?
***
Disclaimer:
*Creation of a 1000 page Functional Spec could possibly be to meet contractual obligations, a political necessity, the system could be genuinely complex (now, definition of "complexity" is a journey unto murky-land).* | 0 | [
2,
7652,
12737,
279,
27475,
5102,
800,
3726,
3726,
19,
1361,
12927,
15,
4786,
46,
4744,
13,
8,
2442,
19,
21,
4235,
8,
9587,
4492,
13,
8,
249,
40,
27850,
22894,
9,
19,
21,
13,
7,
27245,
7,
12927,
1061,
15,
48,
4492,
25,
7203,
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... |
Using NaN in C++?
===
What's the best way to use NaNs in C++?
I found `std::numeric_limits<double>::quiet_NaN()` and `std::numeric_limits<double>::signaling_NaN()`. I'd like to use `signaling_NaN` to represent an uninitialized variable as follows:
double diameter = std::numeric_limits<double>::signaling_NaN();
This, however, signals (raises an exception).
Is there any way to use `signaling_NaN` without raising an exception? Is there a good, portable alternative to `signaling_NaN` that will raise a floating point exception when used? | 0 | [
2,
568,
5884,
19,
272,
20512,
60,
800,
3726,
3726,
98,
22,
18,
14,
246,
161,
20,
275,
5884,
18,
19,
272,
20512,
60,
31,
216,
13,
1,
384,
43,
45,
45,
6336,
14744,
1,
20565,
18,
1,
14368,
1,
45,
45,
24944,
1,
3198,
5,
6,
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... |
Uploading file from web user to server using ASP
===
I am trying to find out how to upload a file from a web user to a server using an ASP page. The displayed page has an Input tag of type "File" like this:
<input type="file" name="uploadfile">
And a submit button that passes the Form info to another .ASP page. This page must take the path it gets from the Input control and use it to somehow save the file to the server.
I keep thinking there must be a common way to do this, since I see this kind of thing on a number of websites, but how is it done? Is there some sort of server object that can be called for it? | 0 | [
2,
71,
16866,
3893,
37,
2741,
4155,
20,
8128,
568,
28,
306,
800,
3726,
3726,
31,
589,
749,
20,
477,
70,
184,
20,
71,
8294,
21,
3893,
37,
21,
2741,
4155,
20,
21,
8128,
568,
40,
28,
306,
2478,
9,
14,
6115,
2478,
63,
40,
6367,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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 apply Theoretical CS?
===
Why is theory useful? Do you ever use it in your day-to-day coding? For example, we learned about the <b>halting problem</b>, Turing machines, reductions, etc... a lot of classmates are saying it's abstract and useless and there's no real point to knowning any of it (meaning, you can forget it once the course is over and not lose anything). | 0 | [
2,
184,
107,
42,
5645,
9482,
272,
18,
60,
800,
3726,
3726,
483,
25,
1639,
4811,
60,
107,
42,
462,
275,
32,
19,
154,
208,
8,
262,
8,
1185,
13,
15458,
60,
26,
823,
15,
95,
2691,
88,
14,
13,
1,
220,
1,
4937,
1203,
1448,
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... |
Unit testing large data sets?
===
What's the best way to unit test large data sets? Some legacy code that I'm maintaining has structures of a hundred members or more; other parts of the code that we're working on create or analyze data sets of hundreds of samples.
The best approach I've found so far is to serialize the structures or data sets from disk, perform the operations under test, serialize the results to disk, then diff the files containing the serialized results against files containing expected results. This isn't terribly fast, and it violates the "don't touch the disk" principle of unit testing. However, the only alternative I can think of (writing code to initialize and test hundreds of members and data points) seems unbearably tedious.
Are there any better solutions? | 0 | [
2,
1237,
4431,
370,
1054,
3415,
60,
800,
3726,
3726,
98,
22,
18,
14,
246,
161,
20,
1237,
1289,
370,
1054,
3415,
60,
109,
7780,
1797,
30,
31,
22,
79,
8215,
63,
3815,
16,
21,
1874,
443,
54,
91,
73,
89,
1341,
16,
14,
1797,
30,
... | [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
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... |
Compare double in VBA precision problem
===
I have trouble comparing 2 double in Excel VBA
suppose that I have the following code
Dim a as double
Dim b as double
a = 0.15
b = 0.01
After a few manipulations on b, b is now equal to 0.6
however the imprecision related to the double data type gives me headache because
if a = b then
'this will never trigger
end if
Do you know how I can remove the trailing imprecision on the double type?
| 0 | [
2,
11590,
1494,
19,
566,
969,
13133,
1448,
800,
3726,
3726,
31,
57,
2572,
15047,
172,
1494,
19,
20700,
566,
969,
5787,
30,
31,
57,
14,
249,
1797,
5937,
21,
28,
1494,
5937,
334,
28,
1494,
21,
800,
713,
9,
1193,
334,
800,
713,
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... |
Is there a Internet Explorer approved substitute for selectionStart and selectionEnd?
===
Finding what's selected in real browsers is as simple as:
var range = {
start: textbox.selectionStart,
end: textbox.selectionEnd
}
But IE, as usual, doesn't understand. What's the best cross-browser way to do this? | 0 | [
2,
25,
80,
21,
2620,
8520,
3469,
6558,
26,
3155,
13680,
17,
3155,
2451,
60,
800,
3726,
3726,
3007,
98,
22,
18,
1704,
19,
683,
16495,
18,
25,
28,
1935,
28,
45,
4033,
978,
800,
13,
1,
799,
45,
1854,
5309,
9,
18,
5033,
13680,
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... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.