PostId
int64 4
11.8M
| PostCreationDate
stringlengths 19
19
| OwnerUserId
int64 1
1.57M
| OwnerCreationDate
stringlengths 10
19
| ReputationAtPostCreation
int64 -55
461k
| OwnerUndeletedAnswerCountAtPostTime
int64 0
21.5k
| Title
stringlengths 3
250
| BodyMarkdown
stringlengths 5
30k
⌀ | Tag1
stringlengths 1
25
⌀ | Tag2
stringlengths 1
25
⌀ | Tag3
stringlengths 1
25
⌀ | Tag4
stringlengths 1
25
⌀ | Tag5
stringlengths 1
25
⌀ | PostClosedDate
stringlengths 19
19
⌀ | OpenStatus
stringclasses 5
values | unified_texts
stringlengths 32
30.1k
| OpenStatus_id
int64 0
4
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
57,249 | 09/11/2008 18:13:31 | 3,796 | 08/30/2008 21:50:13 | 11 | 3 | Getting EPG info from DVB-T | I'm interested in grabbing the EPG data from DVB-T streams. Does anyone know of any C libraries or an alternative means of getting the data? | epg | null | null | null | null | null | open | Getting EPG info from DVB-T
===
I'm interested in grabbing the EPG data from DVB-T streams. Does anyone know of any C libraries or an alternative means of getting the data? | 0 |
57,258 | 09/11/2008 18:17:58 | 4,786 | 09/05/2008 15:29:10 | 107 | 6 | How do I capture Microsoft Office Live Meeting's screencasts? | How do I capture Microsoft Office Live Meeting's screencasts? | microsoft | screencasts | live-meeting | null | null | null | open | How do I capture Microsoft Office Live Meeting's screencasts?
===
How do I capture Microsoft Office Live Meeting's screencasts? | 0 |
57,261 | 09/11/2008 18:19:28 | 5,422 | 09/09/2008 14:02:21 | 61 | 5 | How to connect to PostgreSQL from .NET using TLS with both client and server authentication? | I want to connect a C# .NET application to a PostgreSQL database, using TLS with client _and_ server authentication: in other words, if the certificate from the client can not be verified against the certificate of the server, the client should get access denied, and if the client can not verify the certificate of the server, the client should immediately abort connecting.
I tried this using Npgsql 1.0, but I can not find any way in Npgsql to specify the client certificate that should be used for the connection.
I did manage to get server certificate verification on the client working, and I also did get all the verification working using the commandline db admin tool psql, but this did not help me further in getting it to work with Npgsql.
So, how would I connect my .NET app using TLS client & server authentication to a PostgreSQL database?
Is there maybe a newer/other data provider that does support this?
Is there actually anyone who did get this to work one way or another? | .net | postgresql | ssl | database-connection | tls | null | open | How to connect to PostgreSQL from .NET using TLS with both client and server authentication?
===
I want to connect a C# .NET application to a PostgreSQL database, using TLS with client _and_ server authentication: in other words, if the certificate from the client can not be verified against the certificate of the server, the client should get access denied, and if the client can not verify the certificate of the server, the client should immediately abort connecting.
I tried this using Npgsql 1.0, but I can not find any way in Npgsql to specify the client certificate that should be used for the connection.
I did manage to get server certificate verification on the client working, and I also did get all the verification working using the commandline db admin tool psql, but this did not help me further in getting it to work with Npgsql.
So, how would I connect my .NET app using TLS client & server authentication to a PostgreSQL database?
Is there maybe a newer/other data provider that does support this?
Is there actually anyone who did get this to work one way or another? | 0 |
57,285 | 09/11/2008 18:29:52 | 5,853 | 09/11/2008 14:26:06 | 1 | 0 | SMTP Mail Timeout Issue | When I'm creating a user for my web application, an SMTP email is sent to the user with the
automatically generated password. However, sometimes what I notice is that it times out sometimes and the new user simply won't receive the email with the password.
Alright, so I'll display a message indicating that the mail did not go through but the user is created.
Therefore, the sys admin has 3 options:
a) Reset the password for the user and hope another SMTP mail is sent with the auto-generated password.
b) Delete and recreate the user.
I could rollback the user creation if the smtp is not created but what is the best practice to tackle this problem?
I'm thinking that I should retry sending the email 3 times with a timeout period of 5 seconds each. So 15 seconds would be the worse case scenario.
Is this the way to go? | smtp | email | .net | asp.net | null | null | open | SMTP Mail Timeout Issue
===
When I'm creating a user for my web application, an SMTP email is sent to the user with the
automatically generated password. However, sometimes what I notice is that it times out sometimes and the new user simply won't receive the email with the password.
Alright, so I'll display a message indicating that the mail did not go through but the user is created.
Therefore, the sys admin has 3 options:
a) Reset the password for the user and hope another SMTP mail is sent with the auto-generated password.
b) Delete and recreate the user.
I could rollback the user creation if the smtp is not created but what is the best practice to tackle this problem?
I'm thinking that I should retry sending the email 3 times with a timeout period of 5 seconds each. So 15 seconds would be the worse case scenario.
Is this the way to go? | 0 |
57,287 | 09/11/2008 18:30:47 | 3,043 | 08/26/2008 13:24:14 | 1,974 | 198 | ASP.Net RSS feed | How do I create an rss feed in ASP.Net? Is there anything built in to support it? If not, what third-party tools are available?
I'm thinking webforms, not MVC, though I suppose since this isn't a traditional page the difference may be minimal. | asp.net | rss | webforms | null | null | null | open | ASP.Net RSS feed
===
How do I create an rss feed in ASP.Net? Is there anything built in to support it? If not, what third-party tools are available?
I'm thinking webforms, not MVC, though I suppose since this isn't a traditional page the difference may be minimal. | 0 |
57,291 | 09/11/2008 18:32:33 | 1,958 | 08/19/2008 15:28:47 | 82 | 19 | Is there a simpler way to deploy to WebSphere? | I have seen [this question][1] about deploying to WebSphere using the WAS ant tasks.
Is there a simpler way to do this? In the past I have deployed to Tomcat by dropping a war file into a directory. I was hoping there would be a similar mechanism for WebSphere that doesn't involve calling the IBM libraries or rely on RAD to be installed on your workstation.
[1]: http://stackoverflow.com/questions/4046/can-someone-give-me-a-working-example-of-a-buildxml-for-an-ear-that-deploys-in | ant | websphere | java-ee | null | null | null | open | Is there a simpler way to deploy to WebSphere?
===
I have seen [this question][1] about deploying to WebSphere using the WAS ant tasks.
Is there a simpler way to do this? In the past I have deployed to Tomcat by dropping a war file into a directory. I was hoping there would be a similar mechanism for WebSphere that doesn't involve calling the IBM libraries or rely on RAD to be installed on your workstation.
[1]: http://stackoverflow.com/questions/4046/can-someone-give-me-a-working-example-of-a-buildxml-for-an-ear-that-deploys-in | 0 |
57,314 | 09/11/2008 18:43:19 | 959 | 08/11/2008 05:23:02 | 153 | 13 | Validation framework for business app built on Spring 2.5 | What could the best strategy for writing validation layer for mid-enterprise level business application built on Spring 2.5
I know that Spring provides facility where we can implement Validator interface and write validation logic in validate method. But this will be restricted to only web requests coming through spring controller.
I would like to develop the validation framework which can be utilized during web-services calls.
In other words, the framework can remain and be called independently without the need of implementing Validator interface and then too it can be automatically integrated into Spring MVC flow.
Hope you get my point.
| spring | validation | null | null | null | null | open | Validation framework for business app built on Spring 2.5
===
What could the best strategy for writing validation layer for mid-enterprise level business application built on Spring 2.5
I know that Spring provides facility where we can implement Validator interface and write validation logic in validate method. But this will be restricted to only web requests coming through spring controller.
I would like to develop the validation framework which can be utilized during web-services calls.
In other words, the framework can remain and be called independently without the need of implementing Validator interface and then too it can be automatically integrated into Spring MVC flow.
Hope you get my point.
| 0 |
57,322 | 09/11/2008 18:47:54 | 4,092 | 09/01/2008 18:30:58 | 41 | 1 | <asp:RegularExpressionValidator and RegexOptions.IgnorePatternWhitespace | Is there an easy way of using the `RegularExpressionValidator` control while ignoring white space?
I can use a custom validator control with `Regex` and `IgnorePatternWhitespace`, but it would be good to just have an option in the `RegularExpressionValidator` control. | asp.net | null | null | null | null | null | open | <asp:RegularExpressionValidator and RegexOptions.IgnorePatternWhitespace
===
Is there an easy way of using the `RegularExpressionValidator` control while ignoring white space?
I can use a custom validator control with `Regex` and `IgnorePatternWhitespace`, but it would be good to just have an option in the `RegularExpressionValidator` control. | 0 |
404,675 | 01/01/2009 07:25:30 | 6,126 | 09/12/2008 14:09:42 | 227 | 10 | Calculating optimal stock length | This is similar to the <a href="http://en.wikipedia.org/wiki/Cutting_stock_problem">cutting stock problem</a>, but with a slight difference. I want to find out what the optimal length of the stock is based on the sizes of the cuts.
Potential complications:
1. The Wikipedia article on the Cutting Stock Problem is way over my head. I suspect that understanding how to solve this problem might be critical to solving my own problem.
2. Some cut lengths are more common than others. Anything less than 2 feet is considered scrap, so we'd rather not make a cut that leaves a large piece of scrap. On the other hand, we don't want to hang on to numerous pieces of partial stock in the hopes that we might need one of them some day. | algorithm | null | null | null | null | null | open | Calculating optimal stock length
===
This is similar to the <a href="http://en.wikipedia.org/wiki/Cutting_stock_problem">cutting stock problem</a>, but with a slight difference. I want to find out what the optimal length of the stock is based on the sizes of the cuts.
Potential complications:
1. The Wikipedia article on the Cutting Stock Problem is way over my head. I suspect that understanding how to solve this problem might be critical to solving my own problem.
2. Some cut lengths are more common than others. Anything less than 2 feet is considered scrap, so we'd rather not make a cut that leaves a large piece of scrap. On the other hand, we don't want to hang on to numerous pieces of partial stock in the hopes that we might need one of them some day. | 0 |
404,676 | 01/01/2009 07:28:38 | 8,047 | 09/15/2008 15:01:43 | 829 | 65 | Ruby: More flexibility than Java/C#? | Is is that I'm a newbie learning Ruby, or does it really have more ways to write (the same) things than Java/C#? Also, if it is more flexible than Java, are there any linguistic features of Ruby that are generally **not** used to avoid confusion?
Examples might be parallel assignment and all the different ways to write Strings, perhaps?
**Note:** I'm not asking for a comparison with Java/C#... just this language question, please... | ruby | syntax | null | null | null | null | open | Ruby: More flexibility than Java/C#?
===
Is is that I'm a newbie learning Ruby, or does it really have more ways to write (the same) things than Java/C#? Also, if it is more flexible than Java, are there any linguistic features of Ruby that are generally **not** used to avoid confusion?
Examples might be parallel assignment and all the different ways to write Strings, perhaps?
**Note:** I'm not asking for a comparison with Java/C#... just this language question, please... | 0 |
404,684 | 01/01/2009 07:40:02 | 22,962 | 09/27/2008 09:22:53 | 19 | 2 | mod_rewrite: Check for Custom query string in URL? | I'm trying to use URL rewrite in my new project. But I also need to allow custom query sting in URL.
I just want to know how to write rewrite rule for this URL
> http://www.mysite.com/edit/123/?q1=value1&q2=value2
to become this
> http://www.mysite.com/index.php?action=edit&id=123&q1=value1&q2=value2
The custom query string should be allow unlimited.
Millions of Thanks...
| url-rewriting | apache | null | null | null | null | open | mod_rewrite: Check for Custom query string in URL?
===
I'm trying to use URL rewrite in my new project. But I also need to allow custom query sting in URL.
I just want to know how to write rewrite rule for this URL
> http://www.mysite.com/edit/123/?q1=value1&q2=value2
to become this
> http://www.mysite.com/index.php?action=edit&id=123&q1=value1&q2=value2
The custom query string should be allow unlimited.
Millions of Thanks...
| 0 |
404,830 | 01/01/2009 10:31:23 | 2,594 | 08/23/2008 12:42:57 | 481 | 15 | Cocoa Won't Capture Shift Modifier? | I have an application in which I'm trying to capture the shift key modifier to perform an action, however when I run the program and press and normal key without the shift key modifier I get a beep and the modifier and key are not sent to my keyDown event. The relevant code is:
NSString* eventChars = [theEvent charactersIgnoringModifiers];
if ([eventChars isEqualTo:@"w"]) {
newPlayerRow++;
direction = eUp;
} else if ([eventChars isEqualTo:@"x"]) {
newPlayerRow--;
direction = eDown;
} else if ([eventChars isEqualTo:@"a"]) {
newPlayerCol--;
direction = eLeft;
} else if ([eventChars isEqualTo:@"d"]) {
newPlayerCol++;
direction = eRight;
} else {
[super keyDown:theEvent];
return;
}
// handle the player firing a bullet
if (([theEvent modifierFlags] & (NSShiftKeyMask | NSAlphaShiftKeyMask)) != 0) {
NSLog(@"Shift key");
[self fireBulletAtColumn:newPlayerCol row:newPlayerRow inDirection:direction];
[self setNeedsDisplay:YES];
} else {
...
}
I'm not sure what is causing this, but I'd like to be able to capture shift key presses. Thanks in advance for any help with this problem.
EDIT: Also I'm using a MacBook keyboard if that makes any difference. | osx | cocoa | null | null | null | null | open | Cocoa Won't Capture Shift Modifier?
===
I have an application in which I'm trying to capture the shift key modifier to perform an action, however when I run the program and press and normal key without the shift key modifier I get a beep and the modifier and key are not sent to my keyDown event. The relevant code is:
NSString* eventChars = [theEvent charactersIgnoringModifiers];
if ([eventChars isEqualTo:@"w"]) {
newPlayerRow++;
direction = eUp;
} else if ([eventChars isEqualTo:@"x"]) {
newPlayerRow--;
direction = eDown;
} else if ([eventChars isEqualTo:@"a"]) {
newPlayerCol--;
direction = eLeft;
} else if ([eventChars isEqualTo:@"d"]) {
newPlayerCol++;
direction = eRight;
} else {
[super keyDown:theEvent];
return;
}
// handle the player firing a bullet
if (([theEvent modifierFlags] & (NSShiftKeyMask | NSAlphaShiftKeyMask)) != 0) {
NSLog(@"Shift key");
[self fireBulletAtColumn:newPlayerCol row:newPlayerRow inDirection:direction];
[self setNeedsDisplay:YES];
} else {
...
}
I'm not sure what is causing this, but I'd like to be able to capture shift key presses. Thanks in advance for any help with this problem.
EDIT: Also I'm using a MacBook keyboard if that makes any difference. | 0 |
404,854 | 01/01/2009 10:57:12 | 373,112 | 09/17/2008 18:38:18 | 207 | 10 | in ps -l, what does wchan=stext mean? | when I try to fine-tune my process, I see that the waiting channel is stext, what does it mean?
thanks
mehageg | linux | scheduling | null | null | null | null | open | in ps -l, what does wchan=stext mean?
===
when I try to fine-tune my process, I see that the waiting channel is stext, what does it mean?
thanks
mehageg | 0 |
57,345 | 09/11/2008 18:59:16 | 4,694 | 09/05/2008 09:30:26 | 97 | 9 | How can I stop loosing all my IDE window position when pressing the start debugging button ? | I use Visual Studio 2008. I haven't seen this behaviour before and as far as I know I didn't change anything in the options.
When I press Start debugging all the possibly windows (watch 1 - 4), data sources, properties, registers (to be honest I have not even ever seen these windows before) appear in front of the code window and stay there after I stop the debugger.
Anyone has an idea what could be causing this ? (I am using CodeRush and Refactor for quite a while now)
When I close and restart visual studio all the windows are where they should be. | visual-studio-2008 | null | null | null | null | null | open | How can I stop loosing all my IDE window position when pressing the start debugging button ?
===
I use Visual Studio 2008. I haven't seen this behaviour before and as far as I know I didn't change anything in the options.
When I press Start debugging all the possibly windows (watch 1 - 4), data sources, properties, registers (to be honest I have not even ever seen these windows before) appear in front of the code window and stay there after I stop the debugger.
Anyone has an idea what could be causing this ? (I am using CodeRush and Refactor for quite a while now)
When I close and restart visual studio all the windows are where they should be. | 0 |
57,350 | 09/11/2008 19:03:01 | 327 | 08/04/2008 17:08:49 | 711 | 48 | How do I get the current user's Local Settings folder path in C#? | I want to point a file dialog at a particular folder in the current user's Local Settings folder on Windows. What is the shortcut to get this path? | c# | .net | windows | null | null | null | open | How do I get the current user's Local Settings folder path in C#?
===
I want to point a file dialog at a particular folder in the current user's Local Settings folder on Windows. What is the shortcut to get this path? | 0 |
57,355 | 09/11/2008 19:05:57 | 3,175 | 08/27/2008 06:54:20 | 6 | 2 | Const Struct& | I'm having a little trouble figuring out exactly how const applies in a specific case. Here's the code I have:
struct Widget
{
Widget():x(0), y(0), z(0){}
int x, y, z;
};
struct WidgetHolder //Just a simple struct to hold four Widgets.
{
WidgetHolder(Widget a, Widget b, Widget c, Widget d): A(a), B(b), C(c), D(d){}
Widget& A;
Widget& B;
Widget& C;
Widget& D;
};
class Test //This class uses four widgets internally, and must provide access to them externally.
{
public:
const WidgetHolder AccessWidgets() const
{
//This should return our four widgets, but I don't want anyone messing with them.
return WidgetHolder(A, B, C, D);
}
WidgetHolder AccessWidgets()
{
//This should return our four widgets, I don't care if they get changed.
return WidgetHolder(A, B, C, D);
}
private:
Widget A, B, C, D;
};
int main()
{
const Test unchangeable;
unchangeable.AccessWidgets().A.x = 1; //Why does this compile, shouldn't the Widget& be const?
}
Basically, I have a class called test. It uses four widgets internally, and I need it to return these, but if test was declared const, I want the widgets returned const also.
Can someone explain to me why the code in main() compiles?
Thank you very much. | c++ | null | null | null | null | null | open | Const Struct&
===
I'm having a little trouble figuring out exactly how const applies in a specific case. Here's the code I have:
struct Widget
{
Widget():x(0), y(0), z(0){}
int x, y, z;
};
struct WidgetHolder //Just a simple struct to hold four Widgets.
{
WidgetHolder(Widget a, Widget b, Widget c, Widget d): A(a), B(b), C(c), D(d){}
Widget& A;
Widget& B;
Widget& C;
Widget& D;
};
class Test //This class uses four widgets internally, and must provide access to them externally.
{
public:
const WidgetHolder AccessWidgets() const
{
//This should return our four widgets, but I don't want anyone messing with them.
return WidgetHolder(A, B, C, D);
}
WidgetHolder AccessWidgets()
{
//This should return our four widgets, I don't care if they get changed.
return WidgetHolder(A, B, C, D);
}
private:
Widget A, B, C, D;
};
int main()
{
const Test unchangeable;
unchangeable.AccessWidgets().A.x = 1; //Why does this compile, shouldn't the Widget& be const?
}
Basically, I have a class called test. It uses four widgets internally, and I need it to return these, but if test was declared const, I want the widgets returned const also.
Can someone explain to me why the code in main() compiles?
Thank you very much. | 0 |
57,372 | 09/11/2008 19:12:04 | 4,066 | 09/01/2008 16:06:15 | 86 | 7 | How do I sync between VSS and SVN | I am forced to use VSS at work, but use SVN for a personal repository. What is the best way to sync between VSS and sync? | svn | visual-sourcesafe | sync | null | null | null | open | How do I sync between VSS and SVN
===
I am forced to use VSS at work, but use SVN for a personal repository. What is the best way to sync between VSS and sync? | 0 |
57,380 | 09/11/2008 19:17:24 | 2,357 | 08/21/2008 20:18:05 | 30 | 10 | web page cache setexpires | Will the code below work if the clock on the server is ahead of the clock on the client?
Response.Cache.SetExpires(DateTime.Now.AddSeconds(-1)) | caching | null | null | null | null | null | open | web page cache setexpires
===
Will the code below work if the clock on the server is ahead of the clock on the client?
Response.Cache.SetExpires(DateTime.Now.AddSeconds(-1)) | 0 |
57,382 | 09/11/2008 19:17:49 | 5,285 | 09/08/2008 21:10:47 | 1 | 2 | Obout controls in C# .Net | Is anyone using the Obout controls in C# .Net? How would you rate these controls, especially the Grid Control? | .net | null | null | null | null | null | open | Obout controls in C# .Net
===
Is anyone using the Obout controls in C# .Net? How would you rate these controls, especially the Grid Control? | 0 |
57,383 | 09/11/2008 19:17:52 | 3,205 | 08/27/2008 13:06:13 | 485 | 30 | In C#, how can I rethrow InnerException without loosing stack trace? | I am calling, through reflection, a method which may cause an exception. How can I pass the exception to my caller without the wrapper reflection puts around it? I am rethrowing the InnerException, but this destroys the stack trace. Example code:
public void test1()
{
// Throw an exception for testing purposes
throw new ArgumentException("test1");
}
void test2()
{
try
{
MethodInfo mi = typeof(Program).GetMethod("test1");
mi.Invoke(this, null);
}
catch (TargetInvocationException tiex)
{
// Throw the new exception
throw tiex.InnerException;
}
}
| .net | c# | exception | null | null | null | open | In C#, how can I rethrow InnerException without loosing stack trace?
===
I am calling, through reflection, a method which may cause an exception. How can I pass the exception to my caller without the wrapper reflection puts around it? I am rethrowing the InnerException, but this destroys the stack trace. Example code:
public void test1()
{
// Throw an exception for testing purposes
throw new ArgumentException("test1");
}
void test2()
{
try
{
MethodInfo mi = typeof(Program).GetMethod("test1");
mi.Invoke(this, null);
}
catch (TargetInvocationException tiex)
{
// Throw the new exception
throw tiex.InnerException;
}
}
| 0 |
57,384 | 09/11/2008 19:18:21 | 5,548 | 09/10/2008 12:45:40 | 175 | 9 | Inter-convertability of asymmetric key containers (eg: X.509, PGP, OpenSSH) | Are asymmetrical cryptographic keys fundamentally inter-convertible between the major key container formats? For example, can I convert an X.509 key file into a PGP or OpenGPG key file?
And--assuming the answer is yes--is it "security neutral" to keep one key pair in whatever format and convert into whichever container file format is needed for the occasion?
I'm getting a little tired of maintaining so many key pairs for X.509, OpenGPG, and SSH, when they're all RSA at the heart. | security | ssh | cryptography | gpg | x.509 | null | open | Inter-convertability of asymmetric key containers (eg: X.509, PGP, OpenSSH)
===
Are asymmetrical cryptographic keys fundamentally inter-convertible between the major key container formats? For example, can I convert an X.509 key file into a PGP or OpenGPG key file?
And--assuming the answer is yes--is it "security neutral" to keep one key pair in whatever format and convert into whichever container file format is needed for the occasion?
I'm getting a little tired of maintaining so many key pairs for X.509, OpenGPG, and SSH, when they're all RSA at the heart. | 0 |
57,386 | 09/11/2008 19:18:44 | 4,231 | 09/02/2008 13:21:16 | 138 | 8 | Where do Interfaces "physically live" | I like the idea of having Interfaces and Implementation separate. But how separate? Are the Interface definitions in a separate .Net assembly? Do you have a single project that defines all Interfaces for a solution? Otherwise are there issues with circular dependencies of Interfaces? | architecture | .net | null | null | null | null | open | Where do Interfaces "physically live"
===
I like the idea of having Interfaces and Implementation separate. But how separate? Are the Interface definitions in a separate .Net assembly? Do you have a single project that defines all Interfaces for a solution? Otherwise are there issues with circular dependencies of Interfaces? | 0 |
57,406 | 09/11/2008 19:28:28 | 5,642 | 09/10/2008 15:42:57 | 1 | 0 | Indexed Views in OLTPs? | I'm familiar with SQL Server Indexed Views (or Oracle Materialized Views), we use them in our OLAP applications. They have the really cool feature of being able to usurp an execution plan and remap it to the indexed view w/out having to change existing code.
IE. Let's say I had a SPROC that was a really expensive join.
>SELECT [SOME COLUMNS]
FROM Table1 INNER JOIN Table2 [DETAILS]
INNER JOIN Table3 [BUNCH MORE JOINS]
...
If I authored an indexed view that held a similar result set then the Query Optimizer will very likely send the SPROC to my indexed view as opposed to the base tables and I get a big performance increase.
Now say I wanted to use indexed views in an **OLTP!?** I mean most OLTPs (like this site) are relatively read heavy, if they have expensive joins then we could speed them up a ton AND potentially reduce locking contention (http://www.codinghorror.com/blog/archives/001166.html). Even better is you wouldn't have to change any code, just author the indexed view.
But this also means the database gets bigger since we need to keep a copy of these data in the indexed view...
**Has anyone ever used indexed views to solve contention or speed issues in an OLTP? How come I've never seen this in use?**
| sql-server | database | views | indexed | materialized | null | open | Indexed Views in OLTPs?
===
I'm familiar with SQL Server Indexed Views (or Oracle Materialized Views), we use them in our OLAP applications. They have the really cool feature of being able to usurp an execution plan and remap it to the indexed view w/out having to change existing code.
IE. Let's say I had a SPROC that was a really expensive join.
>SELECT [SOME COLUMNS]
FROM Table1 INNER JOIN Table2 [DETAILS]
INNER JOIN Table3 [BUNCH MORE JOINS]
...
If I authored an indexed view that held a similar result set then the Query Optimizer will very likely send the SPROC to my indexed view as opposed to the base tables and I get a big performance increase.
Now say I wanted to use indexed views in an **OLTP!?** I mean most OLTPs (like this site) are relatively read heavy, if they have expensive joins then we could speed them up a ton AND potentially reduce locking contention (http://www.codinghorror.com/blog/archives/001166.html). Even better is you wouldn't have to change any code, just author the indexed view.
But this also means the database gets bigger since we need to keep a copy of these data in the indexed view...
**Has anyone ever used indexed views to solve contention or speed issues in an OLTP? How come I've never seen this in use?**
| 0 |
57,409 | 09/11/2008 19:29:42 | 572 | 08/06/2008 20:56:54 | 3,680 | 278 | I don't get the concept of Visual Studio Projects and Solutions. | In Eclipse, I have a workspace that contains all of my projects. Each project builds and compiles separately. A project does not interact with another project.
How does this relate to Visual Studio and Projects/Solutions there? | visual-studio | null | null | null | null | null | open | I don't get the concept of Visual Studio Projects and Solutions.
===
In Eclipse, I have a workspace that contains all of my projects. Each project builds and compiles separately. A project does not interact with another project.
How does this relate to Visual Studio and Projects/Solutions there? | 0 |
57,421 | 09/11/2008 19:37:12 | 1,638 | 08/17/2008 17:58:57 | 574 | 50 | Ajax and a restricted uri | I would like to make an ajax call to a different server (same domain and box, just a different port.)
e.g.
My page is
<pre>
http://localhost/index.html
</pre>
I would like to make a ajax get request to:
<pre>
http://localhost:7076/?word=foo
</pre>
I am getting this error:
<pre>
Access to restricted URI denied (NS_ERROR_DOM_BAD_URI)
</pre>
I know that you can not make an ajax request to a different domain, but it seem this also included different ports? are there any workarounds? | ajax | xmlhttp | null | null | null | null | open | Ajax and a restricted uri
===
I would like to make an ajax call to a different server (same domain and box, just a different port.)
e.g.
My page is
<pre>
http://localhost/index.html
</pre>
I would like to make a ajax get request to:
<pre>
http://localhost:7076/?word=foo
</pre>
I am getting this error:
<pre>
Access to restricted URI denied (NS_ERROR_DOM_BAD_URI)
</pre>
I know that you can not make an ajax request to a different domain, but it seem this also included different ports? are there any workarounds? | 0 |
57,424 | 09/11/2008 19:37:26 | 5,346 | 09/09/2008 10:01:45 | 171 | 11 | Sample code for using macbook camera in a program? | I'd like to use the camera in my Macbook in a program. I'm fairly language agnostic - C, Java, Python etc are all fine. Could anyone suggest the best place to look for documents or "Hello world" type code? | osx | camera | language-agnostic | java | c | null | open | Sample code for using macbook camera in a program?
===
I'd like to use the camera in my Macbook in a program. I'm fairly language agnostic - C, Java, Python etc are all fine. Could anyone suggest the best place to look for documents or "Hello world" type code? | 0 |
57,439 | 09/11/2008 19:42:33 | 1,782 | 08/18/2008 14:30:58 | 1,406 | 98 | Activator.CreateInstance(string) and Activator.CreateInstance<T>() difference | No, this is not a question about generics.
I have a Factory pattern with several classes with internal constructors (I don't want them being instantiated if not thorugh the factory).
My problem is that CreateInstance fails with a "No parameterless constructor defined for this object" error unless I pass "true" on the nonPublic parameter
Example
// Fails
Activator.CreateInstance(type);
// Works
Activator.CreateInstance(type, true);
I wanted to make the factory generic to make it a little simpler, like this:
public class GenericFactory<T> where T : MyAbstractType
{
public static T GetInstance()
{
return Activator.CreateInstance<T>();
}
}
However, I was unable to find how to pass that "true" parameter for it to accept non public constructors (internal)
Did I miss something or it isn't possible? | c# | generics | patterns | null | null | null | open | Activator.CreateInstance(string) and Activator.CreateInstance<T>() difference
===
No, this is not a question about generics.
I have a Factory pattern with several classes with internal constructors (I don't want them being instantiated if not thorugh the factory).
My problem is that CreateInstance fails with a "No parameterless constructor defined for this object" error unless I pass "true" on the nonPublic parameter
Example
// Fails
Activator.CreateInstance(type);
// Works
Activator.CreateInstance(type, true);
I wanted to make the factory generic to make it a little simpler, like this:
public class GenericFactory<T> where T : MyAbstractType
{
public static T GetInstance()
{
return Activator.CreateInstance<T>();
}
}
However, I was unable to find how to pass that "true" parameter for it to accept non public constructors (internal)
Did I miss something or it isn't possible? | 0 |
57,449 | 09/11/2008 19:48:38 | 5,422 | 09/09/2008 14:02:21 | 61 | 5 | Upgrading from .NET 1.1 to .NET 2.0, what to expect? | I'm working on a big .NET 1.1 project, and there exists a wish to upgrade this, majorily to be able to use better tools like Visual Studio 2008, but also because of the new features and smaller amount of bugs in the .NET 2.0 framework.
The project consist for the bigger part of VB.NET, but there are also parts in C#. It is a Windows Forms application, using various third party controls. Using .NET remoting the rich client talks to a server process which interfaces with a MSSQL 2000 database.
What kind of issues can we expect in case we decide to perform the upgrade? | .net | null | null | null | null | null | open | Upgrading from .NET 1.1 to .NET 2.0, what to expect?
===
I'm working on a big .NET 1.1 project, and there exists a wish to upgrade this, majorily to be able to use better tools like Visual Studio 2008, but also because of the new features and smaller amount of bugs in the .NET 2.0 framework.
The project consist for the bigger part of VB.NET, but there are also parts in C#. It is a Windows Forms application, using various third party controls. Using .NET remoting the rich client talks to a server process which interfaces with a MSSQL 2000 database.
What kind of issues can we expect in case we decide to perform the upgrade? | 0 |
57,458 | 09/11/2008 19:52:23 | 1,583 | 08/16/2008 20:54:12 | 416 | 14 | What are some gotchas when retargeting .net 2.0 to 3.5? | I am currently working on a project that is moving from .NET 2.0 to 3.5 across the board.
I am well aware that 3.5 is basically a set of added functionality (libraries, if you will) on top of what 2.0 offers.
Are there any gotchas that I might hit by simply re-targeting the compiler to 3.5? | .net | null | null | null | null | 07/03/2012 12:38:37 | not constructive | What are some gotchas when retargeting .net 2.0 to 3.5?
===
I am currently working on a project that is moving from .NET 2.0 to 3.5 across the board.
I am well aware that 3.5 is basically a set of added functionality (libraries, if you will) on top of what 2.0 offers.
Are there any gotchas that I might hit by simply re-targeting the compiler to 3.5? | 4 |
57,467 | 09/11/2008 19:55:27 | 3,594 | 08/29/2008 08:46:29 | 232 | 13 | Perforce blame | Is there an equivalent of svn's blame for Perforce on the command line? `p4 annotate` doesn't display usernames -- only changeset numbers (without ancestor history!).
I currently have to track code back through ancestors and compare against the filelog, and there just has to be an easier way -- maybe a F/OSS utility? | svn | version-control | null | null | null | null | open | Perforce blame
===
Is there an equivalent of svn's blame for Perforce on the command line? `p4 annotate` doesn't display usernames -- only changeset numbers (without ancestor history!).
I currently have to track code back through ancestors and compare against the filelog, and there just has to be an easier way -- maybe a F/OSS utility? | 0 |
57,471 | 09/11/2008 19:55:53 | 5,964 | 09/11/2008 19:55:53 | 1 | 0 | C# graph traversal - tracking path between any two nodes | Looking for a good approach to keep track of a Breadth-First traversal between two nodes, without knowing anything about the graph. Versus Depth-First (where you can throw away the path if it doesn't pan out) you may have quite a few "open" possibilities during the traversal. | c# | graph | traversal | bf | null | null | open | C# graph traversal - tracking path between any two nodes
===
Looking for a good approach to keep track of a Breadth-First traversal between two nodes, without knowing anything about the graph. Versus Depth-First (where you can throw away the path if it doesn't pan out) you may have quite a few "open" possibilities during the traversal. | 0 |
57,473 | 09/11/2008 19:56:53 | 1,583 | 08/16/2008 20:54:12 | 419 | 14 | Converting vb.net to c# tips | I am using reflector disassembly as a quick way to convert some vb.net to c# and am hitting some problems with certain VB-isms:
- Conversions
- Strings
- Information.IsNothing
When trying to compile the converted code, I need to find and change all of these and more.
Any tips on converting vb.net to C# in a clean way?
| c# | vb.net | null | null | null | null | open | Converting vb.net to c# tips
===
I am using reflector disassembly as a quick way to convert some vb.net to c# and am hitting some problems with certain VB-isms:
- Conversions
- Strings
- Information.IsNothing
When trying to compile the converted code, I need to find and change all of these and more.
Any tips on converting vb.net to C# in a clean way?
| 0 |
57,479 | 09/11/2008 20:01:07 | 5,405 | 09/09/2008 13:17:05 | 81 | 3 | AJAX Dropdowns (HTML Select) in Firefox with JQuery | Help! I am using JQuery to make an AJAX call to fill in a drop-down dynamically given the user's previous input (from another drop-down, that is filled server-side). In all other browsers aside from Firefox (IE6/7, Opera, Safari), my append call actually appends the information below my existing option - "Select An <Item>". But in Firefox, it automatically selects the last item given to the select control, regardless of whether I specify the JQuery action to .append or to replace (.html()).
<select name="Products" id="Products" onchange="getHeadings(this.value);">
<option value="">Select Product</option>
</select>
function getProducts(Category)
{
$.ajax({
type: "GET",
url: "getInfo.cfm",
data: "Action=getProducts&Category=" + Category,
success: function(result){
$("#Products").html(result);
}
});
};
Any thoughts? I have tried in the past to also transmit another blank first option, and then trigger a javascript option to re-select the first index, but this triggers the onChange event in my code, rather annoying for the user. | jquery | ajax | html-select | null | null | null | open | AJAX Dropdowns (HTML Select) in Firefox with JQuery
===
Help! I am using JQuery to make an AJAX call to fill in a drop-down dynamically given the user's previous input (from another drop-down, that is filled server-side). In all other browsers aside from Firefox (IE6/7, Opera, Safari), my append call actually appends the information below my existing option - "Select An <Item>". But in Firefox, it automatically selects the last item given to the select control, regardless of whether I specify the JQuery action to .append or to replace (.html()).
<select name="Products" id="Products" onchange="getHeadings(this.value);">
<option value="">Select Product</option>
</select>
function getProducts(Category)
{
$.ajax({
type: "GET",
url: "getInfo.cfm",
data: "Action=getProducts&Category=" + Category,
success: function(result){
$("#Products").html(result);
}
});
};
Any thoughts? I have tried in the past to also transmit another blank first option, and then trigger a javascript option to re-select the first index, but this triggers the onChange event in my code, rather annoying for the user. | 0 |
57,483 | 09/11/2008 20:03:57 | 123 | 08/02/2008 08:01:26 | 1,639 | 91 | Difference between pointer variable and reference variable in C++ | I know references are syntactic sugar, so easier code to read and write :)
But what are the differences? | c++ | pointers | reference | null | null | null | open | Difference between pointer variable and reference variable in C++
===
I know references are syntactic sugar, so easier code to read and write :)
But what are the differences? | 0 |
57,484 | 09/11/2008 20:04:17 | 1,310 | 08/14/2008 13:42:16 | 914 | 40 | How do you "OR" criteria together when using a criteria query with hibernate? | I'm trying to do a basic "OR" on three fields using a hibernate criteria query.
Example
class{
string name;
string address;
string phoneNumber;
}
I'd like to build a criteria query where my search string could match "name" or "address" or "phoneNumber".
| java | hibernate | null | null | null | null | open | How do you "OR" criteria together when using a criteria query with hibernate?
===
I'm trying to do a basic "OR" on three fields using a hibernate criteria query.
Example
class{
string name;
string address;
string phoneNumber;
}
I'd like to build a criteria query where my search string could match "name" or "address" or "phoneNumber".
| 0 |
57,488 | 09/11/2008 20:06:51 | 5,966 | 09/11/2008 20:06:51 | 1 | 0 | .NET Date Const (with Globalization) | Does anyone know of a way to declare a date constant that is compatible with international dates?
Ive tried:
public const ADate as Date = #12/31/04# - not international compatible
public shared readonly ADate As New Date(12, 31, 04) - breaking change if you have an optional parameter that defaults to this value because it isnt constant. | datetime | null | null | null | null | null | open | .NET Date Const (with Globalization)
===
Does anyone know of a way to declare a date constant that is compatible with international dates?
Ive tried:
public const ADate as Date = #12/31/04# - not international compatible
public shared readonly ADate As New Date(12, 31, 04) - breaking change if you have an optional parameter that defaults to this value because it isnt constant. | 0 |
57,493 | 09/11/2008 20:08:29 | 317 | 08/04/2008 15:43:28 | 374 | 19 | WPF Databind Before Saving | In my WPF application, I have a number of databound TextBoxes. The `UpdateSourceTrigger` for these bindings is `LostFocus`. The object is saved using the File menu. The problem I have is that it is possible to enter a new value into a TextBox, select Save from the File menu, and never persist the new value (the one visible in the TextBox) because accessing the menu does not remove focus from the TextBox. How can I fix this? Is there some way to force all the controls in a page to databind? | wpf | data-binding | null | null | null | null | open | WPF Databind Before Saving
===
In my WPF application, I have a number of databound TextBoxes. The `UpdateSourceTrigger` for these bindings is `LostFocus`. The object is saved using the File menu. The problem I have is that it is possible to enter a new value into a TextBox, select Save from the File menu, and never persist the new value (the one visible in the TextBox) because accessing the menu does not remove focus from the TextBox. How can I fix this? Is there some way to force all the controls in a page to databind? | 0 |
57,494 | 09/11/2008 20:08:32 | 5,965 | 09/11/2008 19:58:52 | 1 | 0 | Recommendation on Tools to migrate from Clearcase to SVN? | I'm on the lookout for tools to migrate from ClearCase to SVN.
Ideally would like to get all history information, or as much as can be acquired.
Incremental merges would be very beneficial but isn't required. | svn | migration | clearcase | null | null | null | open | Recommendation on Tools to migrate from Clearcase to SVN?
===
I'm on the lookout for tools to migrate from ClearCase to SVN.
Ideally would like to get all history information, or as much as can be acquired.
Incremental merges would be very beneficial but isn't required. | 0 |
57,512 | 09/11/2008 20:17:58 | 5,487 | 09/09/2008 23:17:20 | 199 | 6 | Users of Gallio, what Advantages and Disadvantages have you experienced using this Tool? | For those of you familiar with [Gallio][1], what Advantages and Disadvantages have you experienced using this tool, a so-called Test Automation Platform?
[1]: http://www.gallio.org | .net | testing | frameworks | integration | null | null | open | Users of Gallio, what Advantages and Disadvantages have you experienced using this Tool?
===
For those of you familiar with [Gallio][1], what Advantages and Disadvantages have you experienced using this tool, a so-called Test Automation Platform?
[1]: http://www.gallio.org | 0 |
57,518 | 09/11/2008 20:20:29 | 5,975 | 09/11/2008 20:20:29 | 1 | 0 | Is it possible for SelectNodes on an XmlDocument to return null? | Is it possible for SelectNodes() called on an XmlDocument to return null?
My predicament is that I am trying to reach 100% unit test code coverage; ReSharper tells me that I need to guard against a null return from the SelectNodes() method, but I can see no way that an XmlDocument can return null (and therefore, no way to test my guard clause and reach 100% unit test coverage!) | .net | xml | null | null | null | null | open | Is it possible for SelectNodes on an XmlDocument to return null?
===
Is it possible for SelectNodes() called on an XmlDocument to return null?
My predicament is that I am trying to reach 100% unit test code coverage; ReSharper tells me that I need to guard against a null return from the SelectNodes() method, but I can see no way that an XmlDocument can return null (and therefore, no way to test my guard clause and reach 100% unit test coverage!) | 0 |
57,522 | 09/11/2008 20:22:31 | 2,755 | 08/24/2008 21:39:28 | 22 | 1 | Javascript array with a mix of literals and arrays | I can create the following and reference it using
area[0].states[0]
area[0].cities[0]
var area = [
{
"State" : "Texas",
"Cities" : ['Austin','Dallas','San Antonio']
},
{
"State" :"Arkansas",
"Cities" : ['Little Rock','Texarkana','Hot Springs']
}
] ;
How could I restructure "area" so that if I know the name of the state, I can use it in a reference to get the array of cities?
Thanks
| javascript | null | null | null | null | null | open | Javascript array with a mix of literals and arrays
===
I can create the following and reference it using
area[0].states[0]
area[0].cities[0]
var area = [
{
"State" : "Texas",
"Cities" : ['Austin','Dallas','San Antonio']
},
{
"State" :"Arkansas",
"Cities" : ['Little Rock','Texarkana','Hot Springs']
}
] ;
How could I restructure "area" so that if I know the name of the state, I can use it in a reference to get the array of cities?
Thanks
| 0 |
57,528 | 09/11/2008 20:26:20 | 2,147 | 08/20/2008 15:14:13 | 1,414 | 83 | parametrization in VBScript/ASP Classic and ADO | I'm a bit confused here. Microsoft as far as I can tell claims that parametrization is the best way to protect your database from SQL injection attacks. But I find two conflicting sources of information here:
[This page][1] says to use the ADO command object. But [this page][2] says that the command object isn't safe for scripting. I seem to recall reading somewhere that the command object shouldn't be used in VBScript or JScript because of security vulnerabilities, but I can't seem to find that article.
Am I missing something here, or do those two articles seem to contradict each other?
[1]: http://support.microsoft.com/kb/200190
[2]: http://msdn.microsoft.com/en-us/library/ms679836(VS.85).aspx | vbscript | sql-server | ado | null | null | null | open | parametrization in VBScript/ASP Classic and ADO
===
I'm a bit confused here. Microsoft as far as I can tell claims that parametrization is the best way to protect your database from SQL injection attacks. But I find two conflicting sources of information here:
[This page][1] says to use the ADO command object. But [this page][2] says that the command object isn't safe for scripting. I seem to recall reading somewhere that the command object shouldn't be used in VBScript or JScript because of security vulnerabilities, but I can't seem to find that article.
Am I missing something here, or do those two articles seem to contradict each other?
[1]: http://support.microsoft.com/kb/200190
[2]: http://msdn.microsoft.com/en-us/library/ms679836(VS.85).aspx | 0 |
57,530 | 09/11/2008 20:26:49 | 29 | 08/01/2008 12:24:53 | 644 | 64 | Any tool to migrate from Vault to Subversion? | Are there any tools (free or paid) to facilitate a migration from [Sourcegear's Vault][1] to [Subversion][2]?
Requirements:
1. One-time migration only
2. Full history with comments
Optional:
1. Some support for labels/branches/tags
2. Relatively speedy. It can take hours but not days
[1]: http://www.sourcegear.com/vault/index.html
[2]: http://subversion.tigris.org/
Bonus points if you can share personal experience related to this process. | vcs | svn | vault | null | null | null | open | Any tool to migrate from Vault to Subversion?
===
Are there any tools (free or paid) to facilitate a migration from [Sourcegear's Vault][1] to [Subversion][2]?
Requirements:
1. One-time migration only
2. Full history with comments
Optional:
1. Some support for labels/branches/tags
2. Relatively speedy. It can take hours but not days
[1]: http://www.sourcegear.com/vault/index.html
[2]: http://subversion.tigris.org/
Bonus points if you can share personal experience related to this process. | 0 |
57,537 | 09/11/2008 20:28:31 | 4,682 | 09/05/2008 07:07:06 | 51 | 4 | Accessing Tomcat Context Path from Servlet | In my Servlet I would like to access the root of the context so that I can do some JavaScript minifying.
It would be possible to do the minify as part of the install process but I would like to do it on Servlet startup to reduce the implementation cost.
Does anyone know of a method for getting the context directory so that I can load and write files to disk? | java | javascript | tomcat | servlets | null | null | open | Accessing Tomcat Context Path from Servlet
===
In my Servlet I would like to access the root of the context so that I can do some JavaScript minifying.
It would be possible to do the minify as part of the install process but I would like to do it on Servlet startup to reduce the implementation cost.
Does anyone know of a method for getting the context directory so that I can load and write files to disk? | 0 |
57,547 | 09/11/2008 20:32:41 | 5,976 | 09/11/2008 20:22:33 | 1 | 0 | IMAP forwarder | I'm wondering what is the quickest and most reliable way to forward mail form an IMAP account.
My university does not allow our student-mailbox to forward to a private e-mail account (everybody uses either Gmail or Hotmail here). It's a pollitical thing, not technical. We do have IMAP access to the mailbox. I would like to have a service wich dowloads the mail trough IMAP, and forwards. And it would be nice to scale it, so thousands of students can use it. Eventualy, I want to build a public signup page, and have it processed automaticly from there.
So far, I've made a decent PHP script wich connects, downloads headers and bodyparts, and ties it all together. I have two problems with that.
1) I'm downloading all kind of parts, and sticking them back together. I hope that every exotic attatched file, weird encoded piece of text and every tipe of header survives this. I'm not even sure I have the complete header.
2) The to: e-mailadres becomes the private e-mailadress, not the original student e-mailadress. I think this is lame, and unconveniant in searching and archiving.
Is the PHP script the way to go? Is there a trick using a particular linux mail service/deamon? Does IMAP have a 'forward' command, I'm missing? | imap | e-mail | forwarding | web-services | web-applications | null | open | IMAP forwarder
===
I'm wondering what is the quickest and most reliable way to forward mail form an IMAP account.
My university does not allow our student-mailbox to forward to a private e-mail account (everybody uses either Gmail or Hotmail here). It's a pollitical thing, not technical. We do have IMAP access to the mailbox. I would like to have a service wich dowloads the mail trough IMAP, and forwards. And it would be nice to scale it, so thousands of students can use it. Eventualy, I want to build a public signup page, and have it processed automaticly from there.
So far, I've made a decent PHP script wich connects, downloads headers and bodyparts, and ties it all together. I have two problems with that.
1) I'm downloading all kind of parts, and sticking them back together. I hope that every exotic attatched file, weird encoded piece of text and every tipe of header survives this. I'm not even sure I have the complete header.
2) The to: e-mailadres becomes the private e-mailadress, not the original student e-mailadress. I think this is lame, and unconveniant in searching and archiving.
Is the PHP script the way to go? Is there a trick using a particular linux mail service/deamon? Does IMAP have a 'forward' command, I'm missing? | 0 |
57,549 | 09/11/2008 20:34:16 | 4,418 | 09/03/2008 15:54:27 | 48 | 5 | GPS and Embedded Development - Where to find resources? | I'm just starting to design some embedded devices, and am looking for resources.
What I want to be able to do is to connect a GPS receiver to a lightweight SBC or mini-ITX, x86-based computer, and track a remote-controlled vehicle's location/progress.
Ideally, this could morph into building some hobby, semi-autonomous vehicles.
But what I need to start with is a development board for GPS programming.
What boards/packages have you used, and where can I find [preferably open source] development for them? | gps | null | null | null | null | null | open | GPS and Embedded Development - Where to find resources?
===
I'm just starting to design some embedded devices, and am looking for resources.
What I want to be able to do is to connect a GPS receiver to a lightweight SBC or mini-ITX, x86-based computer, and track a remote-controlled vehicle's location/progress.
Ideally, this could morph into building some hobby, semi-autonomous vehicles.
But what I need to start with is a development board for GPS programming.
What boards/packages have you used, and where can I find [preferably open source] development for them? | 0 |
57,552 | 09/11/2008 20:34:43 | 1,491,425 | 08/13/2008 13:49:51 | 42 | 3 | AJAX Dropdown Extender Question | Ok, so I got my extender working on a default.aspx page on my website and it looks good. I basically copied and pasted the code for it into a user control control.ascx page. When I do this I completely loose the functionality (just shows the target control label and no dropdown, even upon hover). Is there any reason why it doesn't work in a custom user control inside a masterpage setup? | asp.net | ajax | dropdownextender | null | null | null | open | AJAX Dropdown Extender Question
===
Ok, so I got my extender working on a default.aspx page on my website and it looks good. I basically copied and pasted the code for it into a user control control.ascx page. When I do this I completely loose the functionality (just shows the target control label and no dropdown, even upon hover). Is there any reason why it doesn't work in a custom user control inside a masterpage setup? | 0 |
57,557 | 09/11/2008 20:37:03 | 4,337 | 09/02/2008 22:43:39 | 997 | 99 | Mail Quota Checker in C# | We have a requirement to build a tool for users in an Intranet scenario.
The tool should check how much percentage of the Mailbox Quota (set in Active Directory) is being used.
Currently, they can check their Folder size using Outlook 2003 but this does not show the Quota Limit set for them or the percentage being used.
This [blog][1] has all the exact information I need including vbscript samples.
If you have any similar C# code, please post it.
That will give me a good lead on writing a small system tray application which will poll the Active Directory and show the percentage in real time.
PS: I am not being lazy. Already started writing code for this. Just checking if you folks have some existing code to share.
[1]: http://gsexdev.blogspot.com/2005/03/relating-mailbox-sizes-to-mailbox.html | .net | c# | ldap | exchange-server | outlook | null | open | Mail Quota Checker in C#
===
We have a requirement to build a tool for users in an Intranet scenario.
The tool should check how much percentage of the Mailbox Quota (set in Active Directory) is being used.
Currently, they can check their Folder size using Outlook 2003 but this does not show the Quota Limit set for them or the percentage being used.
This [blog][1] has all the exact information I need including vbscript samples.
If you have any similar C# code, please post it.
That will give me a good lead on writing a small system tray application which will poll the Active Directory and show the percentage in real time.
PS: I am not being lazy. Already started writing code for this. Just checking if you folks have some existing code to share.
[1]: http://gsexdev.blogspot.com/2005/03/relating-mailbox-sizes-to-mailbox.html | 0 |
57,560 | 09/11/2008 20:38:31 | 2,564 | 08/22/2008 22:24:11 | 31 | 3 | How do I check that a Windows QFE/patch has been installed from c#? | What's the best way in c# to determine is a given QFE/patch has been installed? | c# | windows | qfe | null | null | null | open | How do I check that a Windows QFE/patch has been installed from c#?
===
What's the best way in c# to determine is a given QFE/patch has been installed? | 0 |
57,567 | 09/11/2008 20:40:57 | 4,770 | 09/05/2008 14:24:23 | 38 | 4 | Handles vs. AddHandler | Is there an advantage to dynamically attaching/detaching event handlers?
Would manually detaching handlers help ensure that there isn't a reference remaining to a disposed object? | vb.net | .net-3.5 | garbage-collection | null | null | null | open | Handles vs. AddHandler
===
Is there an advantage to dynamically attaching/detaching event handlers?
Would manually detaching handlers help ensure that there isn't a reference remaining to a disposed object? | 0 |
57,576 | 09/11/2008 20:43:18 | 5,008 | 09/07/2008 10:42:10 | 101 | 11 | Secure-Wave and click once applications | I have users who are using "secure-wave" security. Evidently it is some sort of white-listing application monitor.
With my click-once application, the name of the folders that are used are runtime generated, so the administrators are not able to properly whitelist the application and its files.
Any suggestions? | click-once | secure-wave | null | null | null | null | open | Secure-Wave and click once applications
===
I have users who are using "secure-wave" security. Evidently it is some sort of white-listing application monitor.
With my click-once application, the name of the folders that are used are runtime generated, so the administrators are not able to properly whitelist the application and its files.
Any suggestions? | 0 |
57,577 | 09/11/2008 20:43:26 | 3,798 | 08/30/2008 22:09:59 | 453 | 21 | How to I merge XML from distinct DomDocuments. | What is the easiest way to merge Xml from two distinct Dom Documents? Is there a way other than using the Canonical [DataReader][1] approach and then messing with the outputted DOM. What I basically want is to AppendChild to XmlElements without getting: "The node to be inserted is from a different document context." Here is c# code that I want to work, that obviously won't (what I am doing is merging two documents which have bunch of nodes that I am interested in parts of):
XmlDocument doc1 = new XmlDocument();
doc1.LoadXml("<a><items><item1/><item2/><item3/></items></a>");
XmlDocument doc2 = new XmlDocument();
doc2.LoadXml("<b><items><item4/><item5/><item6/></items></b>");
XmlNode doc2Node = doc2.SelectSingleNode("/b/items");
XmlNodeList doc1Nodes = doc1.SelectNodes("/a/items/*");
foreach (XmlNode doc1Node in doc1Nodes)
{
doc2Node.AppendChild(doc1Node);
}
[1]: http://support.microsoft.com/kb/311530 | .net | xml | null | null | null | null | open | How to I merge XML from distinct DomDocuments.
===
What is the easiest way to merge Xml from two distinct Dom Documents? Is there a way other than using the Canonical [DataReader][1] approach and then messing with the outputted DOM. What I basically want is to AppendChild to XmlElements without getting: "The node to be inserted is from a different document context." Here is c# code that I want to work, that obviously won't (what I am doing is merging two documents which have bunch of nodes that I am interested in parts of):
XmlDocument doc1 = new XmlDocument();
doc1.LoadXml("<a><items><item1/><item2/><item3/></items></a>");
XmlDocument doc2 = new XmlDocument();
doc2.LoadXml("<b><items><item4/><item5/><item6/></items></b>");
XmlNode doc2Node = doc2.SelectSingleNode("/b/items");
XmlNodeList doc1Nodes = doc1.SelectNodes("/a/items/*");
foreach (XmlNode doc1Node in doc1Nodes)
{
doc2Node.AppendChild(doc1Node);
}
[1]: http://support.microsoft.com/kb/311530 | 0 |
57,584 | 09/11/2008 20:46:12 | 327 | 08/04/2008 17:08:49 | 733 | 48 | How can I make a ListView's columns auto-resize programmatically? | I've found some examples using the Win32 api or simulating the ^+ button combination (ctrl-+) [using SendKeys][1], but at least with the SendKeys method the listview grabs the cursor and sets it to an hourglass until I hit the start button on my keyboard. What is the cleanest way to do this?
[1]: http://www.codeproject.com/KB/list/AutoResize.aspx | .net | windows | gui | controls | null | null | open | How can I make a ListView's columns auto-resize programmatically?
===
I've found some examples using the Win32 api or simulating the ^+ button combination (ctrl-+) [using SendKeys][1], but at least with the SendKeys method the listview grabs the cursor and sets it to an hourglass until I hit the start button on my keyboard. What is the cleanest way to do this?
[1]: http://www.codeproject.com/KB/list/AutoResize.aspx | 0 |
57,586 | 09/11/2008 20:46:31 | 3,821 | 08/31/2008 02:41:10 | 87 | 11 | ASP.Net UpdatePanel "this._postbackSettings.async is null or not an object" | I get this error on an update panel within a popupControlExtender which is within a dragPanelExtender.
I see that a lot of other people have this issue and have various fixes none of which have worked for me.
I would love to hear a logical explanation for why this is occurring and a foolproof way to avoid such issues in the future. | asp.net | ajax | ajaxtoolkit | updatepanel | null | null | open | ASP.Net UpdatePanel "this._postbackSettings.async is null or not an object"
===
I get this error on an update panel within a popupControlExtender which is within a dragPanelExtender.
I see that a lot of other people have this issue and have various fixes none of which have worked for me.
I would love to hear a logical explanation for why this is occurring and a foolproof way to avoid such issues in the future. | 0 |
57,599 | 09/11/2008 20:50:49 | 845 | 08/09/2008 12:58:59 | 54 | 3 | How to calculate age in TSQL with Years, Months, and Days | What would be the best way to calculate someone's age in years, months, and days in TSQL (SQLServer 2000)?
The datediff function doesn't handle year boundaries well, plus getting the months and days separate will be a bear. I know I can do it on the client side relatively easily, but I'd like to have it done in my sproc. | tsql | datediff | age | null | null | null | open | How to calculate age in TSQL with Years, Months, and Days
===
What would be the best way to calculate someone's age in years, months, and days in TSQL (SQLServer 2000)?
The datediff function doesn't handle year boundaries well, plus getting the months and days separate will be a bear. I know I can do it on the client side relatively easily, but I'd like to have it done in my sproc. | 0 |
57,600 | 09/11/2008 20:50:57 | 2,831 | 08/25/2008 12:57:22 | 33 | 0 | Continue Considered Harmful? | Should developers avoid using [continue][1] in C# or its equivalent in other languages to force the next iteration of a loop? Would arguments for or against overlap with arguments about [Goto][2]?
[1]: http://msdn.microsoft.com/en-us/library/923ahwt1.aspx
[2]: http://stackoverflow.com/questions/46586/goto-still-considered-harmful | continue | .net | c# | goto | loop | null | open | Continue Considered Harmful?
===
Should developers avoid using [continue][1] in C# or its equivalent in other languages to force the next iteration of a loop? Would arguments for or against overlap with arguments about [Goto][2]?
[1]: http://msdn.microsoft.com/en-us/library/923ahwt1.aspx
[2]: http://stackoverflow.com/questions/46586/goto-still-considered-harmful | 0 |
57,609 | 09/11/2008 20:54:07 | 2,488 | 08/22/2008 13:41:55 | 1 | 0 | Save registry values in WinCE using a C# app | I'm working on a WinCE 6.0 system with a touchscreen that stores its calibration data (x-y location, offset, etc.) in the system registry (HKLM\HARDWARE\TOUCH\). Right now, I'm placing the cal values into registry keys that get put into the OS image at build time. That works fine for the monitor that I get the original cal values from, but when I load this image into another system with a different monitor, the touchscreen pointer location is (understandably) off, because the two monitors do not have the same cal values.
My problem is that I don't know how to properly store values into the registry so that they persist after a power cycle. See, I can recalibrate the screen on the second system, but the new values only exist in volatile memory. I suggested to my boss that we could just tell our customer to leave the power on the unit at all times -- that didn't go over well.
I need advice on how to save the new constants into the registry, so that we can calibrate the monitors once before shipping them out to our customer, and not have to make separate OS images for each unit we build.
A C# method that is known to work in CE6.0 would be helpful. Thanks.
-Odbasta | c# | registry | windows-ce | null | null | null | open | Save registry values in WinCE using a C# app
===
I'm working on a WinCE 6.0 system with a touchscreen that stores its calibration data (x-y location, offset, etc.) in the system registry (HKLM\HARDWARE\TOUCH\). Right now, I'm placing the cal values into registry keys that get put into the OS image at build time. That works fine for the monitor that I get the original cal values from, but when I load this image into another system with a different monitor, the touchscreen pointer location is (understandably) off, because the two monitors do not have the same cal values.
My problem is that I don't know how to properly store values into the registry so that they persist after a power cycle. See, I can recalibrate the screen on the second system, but the new values only exist in volatile memory. I suggested to my boss that we could just tell our customer to leave the power on the unit at all times -- that didn't go over well.
I need advice on how to save the new constants into the registry, so that we can calibrate the monitors once before shipping them out to our customer, and not have to make separate OS images for each unit we build.
A C# method that is known to work in CE6.0 would be helpful. Thanks.
-Odbasta | 0 |
57,615 | 09/11/2008 20:55:57 | 337 | 08/04/2008 18:11:42 | 205 | 7 | How to add a Timeout to Console.ReadLine()? | I have a console app in which I want to give the user *x* seconds to respond to the prompt. If no input is made after a certain period of time, program logic should continue. We assume a timeout means empty response.
What is the most straightforward way of approaching this? | c# | .net | console | io | timeout | null | open | How to add a Timeout to Console.ReadLine()?
===
I have a console app in which I want to give the user *x* seconds to respond to the prompt. If no input is made after a certain period of time, program logic should continue. We assume a timeout means empty response.
What is the most straightforward way of approaching this? | 0 |
57,622 | 09/11/2008 20:57:20 | 673 | 08/07/2008 16:33:05 | 776 | 58 | PHP Object Oriented or not? | I have a start of a webapp that I wrote without using the Object Oriented features of PHP.
I don't really know if it is worth it to go back and rewrite the parts I have finished. Is object oriented PHP worth rewriting all or part of a decent working app? | php | web-applications | object-oriented-design | null | null | null | open | PHP Object Oriented or not?
===
I have a start of a webapp that I wrote without using the Object Oriented features of PHP.
I don't really know if it is worth it to go back and rewrite the parts I have finished. Is object oriented PHP worth rewriting all or part of a decent working app? | 0 |
57,625 | 09/11/2008 20:57:48 | 5,469 | 09/09/2008 21:03:22 | 226 | 18 | How do you lock tables in SQL Server 2005, and should I even do it? | This one will take some explaining. What I've done is create a specific custom message queue in SQL Server 2005. I have a table with messages that contain timestamps for both acknowledgement and completion. The stored procedure that callers execute to obtain the next message in their queue also acknowledges the message. So far so good. Well, if the system is experiencing a massive amount of transactions (thousands per minute), isnt it possible for a message to be acknowledged by another execution of the stored procedure while another is prepared to so itself? Let me help by showing my sql code in the stored proc:
--Grab the next message id
declare @MessageId uniqueidentifier
set @MessageId = (select top(1) ActionMessageId from UnacknowledgedDemands);
--Acknowledge the message
update ActionMessages
set AcknowledgedTime = getdate()
where ActionMessageId = @MessageId
--Select the entire message
...
...
In the above code, couldnt another stored procedure running at the same time obtain the same id and attempt to acknowledge it at the same time? Could I (or should I) implement some sort of locking to prevent another stored proc from acknowledging messages that another stored proc is querying?
Wow, did any of this even make sense? It's a bit difficult to put to words... | sql-server | tsql | bestpractice | null | null | null | open | How do you lock tables in SQL Server 2005, and should I even do it?
===
This one will take some explaining. What I've done is create a specific custom message queue in SQL Server 2005. I have a table with messages that contain timestamps for both acknowledgement and completion. The stored procedure that callers execute to obtain the next message in their queue also acknowledges the message. So far so good. Well, if the system is experiencing a massive amount of transactions (thousands per minute), isnt it possible for a message to be acknowledged by another execution of the stored procedure while another is prepared to so itself? Let me help by showing my sql code in the stored proc:
--Grab the next message id
declare @MessageId uniqueidentifier
set @MessageId = (select top(1) ActionMessageId from UnacknowledgedDemands);
--Acknowledge the message
update ActionMessages
set AcknowledgedTime = getdate()
where ActionMessageId = @MessageId
--Select the entire message
...
...
In the above code, couldnt another stored procedure running at the same time obtain the same id and attempt to acknowledge it at the same time? Could I (or should I) implement some sort of locking to prevent another stored proc from acknowledging messages that another stored proc is querying?
Wow, did any of this even make sense? It's a bit difficult to put to words... | 0 |
57,627 | 09/11/2008 20:58:14 | 5,978 | 09/11/2008 20:24:58 | 1 | 0 | msys vs cygwin | I have at least one cygwin shell open all the time, when on windows machine. Any msys users out there? Why would anyone use msys over cygwin (except for building win executables)? | cygwin | null | null | null | null | null | open | msys vs cygwin
===
I have at least one cygwin shell open all the time, when on windows machine. Any msys users out there? Why would anyone use msys over cygwin (except for building win executables)? | 0 |
57,652 | 09/11/2008 21:06:21 | 1,436 | 08/15/2008 15:43:19 | 441 | 22 | How do I get JavaScript to open a popup window on the current monitor | Scenario:
1. The user has two monitors.
2. Their browser is open on the secondary monitor.
3. They click a link in the browser which calls window.open().
4. The popup window always opens on their primary monitor.
Is there any way in JavaScript to get the popup window to open on the same monitor as the initial browser window (the opener)? | javascript | multiple-monitors | null | null | null | null | open | How do I get JavaScript to open a popup window on the current monitor
===
Scenario:
1. The user has two monitors.
2. Their browser is open on the secondary monitor.
3. They click a link in the browser which calls window.open().
4. The popup window always opens on their primary monitor.
Is there any way in JavaScript to get the popup window to open on the same monitor as the initial browser window (the opener)? | 0 |
57,658 | 09/11/2008 21:07:08 | 673 | 08/07/2008 16:33:05 | 782 | 58 | Opensourcing a starter web application | I am just starting with a web application to maintain a household budget.
I really want to opensource it and let anyone who wants to work on it do so, as it is a hobby I don't really have the time to develop on it that much well
The only problem I have is that if this is an app I want to host on my domain, how do I go about doing this?
Should I set up an SVN and allow other people to check things in, and how do I manage checking the code that others write. I dont want to spend all my free time checking to see if someone else is trying to put in an exploit. | svn | open-source | web-applications | startups | starting-out | null | open | Opensourcing a starter web application
===
I am just starting with a web application to maintain a household budget.
I really want to opensource it and let anyone who wants to work on it do so, as it is a hobby I don't really have the time to develop on it that much well
The only problem I have is that if this is an app I want to host on my domain, how do I go about doing this?
Should I set up an SVN and allow other people to check things in, and how do I manage checking the code that others write. I dont want to spend all my free time checking to see if someone else is trying to put in an exploit. | 0 |
57,665 | 09/11/2008 21:09:58 | 5,988 | 09/11/2008 21:09:58 | 1 | 0 | How do I expose data in a JSON format through a web service using Rails? | Is there an easy way to return data to web service clients in JSON using Rails? | ruby-on-rails | web-services | json | null | null | null | open | How do I expose data in a JSON format through a web service using Rails?
===
Is there an easy way to return data to web service clients in JSON using Rails? | 0 |
57,677 | 09/11/2008 21:13:32 | 4,883 | 09/06/2008 10:24:59 | 760 | 5 | How do you create a process-wide singleton object? | I read that the unit of granularity for static fields in .Net are per AppDomain, not per process. Is it possible to create a process-wide singleton object? | .net | null | null | null | null | null | open | How do you create a process-wide singleton object?
===
I read that the unit of granularity for static fields in .Net are per AppDomain, not per process. Is it possible to create a process-wide singleton object? | 0 |
57,679 | 09/11/2008 21:13:53 | 5,261 | 09/08/2008 18:44:40 | 137 | 13 | jQuery ajax $.post successfull ? | I'm trying to figure the result of this call if it was successful or not. The successFunction doesn't get called so i'm assuming it was not. How do i know what went wrong?
xmlRequest = $.post("/url/file/", { 'id' : object.id }, successFunction, 'json');
Do i use the xmlRequest object? | jquery | post | success | xmlhttprequest | null | null | open | jQuery ajax $.post successfull ?
===
I'm trying to figure the result of this call if it was successful or not. The successFunction doesn't get called so i'm assuming it was not. How do i know what went wrong?
xmlRequest = $.post("/url/file/", { 'id' : object.id }, successFunction, 'json');
Do i use the xmlRequest object? | 0 |
57,683 | 09/11/2008 21:14:59 | 1,580 | 08/16/2008 20:34:26 | 13 | 11 | SSRS - Sub Totals Customization - Moving Column to beggining of line | I Have a request for the TOTAL's and subtotals column to be moved to the top/left of columns it represents, and by default SSRS does it on the bottom or right hand side of the columns being totaled. Is there a way to this?
Thanks! | reporting-services | ssrs | sqlreportingservices | null | null | null | open | SSRS - Sub Totals Customization - Moving Column to beggining of line
===
I Have a request for the TOTAL's and subtotals column to be moved to the top/left of columns it represents, and by default SSRS does it on the bottom or right hand side of the columns being totaled. Is there a way to this?
Thanks! | 0 |
57,689 | 09/11/2008 21:19:30 | 5,988 | 09/11/2008 21:09:58 | 1 | 0 | How do I expose data in a JSON format through a web service using Java? | Is there an easy way to return data to web service clients in JSON using java? I'm fine with servlets, spring, etc. | java | web-services | json | null | null | null | open | How do I expose data in a JSON format through a web service using Java?
===
Is there an easy way to return data to web service clients in JSON using java? I'm fine with servlets, spring, etc. | 0 |
57,701 | 09/11/2008 21:25:23 | 3,279 | 08/27/2008 16:46:21 | 889 | 47 | What are the performance characteristics of 'is' reflection in C#? | It's [shown][1] that 'as' casing is much faster than prefix casting, but what about 'is' reflection? How bad is it? As you can imagine, searching for 'is' on Google isn't terribly effective.
[1]: http://www.codeproject.com/KB/cs/csharpcasts.aspx | c# | reflection | null | null | null | null | open | What are the performance characteristics of 'is' reflection in C#?
===
It's [shown][1] that 'as' casing is much faster than prefix casting, but what about 'is' reflection? How bad is it? As you can imagine, searching for 'is' on Google isn't terribly effective.
[1]: http://www.codeproject.com/KB/cs/csharpcasts.aspx | 0 |
57,708 | 09/11/2008 21:28:46 | 680 | 08/07/2008 17:29:04 | 727 | 17 | Convert XML/HTML Entities into Unicode String in Python | I'm doing some web scraping and sites frequently use HTML entities to represent non ascii characters. Does Python have a utility that takes a string with HTML entities and returns a unicode type?
For example:
I get back:
& #x01ce; (There is no space. I put that so Markdown won't interpret it)
which represents an "a" with a tone mark. In binary, this is represented as the 16 bit 01ce. I want to convert the html entity into the value u'\u01ce' | python | html | entities | null | null | null | open | Convert XML/HTML Entities into Unicode String in Python
===
I'm doing some web scraping and sites frequently use HTML entities to represent non ascii characters. Does Python have a utility that takes a string with HTML entities and returns a unicode type?
For example:
I get back:
& #x01ce; (There is no space. I put that so Markdown won't interpret it)
which represents an "a" with a tone mark. In binary, this is represented as the 16 bit 01ce. I want to convert the html entity into the value u'\u01ce' | 0 |
57,712 | 09/11/2008 21:30:50 | 230 | 08/03/2008 19:32:46 | 602 | 37 | MVC .Net and IIS 5 | What is the best way to get hosting of an MVC.Net application to work on IIS 5 (6 or 7). When I tried to publish my MVC application, all I seem to get is 404 errors. Iv done abit of googleing and have found a couple of solutions, but neither seem super elegant, and I worry if they will be unusable once I come to use a shared hosting environment for the application.
[Solution 1][1]
> 1. Right-click your application virtual directory on inetmgr.exe.
> 2. Properties->Virtual Directory Tab-> Configuration.
> 3. Add a new mapping extension. The extension should be .*, which will be
> mapped to the Executable
> C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,
> or the appropriate location on your
> computer (you can simply copy this
> from the mapping for .aspx files). On
> the mapping uncheck "check that file
> exists".
> 4. 3 X OK and you're good to go.
> 5. If you want, you can apply this setting to all your web sites. In
> step1, click on the "Default Web Site"
> node instead of your own virtual
> directory, and in step 2 go to the
> "Home Directory" tab. The rest is the
> same.
Seems a tad hacky to route everything through ASP.NET
[Solutions 2][2]
Edit the mvc routing to contain .mvc in the url and then follow the steps in solutions 1 based around this extension.
> ![alt text][3]
[1]: http://blogs.microsoft.co.il/blogs/dorony/archive/2007/12/15/using-asp-net-mvc-on-iis-5.aspx
[2]: http://blog.pagedesigners.co.nz/?p=29
[3]: http://blog.pagedesigners.co.nz/wp-content/uploads/2007/12/mvc-route-iis51.gif | asp.net-mvc | iis | shared-host | null | null | null | open | MVC .Net and IIS 5
===
What is the best way to get hosting of an MVC.Net application to work on IIS 5 (6 or 7). When I tried to publish my MVC application, all I seem to get is 404 errors. Iv done abit of googleing and have found a couple of solutions, but neither seem super elegant, and I worry if they will be unusable once I come to use a shared hosting environment for the application.
[Solution 1][1]
> 1. Right-click your application virtual directory on inetmgr.exe.
> 2. Properties->Virtual Directory Tab-> Configuration.
> 3. Add a new mapping extension. The extension should be .*, which will be
> mapped to the Executable
> C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,
> or the appropriate location on your
> computer (you can simply copy this
> from the mapping for .aspx files). On
> the mapping uncheck "check that file
> exists".
> 4. 3 X OK and you're good to go.
> 5. If you want, you can apply this setting to all your web sites. In
> step1, click on the "Default Web Site"
> node instead of your own virtual
> directory, and in step 2 go to the
> "Home Directory" tab. The rest is the
> same.
Seems a tad hacky to route everything through ASP.NET
[Solutions 2][2]
Edit the mvc routing to contain .mvc in the url and then follow the steps in solutions 1 based around this extension.
> ![alt text][3]
[1]: http://blogs.microsoft.co.il/blogs/dorony/archive/2007/12/15/using-asp-net-mvc-on-iis-5.aspx
[2]: http://blog.pagedesigners.co.nz/?p=29
[3]: http://blog.pagedesigners.co.nz/wp-content/uploads/2007/12/mvc-route-iis51.gif | 0 |
57,718 | 09/11/2008 21:32:50 | 5,642 | 09/10/2008 15:42:57 | 56 | 3 | Anyone using the Entity Framework *Well*? | Has anyone actually shipped an Entity Framework project that does O/R mapping into conceptual classes that are quite different from the tables in the datastore?
I mean collapse junction (M:M) tables into other entities to form **Conceptual** classes that exist in the business domain but are organized as **multiple tables** in the datastore. All the examples that I see on the MSDN have little use of inheritance, collapsing junction tables into other entities, or collapsing lookup tables into entities.
I'd love to hear of or see examples of the below which support all the CRUD operations you would typically expect to do on a business object.:
1. Vehicle table and a Color table. A Color can appear in many Vehicles (1:M). They form the conceptual class UsedCar which has the property Color.
2. Doctor, DoctorPatients, and Patients tables (form a many to many). Doctors have many Patients, Patients can have many Doctors (M:M). Map out the two conceptual classes Doctor (which has a Patients collection) and Patients (which has a Doctors collection).
**Anyone seen/done this with CSDL in the Entity Framework?** | entity-framework | orm | null | null | null | null | open | Anyone using the Entity Framework *Well*?
===
Has anyone actually shipped an Entity Framework project that does O/R mapping into conceptual classes that are quite different from the tables in the datastore?
I mean collapse junction (M:M) tables into other entities to form **Conceptual** classes that exist in the business domain but are organized as **multiple tables** in the datastore. All the examples that I see on the MSDN have little use of inheritance, collapsing junction tables into other entities, or collapsing lookup tables into entities.
I'd love to hear of or see examples of the below which support all the CRUD operations you would typically expect to do on a business object.:
1. Vehicle table and a Color table. A Color can appear in many Vehicles (1:M). They form the conceptual class UsedCar which has the property Color.
2. Doctor, DoctorPatients, and Patients tables (form a many to many). Doctors have many Patients, Patients can have many Doctors (M:M). Map out the two conceptual classes Doctor (which has a Patients collection) and Patients (which has a Doctors collection).
**Anyone seen/done this with CSDL in the Entity Framework?** | 0 |
57,725 | 09/11/2008 21:35:44 | 4,489 | 09/04/2008 06:00:46 | 173 | 15 | How can I display just a portion of an image in HTML/CSS? | Let's say I want a way to display just the the center 50x50px of an image that's 250x250px in HTML. How can I do that. Also, is there a way to do this for css:url() references?
<p>
I'm aware of *clip* in CSS, but that seems to only work when used with absolute positioning. | html | css | image | null | null | null | open | How can I display just a portion of an image in HTML/CSS?
===
Let's say I want a way to display just the the center 50x50px of an image that's 250x250px in HTML. How can I do that. Also, is there a way to do this for css:url() references?
<p>
I'm aware of *clip* in CSS, but that seems to only work when used with absolute positioning. | 0 |
57,739 | 09/11/2008 21:45:51 | 1,116,922 | 08/04/2008 16:48:14 | 13 | 0 | What is the best workaround for the ASP.NET forms authentication timeout problem when using wildcard mapping? | My team is working on a crappy old website and most of the pages are still ASP classic. However, we've recently migrated to forms authentication using ASP.NET and wildcard mapping. Everything works surprisingly well except for one thing: logged in users are timing out too quickly. After looking in the logs it appears people are timing out exactly after 20 minutes (which is the specified timeout due to inactivity).
So, our hypothesis is that the ASP classic pages are not tripping whatever mechanism in the forms authentication framework that resets the inactivity timer. I've googled around and even read the wildcard mapping post by the Great Gu but still can't find anyone else who is having this problem. So, 1) Have you ever seen this problem? and 2) What's the best workaround? (other than manually placing a hidden frame in every janky ASP page that loads a dumb .NET page in the background)
Thanks in advance. | asp.net | forms-authentication | wildcard-mapping | null | null | null | open | What is the best workaround for the ASP.NET forms authentication timeout problem when using wildcard mapping?
===
My team is working on a crappy old website and most of the pages are still ASP classic. However, we've recently migrated to forms authentication using ASP.NET and wildcard mapping. Everything works surprisingly well except for one thing: logged in users are timing out too quickly. After looking in the logs it appears people are timing out exactly after 20 minutes (which is the specified timeout due to inactivity).
So, our hypothesis is that the ASP classic pages are not tripping whatever mechanism in the forms authentication framework that resets the inactivity timer. I've googled around and even read the wildcard mapping post by the Great Gu but still can't find anyone else who is having this problem. So, 1) Have you ever seen this problem? and 2) What's the best workaround? (other than manually placing a hidden frame in every janky ASP page that loads a dumb .NET page in the background)
Thanks in advance. | 0 |
57,747 | 09/11/2008 21:53:51 | 1,368 | 08/14/2008 18:57:47 | 215 | 10 | Setting up Team foundation server | I have to setup team foundation server for a company, something that I don't have any experience in.
The company will have about 5 or so developers that will be using it.
Is this a big task or something that is fairly easy to do (with instructions)?
Any helpful tutorials that you can recommend?
Any recommendations on server specs for a team of 5-10? | tfs | null | null | null | null | null | open | Setting up Team foundation server
===
I have to setup team foundation server for a company, something that I don't have any experience in.
The company will have about 5 or so developers that will be using it.
Is this a big task or something that is fairly easy to do (with instructions)?
Any helpful tutorials that you can recommend?
Any recommendations on server specs for a team of 5-10? | 0 |
57,751 | 09/11/2008 21:54:47 | 1,412 | 08/15/2008 15:05:57 | 783 | 45 | Emacs query-replace with textual transformation | I want to find any text in a file that matches a regexp of the form *t*`[A-Z]`*u* (i.e., a match *t* followed by a capital letter and another match *u*, and transform the matched text so that the capital letter is lowercase. For example, for the regexp `x[A-Z]y`
xAy
becomes
xay
and
xZy
becomes
xzy
Emacs' `query-replace` function allows back-references, but AFAIK not the transformation of the matched text. Is there a built-in function that does this? Does anybody have a short Elisp function I could use? | regex | emacs | null | null | null | null | open | Emacs query-replace with textual transformation
===
I want to find any text in a file that matches a regexp of the form *t*`[A-Z]`*u* (i.e., a match *t* followed by a capital letter and another match *u*, and transform the matched text so that the capital letter is lowercase. For example, for the regexp `x[A-Z]y`
xAy
becomes
xay
and
xZy
becomes
xzy
Emacs' `query-replace` function allows back-references, but AFAIK not the transformation of the matched text. Is there a built-in function that does this? Does anybody have a short Elisp function I could use? | 0 |
57,759 | 09/11/2008 21:59:21 | 4,906 | 09/06/2008 14:21:25 | 81 | 6 | Does Vista restrict creation of shorcuts to "Programs" on a NonAdmin account? | I'm working on an installer (using Wise Installer, older version from like 1999).
I'm creating a shortcut in the Programs group to an EXE. I'm also creating a shortcut on the Desktop.
If the install is run from an Admin account, then I create the shortcut on the Common Desktop and Common Program Group (i.e., read from the HKEY_LOCAL_MACHINE\\Explorer\Shellfor All Users).
If it's installed from a NonAdmin account, then I install to the HKEY_CURRENT_USER's desktop and Program Group.
**Behavior**
Install on:
XP NonAdmin - Desktop and Program Shortcuts install OK.
Vista Admin - Desktop & Program Shortcuts install OK.
Vista Non-Admin, UAC off- **Desktop shortcut installs, but Program Shortcut does not**. However, the Program group *folder* they're supposed to be installed to *does* get created.
At the end of the install, I launch the Program Group that has the shorcut. It launches in all of the above. I can manually drag a shortcut into that folder and it works just fine.
I'm bloody baffled.
| windows | windows-vista | installer | null | null | null | open | Does Vista restrict creation of shorcuts to "Programs" on a NonAdmin account?
===
I'm working on an installer (using Wise Installer, older version from like 1999).
I'm creating a shortcut in the Programs group to an EXE. I'm also creating a shortcut on the Desktop.
If the install is run from an Admin account, then I create the shortcut on the Common Desktop and Common Program Group (i.e., read from the HKEY_LOCAL_MACHINE\\Explorer\Shellfor All Users).
If it's installed from a NonAdmin account, then I install to the HKEY_CURRENT_USER's desktop and Program Group.
**Behavior**
Install on:
XP NonAdmin - Desktop and Program Shortcuts install OK.
Vista Admin - Desktop & Program Shortcuts install OK.
Vista Non-Admin, UAC off- **Desktop shortcut installs, but Program Shortcut does not**. However, the Program group *folder* they're supposed to be installed to *does* get created.
At the end of the install, I launch the Program Group that has the shorcut. It launches in all of the above. I can manually drag a shortcut into that folder and it works just fine.
I'm bloody baffled.
| 0 |
57,762 | 09/11/2008 22:01:09 | 5,416 | 09/09/2008 13:41:43 | 36 | 5 | Step-By-Step ASP.NET Automated Build/Deploy | Seems like there are so many different ways of automating one's build/deployment that it becomes difficult to parse through all the different scenarios that people support in tutorials on the web. So I wanted to present the question to the stackoverflow crowd ... what would be the best way to set up an automated build and deployment system using the following configuration:
- Visual Studio 2008
- Web Application Project
- CruiseControl.NET
One of the first things I tried was to have CCnet automatically zip the output and copy it to the server, but then that requires manual work to unzip at the destination. However, if we try to copy all the files individually, then it could potentially take a long time if it's a large application (build server lives outside of the datacenter in our office ... I know).
Also of particular interest is how we would support multiple environments as we have dev, qa, uat, and then of course prod. | asp.net | iis | deployment | null | null | null | open | Step-By-Step ASP.NET Automated Build/Deploy
===
Seems like there are so many different ways of automating one's build/deployment that it becomes difficult to parse through all the different scenarios that people support in tutorials on the web. So I wanted to present the question to the stackoverflow crowd ... what would be the best way to set up an automated build and deployment system using the following configuration:
- Visual Studio 2008
- Web Application Project
- CruiseControl.NET
One of the first things I tried was to have CCnet automatically zip the output and copy it to the server, but then that requires manual work to unzip at the destination. However, if we try to copy all the files individually, then it could potentially take a long time if it's a large application (build server lives outside of the datacenter in our office ... I know).
Also of particular interest is how we would support multiple environments as we have dev, qa, uat, and then of course prod. | 0 |
57,766 | 09/11/2008 22:03:14 | 4,770 | 09/05/2008 14:24:23 | 38 | 5 | BufferedGraphicsContext Error | I am getting the below error and call stack at the same time everyday after several hours of application use. Can anyone shed some light on what is happening?
System.InvalidOperationException: BufferedGraphicsContext cannot be disposed of because a buffer operation is currently in progress.
at System.Drawing.BufferedGraphicsContext.Dispose(Boolean disposing)
at System.Drawing.BufferedGraphicsContext.Dispose()
at System.Drawing.BufferedGraphicsContext.AllocBufferInTempManager(Graphics targetGraphics, IntPtr targetDC, Rectangle targetRectangle)
at System.Drawing.BufferedGraphicsContext.Allocate(IntPtr targetDC, Rectangle targetRectangle)
at System.Windows.Forms.Control.WmPaint(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.MenuStrip.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
| winforms | exception | multithreading | gdi+ | null | null | open | BufferedGraphicsContext Error
===
I am getting the below error and call stack at the same time everyday after several hours of application use. Can anyone shed some light on what is happening?
System.InvalidOperationException: BufferedGraphicsContext cannot be disposed of because a buffer operation is currently in progress.
at System.Drawing.BufferedGraphicsContext.Dispose(Boolean disposing)
at System.Drawing.BufferedGraphicsContext.Dispose()
at System.Drawing.BufferedGraphicsContext.AllocBufferInTempManager(Graphics targetGraphics, IntPtr targetDC, Rectangle targetRectangle)
at System.Drawing.BufferedGraphicsContext.Allocate(IntPtr targetDC, Rectangle targetRectangle)
at System.Windows.Forms.Control.WmPaint(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.MenuStrip.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
| 0 |
57,768 | 09/11/2008 22:04:46 | 4,787 | 09/05/2008 15:36:12 | 20 | 1 | How should you go about learning ASP.NET after life as a ColdFusion developer? | As someone who has spent around 10 years programming web applications with Adobe's ColdFusion, I have decided to add ASP.NET as a string to my bow.
For someone who has spent so long with CF and the underlying Java, ASP.NET seems a little alien to me. How should I go about getting up to speed with ASP.NET so that I can be truly dangerous with it? Do I need to know C# at any great amount of detail?
I want to be in a position where I can build basic web apps fairly quickly so I can learn more doing the tricky stuff. | asp.net | coldfusion | null | null | null | null | open | How should you go about learning ASP.NET after life as a ColdFusion developer?
===
As someone who has spent around 10 years programming web applications with Adobe's ColdFusion, I have decided to add ASP.NET as a string to my bow.
For someone who has spent so long with CF and the underlying Java, ASP.NET seems a little alien to me. How should I go about getting up to speed with ASP.NET so that I can be truly dangerous with it? Do I need to know C# at any great amount of detail?
I want to be in a position where I can build basic web apps fairly quickly so I can learn more doing the tricky stuff. | 0 |
57,773 | 09/11/2008 22:08:11 | 2,141 | 08/20/2008 14:38:34 | 437 | 4 | Zend PHP framework | What are the advantages and disadvantages of this framework when compared to other PHP frameworks? | php | null | null | null | null | null | open | Zend PHP framework
===
What are the advantages and disadvantages of this framework when compared to other PHP frameworks? | 0 |
57,776 | 09/11/2008 22:09:48 | 2,213 | 08/20/2008 22:31:55 | 507 | 32 | How to "Add Existing Item" an entire directory structure in Visual Studio | I feel ridiculous for asking this because it seems like it should be so simple, however I have been unable to discover an answer to this question.
I have a free standing set of files not affiliated with any C# project at all that reside in a complicated nested directory structure. I want to add them in that format to a different directory in an ASP.NET web application I am working on; while retaining the same structure. So, I copied the folder into the target location of my project and I tried to “add existing item” only to lose the previous folder hierarchy. Usually I have re-created the directories by hand, copied across on a one-to-one basis, and then added existing items. There are simply too many directories/items in this case.
**So how do you add existing directories and files in Visual Studio 2008?**
| visual-studio | ide | tips-and-tricks | null | null | null | open | How to "Add Existing Item" an entire directory structure in Visual Studio
===
I feel ridiculous for asking this because it seems like it should be so simple, however I have been unable to discover an answer to this question.
I have a free standing set of files not affiliated with any C# project at all that reside in a complicated nested directory structure. I want to add them in that format to a different directory in an ASP.NET web application I am working on; while retaining the same structure. So, I copied the folder into the target location of my project and I tried to “add existing item” only to lose the previous folder hierarchy. Usually I have re-created the directories by hand, copied across on a one-to-one basis, and then added existing items. There are simply too many directories/items in this case.
**So how do you add existing directories and files in Visual Studio 2008?**
| 0 |
57,790 | 09/11/2008 22:15:51 | 2,536 | 08/22/2008 17:37:07 | 861 | 38 | Visual Studio 2008 / Web site problem | I am using VS 2008 with SP1 and the IE 8 beta 2. Whenever I start a new Web site or when I double-click an ASPX in the solution explorer, VS insists on attempting to the display the ASPX page in a free-standing IE browser instance. The address is the local file path to the ASPX it's trying to load and an error that says, "The XML page cannot be displayed" is shown.
Otherwise, things work work correctly (I just close the offending browser window. ASP.NET is registered with IIS and I have no other problems. I have tested my same configuration on other PCs and it works fine. Has anyone had this problem?
Thanks
rp | vs2008 | sp1 | internet-explorer-8 | null | null | null | open | Visual Studio 2008 / Web site problem
===
I am using VS 2008 with SP1 and the IE 8 beta 2. Whenever I start a new Web site or when I double-click an ASPX in the solution explorer, VS insists on attempting to the display the ASPX page in a free-standing IE browser instance. The address is the local file path to the ASPX it's trying to load and an error that says, "The XML page cannot be displayed" is shown.
Otherwise, things work work correctly (I just close the offending browser window. ASP.NET is registered with IIS and I have no other problems. I have tested my same configuration on other PCs and it works fine. Has anyone had this problem?
Thanks
rp | 0 |
57,791 | 09/11/2008 22:16:24 | 2,577 | 08/23/2008 03:18:09 | 199 | 9 | Can I override onbeforeunload for a particular element? | I have a page which does quite a bit of work and I don't want the user to be able to navigate away from that page (close browser, hit back button, etc.) without getting a warning. I found that the onbeforeunload event (which I think is IE-specific, which works fine for me as the project uses lots of ActiveX) works great.
Problem is, I want the user to be able to click on a little "help" icon in the upper-right corner and pop up a help window at any time. This causes onbeforeunload to fire, even though the main window never goes anywhere and the page never unloads.
The JavaScript function that runs when the onbeforeunload event runs just puts text into event.returnValue. If I could ascertain, somehow, that the help icon is the one that was clicked then I could just not put text into event.returnValue in that situation. But how could I have the page figure that out? | javascript | events | null | null | null | null | open | Can I override onbeforeunload for a particular element?
===
I have a page which does quite a bit of work and I don't want the user to be able to navigate away from that page (close browser, hit back button, etc.) without getting a warning. I found that the onbeforeunload event (which I think is IE-specific, which works fine for me as the project uses lots of ActiveX) works great.
Problem is, I want the user to be able to click on a little "help" icon in the upper-right corner and pop up a help window at any time. This causes onbeforeunload to fire, even though the main window never goes anywhere and the page never unloads.
The JavaScript function that runs when the onbeforeunload event runs just puts text into event.returnValue. If I could ascertain, somehow, that the help icon is the one that was clicked then I could just not put text into event.returnValue in that situation. But how could I have the page figure that out? | 0 |
57,800 | 09/11/2008 22:23:17 | 1,219 | 08/13/2008 13:44:47 | 2,341 | 142 | What's the bare minimum permission set for Sql Server 2005 services? | Best practices recommend not installing Sql Server to run as SYSTEM. What is the bare minumum you need to give the user account you create for it? | security | sql-server-2005 | system-administration | null | null | null | open | What's the bare minimum permission set for Sql Server 2005 services?
===
Best practices recommend not installing Sql Server to run as SYSTEM. What is the bare minumum you need to give the user account you create for it? | 0 |
57,803 | 09/11/2008 22:26:58 | 5,556 | 09/10/2008 14:01:15 | 18 | 4 | How to convert decimal to hex in JavaScript? | How do you convert decimal values to their hex equivalent in JavaScript? | javascript | hex | null | null | null | null | open | How to convert decimal to hex in JavaScript?
===
How do you convert decimal values to their hex equivalent in JavaScript? | 0 |
57,804 | 09/11/2008 22:27:05 | 4,140 | 09/02/2008 01:10:54 | 584 | 41 | NHibernate.MappingException: No persister for: | Now, before you say it I DID google and my hbm.xml file IS an Embedded Resource.
Here is the code I am calling:
ISession session = GetCurrentSession();
var returnObject = session.Get<T>(Id);
Here is my mapping file for the class:
<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2">
<class name="HQData.Objects.SubCategory, HQData" table="SubCategory" lazy="true">
<id name="ID" column="ID" unsaved-value="0">
<generator class="identity" />
</id>
<property name="Name" column="Name" />
<property name="NumberOfBuckets" column="NumberOfBuckets" />
<property name="SearchCriteriaOne" column="SearchCriteriaOne" />
<bag name="_Businesses" cascade="all">
<key column="SubCategoryId"/>
<one-to-many
class="HQData.Objects.Business, HQData"/>
</bag>
<bag name="_Buckets" cascade="all">
<key column="SubCategoryId"/>
<one-to-many
class="HQData.Objects.Bucket, HQData"/>
</bag>
</class>
</hibernate-mapping>
Has anyone run to this issue before? | nhibernate | c# | .net | null | null | null | open | NHibernate.MappingException: No persister for:
===
Now, before you say it I DID google and my hbm.xml file IS an Embedded Resource.
Here is the code I am calling:
ISession session = GetCurrentSession();
var returnObject = session.Get<T>(Id);
Here is my mapping file for the class:
<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2">
<class name="HQData.Objects.SubCategory, HQData" table="SubCategory" lazy="true">
<id name="ID" column="ID" unsaved-value="0">
<generator class="identity" />
</id>
<property name="Name" column="Name" />
<property name="NumberOfBuckets" column="NumberOfBuckets" />
<property name="SearchCriteriaOne" column="SearchCriteriaOne" />
<bag name="_Businesses" cascade="all">
<key column="SubCategoryId"/>
<one-to-many
class="HQData.Objects.Business, HQData"/>
</bag>
<bag name="_Buckets" cascade="all">
<key column="SubCategoryId"/>
<one-to-many
class="HQData.Objects.Bucket, HQData"/>
</bag>
</class>
</hibernate-mapping>
Has anyone run to this issue before? | 0 |
57,812 | 09/11/2008 22:32:28 | 5,464 | 09/09/2008 20:26:13 | 1 | 0 | jQuery: Remove all classes that begin with a certain string | I have a div with id="a" that may have any number of classes attached to it, from several groups. Each group has a specific prefix. In the javascript, I don't know which class from the group is on the div. I want to be able to clear all classes with a given prefix and then add a new one. If I want to remove all of the classes that begin with "bg", how do I do that? Something like this, but that actually works:
$("#a").removeClass("bg*"); | javascript | css | jquery | null | null | null | open | jQuery: Remove all classes that begin with a certain string
===
I have a div with id="a" that may have any number of classes attached to it, from several groups. Each group has a specific prefix. In the javascript, I don't know which class from the group is on the div. I want to be able to clear all classes with a given prefix and then add a new one. If I want to remove all of the classes that begin with "bg", how do I do that? Something like this, but that actually works:
$("#a").removeClass("bg*"); | 0 |
57,839 | 09/11/2008 22:44:49 | 3,575 | 08/29/2008 06:54:39 | 31 | 3 | Crash Instantiating System.Xml.Serialization.XmlSerializer in C#. | We're seeing a crash when instantiating an instance of the System.Xml.Serialization.XmlSerializer class in a C# library. The crash occurs in the constructor, when it tries to add a duplicate key to a dictionary. I've included a stack trace below.
This crash is only occurring on one machine, and repairing our installation of .NET 3.5 didn't help. Has anyone else seen any similar issues?
System.ArgumentException was unhandled
Message="Item has already been added. Key in dictionary: 'mainbuild' Key being added: 'mainbuild'"
Source="mscorlib"
StackTrace:
at System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)
at System.Collections.Hashtable.Add(Object key, Object value)
at System.Collections.Specialized.StringDictionary.Add(String key, String value)
at System.CodeDom.Compiler.Executor.ExecWaitWithCaptureUnimpersonated(SafeUserTokenHandle userToken, String cmd, String currentDir, TempFileCollection tempFiles, String& outputName, String& errorName, String trueCmdLine)
at System.CodeDom.Compiler.Executor.ExecWaitWithCapture(SafeUserTokenHandle userToken, String cmd, String currentDir, TempFileCollection tempFiles, String& outputName, String& errorName, String trueCmdLine)
at Microsoft.CSharp.CSharpCodeGenerator.Compile(CompilerParameters options, String compilerDirectory, String compilerExe, String arguments, String& outputFile, Int32& nativeReturnValue, String trueArgs)
at Microsoft.CSharp.CSharpCodeGenerator.FromFileBatch(CompilerParameters options, String[] fileNames)
at Microsoft.CSharp.CSharpCodeGenerator.FromSourceBatch(CompilerParameters options, String[] sources)
at Microsoft.CSharp.CSharpCodeGenerator.System.CodeDom.Compiler.ICodeCompiler.CompileAssemblyFromSourceBatch(CompilerParameters options, String[] sources)
at System.CodeDom.Compiler.CodeDomProvider.CompileAssemblyFromSource(CompilerParameters options, String[] sources)
at System.Xml.Serialization.Compiler.Compile(Assembly parent, String ns, XmlSerializerCompilerParameters xmlParameters, Evidence evidence)
at System.Xml.Serialization.TempAssembly.GenerateAssembly(XmlMapping[] xmlMappings, Type[] types, String defaultNamespace, Evidence evidence, XmlSerializerCompilerParameters parameters, Assembly assembly, Hashtable assemblies)
at System.Xml.Serialization.TempAssembly..ctor(XmlMapping[] xmlMappings, Type[] types, String defaultNamespace, String location, Evidence evidence)
at System.Xml.Serialization.XmlSerializer.GenerateTempAssembly(XmlMapping xmlMapping, Type type, String defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type, String defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type)
at OurTools.Tools.Common.XML.DataAccess`1.DeserializeFromXml(String strFilePath) in c:\AutomatedBuild\projects\1.0\OurTools.Tools.Common\OurTools.Tools.Common\XML\DataAcess.cs:line 100
at OurTools.Tools.Common.ProjectFileManager.GetProjectInfoModel() in c:\AutomatedBuild\projects\1.0\OurTools.Tools.Common\OurTools.Tools.Common\ProjectFileManager.cs:line 252
at OurTools.Tools.Common.ProjectFileManager.GetAvailableCultures() in c:\AutomatedBuild\projects\1.0\OurTools.Tools.Common\OurTools.Tools.Common\ProjectFileManager.cs:line 299
at OurAppLib.GeneratorOptions.DefaultCultures() in c:\AutomatedBuild\projects\1.0\OurApp\OurAppLib\GeneratorOptions.cs:line 192
at OurAppLib.GeneratorOptions.ReadCulturesFromArgs(List`1 arglist, String& errormsg) in c:\AutomatedBuild\projects\1.0\OurApp\OurAppLib\GeneratorOptions.cs:line 358
at OurAppLib.GeneratorOptions.ReadFromArgs(String[] args, String& errormsg) in c:\AutomatedBuild\projects\1.0\OurApp\OurAppLib\GeneratorOptions.cs:line 261
at OurApp.Program.Main(String[] args) in c:\AutomatedBuild\projects\1.0\OurApp\OurApp\Program.cs:line 76`print("code sample");` | c# | .net | serialization | null | null | null | open | Crash Instantiating System.Xml.Serialization.XmlSerializer in C#.
===
We're seeing a crash when instantiating an instance of the System.Xml.Serialization.XmlSerializer class in a C# library. The crash occurs in the constructor, when it tries to add a duplicate key to a dictionary. I've included a stack trace below.
This crash is only occurring on one machine, and repairing our installation of .NET 3.5 didn't help. Has anyone else seen any similar issues?
System.ArgumentException was unhandled
Message="Item has already been added. Key in dictionary: 'mainbuild' Key being added: 'mainbuild'"
Source="mscorlib"
StackTrace:
at System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)
at System.Collections.Hashtable.Add(Object key, Object value)
at System.Collections.Specialized.StringDictionary.Add(String key, String value)
at System.CodeDom.Compiler.Executor.ExecWaitWithCaptureUnimpersonated(SafeUserTokenHandle userToken, String cmd, String currentDir, TempFileCollection tempFiles, String& outputName, String& errorName, String trueCmdLine)
at System.CodeDom.Compiler.Executor.ExecWaitWithCapture(SafeUserTokenHandle userToken, String cmd, String currentDir, TempFileCollection tempFiles, String& outputName, String& errorName, String trueCmdLine)
at Microsoft.CSharp.CSharpCodeGenerator.Compile(CompilerParameters options, String compilerDirectory, String compilerExe, String arguments, String& outputFile, Int32& nativeReturnValue, String trueArgs)
at Microsoft.CSharp.CSharpCodeGenerator.FromFileBatch(CompilerParameters options, String[] fileNames)
at Microsoft.CSharp.CSharpCodeGenerator.FromSourceBatch(CompilerParameters options, String[] sources)
at Microsoft.CSharp.CSharpCodeGenerator.System.CodeDom.Compiler.ICodeCompiler.CompileAssemblyFromSourceBatch(CompilerParameters options, String[] sources)
at System.CodeDom.Compiler.CodeDomProvider.CompileAssemblyFromSource(CompilerParameters options, String[] sources)
at System.Xml.Serialization.Compiler.Compile(Assembly parent, String ns, XmlSerializerCompilerParameters xmlParameters, Evidence evidence)
at System.Xml.Serialization.TempAssembly.GenerateAssembly(XmlMapping[] xmlMappings, Type[] types, String defaultNamespace, Evidence evidence, XmlSerializerCompilerParameters parameters, Assembly assembly, Hashtable assemblies)
at System.Xml.Serialization.TempAssembly..ctor(XmlMapping[] xmlMappings, Type[] types, String defaultNamespace, String location, Evidence evidence)
at System.Xml.Serialization.XmlSerializer.GenerateTempAssembly(XmlMapping xmlMapping, Type type, String defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type, String defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type)
at OurTools.Tools.Common.XML.DataAccess`1.DeserializeFromXml(String strFilePath) in c:\AutomatedBuild\projects\1.0\OurTools.Tools.Common\OurTools.Tools.Common\XML\DataAcess.cs:line 100
at OurTools.Tools.Common.ProjectFileManager.GetProjectInfoModel() in c:\AutomatedBuild\projects\1.0\OurTools.Tools.Common\OurTools.Tools.Common\ProjectFileManager.cs:line 252
at OurTools.Tools.Common.ProjectFileManager.GetAvailableCultures() in c:\AutomatedBuild\projects\1.0\OurTools.Tools.Common\OurTools.Tools.Common\ProjectFileManager.cs:line 299
at OurAppLib.GeneratorOptions.DefaultCultures() in c:\AutomatedBuild\projects\1.0\OurApp\OurAppLib\GeneratorOptions.cs:line 192
at OurAppLib.GeneratorOptions.ReadCulturesFromArgs(List`1 arglist, String& errormsg) in c:\AutomatedBuild\projects\1.0\OurApp\OurAppLib\GeneratorOptions.cs:line 358
at OurAppLib.GeneratorOptions.ReadFromArgs(String[] args, String& errormsg) in c:\AutomatedBuild\projects\1.0\OurApp\OurAppLib\GeneratorOptions.cs:line 261
at OurApp.Program.Main(String[] args) in c:\AutomatedBuild\projects\1.0\OurApp\OurApp\Program.cs:line 76`print("code sample");` | 0 |
57,840 | 09/11/2008 22:45:29 | 5,734 | 09/11/2008 06:31:57 | 1 | 0 | How to attach debugger to step into native (C++) code from a managed (C#) wrapper? | I have a wrapper around a C++ function call which I call from C# code. How do I attach a debugger in Visual Studio to step into the native C++ code?
This is the wrapper that I have which calls GetData() defined in a C++ file:
[DllImport("Unmanaged.dll", CallingConvention=CallingConvention.Cdecl,
EntryPoint = "GetData", BestFitMapping = false)]
public static extern String GetData(String url);
The code is crashing and I want to investigate the root cause.
Thanks,
Nikhil
| c# | c++ | visual-studio | debugging | null | null | open | How to attach debugger to step into native (C++) code from a managed (C#) wrapper?
===
I have a wrapper around a C++ function call which I call from C# code. How do I attach a debugger in Visual Studio to step into the native C++ code?
This is the wrapper that I have which calls GetData() defined in a C++ file:
[DllImport("Unmanaged.dll", CallingConvention=CallingConvention.Cdecl,
EntryPoint = "GetData", BestFitMapping = false)]
public static extern String GetData(String url);
The code is crashing and I want to investigate the root cause.
Thanks,
Nikhil
| 0 |
57,845 | 09/11/2008 22:49:34 | 1,647 | 08/17/2008 18:32:33 | 77 | 10 | BackgroundWorker thread in asp.net | Is it possible to use BackGroundWorker thread in asp.net 2.0 for the following scenario, so that the user at the browser's end does not have to wait for long time??
Scenario
---------
1. Browser requests a page, say SendEmails.aspx
2. SendEmails.aspx page creates a BackgroundWorker thread, and supplies the thread with enough context to create and send emails.
3. Browser receives the response from the ComposeAndSendEmails.aspx, saying that emails are being sent.
4. Meanwhile, the background thread is engaged in a process of creating and sending emails which could take some considerable time to complete.
Thanks
| asp.net | null | null | null | null | null | open | BackgroundWorker thread in asp.net
===
Is it possible to use BackGroundWorker thread in asp.net 2.0 for the following scenario, so that the user at the browser's end does not have to wait for long time??
Scenario
---------
1. Browser requests a page, say SendEmails.aspx
2. SendEmails.aspx page creates a BackgroundWorker thread, and supplies the thread with enough context to create and send emails.
3. Browser receives the response from the ComposeAndSendEmails.aspx, saying that emails are being sent.
4. Meanwhile, the background thread is engaged in a process of creating and sending emails which could take some considerable time to complete.
Thanks
| 0 |
57,859 | 09/11/2008 23:00:55 | 5,975 | 09/11/2008 20:20:29 | 1 | 2 | Is there a standard ReSharper code style definition that matches all the StyleCop requirements? | The ReSharper reformat code feature is very handy and flexible, particularly with the new code layout templating flexibility JetBrains have added in version 3.0.
Is there a standard set of code style settings for ReSharper which match the rules enforced by [Microsoft StyleCop][1], so that StyleCop compliance can be as easy as running the ReSharper "reformat code" feature?
[1]: http://code.msdn.microsoft.com/sourceanalysis | resharper | stylecop | null | null | null | null | open | Is there a standard ReSharper code style definition that matches all the StyleCop requirements?
===
The ReSharper reformat code feature is very handy and flexible, particularly with the new code layout templating flexibility JetBrains have added in version 3.0.
Is there a standard set of code style settings for ReSharper which match the rules enforced by [Microsoft StyleCop][1], so that StyleCop compliance can be as easy as running the ReSharper "reformat code" feature?
[1]: http://code.msdn.microsoft.com/sourceanalysis | 0 |
57,867 | 09/11/2008 23:04:01 | 4,906 | 09/06/2008 14:21:25 | 81 | 6 | Is there a Windows Registry "dictionary" that explains the whole (or most of) the Windows Registry? |
I'd like to be able to see what registry keys are used for. A book on the registry would be fine as well. Info on Windows Vista changes would be great! | windows | registry | null | null | null | null | open | Is there a Windows Registry "dictionary" that explains the whole (or most of) the Windows Registry?
===
I'd like to be able to see what registry keys are used for. A book on the registry would be fine as well. Info on Windows Vista changes would be great! | 0 |
57,878 | 09/11/2008 23:09:47 | 5,295 | 09/08/2008 22:12:56 | 20 | 1 | SQL/Oracle: when indexes on multiple columns can be used | If I create an index on columns (A, B, C), in that order, my understanding is that the database will be able to use it even if I search only on (A), or (A and B), or (A and B and C), but not if I search only on (B), or (C), or (B and C). Is this correct? | oracle | indexing | null | null | null | null | open | SQL/Oracle: when indexes on multiple columns can be used
===
If I create an index on columns (A, B, C), in that order, my understanding is that the database will be able to use it even if I search only on (A), or (A and B), or (A and B and C), but not if I search only on (B), or (C), or (B and C). Is this correct? | 0 |
57,882 | 09/11/2008 23:13:59 | 1,130 | 08/12/2008 16:39:54 | 66 | 4 | IDE for developping in ActionScript (Flash). Any suggestions ? | I started to work with Adobe Flash a few days ago and I'd say that the code editor lacks a few features before even being considered as an IDE (it sucks actually).
Do you know any other solution for developping in Flash ? For AS3 coding only, I don't care about designer and timeline... I just want to work efficiently with the code.
Thank you ! | ide | actionscript | null | null | null | null | open | IDE for developping in ActionScript (Flash). Any suggestions ?
===
I started to work with Adobe Flash a few days ago and I'd say that the code editor lacks a few features before even being considered as an IDE (it sucks actually).
Do you know any other solution for developping in Flash ? For AS3 coding only, I don't care about designer and timeline... I just want to work efficiently with the code.
Thank you ! | 0 |
57,902 | 09/11/2008 23:29:43 | 1,438 | 08/15/2008 15:44:20 | 594 | 33 | What is your experience with Sun CoolThreads technology? | My project has some money to spend before the end of the fiscal year and we are considering replacing a Sun-Fire-V490 server we've had for a few years. One option we are looking at is the [CoolThreads](http://www.sun.com/servers/coolthreads/overview/index.jsp) technology. All I know is the Sun marketing, which may not be 100% unbiased. Has anyone actually played with one of these?
I suspect it will be no value to us, since we don't use threads or virtual machines much and we can't spend a lot of time retrofitting code. We do spawn a ton of processes, but I doubt CoolThreads will be of help there.
(And yes, the money would be better spent on bonuses or something, but that's not going to happen.)
| solaris | coolthreads | sun | null | null | null | open | What is your experience with Sun CoolThreads technology?
===
My project has some money to spend before the end of the fiscal year and we are considering replacing a Sun-Fire-V490 server we've had for a few years. One option we are looking at is the [CoolThreads](http://www.sun.com/servers/coolthreads/overview/index.jsp) technology. All I know is the Sun marketing, which may not be 100% unbiased. Has anyone actually played with one of these?
I suspect it will be no value to us, since we don't use threads or virtual machines much and we can't spend a lot of time retrofitting code. We do spawn a ton of processes, but I doubt CoolThreads will be of help there.
(And yes, the money would be better spent on bonuses or something, but that's not going to happen.)
| 0 |
57,909 | 09/11/2008 23:33:59 | 5,703 | 09/11/2008 02:52:22 | 1 | 0 | When creating a new GUI, is WPF the prefered choice over Windows Forms? | Most restrictions and tricks with windows forms are common to most programmers. But since .NET 3.0 there is also WPF available, the Windows Presentation Foundation. It is said that you can make "sexy applications" more easy with it and with .NET 3.5 SP1 it got a good speed boost on execution.
But on the other side a lot of things are working different with WPF. I will not say it is more difficult but you have to learn "everything" from scratch.
My question: Is it worth to spend this extra time when you have to create a new GUI and there is no time pressure for the project? | .net | wpf | .net-3.5 | winforms | .net-3.0 | 10/02/2011 14:01:25 | not constructive | When creating a new GUI, is WPF the prefered choice over Windows Forms?
===
Most restrictions and tricks with windows forms are common to most programmers. But since .NET 3.0 there is also WPF available, the Windows Presentation Foundation. It is said that you can make "sexy applications" more easy with it and with .NET 3.5 SP1 it got a good speed boost on execution.
But on the other side a lot of things are working different with WPF. I will not say it is more difficult but you have to learn "everything" from scratch.
My question: Is it worth to spend this extra time when you have to create a new GUI and there is no time pressure for the project? | 4 |
57,912 | 09/11/2008 23:34:31 | 3,068 | 08/26/2008 14:28:42 | 68 | 8 | Update schema and rows in one transaction, SQL Server 2005 | I'm currently updating a legacy system which allows users to dictate part of the schema of one of its tables. Users can create and remove columns from the table through this interface. This legacy system is using ADO 2.8, and is using SQL Server 2005 as its database (you don't even WANT to know what database it was using before the attempt to modernize this beast began... but I digress. =) )
In this same editing process, users can define (and change) a list of valid values that can be stored in these user created fields (if the user wants to limit what can be in the field).
When the user changes the list of valid entries for a field, if they remove one of the valid values, they are allowed to choose a new "valid value" to map any rows that have this (now invalid) value in it, so that they now have a valid value again.
In looking through the old code, I noticed that it is extremely vulnerable to putting the system into an invalid state, because the changes mentioned above are not done within a transaction (so if someone else came along halfway through the process mentioned above and made their own changes... well, you can imagine the problems that might cause).
The problem is, I've been trying to get them to update under a single transaction, but whenever the code gets to the part where it changes the schema of that table, all of the other changes (updating values in rows, be it in the table where the schema changed or not... they can be completely unrelated tables even) made up to that point in the transaction appear to be silently dropped. I receive no error message indicating that they were dropped, and when I commit the transaction at the end no error is raised... but when I go to look in the tables that were supposed to be updated in the transaction, only the new columns are there. None of the non-schema changes made are saved.
Looking on the net for answers has, thus far, proved to be a waste of a couple hours... so I turn here for help. Has anyone ever tried to perform a transaction through ADO that both updates the schema of a table and updates rows in tables (be it that same table, or others)? Is it not allowed? Is there any documentation out there that could be helpful in this situation? | database | transactions | ado | null | null | null | open | Update schema and rows in one transaction, SQL Server 2005
===
I'm currently updating a legacy system which allows users to dictate part of the schema of one of its tables. Users can create and remove columns from the table through this interface. This legacy system is using ADO 2.8, and is using SQL Server 2005 as its database (you don't even WANT to know what database it was using before the attempt to modernize this beast began... but I digress. =) )
In this same editing process, users can define (and change) a list of valid values that can be stored in these user created fields (if the user wants to limit what can be in the field).
When the user changes the list of valid entries for a field, if they remove one of the valid values, they are allowed to choose a new "valid value" to map any rows that have this (now invalid) value in it, so that they now have a valid value again.
In looking through the old code, I noticed that it is extremely vulnerable to putting the system into an invalid state, because the changes mentioned above are not done within a transaction (so if someone else came along halfway through the process mentioned above and made their own changes... well, you can imagine the problems that might cause).
The problem is, I've been trying to get them to update under a single transaction, but whenever the code gets to the part where it changes the schema of that table, all of the other changes (updating values in rows, be it in the table where the schema changed or not... they can be completely unrelated tables even) made up to that point in the transaction appear to be silently dropped. I receive no error message indicating that they were dropped, and when I commit the transaction at the end no error is raised... but when I go to look in the tables that were supposed to be updated in the transaction, only the new columns are there. None of the non-schema changes made are saved.
Looking on the net for answers has, thus far, proved to be a waste of a couple hours... so I turn here for help. Has anyone ever tried to perform a transaction through ADO that both updates the schema of a table and updates rows in tables (be it that same table, or others)? Is it not allowed? Is there any documentation out there that could be helpful in this situation? | 0 |
57,915 | 09/11/2008 23:35:21 | 6,013 | 09/11/2008 23:30:44 | 1 | 0 | What are some good examples of a WS-Eventing client in Java? | There are a few web service frameworks available for Java: Axis2, CXF, JBossWS, and Metro. Does anyone have some good examples of a WS-Eventing client with these frameworks? | java | web-services | eventing | null | null | null | open | What are some good examples of a WS-Eventing client in Java?
===
There are a few web service frameworks available for Java: Axis2, CXF, JBossWS, and Metro. Does anyone have some good examples of a WS-Eventing client with these frameworks? | 0 |
57,918 | 09/11/2008 23:37:56 | 781 | 08/08/2008 21:28:19 | 358 | 15 | When should you use full-text indexing? | We have a whole bunch fo queries that "search" for clients, customers, etc. You can search by firstname, email, etc. We're using LIKE statements in the following manner:
<pre>
select * from customer where fname like '%someName%'
</pre>
Does full-text indexing help in the scenario? | full-text-search | indexing | null | null | null | null | open | When should you use full-text indexing?
===
We have a whole bunch fo queries that "search" for clients, customers, etc. You can search by firstname, email, etc. We're using LIKE statements in the following manner:
<pre>
select * from customer where fname like '%someName%'
</pre>
Does full-text indexing help in the scenario? | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.