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
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
62,251 | 09/15/2008 11:57:44 | 6,522 | 09/15/2008 11:57:44 | 1 | 0 | Where can i Find GOOD ASP.NET tutorial(or books) online? | Looking for some good resources (or tutorials) that will demonstrate the proper techniques on building ASP.NET web sites.
| asp.net | null | null | null | null | null | open | Where can i Find GOOD ASP.NET tutorial(or books) online?
===
Looking for some good resources (or tutorials) that will demonstrate the proper techniques on building ASP.NET web sites.
| 0 |
62,264 | 09/15/2008 12:04:31 | 4,161 | 09/02/2008 07:55:46 | 408 | 13 | Dealing with SVN keyword expansion with git-svn | I recently asked about [keyword expansion in Git](http://stackoverflow.com/questions/39742/does-git-have-anything-like-svn-propset-svnkeywords-or-pre-post-commit-hooks) and I'm willing to accept the design design not to really support this idea in Git.
For better or worse, the project I'm working on at the moment requires SVN keyword expansion like this
svn propset svn:keywords "Id" expl3.dtx
to keep this string up-to-date:
$Id: expl3.dtx 803 2008-09-11 14:01:58Z will $
But I would quite like to use GIt to do my version control. Unfortunately, git-svn doesn't support this, according to the docs:
> "We ignore all SVN properties except svn:executable"
But it doesn't seem to tricky have this keyword stuff emulated by a couple of pre/post commit hooks. But am I the first person to want this? Does anyone have some code to do this? | svn | version-control | git | null | null | null | open | Dealing with SVN keyword expansion with git-svn
===
I recently asked about [keyword expansion in Git](http://stackoverflow.com/questions/39742/does-git-have-anything-like-svn-propset-svnkeywords-or-pre-post-commit-hooks) and I'm willing to accept the design design not to really support this idea in Git.
For better or worse, the project I'm working on at the moment requires SVN keyword expansion like this
svn propset svn:keywords "Id" expl3.dtx
to keep this string up-to-date:
$Id: expl3.dtx 803 2008-09-11 14:01:58Z will $
But I would quite like to use GIt to do my version control. Unfortunately, git-svn doesn't support this, according to the docs:
> "We ignore all SVN properties except svn:executable"
But it doesn't seem to tricky have this keyword stuff emulated by a couple of pre/post commit hooks. But am I the first person to want this? Does anyone have some code to do this? | 0 |
62,268 | 09/15/2008 12:07:18 | 4,050 | 09/01/2008 14:24:01 | 354 | 33 | Error consuming Web Service from Winform App - "Cannot execute a program..." | I have a winform app that calls a web service to check for updates. This works in dev and it also works everywhere else I've tried it, just not on the installed copy on my machine (which happens to be the same in dev).
The error is:
Cannot execute a program. The command being executed was "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\csc.exe" /noconfig /fullpaths @"C:\Documents and Settings\Giovanni.DOUBLE-AFSSZ043\Local Settings\Temp\squ8oock.cmdline".
The firewall is disabled and I've looked for "C:\Documents and Settings\Giovanni.DOUBLE-AFSSZ043\Local Settings\Temp\squ8oock.cmdline" and it is not there. Note that every time I try to use the web service the ".cmdline" file is different, for example the second time I ran it it was "dae8rgen.cmdline." No matter what name it has, I can never find the file.
Any suggestions?
| .net | winforms | webservice | null | null | null | open | Error consuming Web Service from Winform App - "Cannot execute a program..."
===
I have a winform app that calls a web service to check for updates. This works in dev and it also works everywhere else I've tried it, just not on the installed copy on my machine (which happens to be the same in dev).
The error is:
Cannot execute a program. The command being executed was "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\csc.exe" /noconfig /fullpaths @"C:\Documents and Settings\Giovanni.DOUBLE-AFSSZ043\Local Settings\Temp\squ8oock.cmdline".
The firewall is disabled and I've looked for "C:\Documents and Settings\Giovanni.DOUBLE-AFSSZ043\Local Settings\Temp\squ8oock.cmdline" and it is not there. Note that every time I try to use the web service the ".cmdline" file is different, for example the second time I ran it it was "dae8rgen.cmdline." No matter what name it has, I can never find the file.
Any suggestions?
| 0 |
62,276 | 09/15/2008 12:11:08 | 6,309 | 09/13/2008 22:22:33 | 13 | 3 | java package cycle detection: how to find the specific classes involved ? | What tool would you recommend to detect **java package cyclic dependencies**,
knowing that the goal is to _list explicitly the specific classes involved in the detected 'across-packages cycle'_ ?
I know about [classycle][1] and [JDepend][2] , but they both fail to list the classes involved in a cyclic package dependency.
[Metrics][3] has an interesting graphical representation of cycles, but again limited to packages, and quite difficult to read sometime.
I am getting tired to get a:
> _" you have a package cycle dependency between those 3 packages_
> _you have xxx classes in each_
> _good luck to find the right classes and break this cycle "_
Do you know any tool that takes the extra step to actually explain to you why the cycle is detected (i.e. 'list the involved classes') ?
[1]: http://classycle.sourceforge.net/
[2]: http://clarkware.com/software/JDepend.html
[3]: http://metrics.sourceforge.net/ | java | software-tools | classes | dependencies | packages | null | open | java package cycle detection: how to find the specific classes involved ?
===
What tool would you recommend to detect **java package cyclic dependencies**,
knowing that the goal is to _list explicitly the specific classes involved in the detected 'across-packages cycle'_ ?
I know about [classycle][1] and [JDepend][2] , but they both fail to list the classes involved in a cyclic package dependency.
[Metrics][3] has an interesting graphical representation of cycles, but again limited to packages, and quite difficult to read sometime.
I am getting tired to get a:
> _" you have a package cycle dependency between those 3 packages_
> _you have xxx classes in each_
> _good luck to find the right classes and break this cycle "_
Do you know any tool that takes the extra step to actually explain to you why the cycle is detected (i.e. 'list the involved classes') ?
[1]: http://classycle.sourceforge.net/
[2]: http://clarkware.com/software/JDepend.html
[3]: http://metrics.sourceforge.net/ | 0 |
62,292 | 09/15/2008 12:18:42 | 1,944 | 08/19/2008 14:49:14 | 604 | 22 | Are liquid layouts still relevant? | Now that most of the major browsers support full page zoom (at present, the only notable exception being Google Chrome), are liquid or elastic layouts no longer needed? Is the relative pain of building liquid/elastic layouts worth the effort? Are there any situations where a liquid layout would still be of benefit? Is full page zoom the real solution it at first appears to be? | html | css | webdesign | layout | null | null | open | Are liquid layouts still relevant?
===
Now that most of the major browsers support full page zoom (at present, the only notable exception being Google Chrome), are liquid or elastic layouts no longer needed? Is the relative pain of building liquid/elastic layouts worth the effort? Are there any situations where a liquid layout would still be of benefit? Is full page zoom the real solution it at first appears to be? | 0 |
62,294 | 09/15/2008 12:19:21 | 6,555 | 09/15/2008 12:15:36 | 1 | 0 | How to modify the defaul Check-in Action in TFS? | The default check-in action for a work-item is "resolve". I'd like to set it to "associate" so that this work item isn't automaticaly closed if I check-in stuff too fast. How can I do that?
Thanks. | version-control | tfs | work-item | null | null | null | open | How to modify the defaul Check-in Action in TFS?
===
The default check-in action for a work-item is "resolve". I'd like to set it to "associate" so that this work item isn't automaticaly closed if I check-in stuff too fast. How can I do that?
Thanks. | 0 |
62,302 | 09/15/2008 12:20:42 | 6,600 | 09/15/2008 12:20:42 | 1 | 0 | What’s a good book for learning F#? | I am looking at taking F# for a test drive. What is a really good book to get started for a C# developer? | f# | null | null | null | null | 10/02/2011 16:20:34 | not constructive | What’s a good book for learning F#?
===
I am looking at taking F# for a test drive. What is a really good book to get started for a C# developer? | 4 |
62,322 | 09/15/2008 12:26:00 | 1,068 | 08/12/2008 08:44:09 | 140 | 6 | Asynchronous APIs | When trying to implement a asynchronous API calls / Non-blocking calls, i know a little in a All Plain-C applicaiton I have, i read a about APM(Asynchronous Programming Model) by 'Delegates'. Basically what i want to do is call one API f1() to do a functionality(which takes long time 8-10 seconds), So i call that API f1(), forget about it, and continue doing some other work, e.g. I/O for to fetch data for next call of the f1() or some functionality not dependant on result of f1().
If any one has used that APM model of programming, I am looking at some concise explanation for implementing non-blocking calls.
Is there any other way of implementing asynchronous APIs , any other library/framework which might help in this?
-AD | c | asynchronous | api | null | null | null | open | Asynchronous APIs
===
When trying to implement a asynchronous API calls / Non-blocking calls, i know a little in a All Plain-C applicaiton I have, i read a about APM(Asynchronous Programming Model) by 'Delegates'. Basically what i want to do is call one API f1() to do a functionality(which takes long time 8-10 seconds), So i call that API f1(), forget about it, and continue doing some other work, e.g. I/O for to fetch data for next call of the f1() or some functionality not dependant on result of f1().
If any one has used that APM model of programming, I am looking at some concise explanation for implementing non-blocking calls.
Is there any other way of implementing asynchronous APIs , any other library/framework which might help in this?
-AD | 0 |
62,328 | 09/15/2008 12:26:42 | 3,968 | 09/01/2008 04:28:06 | 1 | 0 | Is there an algorithm that tells the semantic similarity of two phrases | input: phrase 1, phrase 2
output: semantic similarity value (between 0 and 1), or the probability this two phrases are talking about the same thing | algorithm | semantic | nlp | null | null | null | open | Is there an algorithm that tells the semantic similarity of two phrases
===
input: phrase 1, phrase 2
output: semantic similarity value (between 0 and 1), or the probability this two phrases are talking about the same thing | 0 |
62,340 | 09/15/2008 12:28:49 | 6,605 | 09/15/2008 12:21:15 | 1 | 0 | Is a pop_back() in a std::vector really invalidates *all* iterators on the vector? | std::vector<int> ints;
// ... fill ints with random values
for(std::vector<int>::iterator it = ints.begin(); it != ints.end(); )
{
if(*it < 10)
{
*it = ints.back();
ints.pop_back();
continue;
}
it++;
}
This code is not working because when pop_back() is called, the **it** is invalidate. But I don't find any doc talking about invalidation of iterators in std::vector:pop_back().
Do you have some links about that?
| c++ | stl | null | null | null | null | open | Is a pop_back() in a std::vector really invalidates *all* iterators on the vector?
===
std::vector<int> ints;
// ... fill ints with random values
for(std::vector<int>::iterator it = ints.begin(); it != ints.end(); )
{
if(*it < 10)
{
*it = ints.back();
ints.pop_back();
continue;
}
it++;
}
This code is not working because when pop_back() is called, the **it** is invalidate. But I don't find any doc talking about invalidation of iterators in std::vector:pop_back().
Do you have some links about that?
| 0 |
62,353 | 09/15/2008 12:31:11 | 2,361 | 08/21/2008 20:41:09 | 577 | 29 | What are the best practices for using Assembly Attributes? | I have a solution with multiple project. I am trying to optimize AssemblyInfo.cs files by linking one solution wide assembly info file. What are the best practices for doing this? Which attributes should be in solution wide file and which are project/assembly specific? | .net | null | null | null | null | null | open | What are the best practices for using Assembly Attributes?
===
I have a solution with multiple project. I am trying to optimize AssemblyInfo.cs files by linking one solution wide assembly info file. What are the best practices for doing this? Which attributes should be in solution wide file and which are project/assembly specific? | 0 |
62,365 | 09/15/2008 12:32:39 | 60 | 08/01/2008 14:04:09 | 1,854 | 73 | Using reflection to call an ASP.NET web service | Say I have an ASMX web service, MyService. The service has a method, MyMethod. I could execute MyMethod on the server side as follows:
MyService service = new MyService();
service.MyMethod();
I need to do similar, with service and method not known until runtime.
I'm assuming that reflection is the way to go about that. Unfortunately, I'm having a hard time making it work. When I execute this code:
Type.GetType("MyService", true);
It throws this error:
> Could not load type 'MyService' from assembly 'App_Web__ktsp_r0, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'.
Any guidance would be appreciated.
| c# | asp.net | web-services | reflection | null | null | open | Using reflection to call an ASP.NET web service
===
Say I have an ASMX web service, MyService. The service has a method, MyMethod. I could execute MyMethod on the server side as follows:
MyService service = new MyService();
service.MyMethod();
I need to do similar, with service and method not known until runtime.
I'm assuming that reflection is the way to go about that. Unfortunately, I'm having a hard time making it work. When I execute this code:
Type.GetType("MyService", true);
It throws this error:
> Could not load type 'MyService' from assembly 'App_Web__ktsp_r0, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'.
Any guidance would be appreciated.
| 0 |
62,382 | 09/15/2008 12:35:33 | 6,483 | 09/15/2008 10:58:34 | 1 | 1 | Can you animate a custom dependency property in Silverlight? | I might be missing something really obvious. I'm trying to write a custom Panel where the contents are laid out according to a couple of dependency properties (I'm assuming they *have* to be DPs because I want to be able to animate them.)
However, when I try to run a storyboard to animate both of these properties, Silverlight throws a Catastophic Error. But if I try to animate just one of them, it works fine. And if I try to animate one of my properties and a 'built-in' property (like Opacity) it also works. But if I try to animate both my custom properties I get the Catastrophic error.
Anyone else come across this? | silverlight | null | null | null | null | null | open | Can you animate a custom dependency property in Silverlight?
===
I might be missing something really obvious. I'm trying to write a custom Panel where the contents are laid out according to a couple of dependency properties (I'm assuming they *have* to be DPs because I want to be able to animate them.)
However, when I try to run a storyboard to animate both of these properties, Silverlight throws a Catastophic Error. But if I try to animate just one of them, it works fine. And if I try to animate one of my properties and a 'built-in' property (like Opacity) it also works. But if I try to animate both my custom properties I get the Catastrophic error.
Anyone else come across this? | 0 |
62,384 | 09/15/2008 12:35:40 | 6,595 | 09/15/2008 12:19:42 | 1 | 0 | How to convert Apache .htaccess files into Lighttpd rules? | It's big problem to convert mod_rewrite rules to lighttpd format | apache | .htaccess | lighttpd | null | null | null | open | How to convert Apache .htaccess files into Lighttpd rules?
===
It's big problem to convert mod_rewrite rules to lighttpd format | 0 |
62,389 | 09/15/2008 12:36:05 | 6,619 | 09/15/2008 12:22:26 | 1 | 0 | visual C++ 6.0 VS visual C++ 2008 | what are the advantages/disadvantages of between msvs c++ 6.0 vs msvs c++ 2008? the main reason for asking such question is that still there are many decent programmers that prefer using the older version insteed of the the newest version. | c++ | null | null | null | null | null | open | visual C++ 6.0 VS visual C++ 2008
===
what are the advantages/disadvantages of between msvs c++ 6.0 vs msvs c++ 2008? the main reason for asking such question is that still there are many decent programmers that prefer using the older version insteed of the the newest version. | 0 |
62,398 | 09/15/2008 12:37:03 | 6,775 | 09/15/2008 12:37:02 | 1 | 0 | Middleware API Best Practices, What are they? | We are developing a middleware SDK, both in C++ and Java to be used as a library/DLL by, for example, game developers, animation software developers, Avatar developers to enhance their products.
What I would like to know is this: Are there standard "Best Practices" for the development of these types of API?
I am thinking in terms of useability, readability, efficiency etc. | java | c++ | api | middleware | null | null | open | Middleware API Best Practices, What are they?
===
We are developing a middleware SDK, both in C++ and Java to be used as a library/DLL by, for example, game developers, animation software developers, Avatar developers to enhance their products.
What I would like to know is this: Are there standard "Best Practices" for the development of these types of API?
I am thinking in terms of useability, readability, efficiency etc. | 0 |
62,403 | 09/15/2008 12:37:48 | 572 | 08/06/2008 20:56:54 | 3,864 | 277 | What technical considerations must a system/network administrator worry about when a site gets onto social bookmarking/sharing sites? | The reason I ask is that Stack Overflow has been [Dugg][1], [Slashdotted][2], and [Redditted][3].
First, what kinds of effect does this have on the servers that power a website? Second, what can be done by system administrators to ensure that their sites remain up and running as best as possible?
[1]: http://digg.com/programming/Stack_Overflow
[2]: http://slashdot.org/firehose.pl?op=view&id=1170403
[3]: http://www.reddit.com/r/programming/comments/71i4v/stack_overflow_launched_into_public/ | system-administration | null | null | null | null | null | open | What technical considerations must a system/network administrator worry about when a site gets onto social bookmarking/sharing sites?
===
The reason I ask is that Stack Overflow has been [Dugg][1], [Slashdotted][2], and [Redditted][3].
First, what kinds of effect does this have on the servers that power a website? Second, what can be done by system administrators to ensure that their sites remain up and running as best as possible?
[1]: http://digg.com/programming/Stack_Overflow
[2]: http://slashdot.org/firehose.pl?op=view&id=1170403
[3]: http://www.reddit.com/r/programming/comments/71i4v/stack_overflow_launched_into_public/ | 0 |
62,406 | 09/15/2008 12:39:06 | 419,788 | 09/15/2008 12:25:53 | 1 | 0 | Alternative Style(CSS) methods in SAP Portal? | I am overriding a lot of SAP's Portal functionality in my current project. I have to create a custom fixed width framework, custom iView trays, custom KM API functionality, and more.
With all of these custom parts, I will not be using a lot of the style functionality implemented by SAP's Theme editor. What I would like to do is create an external CSS, store it outside of the Portal and reference it. Storing externally will allow for easier updates rather than storing the CSS within a portal application. It would also allow for all custom pieces to have their styles in once place.
Unfortunately, I've not found a way to gain access to the HEAD portion of the page that allows me to insert an external stylesheet. Portal Applications can do so using the IResource object to gain access to internal references, but not items on another server.
I'm looking for any ideas that would allow me to gain this functionality. I will x-post on SAP's SDN, but I suspect I'll get a better answer here. | sap | null | null | null | null | null | open | Alternative Style(CSS) methods in SAP Portal?
===
I am overriding a lot of SAP's Portal functionality in my current project. I have to create a custom fixed width framework, custom iView trays, custom KM API functionality, and more.
With all of these custom parts, I will not be using a lot of the style functionality implemented by SAP's Theme editor. What I would like to do is create an external CSS, store it outside of the Portal and reference it. Storing externally will allow for easier updates rather than storing the CSS within a portal application. It would also allow for all custom pieces to have their styles in once place.
Unfortunately, I've not found a way to gain access to the HEAD portion of the page that allows me to insert an external stylesheet. Portal Applications can do so using the IResource object to gain access to internal references, but not items on another server.
I'm looking for any ideas that would allow me to gain this functionality. I will x-post on SAP's SDN, but I suspect I'll get a better answer here. | 0 |
62,418 | 09/15/2008 12:41:13 | 6,094 | 09/12/2008 11:40:35 | 56 | 4 | Knowing which java.exe process to kill on a windows machine | When a java based application starts to misbehave on a windows machine, you want to be able to kill the process in the task manager if you can't quit the application normally. Most of the time, there's more than one java based application running on my machine. Is there a better way than just randomly killing java.exe processes in hope that you'll hit the correct application eventually? | java | windows | null | null | null | null | open | Knowing which java.exe process to kill on a windows machine
===
When a java based application starts to misbehave on a windows machine, you want to be able to kill the process in the task manager if you can't quit the application normally. Most of the time, there's more than one java based application running on my machine. Is there a better way than just randomly killing java.exe processes in hope that you'll hit the correct application eventually? | 0 |
62,430 | 09/15/2008 12:42:53 | 4,984 | 09/07/2008 08:11:30 | 26 | 1 | Regular expression that rejects all input? | Is is possible to construct a regular expression that rejects all input strings? | regex | null | null | null | null | null | open | Regular expression that rejects all input?
===
Is is possible to construct a regular expression that rejects all input strings? | 0 |
62,433 | 09/15/2008 12:43:08 | 6,788 | 09/15/2008 12:37:49 | 1 | 0 | Facebook java integration | I have looked in vain for a good example or starting point to write a java based facebook application... I was hoping that someone here would know of one. As well, I hear that facebook will no longer support their java API is this true and if yes does that mean that we should no longer use java to write facebook apps?? | java | api | facebook | support | example | null | open | Facebook java integration
===
I have looked in vain for a good example or starting point to write a java based facebook application... I was hoping that someone here would know of one. As well, I hear that facebook will no longer support their java API is this true and if yes does that mean that we should no longer use java to write facebook apps?? | 0 |
62,436 | 09/15/2008 12:43:28 | 6,783 | 09/15/2008 12:37:24 | 1 | 0 | DevExpress eXpressApp Framework (XAF) and eXpress Persistent Objects (XPO): how do I speed up the loading time of associations? | I am having a problem with the speed of accessing an association property with a large number of records.
I have an XAF app with a parent class called MyParent.
There are 230 records in MyParent.
MyParent has a child class called MyChild.
There are 49,000 records in MyChild.
I have an association defined between MyParent and MyChild in the standard way:
In MyChild:
// MyChild (many) and MyParent (one)
[Association("MyChild-MyParent")]
public MyParent MyParent;
And in MyParent:
[Association("MyChild-MyParent", typeof(MyChild))]
public XPCollection<MyCHild> MyCHildren
{
get { return GetCollection<MyCHild>("MyCHildren"); }
}
There's a specific MyParent record called MyParent1.
For MyParent1, there are 630 MyChild records.
I have a DetailView for a class called MyUI.
The user chooses an item in one drop-down in the MyUI DetailView, and my code has to fill another drop-down with
MyChild objects.
The user chooses MyParent1 in the first drop-down.
I created a property in MyUI to return the collection of MyChild objects for the selected value in the first drop-
down.
Here is the code for the property:
[NonPersistent]
public XPCollection<MyChild> DisplayedValues
{
get
{
Session theSession;
MyParent theParentValue;
XPCollection<MyCHild> theChildren;
theParentValue = this.DropDownOne;
// get the parent value
if theValue == null)
{
// if none
return null;
// return null
}
theChildren = theParentValue.MyChildren;
// get the child values for the parent
return theChildren;
// return it
}
I marked the DisplayedValues property as NonPersistent because it is only needed for the UI of the DetailVIew. I
don't think that persisting it will speed up the creation of the collection the first time, and after it's used to
fill the drop-down, I don't need it, so I don't want to spend time storing it.
The problem is that it takes 45 seconds to call theParentValue = this.DropDownOne.
Specs:
Vista Business
8 gigs of RAM
2.33 GHz E6550 processor
SQL Server Express 2005
This is too long for users to wait for one of many drop-downs in the DetailView.
I took the time to sketch out the business case because I have two questions:
1) How can I make the associated values load faster?
2) Is there another (simple) way to program the drop-downs and DetailView that runs much faster?
Yes, you can say that 630 is too many items to display in a drop-down, but this code is taking so long I suspect
that the speed is proportional to the 49,000 and not to the 630. 100 items in the drop-down would not be too many
for my app.
I need quite a few of these drop-downs in my app, so it's not appropriate to force the user to enter more
complicated filtering criteria for each one. The user needs to pick one value and see the related values.
I would understand if finding a large number of records was slow, but finding a few hundred shouldn't take that long.
Thanks very much in advance,
Adam Leffert | devexpress | xpo | xaf | null | null | null | open | DevExpress eXpressApp Framework (XAF) and eXpress Persistent Objects (XPO): how do I speed up the loading time of associations?
===
I am having a problem with the speed of accessing an association property with a large number of records.
I have an XAF app with a parent class called MyParent.
There are 230 records in MyParent.
MyParent has a child class called MyChild.
There are 49,000 records in MyChild.
I have an association defined between MyParent and MyChild in the standard way:
In MyChild:
// MyChild (many) and MyParent (one)
[Association("MyChild-MyParent")]
public MyParent MyParent;
And in MyParent:
[Association("MyChild-MyParent", typeof(MyChild))]
public XPCollection<MyCHild> MyCHildren
{
get { return GetCollection<MyCHild>("MyCHildren"); }
}
There's a specific MyParent record called MyParent1.
For MyParent1, there are 630 MyChild records.
I have a DetailView for a class called MyUI.
The user chooses an item in one drop-down in the MyUI DetailView, and my code has to fill another drop-down with
MyChild objects.
The user chooses MyParent1 in the first drop-down.
I created a property in MyUI to return the collection of MyChild objects for the selected value in the first drop-
down.
Here is the code for the property:
[NonPersistent]
public XPCollection<MyChild> DisplayedValues
{
get
{
Session theSession;
MyParent theParentValue;
XPCollection<MyCHild> theChildren;
theParentValue = this.DropDownOne;
// get the parent value
if theValue == null)
{
// if none
return null;
// return null
}
theChildren = theParentValue.MyChildren;
// get the child values for the parent
return theChildren;
// return it
}
I marked the DisplayedValues property as NonPersistent because it is only needed for the UI of the DetailVIew. I
don't think that persisting it will speed up the creation of the collection the first time, and after it's used to
fill the drop-down, I don't need it, so I don't want to spend time storing it.
The problem is that it takes 45 seconds to call theParentValue = this.DropDownOne.
Specs:
Vista Business
8 gigs of RAM
2.33 GHz E6550 processor
SQL Server Express 2005
This is too long for users to wait for one of many drop-downs in the DetailView.
I took the time to sketch out the business case because I have two questions:
1) How can I make the associated values load faster?
2) Is there another (simple) way to program the drop-downs and DetailView that runs much faster?
Yes, you can say that 630 is too many items to display in a drop-down, but this code is taking so long I suspect
that the speed is proportional to the 49,000 and not to the 630. 100 items in the drop-down would not be too many
for my app.
I need quite a few of these drop-downs in my app, so it's not appropriate to force the user to enter more
complicated filtering criteria for each one. The user needs to pick one value and see the related values.
I would understand if finding a large number of records was slow, but finding a few hundred shouldn't take that long.
Thanks very much in advance,
Adam Leffert | 0 |
62,437 | 09/15/2008 12:43:39 | 1,199,623 | 09/15/2008 12:20:30 | 1 | 0 | How do I prevent Flash's URLRequest from escaping the url? | I load some XML from a servlet from my Flex application like this:
_loader = new URLLoader();
_loader.load(new URLRequest(_servletURL+"?do=load&id="+_id));
As you can imagine _servletURL is something like http://foo.bar/path/to/servlet
In some cases, this URL contains accented characters (long story). I pass the unescaped string to URLRequest, but it seems that flash escapes it and calls the escaped URL, which is invalid. Ideas? | flex | flash | urlrequest | null | null | null | open | How do I prevent Flash's URLRequest from escaping the url?
===
I load some XML from a servlet from my Flex application like this:
_loader = new URLLoader();
_loader.load(new URLRequest(_servletURL+"?do=load&id="+_id));
As you can imagine _servletURL is something like http://foo.bar/path/to/servlet
In some cases, this URL contains accented characters (long story). I pass the unescaped string to URLRequest, but it seems that flash escapes it and calls the escaped URL, which is invalid. Ideas? | 0 |
62,449 | 09/15/2008 12:44:48 | 1,271 | 08/14/2008 09:09:52 | 42 | 1 | How to spread tcplistener incoming connections over threads in .NET? | When using the Net.Sockets.TcpListener, what is the best way to handle incoming connections (.AcceptSocket) in seperate threads?
The idea is to start a new thread when a new incoming connection is accepted, while the tcplistener then stays available for further incoming connections (and for every new incoming connection a new thread is created).
Example C# of VB.NET code is appreciated. Thanks in advance. | tcplistener | multithreading | .net | null | null | null | open | How to spread tcplistener incoming connections over threads in .NET?
===
When using the Net.Sockets.TcpListener, what is the best way to handle incoming connections (.AcceptSocket) in seperate threads?
The idea is to start a new thread when a new incoming connection is accepted, while the tcplistener then stays available for further incoming connections (and for every new incoming connection a new thread is created).
Example C# of VB.NET code is appreciated. Thanks in advance. | 0 |
62,472 | 09/15/2008 12:46:59 | 6,678 | 09/15/2008 12:28:52 | 1 | 1 | Any PHP editors supporting 5.3 syntax? | I'm using namespaces in a project and Eclipse PDT, my IDE of choice, recognizes them as syntax errors. Not only it renders its convenient error checking unusable, but it also ruins Eclipse's PHP explorer.
5.3 features are coming to PDT 2.0 scheduled for release in December. Are there any alternatives for the present moment? I'm looking for 5.3 syntax highlighting and error checking at the least. | php | null | null | null | null | null | open | Any PHP editors supporting 5.3 syntax?
===
I'm using namespaces in a project and Eclipse PDT, my IDE of choice, recognizes them as syntax errors. Not only it renders its convenient error checking unusable, but it also ruins Eclipse's PHP explorer.
5.3 features are coming to PDT 2.0 scheduled for release in December. Are there any alternatives for the present moment? I'm looking for 5.3 syntax highlighting and error checking at the least. | 0 |
62,490 | 09/15/2008 12:48:18 | 5,035 | 09/07/2008 13:39:10 | 116 | 7 | How can I get Axis 1.4 to not generate several prefixes for the same XML namespace? | I am receiving SOAP requests from a client that uses the Axis 1.4 libraries. The requests have the following form:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<PlaceOrderRequest xmlns="http://example.com/schema/order/request">
<order>
<ns1:requestParameter xmlns:ns1="http://example.com/schema/common/request">
<ns1:orderingSystemWithDomain>
<ns1:orderingSystem>Internet</ns1:orderingSystem>
<ns1:domainSign>2</ns1:domainSign>
</ns1:orderingSystemWithDomain>
</ns1:requestParameter>
<ns2:directDeliveryAddress ns2:addressType="0" ns2:index="1"
xmlns:ns2="http://example.com/schema/order/request">
<ns3:address xmlns:ns3="http://example.com/schema/common/request">
<ns4:zipcode xmlns:ns4="http://example.com/schema/common">12345</ns4:zipcode>
<ns5:city xmlns:ns5="http://example.com/schema/common">City</ns5:city>
<ns6:street xmlns:ns6="http://example.com/schema/common">Street</ns6:street>
<ns7:houseNum xmlns:ns7="http://example.com/schema/common">1</ns7:houseNum>
<ns8:country xmlns:ns8="http://example.com/schema/common">XX</ns8:country>
</ns3:address>
[...]
As you can see, several prefixes are defined for the same namespace, e.g. the namespace http://example.com/schema/common has the prefixes ns4, ns5, ns6, ns7 and ns8. Some long requests define several hundred prefixes for the same namespace.
This causes a problem with the [Saxon](http://saxon.sourceforge.net/) XSLT processor, that I use to transform the requests. Saxon limits the the number of different prefixes for the same namespace to 255 and throws an exception when you define more prefixes.
Can Axis 1.4 be configured to define smarter prefixes, so that there is only one prefix for each namespace? | java | xml | soap | namespaces | axis | null | open | How can I get Axis 1.4 to not generate several prefixes for the same XML namespace?
===
I am receiving SOAP requests from a client that uses the Axis 1.4 libraries. The requests have the following form:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<PlaceOrderRequest xmlns="http://example.com/schema/order/request">
<order>
<ns1:requestParameter xmlns:ns1="http://example.com/schema/common/request">
<ns1:orderingSystemWithDomain>
<ns1:orderingSystem>Internet</ns1:orderingSystem>
<ns1:domainSign>2</ns1:domainSign>
</ns1:orderingSystemWithDomain>
</ns1:requestParameter>
<ns2:directDeliveryAddress ns2:addressType="0" ns2:index="1"
xmlns:ns2="http://example.com/schema/order/request">
<ns3:address xmlns:ns3="http://example.com/schema/common/request">
<ns4:zipcode xmlns:ns4="http://example.com/schema/common">12345</ns4:zipcode>
<ns5:city xmlns:ns5="http://example.com/schema/common">City</ns5:city>
<ns6:street xmlns:ns6="http://example.com/schema/common">Street</ns6:street>
<ns7:houseNum xmlns:ns7="http://example.com/schema/common">1</ns7:houseNum>
<ns8:country xmlns:ns8="http://example.com/schema/common">XX</ns8:country>
</ns3:address>
[...]
As you can see, several prefixes are defined for the same namespace, e.g. the namespace http://example.com/schema/common has the prefixes ns4, ns5, ns6, ns7 and ns8. Some long requests define several hundred prefixes for the same namespace.
This causes a problem with the [Saxon](http://saxon.sourceforge.net/) XSLT processor, that I use to transform the requests. Saxon limits the the number of different prefixes for the same namespace to 255 and throws an exception when you define more prefixes.
Can Axis 1.4 be configured to define smarter prefixes, so that there is only one prefix for each namespace? | 0 |
62,491 | 09/15/2008 12:48:20 | 6,827 | 09/15/2008 12:41:25 | 1 | 0 | How to create J2ME midlets for Nokia S40 using Eclipse | Nokia has stopped offering its Developer's Suite, relying on other IDEs, including Eclipse. Meanwhile, Nokia changed its own development tools again and EclipseMe has also changed. This leaves most documentation irrelevant.
I want to know what does it take to make a simple Hello-World?
(I already found out myself, so this is a Q&A for other people to use) | java-me | java | eclipse | nokia | wtk | null | open | How to create J2ME midlets for Nokia S40 using Eclipse
===
Nokia has stopped offering its Developer's Suite, relying on other IDEs, including Eclipse. Meanwhile, Nokia changed its own development tools again and EclipseMe has also changed. This leaves most documentation irrelevant.
I want to know what does it take to make a simple Hello-World?
(I already found out myself, so this is a Q&A for other people to use) | 0 |
62,496 | 09/15/2008 12:49:01 | 890 | 08/10/2008 08:05:36 | 156 | 5 | Similarity between line strings | I have a number of tracks recorded by a GPS, which more formally can be described as a number of line strings.
Now, some of the recorded tracks might be recordings of the same route, but because of inaccurasies in the GPS system, the fact that the recordings were made on separate occasions and that they might have been recorded travelling at different speeds, they won't match up perfectly, but still look close enough when viewed on a map by a human to determine that it's actually the same route that has been recorded.
I want to find an algorithm that calculates the similarity between two line strings. I have come up with some home grown methods to do this, but would like to know if this is a problem that's already has good algorithms to solve it.
How would you calculate the similarity, given that similar means represents the same path on a map? | algorithm | gis | null | null | null | null | open | Similarity between line strings
===
I have a number of tracks recorded by a GPS, which more formally can be described as a number of line strings.
Now, some of the recorded tracks might be recordings of the same route, but because of inaccurasies in the GPS system, the fact that the recordings were made on separate occasions and that they might have been recorded travelling at different speeds, they won't match up perfectly, but still look close enough when viewed on a map by a human to determine that it's actually the same route that has been recorded.
I want to find an algorithm that calculates the similarity between two line strings. I have come up with some home grown methods to do this, but would like to know if this is a problem that's already has good algorithms to solve it.
How would you calculate the similarity, given that similar means represents the same path on a map? | 0 |
62,501 | 09/15/2008 12:49:41 | 6,698 | 09/15/2008 12:30:27 | 1 | 0 | Remote installing of windows service | I need to remotely install windows service on number of computers, so I use CreateService() and other service functions from winapi. I know admin password and user name for machines that I need access to. In order to gain access to remote machine I impersonate calling process with help of LogonUser like this:
//all variables are initialized correctly
int status = 0;
status = LogonUser(lpwUsername,
lpwDomain,
lpwPassword,
LOGON32_LOGON_NEW_CREDENTIALS,
LOGON32_PROVIDER_DEFAULT,
&hToken);
if (status == 0)
{
//here comes a error
}
status = ImpersonateLoggedOnUser(hToken);
if (status == 0)
{
//once again a error
}
//ok, now we are impersonated, do all service work there
So, I gain access to machine in a domain, but some of computers are out of domain. On machines that are out of domain this code doesn't work. Is there any way to access service manager on machine out of domain ? | c++ | windows | windowsservice | null | null | null | open | Remote installing of windows service
===
I need to remotely install windows service on number of computers, so I use CreateService() and other service functions from winapi. I know admin password and user name for machines that I need access to. In order to gain access to remote machine I impersonate calling process with help of LogonUser like this:
//all variables are initialized correctly
int status = 0;
status = LogonUser(lpwUsername,
lpwDomain,
lpwPassword,
LOGON32_LOGON_NEW_CREDENTIALS,
LOGON32_PROVIDER_DEFAULT,
&hToken);
if (status == 0)
{
//here comes a error
}
status = ImpersonateLoggedOnUser(hToken);
if (status == 0)
{
//once again a error
}
//ok, now we are impersonated, do all service work there
So, I gain access to machine in a domain, but some of computers are out of domain. On machines that are out of domain this code doesn't work. Is there any way to access service manager on machine out of domain ? | 0 |
62,503 | 09/15/2008 12:49:50 | 1,826 | 08/18/2008 18:27:20 | 76 | 5 | C#, int or Int32? Should I care? | From my understanding int and Int32 are the same thing in C#, but I've read a number of times that int is preferred over Int32 but without any reason given. So, what is the reason? Should I care? | c# | variable-types | null | null | null | null | open | C#, int or Int32? Should I care?
===
From my understanding int and Int32 are the same thing in C#, but I've read a number of times that int is preferred over Int32 but without any reason given. So, what is the reason? Should I care? | 0 |
62,504 | 09/15/2008 12:49:56 | 6,613 | 09/15/2008 12:22:08 | 1 | 2 | Is there any way to create multiple insert statements in a ms-access query? | I am using MS Access 2003. I want to run a lot of insert SQL statements in what is called 'Query' in MS Access. Is there any easy(or indeed any way) to do it? | ms-access | null | null | null | null | null | open | Is there any way to create multiple insert statements in a ms-access query?
===
I am using MS Access 2003. I want to run a lot of insert SQL statements in what is called 'Query' in MS Access. Is there any easy(or indeed any way) to do it? | 0 |
62,505 | 09/15/2008 12:49:56 | 6,770 | 09/15/2008 12:36:56 | 1 | 0 | How do I move tags in Subversion | I wish Subversion had a better way of moving tags. The only way that I know to move a tag is to remove the file from the tag and then copy it again. Revision tree browsers don't seem to handle that very well. This also requires keeping the directory structure under the trunk and tag in sync.
Use case: We have thousands of "maps" and we want to tag which version of each map is the "production" version. We need to be able to easily get the production version of all maps.
Can anyone suggest a better way to address our use case?
I have considered properties also but then we can't get the prod version of all files easily. Merging to the tag doesn't appear to be very easy either.
(Originally posted to [http://jamesjava.blogspot.com/2007/12/subversion-moving-tags.html][1])
[1]: http://jamesjava.blogspot.com/2007/12/subversion-moving-tags.html | svn | null | null | null | null | null | open | How do I move tags in Subversion
===
I wish Subversion had a better way of moving tags. The only way that I know to move a tag is to remove the file from the tag and then copy it again. Revision tree browsers don't seem to handle that very well. This also requires keeping the directory structure under the trunk and tag in sync.
Use case: We have thousands of "maps" and we want to tag which version of each map is the "production" version. We need to be able to easily get the production version of all maps.
Can anyone suggest a better way to address our use case?
I have considered properties also but then we can't get the prod version of all files easily. Merging to the tag doesn't appear to be very easy either.
(Originally posted to [http://jamesjava.blogspot.com/2007/12/subversion-moving-tags.html][1])
[1]: http://jamesjava.blogspot.com/2007/12/subversion-moving-tags.html | 0 |
62,512 | 09/15/2008 12:50:19 | 6,795 | 09/15/2008 12:38:31 | 1 | 0 | Three dimensional arrays of integers in C++ | I would like to find out safe ways of implementing three dimensional arrays of integers in C++, using pointer arithmetic / dynamic memory allocation, or, alternatively using STL techniques such as vectors.
Essentially I want my integer array dimensions to look like:
[ x ][ y ][ z ]
x and y are in the range 20-6000
z is known and equals 4.
Any feedback or suggestions greatly appreciated.
Thanks in anticipation.
Andy | c++ | arrays | multidimensional | null | null | null | open | Three dimensional arrays of integers in C++
===
I would like to find out safe ways of implementing three dimensional arrays of integers in C++, using pointer arithmetic / dynamic memory allocation, or, alternatively using STL techniques such as vectors.
Essentially I want my integer array dimensions to look like:
[ x ][ y ][ z ]
x and y are in the range 20-6000
z is known and equals 4.
Any feedback or suggestions greatly appreciated.
Thanks in anticipation.
Andy | 0 |
62,513 | 09/15/2008 12:50:19 | 6,775 | 09/15/2008 12:37:02 | 1 | 0 | REST type API for non web based applications, Is It a good idea? | We are developing a middleware SDK, both in C++ and Java to be used as a library/DLL by, for example, game developers, animation software developers, Avatar developers to enhance their products.
Having created a typical API using specific calls for specific functions I am considering simplifying the API by using a REST type API (GET, PUT, POST, DELETE) or CRUD type (CREATE, READ, UPDATE, DELETE) interface.
This would work in a similar way to a client-server type REST API where there are only 4 possible API calls but these can take flexible parameters.
This seems to have the benefit of making the API stable in that new calls are not being added and old calls are not being removed. So a consumer of this API need not worry about having to recompile and change their code to suit any updates to our middleware.
The overhead is that there is an extra layer of redirection in the middleware controller to route API calls and the developer needs to know what parameters are available for each REST call (supplied of course).
I have not so far seen this system used outside of web type client server applications so my question is this: Is this a feasible idea?
I am thinking in terms of its efficiency as well as if for example a game developer would find it easy to use.
| api | rest | middleware | engine | null | null | open | REST type API for non web based applications, Is It a good idea?
===
We are developing a middleware SDK, both in C++ and Java to be used as a library/DLL by, for example, game developers, animation software developers, Avatar developers to enhance their products.
Having created a typical API using specific calls for specific functions I am considering simplifying the API by using a REST type API (GET, PUT, POST, DELETE) or CRUD type (CREATE, READ, UPDATE, DELETE) interface.
This would work in a similar way to a client-server type REST API where there are only 4 possible API calls but these can take flexible parameters.
This seems to have the benefit of making the API stable in that new calls are not being added and old calls are not being removed. So a consumer of this API need not worry about having to recompile and change their code to suit any updates to our middleware.
The overhead is that there is an extra layer of redirection in the middleware controller to route API calls and the developer needs to know what parameters are available for each REST call (supplied of course).
I have not so far seen this system used outside of web type client server applications so my question is this: Is this a feasible idea?
I am thinking in terms of its efficiency as well as if for example a game developer would find it easy to use.
| 0 |
62,529 | 09/15/2008 12:52:15 | 6,941 | 09/15/2008 12:52:15 | 1 | 0 | Best Practice for Model Design in Ruby on Rails | The RoR tutorials posit one model per table for the ORM to work.
My DB schema has some 70 tables divided conceptually into 5 groups of functionality
(eg, any given table lives in one and only one functional group, and relations between tables of different groups are minimised.)
So: should I design a model per conceptual group, or should I simply have 70 Rails models and leave the grouping 'conceptual'?
Thanks!
| ruby | activerecord | rubyonrails | null | null | null | open | Best Practice for Model Design in Ruby on Rails
===
The RoR tutorials posit one model per table for the ORM to work.
My DB schema has some 70 tables divided conceptually into 5 groups of functionality
(eg, any given table lives in one and only one functional group, and relations between tables of different groups are minimised.)
So: should I design a model per conceptual group, or should I simply have 70 Rails models and leave the grouping 'conceptual'?
Thanks!
| 0 |
62,530 | 09/15/2008 12:52:17 | 6,942 | 09/15/2008 12:52:17 | 1 | 0 | How to prevent IE6 from refetching already-fetched images added via DOM manipulation | If you add a image to your browser's DOM, IE6 will not check its cache to see if it already downloaded the image but will, instead, re-retrieve it from the server. I have not found any combination of HTTP response headers (of the ensuing image request) to convince IE6 that it can cache the image: Cache-control, Expires, Last-modified.
Some suggest you can return a 304 of the subsequent image requests to tell IE6 "you already got it" but I want to avoid the whole round trip to the server in the first place.
| ajax | caching | internet-explorer-6 | image | null | null | open | How to prevent IE6 from refetching already-fetched images added via DOM manipulation
===
If you add a image to your browser's DOM, IE6 will not check its cache to see if it already downloaded the image but will, instead, re-retrieve it from the server. I have not found any combination of HTTP response headers (of the ensuing image request) to convince IE6 that it can cache the image: Cache-control, Expires, Last-modified.
Some suggest you can return a 304 of the subsequent image requests to tell IE6 "you already got it" but I want to avoid the whole round trip to the server in the first place.
| 0 |
62,539 | 09/15/2008 12:53:20 | 3,012 | 08/26/2008 11:55:24 | 320 | 12 | The Dependency Inversion Principle | What is the Dependency Inversion Principle and why is it important? | oop | null | null | null | null | null | open | The Dependency Inversion Principle
===
What is the Dependency Inversion Principle and why is it important? | 0 |
62,540 | 09/15/2008 12:53:29 | 6,915 | 09/15/2008 12:49:49 | 1 | 0 | Learning OpenGl | what's a good book for learning OpenGl programming? | books | opengl | null | null | null | 11/01/2011 16:01:46 | not constructive | Learning OpenGl
===
what's a good book for learning OpenGl programming? | 4 |
62,542 | 09/15/2008 12:54:08 | 6,751 | 09/15/2008 12:35:36 | 1 | 0 | What is the best free test tracking software? | I'm not talking about bug tracking software (like Bugzilla or Jira). I'm looking for something that will let me:
1. Store test specifications in text format
2. Combine test specs into test coverage scenarios
3. Keep track of the progress through testing scenarios
4. Link test specs with bug reports stored in Bugzilla
5. Generate progress reports | testing | progress | null | null | null | 05/01/2012 02:25:01 | not constructive | What is the best free test tracking software?
===
I'm not talking about bug tracking software (like Bugzilla or Jira). I'm looking for something that will let me:
1. Store test specifications in text format
2. Combine test specs into test coverage scenarios
3. Keep track of the progress through testing scenarios
4. Link test specs with bug reports stored in Bugzilla
5. Generate progress reports | 4 |
62,567 | 09/15/2008 12:57:10 | 6,984 | 09/15/2008 12:57:10 | 1 | 0 | Ignore case in Python strings | What is the easiest way to compare strings in Python, ignoring case?
Of course one can do (str1.lower() <= str2.lower()), etc., but this created two additional temporary strings (whith the obvious alloc/g-c overheads).
I guess I'm looking for an equivalent to C's stricmp(). | python | string | null | null | null | null | open | Ignore case in Python strings
===
What is the easiest way to compare strings in Python, ignoring case?
Of course one can do (str1.lower() <= str2.lower()), etc., but this created two additional temporary strings (whith the obvious alloc/g-c overheads).
I guess I'm looking for an equivalent to C's stricmp(). | 0 |
62,570 | 09/15/2008 12:57:16 | 1,436 | 08/15/2008 15:43:19 | 441 | 22 | How do I move a file (or folder) from one folder to another in Subversion | I would like to move a file or folder from one place to another within the same repository without having to use Repo Browser to do it, and without creating two independent add/delete operations. Using Repo Browser works fine except that your code will be hanging in a broken state until you get any supporting changes checked in afterwards (like the .csproj file for example). | subversion | null | null | null | null | null | open | How do I move a file (or folder) from one folder to another in Subversion
===
I would like to move a file or folder from one place to another within the same repository without having to use Repo Browser to do it, and without creating two independent add/delete operations. Using Repo Browser works fine except that your code will be hanging in a broken state until you get any supporting changes checked in afterwards (like the .csproj file for example). | 0 |
62,578 | 09/15/2008 12:57:57 | 290 | 08/04/2008 12:57:50 | 983 | 57 | APIs and Datasets for Natural Languages? | Are there any good APIs and public datasets (dictionaries, phrases) for working w/ natural languages?
Specifically, do any good ones exist for working on translation between English and Korean?
| language-agnostic | api | dictionary | nlp | null | null | open | APIs and Datasets for Natural Languages?
===
Are there any good APIs and public datasets (dictionaries, phrases) for working w/ natural languages?
Specifically, do any good ones exist for working on translation between English and Korean?
| 0 |
62,588 | 09/15/2008 12:59:24 | 6,897 | 09/15/2008 12:47:00 | 1 | 0 | Shared/Static variable in Global.asax isolated per request? | I have some ASP.NET web services which all share a common helper class they only need to instantiate one instance of *per server*. It's used for simple translation of data, but does spend some time during start-up loading things from the web.config file, etc. We've deployed the web services to IIS 6.0 and using an Application Pool, with a Web Garden of 15 workers.
I declared the helper class as a Private Shared variable in Global.asax, and added a lazy load Shared ReadOnly property like this:
Private Shared _helper As MyHelperClass
Public Shared ReadOnly Property Helper() As MyHelperClass
Get
If _helper Is Nothing Then
_helper = New MyHelperClass()
End If
Return _helper
End Get
End Property
I have logging code in the constructor for MyHelperClass(), and it shows the constructor running for each request, even on the same thread. I'm sure I'm just missing some key detail of ASP.NET but MSDN hasn't been very helpful. | asp.net | vb.net | web-services | null | null | null | open | Shared/Static variable in Global.asax isolated per request?
===
I have some ASP.NET web services which all share a common helper class they only need to instantiate one instance of *per server*. It's used for simple translation of data, but does spend some time during start-up loading things from the web.config file, etc. We've deployed the web services to IIS 6.0 and using an Application Pool, with a Web Garden of 15 workers.
I declared the helper class as a Private Shared variable in Global.asax, and added a lazy load Shared ReadOnly property like this:
Private Shared _helper As MyHelperClass
Public Shared ReadOnly Property Helper() As MyHelperClass
Get
If _helper Is Nothing Then
_helper = New MyHelperClass()
End If
Return _helper
End Get
End Property
I have logging code in the constructor for MyHelperClass(), and it shows the constructor running for each request, even on the same thread. I'm sure I'm just missing some key detail of ASP.NET but MSDN hasn't been very helpful. | 0 |
62,599 | 09/15/2008 13:00:22 | 6,369 | 09/14/2008 23:13:34 | 36 | 4 | Setting the namespace of a WinForms UserControl in VB.NET | How do you define your UserControls as being in a namespace below the project namespace, ie. [RootNameSpace].[SubSectionOfProgram].Controls? | vb.net | winforms | namespaces | null | null | null | open | Setting the namespace of a WinForms UserControl in VB.NET
===
How do you define your UserControls as being in a namespace below the project namespace, ie. [RootNameSpace].[SubSectionOfProgram].Controls? | 0 |
62,606 | 09/15/2008 13:01:24 | 905 | 08/10/2008 09:37:14 | 4,427 | 250 | .Net 2+: why does if( 1 == null ) no longer throw a compiler exception? | I'm using `int` as an example, but this applies to any value type in .Net
In .Net 1 the following would throw a compiler exception:
int i = SomeFunctionThatReturnsInt();
if( i == null ) //compiler exception here
Now (in .Net 2 or 3.5) that exception has gone.
I know why this is:
int? j = null; //nullable int
if( i == j ) //this shouldn't throw an exception
The problem is that because `int?` is nullable and `int` now has a implicit cast to `int?`. The syntax above is compiler magic. Really we're doing:
Nullable<int> j = null; //nullable int
//compiler is smart enough to do this
if( (Nullable<int>) i == j)
//and not this
if( i == (int) j)
So now, when we do `i == null` we get:
if( (Nullable<int>) i == null )
Given that C# is doing compiler logic to calculate this anyway why can't it be smart enough to not do it when dealing with absolute values like `null`? | c# | .net-3.5 | compiler | .net-2.0 | null | null | open | .Net 2+: why does if( 1 == null ) no longer throw a compiler exception?
===
I'm using `int` as an example, but this applies to any value type in .Net
In .Net 1 the following would throw a compiler exception:
int i = SomeFunctionThatReturnsInt();
if( i == null ) //compiler exception here
Now (in .Net 2 or 3.5) that exception has gone.
I know why this is:
int? j = null; //nullable int
if( i == j ) //this shouldn't throw an exception
The problem is that because `int?` is nullable and `int` now has a implicit cast to `int?`. The syntax above is compiler magic. Really we're doing:
Nullable<int> j = null; //nullable int
//compiler is smart enough to do this
if( (Nullable<int>) i == j)
//and not this
if( i == (int) j)
So now, when we do `i == null` we get:
if( (Nullable<int>) i == null )
Given that C# is doing compiler logic to calculate this anyway why can't it be smart enough to not do it when dealing with absolute values like `null`? | 0 |
62,617 | 09/15/2008 13:02:38 | 6,681 | 09/15/2008 12:29:11 | 1 | 1 | What's the best way to separate PHP Code and HTML | I realy don't like mixing PHP and HTML. It makes it difficult to maintain both the PHP and the HTML, and it just makes sense to keep the two apart.
How to do it? | php | html | null | null | null | 05/22/2012 12:23:01 | not constructive | What's the best way to separate PHP Code and HTML
===
I realy don't like mixing PHP and HTML. It makes it difficult to maintain both the PHP and the HTML, and it just makes sense to keep the two apart.
How to do it? | 4 |
62,618 | 09/15/2008 13:02:39 | 4,230 | 09/02/2008 13:21:04 | 11 | 4 | What is the best way to merge mp3 files? | I've got many, many mp3 files that I would like to merge into a single file. I've used the command line method
copy /b 1.mp3+2.mp3 3.mp3
but it's a pain when there's a lot of them and they're naming is inconsistent. The time never seems to come out right either. | audio | mp3 | null | null | null | null | open | What is the best way to merge mp3 files?
===
I've got many, many mp3 files that I would like to merge into a single file. I've used the command line method
copy /b 1.mp3+2.mp3 3.mp3
but it's a pain when there's a lot of them and they're naming is inconsistent. The time never seems to come out right either. | 0 |
62,629 | 09/15/2008 13:03:48 | 460,958 | 09/15/2008 12:57:47 | 1 | 0 | How do I detect application Level Focus-In in Qt 4.4.1? | I need to determine when my Qt 4.4.1 application receives focus.
I have come up with 2 possible solutions, but they both don’t work exactly as I would like.
In the first possible solution, I connect the focusChanged() signal from qApp to a SLOT. In the slot I check the ‘old’ pointer. If it ‘0’, then I know we’ve switched to this application, and I do what I want. This seems to be the most reliable method of getting the application to detect focus in of the two solutions presented here, but suffers from the problem described below.
In the second possible solution, I overrode the ‘focusInEvent()’ routine, and do what I want if the reason is ‘ActiveWindowFocusReason’.
In both of these solutions, the code is executed at times when I don’t want it to be.
For example, I have this code that overrides the focusInEvent() routine:
void
ApplicationWindow::focusInEvent( QFocusEvent* p_event )
{
Qt::FocusReason reason = p_event->reason();
if( reason == Qt::ActiveWindowFocusReason &&
hasNewUpstreamData() )
{
switch( QMessageBox::warning( this, "New Upstream Data Found!",
"New upstream data exists!\n"
"Do you want to refresh this simulation?",
"&Yes", "&No", 0, 0, 1 ) )
{
case 0: // Yes
refreshSimulation();
break;
case 1: // No
break;
}
}
}
When this gets executed, the QMessageBox dialog appears. However, when the dialog is dismissed by pressing either ‘yes’ or ‘no’, this function immediately gets called again because I suppose the focus changed back to the application window at that point with the ActiveWindowFocusReason. Obviously I don’t want this to happen.
Likewise, if the user is using the application opening & closing dialogs and windows etc, I don’t want this routine to activate. NOTE: I’m not sure of the circumstances when this routine is activated though since I’ve tried a bit, and it doesn’t happen for all windows & dialogs, though it does happen at least for the one shown in the sample code.
I only want it to activate if the application is focussed on from outside of this application, not when the main window is focussed in from other dialog windows.
Is this possible? How can this be done?
Thanks for any information, since this is very important for our application to do.
Raymond.
| c++ | qt | null | null | null | null | open | How do I detect application Level Focus-In in Qt 4.4.1?
===
I need to determine when my Qt 4.4.1 application receives focus.
I have come up with 2 possible solutions, but they both don’t work exactly as I would like.
In the first possible solution, I connect the focusChanged() signal from qApp to a SLOT. In the slot I check the ‘old’ pointer. If it ‘0’, then I know we’ve switched to this application, and I do what I want. This seems to be the most reliable method of getting the application to detect focus in of the two solutions presented here, but suffers from the problem described below.
In the second possible solution, I overrode the ‘focusInEvent()’ routine, and do what I want if the reason is ‘ActiveWindowFocusReason’.
In both of these solutions, the code is executed at times when I don’t want it to be.
For example, I have this code that overrides the focusInEvent() routine:
void
ApplicationWindow::focusInEvent( QFocusEvent* p_event )
{
Qt::FocusReason reason = p_event->reason();
if( reason == Qt::ActiveWindowFocusReason &&
hasNewUpstreamData() )
{
switch( QMessageBox::warning( this, "New Upstream Data Found!",
"New upstream data exists!\n"
"Do you want to refresh this simulation?",
"&Yes", "&No", 0, 0, 1 ) )
{
case 0: // Yes
refreshSimulation();
break;
case 1: // No
break;
}
}
}
When this gets executed, the QMessageBox dialog appears. However, when the dialog is dismissed by pressing either ‘yes’ or ‘no’, this function immediately gets called again because I suppose the focus changed back to the application window at that point with the ActiveWindowFocusReason. Obviously I don’t want this to happen.
Likewise, if the user is using the application opening & closing dialogs and windows etc, I don’t want this routine to activate. NOTE: I’m not sure of the circumstances when this routine is activated though since I’ve tried a bit, and it doesn’t happen for all windows & dialogs, though it does happen at least for the one shown in the sample code.
I only want it to activate if the application is focussed on from outside of this application, not when the main window is focussed in from other dialog windows.
Is this possible? How can this be done?
Thanks for any information, since this is very important for our application to do.
Raymond.
| 0 |
62,658 | 09/15/2008 13:06:38 | 6,939 | 09/15/2008 12:52:05 | 1 | 0 | Getting PEAR to work on XAMPP (Apache/MySQL stack on Windows) | I'm trying to install [Laconica][1], an open-source Microblogging application on my Windows development server using XAMPP as per the [instructions provided][2].
The website cannot find PEAR, and throws the below errors:
Warning: require_once(PEAR.php) [function.require-once]: failed to open stream: No such file or directory in C:\xampplite\htdocs\laconica\lib\common.php on line 31
Fatal error: require_once() [function.require]: Failed opening required 'PEAR.php' (include_path='.;\xampplite\php\pear\PEAR') in C:\xampplite\htdocs\laconica\lib\common.php on line 31
1. PEAR is located in C:\xampplite\php\pear
2. php_info shows me that the include path is ".;\xampplite\php\pear"
What am I doing wrong? Why isn't the PEAR folder being included?
[1]: http://laconi.ca/
[2]: http://laconi.ca/trac/wiki/InstallationWindows | php | pear | laconica | null | null | null | open | Getting PEAR to work on XAMPP (Apache/MySQL stack on Windows)
===
I'm trying to install [Laconica][1], an open-source Microblogging application on my Windows development server using XAMPP as per the [instructions provided][2].
The website cannot find PEAR, and throws the below errors:
Warning: require_once(PEAR.php) [function.require-once]: failed to open stream: No such file or directory in C:\xampplite\htdocs\laconica\lib\common.php on line 31
Fatal error: require_once() [function.require]: Failed opening required 'PEAR.php' (include_path='.;\xampplite\php\pear\PEAR') in C:\xampplite\htdocs\laconica\lib\common.php on line 31
1. PEAR is located in C:\xampplite\php\pear
2. php_info shows me that the include path is ".;\xampplite\php\pear"
What am I doing wrong? Why isn't the PEAR folder being included?
[1]: http://laconi.ca/
[2]: http://laconi.ca/trac/wiki/InstallationWindows | 0 |
62,661 | 09/15/2008 13:07:01 | 7,071 | 09/15/2008 13:07:00 | 1 | 0 | Implementing Porter-Duff Rules in Direct3D | What Direct3D render states should be used to implement Java's Porter-Duff compositing rules (CLEAR, SRC, SRCOVER, etc.)? | direct3d | alphablending | compositing | null | null | null | open | Implementing Porter-Duff Rules in Direct3D
===
What Direct3D render states should be used to implement Java's Porter-Duff compositing rules (CLEAR, SRC, SRCOVER, etc.)? | 0 |
62,663 | 09/15/2008 13:07:15 | 7,040 | 09/15/2008 13:03:15 | 1 | 0 | GDI+ DrawImage() with transparent bitmap to a printer | Does anybody have any pointers on how to successfully draw a bitmap that has
an alpha channel using Graphics::DrawImage() when the Graphics context is
created based on a printer HDC? The printer drivers don't generally support alpha blending - so is there an alternative to rendering everything to an offscreen bitmap and just sending that to the printer. This is often not feasible, especially for high res printing to large format printers. | windows | gdi+ | null | null | null | null | open | GDI+ DrawImage() with transparent bitmap to a printer
===
Does anybody have any pointers on how to successfully draw a bitmap that has
an alpha channel using Graphics::DrawImage() when the Graphics context is
created based on a printer HDC? The printer drivers don't generally support alpha blending - so is there an alternative to rendering everything to an offscreen bitmap and just sending that to the printer. This is often not feasible, especially for high res printing to large format printers. | 0 |
62,686 | 09/15/2008 13:09:28 | 6,165 | 09/12/2008 18:18:01 | 1 | 1 | Performing validation on a databound object after the property has been updated | I have a basic form with controls that are databound to an object implementing the _INotifyPropertyChanged_ interface. I would like to add some validation to a couple of properties but dont want to go through implementing _IDataErrorInfo_ for the sake of validating a couple of properties.
I have created the functions that perform the validation and return the error message (if applicable) in the object. What I would like to do is call these functions from my form when the relevant properties on the object have changed, and setup the _ErrorProvider_ control in my form with any error messages that have been returned from the validation functions.
I have tried hooking up event handlers to the Validating and LostFocus events, but these seem to fire before my object is updated, and hence they are not validating the correct data. Its only when I leave the textbox, go back in and then leave again that the validation runs against the correct data.
Is there another event that I can hook into so that I can call these validation functions after the property on my object has been updated? Or am I better off just implementing the _IDataErrorInfo_ interface? | .net | vb.net | validation | data-binding | null | null | open | Performing validation on a databound object after the property has been updated
===
I have a basic form with controls that are databound to an object implementing the _INotifyPropertyChanged_ interface. I would like to add some validation to a couple of properties but dont want to go through implementing _IDataErrorInfo_ for the sake of validating a couple of properties.
I have created the functions that perform the validation and return the error message (if applicable) in the object. What I would like to do is call these functions from my form when the relevant properties on the object have changed, and setup the _ErrorProvider_ control in my form with any error messages that have been returned from the validation functions.
I have tried hooking up event handlers to the Validating and LostFocus events, but these seem to fire before my object is updated, and hence they are not validating the correct data. Its only when I leave the textbox, go back in and then leave again that the validation runs against the correct data.
Is there another event that I can hook into so that I can call these validation functions after the property on my object has been updated? Or am I better off just implementing the _IDataErrorInfo_ interface? | 0 |
62,694 | 09/15/2008 13:09:57 | 6,462 | 09/15/2008 10:28:07 | 11 | 3 | How do i start working in open source projects???? | Im planning to start working in opensource projects. Give some ideas related to that and give references also.. | opensource | null | null | null | null | null | open | How do i start working in open source projects????
===
Im planning to start working in opensource projects. Give some ideas related to that and give references also.. | 0 |
62,702 | 09/15/2008 13:10:34 | 3,333 | 08/28/2008 00:32:00 | 700 | 43 | Good text on order analysis | As a self-taught computer programmer, I'm often at a loss to estimate the O() value for a particular operation. Yeah, I know off the top of my head most of the important ones, like for the major sorts and searches, but I don't know how to calculate one when something new comes along, unless it's blindingly obvious. Is there a good web site or text that explains how to do that? Heck, I don't even know what computer scientists call it, so I can't google it. | computer-science | null | null | null | null | null | open | Good text on order analysis
===
As a self-taught computer programmer, I'm often at a loss to estimate the O() value for a particular operation. Yeah, I know off the top of my head most of the important ones, like for the major sorts and searches, but I don't know how to calculate one when something new comes along, unless it's blindingly obvious. Is there a good web site or text that explains how to do that? Heck, I don't even know what computer scientists call it, so I can't google it. | 0 |
62,713 | 09/15/2008 13:12:04 | 6,871 | 09/15/2008 12:44:57 | 1 | 0 | Accessing a bean with a dot(.) in its ID | In a flow definition, I am trying to access a bean that has a dot in its ID
(example: `<evaluate expression="bus.MyServiceFacade.someAction()" />`
However, it does not work. SWF tries to find a bean "bus" instead.
Initially, I got over it by using a helper bean to load the required bean, but the solution is inelegant and uncomfortable. The use of alias'es is also out of the question since the beans are part of a large system and I cannot tamper with them.
In a nutshell, none of the solution allowed me to refernce the bean directly by using its original name. Is that even possible in the current SWF release? | spring | webflow | null | null | null | null | open | Accessing a bean with a dot(.) in its ID
===
In a flow definition, I am trying to access a bean that has a dot in its ID
(example: `<evaluate expression="bus.MyServiceFacade.someAction()" />`
However, it does not work. SWF tries to find a bean "bus" instead.
Initially, I got over it by using a helper bean to load the required bean, but the solution is inelegant and uncomfortable. The use of alias'es is also out of the question since the beans are part of a large system and I cannot tamper with them.
In a nutshell, none of the solution allowed me to refernce the bean directly by using its original name. Is that even possible in the current SWF release? | 0 |
62,716 | 09/15/2008 13:12:39 | 3,153 | 08/27/2008 02:45:05 | 1,375 | 57 | SVN externals sub folder changes not showing in view log (tortoise svn) | SVN externals allow you to make an SVN folder appear as if it's at another location. A good use for this is having a common folder shared across all of your projects in SVN.
I have a /trunk/common folder in SVN that I share via several different project.
Example:
- Project1 : /trunk/project1/depends
- Project2 : /trunk/project2/depends
- Project3 : /trunk/project3/depends
- Project4 : /trunk/project4/depends
Each of these depends folders are empty, but have an svn:external defined to point to my /trunk/common folder.
The problem is when I view log within any of the projects: /trunk/projectX/ it does not show changes from the svn:externals. I am using tortoise SVN as my SVN client.
Does anyone know how to change this behavior? I would like for the show log of /trunk/projectX to include any changes to any defined svn:externals as well. | svn | tortoisesvn | null | null | null | null | open | SVN externals sub folder changes not showing in view log (tortoise svn)
===
SVN externals allow you to make an SVN folder appear as if it's at another location. A good use for this is having a common folder shared across all of your projects in SVN.
I have a /trunk/common folder in SVN that I share via several different project.
Example:
- Project1 : /trunk/project1/depends
- Project2 : /trunk/project2/depends
- Project3 : /trunk/project3/depends
- Project4 : /trunk/project4/depends
Each of these depends folders are empty, but have an svn:external defined to point to my /trunk/common folder.
The problem is when I view log within any of the projects: /trunk/projectX/ it does not show changes from the svn:externals. I am using tortoise SVN as my SVN client.
Does anyone know how to change this behavior? I would like for the show log of /trunk/projectX to include any changes to any defined svn:externals as well. | 0 |
62,720 | 09/15/2008 13:12:55 | 6,954 | 09/15/2008 12:54:06 | 1 | 0 | IIS crashes when serving an ASP.NET application under heavy load. How to troubleshoot it? | I am working on an ASP.NET web application, it seems to be working properly when I try to debug it in Visual Studio. However when I emulate heavy load, IIS crashes without any trace -- log entry in the system journal is very generic, "The World Wide Web Publishing service terminated unexpectedly. It has done this 4 time(s)."
How is it possible to get more information from IIS to troubleshoot this problem? | debugging | iis | null | null | null | null | open | IIS crashes when serving an ASP.NET application under heavy load. How to troubleshoot it?
===
I am working on an ASP.NET web application, it seems to be working properly when I try to debug it in Visual Studio. However when I emulate heavy load, IIS crashes without any trace -- log entry in the system journal is very generic, "The World Wide Web Publishing service terminated unexpectedly. It has done this 4 time(s)."
How is it possible to get more information from IIS to troubleshoot this problem? | 0 |
62,742 | 09/15/2008 13:14:41 | 7,040 | 09/15/2008 13:03:15 | 1 | 0 | polyline with gradient | Is there a way to draw a line along a curved path with a gradient that varies in a direction perpendicular to the direction of the line? I am using the GDI+ framework for my graphics. | windows | graphics | gdi+ | null | null | null | open | polyline with gradient
===
Is there a way to draw a line along a curved path with a gradient that varies in a direction perpendicular to the direction of the line? I am using the GDI+ framework for my graphics. | 0 |
62,771 | 09/15/2008 13:17:29 | 7,162 | 09/15/2008 13:17:29 | 1 | 0 | How check if given string is legal (allowed) file name under Windows? | I want to include batch file rename functionality in my application. User can type destination filename pattern and (after replacing some wildcards in pattern) I need to check if it's going to be legal filename under Windows. I tried to use regular expression like [a-zA-Z0-9_]+ but it doesn't include many national-specific characters from various languages (umlauts and so on). What is the best way to do such check? | c# | windows | file | filesystems | null | null | open | How check if given string is legal (allowed) file name under Windows?
===
I want to include batch file rename functionality in my application. User can type destination filename pattern and (after replacing some wildcards in pattern) I need to check if it's going to be legal filename under Windows. I tried to use regular expression like [a-zA-Z0-9_]+ but it doesn't include many national-specific characters from various languages (umlauts and so on). What is the best way to do such check? | 0 |
62,776 | 09/15/2008 13:18:22 | 7,174 | 09/15/2008 13:18:22 | 1 | 0 | How to implement the Edit -> Copy menu in c#/.net | How do I implement a Copy menu item in a Windows application written in .NET 2.0?
I want to let the user to mark some rows in a datagrid and then select the Copy menu item from an Edit menu in the menubar of the application and then do a Paste in for example Excel.
What makes my head spin is how to first determine which child form is active and then how to find the control that contains the marked text that shuld be copied to the clipboard. Especially the data grid view has caused me problems.
Help, please. | .net | c# | gui | null | null | null | open | How to implement the Edit -> Copy menu in c#/.net
===
How do I implement a Copy menu item in a Windows application written in .NET 2.0?
I want to let the user to mark some rows in a datagrid and then select the Copy menu item from an Edit menu in the menubar of the application and then do a Paste in for example Excel.
What makes my head spin is how to first determine which child form is active and then how to find the control that contains the marked text that shuld be copied to the clipboard. Especially the data grid view has caused me problems.
Help, please. | 0 |
62,784 | 09/15/2008 13:19:32 | 6,957 | 09/15/2008 12:54:34 | 1 | 0 | Should you design websites that require JavaScript in this day & age? | It's fall of 2008, and I still hear developers say that you should not design a site that requires JavaScript.
I understand that you should develop sites that degrade gracefully when JS is not present/on. But at what point do you not include funcitonality that can only be powered by JS?
I guess the question comes down to demographics. Are there numbers out there of how many folks are browsing without JS? | javascript | web | development | null | null | null | open | Should you design websites that require JavaScript in this day & age?
===
It's fall of 2008, and I still hear developers say that you should not design a site that requires JavaScript.
I understand that you should develop sites that degrade gracefully when JS is not present/on. But at what point do you not include funcitonality that can only be powered by JS?
I guess the question comes down to demographics. Are there numbers out there of how many folks are browsing without JS? | 0 |
62,798 | 09/15/2008 13:21:13 | 5,802 | 09/11/2008 12:26:41 | 26 | 5 | Applying AOP | I've been using some basic AOP style solutions for cross-cutting concerns like security, logging, validation, etc. My solution has envolved around [Castle Windsor][1] and DynamicProxy. I've gone down this route because I can apply everything using a Boo based DSL and keep my code clean of Attributes. I was told at the weekend to have a look at [PostSharp][2] as it's supposed to be a "better" solution. I've had a quick look at PostSharp, but I've been put off by the Attribute usage.
Has anyone tried both solutions and would care to share their experiences?
[1]: http://www.castleproject.org/container/index.html
[2]: http://www.postsharp.org/ | c# | castle-windsor | aop | castle-dynamicproxy | null | null | open | Applying AOP
===
I've been using some basic AOP style solutions for cross-cutting concerns like security, logging, validation, etc. My solution has envolved around [Castle Windsor][1] and DynamicProxy. I've gone down this route because I can apply everything using a Boo based DSL and keep my code clean of Attributes. I was told at the weekend to have a look at [PostSharp][2] as it's supposed to be a "better" solution. I've had a quick look at PostSharp, but I've been put off by the Attribute usage.
Has anyone tried both solutions and would care to share their experiences?
[1]: http://www.castleproject.org/container/index.html
[2]: http://www.postsharp.org/ | 0 |
62,804 | 09/15/2008 13:22:13 | 7,105 | 09/15/2008 13:10:37 | 1 | 0 | How to Convert XS Duration to TimeSpan in VB.Net? | Is there a standard library method that converts a string that has duration in the standard XS:Duration format into the .NET TimeSpan object?
For example, P0DT1H0M0S which represents a duration of one hour, is converted into New TimeSpan(0,1,0,0,0).
A Reverse converter does exist which works as follows:
Xml.XmlConvert.ToString(New TimeSpan(0,1,0,0,0))
The above expression will return P0DT1H0M0S.
| timespan | null | null | null | null | null | open | How to Convert XS Duration to TimeSpan in VB.Net?
===
Is there a standard library method that converts a string that has duration in the standard XS:Duration format into the .NET TimeSpan object?
For example, P0DT1H0M0S which represents a duration of one hour, is converted into New TimeSpan(0,1,0,0,0).
A Reverse converter does exist which works as follows:
Xml.XmlConvert.ToString(New TimeSpan(0,1,0,0,0))
The above expression will return P0DT1H0M0S.
| 0 |
62,810 | 09/15/2008 13:22:54 | 7,224 | 09/15/2008 13:22:54 | 1 | 0 | Exceptions not passed correctly thru RCF (using Boost.Serialization) | I use RCF with boost.serialization (why use RCF's copy when we already use the original?) It works OK, but when an exception is thrown in the server, it's not passed correctly to the client. Instead, I get an RCF::SerializationException quoting an `archive_exception` saying "class name too long". When I change the protocol to BsText, the exceptions is "unregistered class". When I change the protocol to SfBinary, it works.
I've registered RemoteException on both server and client like this:
BOOST_CLASS_VERSION(RCF::RemoteException, 0)
BOOST_CLASS_EXPORT(RCF::RemoteException)
I even tried serializing and deserializing a `boost::shared_ptr<RCF::RemoteException>` in the same test, and it works.
So how can I make RCF pass exceptions correctly without resorting to SF? | c++ | serialization | boost | rcf | null | null | open | Exceptions not passed correctly thru RCF (using Boost.Serialization)
===
I use RCF with boost.serialization (why use RCF's copy when we already use the original?) It works OK, but when an exception is thrown in the server, it's not passed correctly to the client. Instead, I get an RCF::SerializationException quoting an `archive_exception` saying "class name too long". When I change the protocol to BsText, the exceptions is "unregistered class". When I change the protocol to SfBinary, it works.
I've registered RemoteException on both server and client like this:
BOOST_CLASS_VERSION(RCF::RemoteException, 0)
BOOST_CLASS_EXPORT(RCF::RemoteException)
I even tried serializing and deserializing a `boost::shared_ptr<RCF::RemoteException>` in the same test, and it works.
So how can I make RCF pass exceptions correctly without resorting to SF? | 0 |
62,814 | 09/15/2008 13:23:05 | 7,086 | 09/15/2008 13:09:14 | 1 | 0 | Difference between binary semaphore and mutex. | Is there any difference between binary semaphore and mutex or they are essentialy same? | operating-system | linux | deiffer | null | null | null | open | Difference between binary semaphore and mutex.
===
Is there any difference between binary semaphore and mutex or they are essentialy same? | 0 |
62,816 | 09/15/2008 13:23:11 | 6,629 | 09/15/2008 12:23:22 | 11 | 3 | What could be good ways to deploy ASP.Net Web Applications? | We currently deploy web applications by creating a database and running SQL scripts through query analyzer. Then we copy the output from "publish website" and set up that website in IIS.
We have seen websetup in visual studio, but that part seems to be thinly documented. For example, we are not clear how to ask the user for IP and password of SQL server. We also tend to get websites deployed this way coming up under folders like http://example.com/project, instead of just http://example.com.
Then there are issues with AJAX.Net not being installed or some or the other patch not applied.
So far, we have physical access to the servers. Pretty soon though we are going to be shipping CDROMs. What is the practical tradeoff between manual intervention and automation? | asp.net | sql-server | deployment | web-applications | installer | null | open | What could be good ways to deploy ASP.Net Web Applications?
===
We currently deploy web applications by creating a database and running SQL scripts through query analyzer. Then we copy the output from "publish website" and set up that website in IIS.
We have seen websetup in visual studio, but that part seems to be thinly documented. For example, we are not clear how to ask the user for IP and password of SQL server. We also tend to get websites deployed this way coming up under folders like http://example.com/project, instead of just http://example.com.
Then there are issues with AJAX.Net not being installed or some or the other patch not applied.
So far, we have physical access to the servers. Pretty soon though we are going to be shipping CDROMs. What is the practical tradeoff between manual intervention and automation? | 0 |
62,832 | 09/15/2008 13:24:31 | 259 | 08/04/2008 08:10:58 | 351 | 33 | Reading data from a log file as a separate application is writing to it. | I would like to monitor a log file that is being written to by an application. I want to process the file line by line as, or shortly after, it is written. I have not found a way of detecting that a file has been extended after reaching eof.
The code needs to work on Mac and PC, and can be in any language, though I am most familiar with C++ and Perl.
Does anybody have a suggestion for the best way to do it? | c++ | perl | osx | file-io | logging | null | open | Reading data from a log file as a separate application is writing to it.
===
I would like to monitor a log file that is being written to by an application. I want to process the file line by line as, or shortly after, it is written. I have not found a way of detecting that a file has been extended after reaching eof.
The code needs to work on Mac and PC, and can be in any language, though I am most familiar with C++ and Perl.
Does anybody have a suggestion for the best way to do it? | 0 |
62,859 | 09/15/2008 13:27:13 | 7,160 | 09/15/2008 13:17:27 | 1 | 0 | Regression Testing with Rational Robot | Is it possible to run a pre-recorded Rational Robot script on a continuous integration server in a manner that doesn't require the machine to be physically logged into?
| build-process | build-automation | rational | null | null | null | open | Regression Testing with Rational Robot
===
Is it possible to run a pre-recorded Rational Robot script on a continuous integration server in a manner that doesn't require the machine to be physically logged into?
| 0 |
62,865 | 09/15/2008 13:27:27 | 7,172 | 09/15/2008 13:18:09 | 1 | 0 | Can we have customized "Date Prompt" in cognos8? | I am working with Cognos8 Report Studio. In my report there are two date prompts, (1) START date, (2) END date. Users can select two different dates or two same dates. But the report has valid data only for last business date of each month. For example, if Jan 31 is Sunday, valid data is available only for Jan 29 which is Friday(last business day of the month).
Can I have a customized "Date Prompt" where I can disable all other dates except the last business day of each month? Users should be able to select only month-end dates and no other dates? | reporting | date | prompt | cognos | null | null | open | Can we have customized "Date Prompt" in cognos8?
===
I am working with Cognos8 Report Studio. In my report there are two date prompts, (1) START date, (2) END date. Users can select two different dates or two same dates. But the report has valid data only for last business date of each month. For example, if Jan 31 is Sunday, valid data is available only for Jan 29 which is Friday(last business day of the month).
Can I have a customized "Date Prompt" where I can disable all other dates except the last business day of each month? Users should be able to select only month-end dates and no other dates? | 0 |
62,868 | 09/15/2008 13:27:37 | 7,282 | 09/15/2008 13:27:37 | 1 | 0 | Get mac address for remote computer under NT4 in C | Is it possible to get the mac address for a remote connection under NT4. The remote pc opens a socket connection into the program and I can get the ip address but need the mac.
I have tried using SendARP but this doesn't seem to be supported in NT4.
| c | mac-address | nt4 | null | null | null | open | Get mac address for remote computer under NT4 in C
===
Is it possible to get the mac address for a remote connection under NT4. The remote pc opens a socket connection into the program and I can get the ip address but need the mac.
I have tried using SendARP but this doesn't seem to be supported in NT4.
| 0 |
62,876 | 09/15/2008 13:28:54 | 5,662 | 09/10/2008 17:55:42 | 101 | 4 | What's the best way to save and retrieve binary files with Oracle 10g? | I'm about to implement a feature in our application that allows the user to 'upload' a PDF or Microsoft PowerPoint document, which the application will then make available to other users in a viewer (so they don't get to 'download' it in the 'Save as..' sense).
I already know how to save and retrieve arbitrary binary information in database columns, but as this will be a commonly used feature of our application I fear that solution would lead to enormously large database tables (as we know one of our customers will want to put video in PowerPoint documents).
I know there's a way to create a 'directory' object in Oracle, but is there a way to use this feature to store and retrieve binary files saved elsewhere on the Database Server?
Or am I being overly paranoid about the database size?
(for completeness our application is .Net WinForms using [CoreLab / DevArt OraDirect.Net drivers][1] to Oracle 10g)
Thanks for your help :o)
[1]: http://www.devart.com/oranet/ | .net | oracle | binaryfiles | null | null | null | open | What's the best way to save and retrieve binary files with Oracle 10g?
===
I'm about to implement a feature in our application that allows the user to 'upload' a PDF or Microsoft PowerPoint document, which the application will then make available to other users in a viewer (so they don't get to 'download' it in the 'Save as..' sense).
I already know how to save and retrieve arbitrary binary information in database columns, but as this will be a commonly used feature of our application I fear that solution would lead to enormously large database tables (as we know one of our customers will want to put video in PowerPoint documents).
I know there's a way to create a 'directory' object in Oracle, but is there a way to use this feature to store and retrieve binary files saved elsewhere on the Database Server?
Or am I being overly paranoid about the database size?
(for completeness our application is .Net WinForms using [CoreLab / DevArt OraDirect.Net drivers][1] to Oracle 10g)
Thanks for your help :o)
[1]: http://www.devart.com/oranet/ | 0 |
62,892 | 09/15/2008 13:31:05 | 4,753 | 09/05/2008 13:03:03 | 56 | 4 | Using Actionscript 3 to connect to a database | I'm looking for advice on how to dynamically create content in flash based on a database. Initially I was thinking that we would export the database to an XML file and use the built in Actionscript XML parser to take care of that, however the size of the XML file may prove prohibitive.
I have read about using an intermediary step (PHP, ASP) to retrieve information and pass it back as something that Actionscript can read, but I would prefer not to do that if possible. Has anyone worked with the [asSQL](http://code.google.com/p/assql/) libraries before? Or is there something else that I am missing? | flash | database-connection | null | null | null | null | open | Using Actionscript 3 to connect to a database
===
I'm looking for advice on how to dynamically create content in flash based on a database. Initially I was thinking that we would export the database to an XML file and use the built in Actionscript XML parser to take care of that, however the size of the XML file may prove prohibitive.
I have read about using an intermediary step (PHP, ASP) to retrieve information and pass it back as something that Actionscript can read, but I would prefer not to do that if possible. Has anyone worked with the [asSQL](http://code.google.com/p/assql/) libraries before? Or is there something else that I am missing? | 0 |
62,903 | 09/15/2008 13:33:22 | 6,801 | 09/15/2008 12:38:53 | 21 | 5 | Shareware marketing | I make a shareware application, a good one if I say so myself.
I have a listing on all major and minor download sites, which update automatically when I release a new version. My main problem is that I am only selling hundreds of licenses when I should be selling thousands.
I send out press releases to most newspapers, I get full page coverage in industry magazines and great reviews.
So what is next ? What can I do ? My biggest hurdle is that people think they are stuck with their old software.
So, what is a good way to market a shareware app ? I have no faith in Hollywood marketing. I have been on a few offer sites with 50% off the price and only getting 50% of that price, totally not worth it.
| marketing | shareware | null | null | null | null | open | Shareware marketing
===
I make a shareware application, a good one if I say so myself.
I have a listing on all major and minor download sites, which update automatically when I release a new version. My main problem is that I am only selling hundreds of licenses when I should be selling thousands.
I send out press releases to most newspapers, I get full page coverage in industry magazines and great reviews.
So what is next ? What can I do ? My biggest hurdle is that people think they are stuck with their old software.
So, what is a good way to market a shareware app ? I have no faith in Hollywood marketing. I have been on a few offer sites with 50% off the price and only getting 50% of that price, totally not worth it.
| 0 |
62,906 | 09/15/2008 13:33:35 | 672 | 08/07/2008 16:18:07 | 734 | 55 | Predefined Dialog templates in VB.NET? | In VB.NET is there a library of template dialogs I can use? It's easy to create a custom dialog and inherit from that, but it seems like there would be some templates for that sor tof thing.
I just need something simple like Save/Cancel, Yes/No, etc. | vb.net | null | null | null | null | null | open | Predefined Dialog templates in VB.NET?
===
In VB.NET is there a library of template dialogs I can use? It's easy to create a custom dialog and inherit from that, but it seems like there would be some templates for that sor tof thing.
I just need something simple like Save/Cancel, Yes/No, etc. | 0 |
62,916 | 09/15/2008 13:35:31 | 3,842 | 08/31/2008 10:43:25 | 1 | 0 | How do I get logout to work on RubyCAS-Server? | I have installed and setup RubyCAS-Server and RubyCAS-Client on my machine. Login works perfectly but when I try to logout I get this error message from the RubyCAS-Server:
Camping Problem!
CASServer::Controllers::Logout.GET
ActiveRecord::StatementInvalid Mysql::Error: Unknown column 'username' in 'where clause': SELECT * FROM `casserver_pgt` WHERE (username = 'lgs') :
I am using version 0.6 of the gem. Looking at the migrations in the RubyCAS-Server it looks like there shouldn't be a username column in that table at all.
Does anyone know why this is happening and what I can do about it? | ruby | sso | cas | null | null | null | open | How do I get logout to work on RubyCAS-Server?
===
I have installed and setup RubyCAS-Server and RubyCAS-Client on my machine. Login works perfectly but when I try to logout I get this error message from the RubyCAS-Server:
Camping Problem!
CASServer::Controllers::Logout.GET
ActiveRecord::StatementInvalid Mysql::Error: Unknown column 'username' in 'where clause': SELECT * FROM `casserver_pgt` WHERE (username = 'lgs') :
I am using version 0.6 of the gem. Looking at the migrations in the RubyCAS-Server it looks like there shouldn't be a username column in that table at all.
Does anyone know why this is happening and what I can do about it? | 0 |
62,918 | 09/15/2008 13:35:39 | 2,958 | 08/26/2008 08:58:45 | 153 | 8 | Using GCC from within VS 2005(8) IDE | **Is there a way to utilise the GCC compiler whilst still being able to develop via the Visual Studio IDE?**
Our project is cross-platform, and I quite frequently get into trouble from my [colleague][1] because I'm checking in code that's not standards compliant (this can be attributed to the VS compiler!).
I'd still like to be able to compile using the MS compiler, so I can continue debugging, etc, however I'd like to be able to *switch* to compile using GCC, just so that I can be sure I'm not breaking the build on other platforms.
**Is this possible?**
[1]: http://stackoverflow.com/users/912/jkp | c++ | visual-studio | gcc | crossplatform | visual-c++ | null | open | Using GCC from within VS 2005(8) IDE
===
**Is there a way to utilise the GCC compiler whilst still being able to develop via the Visual Studio IDE?**
Our project is cross-platform, and I quite frequently get into trouble from my [colleague][1] because I'm checking in code that's not standards compliant (this can be attributed to the VS compiler!).
I'd still like to be able to compile using the MS compiler, so I can continue debugging, etc, however I'd like to be able to *switch* to compile using GCC, just so that I can be sure I'm not breaking the build on other platforms.
**Is this possible?**
[1]: http://stackoverflow.com/users/912/jkp | 0 |
62,921 | 09/15/2008 13:35:54 | 7,086 | 09/15/2008 13:09:14 | 21 | 0 | Process vs Threads | How to decide whether to use threads or create seprate process altogether in your application to achieve parallelism. | operating-system | null | null | null | null | null | open | Process vs Threads
===
How to decide whether to use threads or create seprate process altogether in your application to achieve parallelism. | 0 |
62,936 | 09/15/2008 13:37:47 | 7,370 | 09/15/2008 13:37:47 | 1 | 0 | What does the number in brackets shown after unix command names mean ? | E.g man(1), find(3), updatedb(2) ?
what do these numbers mean ? | linux | command-line | null | null | null | 07/26/2012 12:47:24 | off topic | What does the number in brackets shown after unix command names mean ?
===
E.g man(1), find(3), updatedb(2) ?
what do these numbers mean ? | 2 |
62,946 | 09/15/2008 13:39:28 | 6,807 | 09/15/2008 12:39:45 | 1 | 0 | Misra standard for embedded software. | I have a requirement to make a large amount of code MISRA compliant.
First question: Can somebody to give an **estimation** for passing well written code for embedded system based on experience. I understand that "well written" is poorly defined and vague so i ask for raw estimation.
Second question: Any recommendation for tool that can be customizable (i.e allowing suppress specific warnings) and used in automatic build environment (i.e command line interface)
Any other useful suggestions that can help with this task.
Thanks Ilya. | c | null | null | null | null | null | open | Misra standard for embedded software.
===
I have a requirement to make a large amount of code MISRA compliant.
First question: Can somebody to give an **estimation** for passing well written code for embedded system based on experience. I understand that "well written" is poorly defined and vague so i ask for raw estimation.
Second question: Any recommendation for tool that can be customizable (i.e allowing suppress specific warnings) and used in automatic build environment (i.e command line interface)
Any other useful suggestions that can help with this task.
Thanks Ilya. | 0 |
62,951 | 09/15/2008 13:40:21 | 6,902 | 09/15/2008 12:47:42 | 1 | 0 | Implementing CollectionConstraints across NUnit versions | We've implemented a CollectionConstraint for Nunit in version 2.4.3 in C#. Some of our developers have already upgraded to version 2.4.7 though, and they get project creation errors when compiling. The error is "doMatch: no suitable method found to override". Any advice on how to get this constraint so it compiles version-agnostically? | c# | nunit | null | null | null | null | open | Implementing CollectionConstraints across NUnit versions
===
We've implemented a CollectionConstraint for Nunit in version 2.4.3 in C#. Some of our developers have already upgraded to version 2.4.7 though, and they get project creation errors when compiling. The error is "doMatch: no suitable method found to override". Any advice on how to get this constraint so it compiles version-agnostically? | 0 |
62,960 | 09/15/2008 13:41:16 | 7,205 | 09/15/2008 13:20:33 | 1 | 0 | What are the Basics of Networking/Sys-administration a Programmer Should Know? | Like:
* Learning the basic troubleshooting skills
* Learning how to configure a network
* Understanding different types of networks
* etc.
I was configuring a home network between my Windows and Ubuntu machine and I had a tough time doing it. I later figured out that both of them should be configured with the same subnet mask. I don't what that means, but it worked. That made me realize that I lack the basic networking/sysadmin skills and any help in terms of how-to's, links to tutorials that can help me learn is very much appreciated.
And is there any good certification exam that a programmer can take which covers the basic networking concepts and helps him/her build a strong foundation? | programmer-skills | networking | system-administration | null | null | null | open | What are the Basics of Networking/Sys-administration a Programmer Should Know?
===
Like:
* Learning the basic troubleshooting skills
* Learning how to configure a network
* Understanding different types of networks
* etc.
I was configuring a home network between my Windows and Ubuntu machine and I had a tough time doing it. I later figured out that both of them should be configured with the same subnet mask. I don't what that means, but it worked. That made me realize that I lack the basic networking/sysadmin skills and any help in terms of how-to's, links to tutorials that can help me learn is very much appreciated.
And is there any good certification exam that a programmer can take which covers the basic networking concepts and helps him/her build a strong foundation? | 0 |
62,963 | 09/15/2008 13:41:40 | 5,869 | 09/11/2008 14:38:28 | 1 | 1 | How do you extend Linq to SQL? | Last year, Scott Guthrie <a href="http://weblogs.asp.net/scottgu/archive/2007/07/31/linq-to-sql-debug-visualizer.aspx">stated</a> “You can actually override the raw SQL that LINQ to SQL uses if you want absolute control over the SQL executed”, but I can’t find documentation describing an extensibility method.
I would like to modify the following LINQ to SQL query:
<pre>using (NorthwindContext northwind = new NorthwindContext ()) {
var q = from row in northwind.Customers
let orderCount = row.Orders.Count ()
select new {
row.ContactName,
orderCount
};
}</pre>
Which results in the following TSQL:
<pre>SELECT [t0].[ContactName], (
SELECT COUNT(*)
FROM [dbo].[Orders] AS [t1]
WHERE [t1].[CustomerID] = [t0].[CustomerID]
) AS [orderCount]
FROM [dbo].[Customers] AS [t0]</pre>
To:
<pre>using (NorthwindContext northwind = new NorthwindContext ()) {
var q = from row in northwind.Customers.With (
TableHint.NoLock, TableHint.Index (0))
let orderCount = row.Orders.With (
TableHint.HoldLock).Count ()
select new {
row.ContactName,
orderCount
};
}</pre>
Which <em>would</em> result in the following TSQL:
<pre>SELECT [t0].[ContactName], (
SELECT COUNT(*)
FROM [dbo].[Orders] AS [t1] WITH (HOLDLOCK)
WHERE [t1].[CustomerID] = [t0].[CustomerID]
) AS [orderCount]
FROM [dbo].[Customers] AS [t0] WITH (NOLOCK, INDEX(0))</pre>
Using:
<pre>public static Table<TEntity> With<TEntity> (
this Table<TEntity> table,
params TableHint[] args) where TEntity : class {
//TODO: implement
return table;
}
public static EntitySet<TEntity> With<TEntity> (
this EntitySet<TEntity> entitySet,
params TableHint[] args) where TEntity : class {
//TODO: implement
return entitySet;
}</pre>
And
<pre>
public class TableHint {
//TODO: implement
public static TableHint NoLock;
public static TableHint HoldLock;
public static TableHint Index (int id) {
return null;
}
public static TableHint Index (string name) {
return null;
}
}</pre>
Using some type of LINQ to SQL extensibility, other than <a href="http://blogs.msdn.com/mattwar/archive/2008/05/04/mocks-nix-an-extensible-linq-to-sql-datacontext.aspx">this one</a>. Any ideas? | linq | linq-to-sql | null | null | null | null | open | How do you extend Linq to SQL?
===
Last year, Scott Guthrie <a href="http://weblogs.asp.net/scottgu/archive/2007/07/31/linq-to-sql-debug-visualizer.aspx">stated</a> “You can actually override the raw SQL that LINQ to SQL uses if you want absolute control over the SQL executed”, but I can’t find documentation describing an extensibility method.
I would like to modify the following LINQ to SQL query:
<pre>using (NorthwindContext northwind = new NorthwindContext ()) {
var q = from row in northwind.Customers
let orderCount = row.Orders.Count ()
select new {
row.ContactName,
orderCount
};
}</pre>
Which results in the following TSQL:
<pre>SELECT [t0].[ContactName], (
SELECT COUNT(*)
FROM [dbo].[Orders] AS [t1]
WHERE [t1].[CustomerID] = [t0].[CustomerID]
) AS [orderCount]
FROM [dbo].[Customers] AS [t0]</pre>
To:
<pre>using (NorthwindContext northwind = new NorthwindContext ()) {
var q = from row in northwind.Customers.With (
TableHint.NoLock, TableHint.Index (0))
let orderCount = row.Orders.With (
TableHint.HoldLock).Count ()
select new {
row.ContactName,
orderCount
};
}</pre>
Which <em>would</em> result in the following TSQL:
<pre>SELECT [t0].[ContactName], (
SELECT COUNT(*)
FROM [dbo].[Orders] AS [t1] WITH (HOLDLOCK)
WHERE [t1].[CustomerID] = [t0].[CustomerID]
) AS [orderCount]
FROM [dbo].[Customers] AS [t0] WITH (NOLOCK, INDEX(0))</pre>
Using:
<pre>public static Table<TEntity> With<TEntity> (
this Table<TEntity> table,
params TableHint[] args) where TEntity : class {
//TODO: implement
return table;
}
public static EntitySet<TEntity> With<TEntity> (
this EntitySet<TEntity> entitySet,
params TableHint[] args) where TEntity : class {
//TODO: implement
return entitySet;
}</pre>
And
<pre>
public class TableHint {
//TODO: implement
public static TableHint NoLock;
public static TableHint HoldLock;
public static TableHint Index (int id) {
return null;
}
public static TableHint Index (string name) {
return null;
}
}</pre>
Using some type of LINQ to SQL extensibility, other than <a href="http://blogs.msdn.com/mattwar/archive/2008/05/04/mocks-nix-an-extensible-linq-to-sql-datacontext.aspx">this one</a>. Any ideas? | 0 |
62,965 | 09/15/2008 13:41:56 | 27,870 | 09/15/2008 12:11:54 | 1 | 0 | ASP.NET WebService Returns Gibberish Characters When Throwing Exceptions | Greetings!
I have a web service (ASMX) and in it, a web method that does some work and throws an exception if the input wasn't valid.
[ScriptMethod]
[WebMethod]
public string MyWebMethod(string input)
{
string l_returnVal;
if (!ValidInput(input))
{
string l_errMsg = System.Web.HttpUtility.HtmlEncode(GetErrorMessage());
throw new Exception(l_errMsg);
}
// some work gets done...
return System.Web.HttpUtility.HtmlEncode(l_returnVal);
}
Back in the client-side JavaScript on the Web page, on the error callback function, I display my error:
function GetInputErrorCallback(error)
{
$get('input_error_msg_div').innerHTML = error.get_message();
}
This works great and when my Web method returns (a string), it always looks perfect. However, if one of my error messages from a my thrown exception contains a special character, it's displayed incorrectly in the browser. For example, if the error message were to contain the following:
**That input isn’t valid!** (that's an ASCII #146 in there)
It displays this:
**That input isn’t valid!**
Or:
**Do you like Hüsker Dü?** (ASCII # 252)
Becomes:
**Do you like Hüsker Dü?**
The content of the error messages comes from XML files with UTF-8 encoding:
<?xml version="1.0" encoding="UTF-8"?>
<ErrorMessages>
<Message id="invalid_input">Your input isn’t valid!</Message>
.
.
.
</ErrorMessages>
And as far as page encoding is concerned, in my Web.config, I have:
<globalization enableClientBasedCulture="true" fileEncoding="utf-8" />
I also have an HTTP Module to set L10n parameters:
Thread.CurrentThread.CurrentUICulture = m_selectedCulture;
Encoding l_Enc = Encoding.GetEncoding(m_selectedCulture.TextInfo.ANSICodePage);
HttpContext.Current.Response.ContentEncoding = l_Enc;
HttpContext.Current.Request.ContentEncoding = l_Enc;
I've tried disabling this HTTP Module but the result is the same.
The values returned by the web service (in the l_errMsg variable) look fine in the VS debugger. It's just once the client script has a hold of, it displays incorrectly. I've used Firebug to look at the response and special characters are mangled in there, too. So I find it pretty strange that strings returned by my web method look fine, even if there's special characters in them. Yet when I throw an exception from the web method, special characters in its message are incorrect. How can I fix this? Thanks in advance. | asp.net | web-services | ajax | exception | encoding | null | open | ASP.NET WebService Returns Gibberish Characters When Throwing Exceptions
===
Greetings!
I have a web service (ASMX) and in it, a web method that does some work and throws an exception if the input wasn't valid.
[ScriptMethod]
[WebMethod]
public string MyWebMethod(string input)
{
string l_returnVal;
if (!ValidInput(input))
{
string l_errMsg = System.Web.HttpUtility.HtmlEncode(GetErrorMessage());
throw new Exception(l_errMsg);
}
// some work gets done...
return System.Web.HttpUtility.HtmlEncode(l_returnVal);
}
Back in the client-side JavaScript on the Web page, on the error callback function, I display my error:
function GetInputErrorCallback(error)
{
$get('input_error_msg_div').innerHTML = error.get_message();
}
This works great and when my Web method returns (a string), it always looks perfect. However, if one of my error messages from a my thrown exception contains a special character, it's displayed incorrectly in the browser. For example, if the error message were to contain the following:
**That input isn’t valid!** (that's an ASCII #146 in there)
It displays this:
**That input isn’t valid!**
Or:
**Do you like Hüsker Dü?** (ASCII # 252)
Becomes:
**Do you like Hüsker Dü?**
The content of the error messages comes from XML files with UTF-8 encoding:
<?xml version="1.0" encoding="UTF-8"?>
<ErrorMessages>
<Message id="invalid_input">Your input isn’t valid!</Message>
.
.
.
</ErrorMessages>
And as far as page encoding is concerned, in my Web.config, I have:
<globalization enableClientBasedCulture="true" fileEncoding="utf-8" />
I also have an HTTP Module to set L10n parameters:
Thread.CurrentThread.CurrentUICulture = m_selectedCulture;
Encoding l_Enc = Encoding.GetEncoding(m_selectedCulture.TextInfo.ANSICodePage);
HttpContext.Current.Response.ContentEncoding = l_Enc;
HttpContext.Current.Request.ContentEncoding = l_Enc;
I've tried disabling this HTTP Module but the result is the same.
The values returned by the web service (in the l_errMsg variable) look fine in the VS debugger. It's just once the client script has a hold of, it displays incorrectly. I've used Firebug to look at the response and special characters are mangled in there, too. So I find it pretty strange that strings returned by my web method look fine, even if there's special characters in them. Yet when I throw an exception from the web method, special characters in its message are incorrect. How can I fix this? Thanks in advance. | 0 |
62,977 | 09/15/2008 13:43:15 | 7,425 | 09/15/2008 13:43:15 | 1 | 0 | How to write a C++ FireFox 3 plugin (not extension) on Windows? | Could someone write-up a step by step guide to developing a C++ based plugin for FireFox on Windows?
The links and examples on http://www.mozilla.org/projects/plugins/ are all old and inaccurate - the "NEW" link was added to the page in 2004.
The example could be anything, but I was thinking a plugin that lets JavaScript set the name and then displays "Hello {Name}". To show 2-way communication, it could have a property that returns the full salutation.
Though not as important, it would be nice if the plugin would work in Chrome too...
Thanks in advance.
| c++ | windows | firefox | plugins | null | null | open | How to write a C++ FireFox 3 plugin (not extension) on Windows?
===
Could someone write-up a step by step guide to developing a C++ based plugin for FireFox on Windows?
The links and examples on http://www.mozilla.org/projects/plugins/ are all old and inaccurate - the "NEW" link was added to the page in 2004.
The example could be anything, but I was thinking a plugin that lets JavaScript set the name and then displays "Hello {Name}". To show 2-way communication, it could have a property that returns the full salutation.
Though not as important, it would be nice if the plugin would work in Chrome too...
Thanks in advance.
| 0 |
62,987 | 09/15/2008 13:44:19 | 5,005 | 09/07/2008 10:04:13 | 11 | 1 | Best way of constructing dynamic sql queries in C#/.NET3.5? | A project I'm working on at the moment involves refactoring a C# Com Object which serves as a database access layer to some Sql 2005 databases.
The author of the existent code has built all the sql queries manually using a string and many if-statements to construct the fairly complex sql statement (~10 joins, >10 sub selects, ~15-25 where conditions and GroupBy's). The base table is always the same one, but the structure of joins, conditions and groupings depend on a set of parameters that are passed into my class/method.
Constructing the sql query like this does work but it obviously isn't a very elegant solution (and rather hard to read/understand and maintain as well)... I could just write a simple "querybuilder" myself but I am pretty sure that I am not the first one with this kind of problem, hence my questions:
- How do *you* construct your database queries?
- Does C# offer an easy way to dynamically build queries? | c# | sql | .net-3.5 | null | null | null | open | Best way of constructing dynamic sql queries in C#/.NET3.5?
===
A project I'm working on at the moment involves refactoring a C# Com Object which serves as a database access layer to some Sql 2005 databases.
The author of the existent code has built all the sql queries manually using a string and many if-statements to construct the fairly complex sql statement (~10 joins, >10 sub selects, ~15-25 where conditions and GroupBy's). The base table is always the same one, but the structure of joins, conditions and groupings depend on a set of parameters that are passed into my class/method.
Constructing the sql query like this does work but it obviously isn't a very elegant solution (and rather hard to read/understand and maintain as well)... I could just write a simple "querybuilder" myself but I am pretty sure that I am not the first one with this kind of problem, hence my questions:
- How do *you* construct your database queries?
- Does C# offer an easy way to dynamically build queries? | 0 |
62,995 | 09/15/2008 13:45:03 | 7,215 | 09/15/2008 13:22:15 | 1 | 0 | Access Global .resx file in ASP.Net View Page | I am currently building in Version 3.5 of the .Net framework and I have a resource (.resx) file that I am trying to access in a web application. I have exposed the .resx properties as public access modifiers and am able to access these properties in the controller files or other .cs files in the web app. My question is this: Is it possible to access the name/value pairs within my view page? I'd like to do something like this...
text="<%$ Resources: Namespace.ResourceFileName, NAME %>"
or some other similar method in the view page. | asp.net | resources | localization | null | null | null | open | Access Global .resx file in ASP.Net View Page
===
I am currently building in Version 3.5 of the .Net framework and I have a resource (.resx) file that I am trying to access in a web application. I have exposed the .resx properties as public access modifiers and am able to access these properties in the controller files or other .cs files in the web app. My question is this: Is it possible to access the name/value pairs within my view page? I'd like to do something like this...
text="<%$ Resources: Namespace.ResourceFileName, NAME %>"
or some other similar method in the view page. | 0 |
63,008 | 09/15/2008 13:46:42 | 6,389 | 09/15/2008 07:25:16 | 1 | 0 | C# SQL Restore database to default data location | I'm writing a C# application which downloads a compressed database backup via FTP. The application then needs to extract the backup and restore it to the default database location.
Since I won't know what version of SQL will be installed on the machine where the application runs, I need to be able to find the default location based on the instance name (which is in the config file).
The examples I found all had a registry key which they read, but this won't work, since this assumes that only one instance of SQL is installed.
Another expample, created a database, and then read that database's file properties, before deleting the database again. That's just cumbersome,
I did find something in the .NET framework which should work, ie:
<pre><code>Microsoft.SqlServer.Management.Smo.Server(ServerName).Settings.DefaultFile</code></pre>
The problem is that this is returning empty strings, which does not help.
I also need to find out the NT account under which the SQL service is running, so that I can grant read access to that user once I have the file extracted.
| c# | sql | null | null | null | null | open | C# SQL Restore database to default data location
===
I'm writing a C# application which downloads a compressed database backup via FTP. The application then needs to extract the backup and restore it to the default database location.
Since I won't know what version of SQL will be installed on the machine where the application runs, I need to be able to find the default location based on the instance name (which is in the config file).
The examples I found all had a registry key which they read, but this won't work, since this assumes that only one instance of SQL is installed.
Another expample, created a database, and then read that database's file properties, before deleting the database again. That's just cumbersome,
I did find something in the .NET framework which should work, ie:
<pre><code>Microsoft.SqlServer.Management.Smo.Server(ServerName).Settings.DefaultFile</code></pre>
The problem is that this is returning empty strings, which does not help.
I also need to find out the NT account under which the SQL service is running, so that I can grant read access to that user once I have the file extracted.
| 0 |
63,030 | 09/15/2008 13:48:27 | 6,583 | 09/15/2008 12:18:30 | 31 | 1 | BufferedImage in IKVM | What is the best and/or easiest way to replace the missing BufferedImage functionality for a Java project I am converting to .NET with IKVM?
I'm basically getting "cli.System.NotImplementedException: BufferedImage" exceptions when running the application, which otherwise runs fine. | .net | java | ikvm | null | null | null | open | BufferedImage in IKVM
===
What is the best and/or easiest way to replace the missing BufferedImage functionality for a Java project I am converting to .NET with IKVM?
I'm basically getting "cli.System.NotImplementedException: BufferedImage" exceptions when running the application, which otherwise runs fine. | 0 |
63,038 | 09/15/2008 13:49:16 | 7,478 | 09/15/2008 13:49:16 | 1 | 0 | AS3 FTP Programming and the Socket and ByteArray Classes | Sorry for the subject line sounding like an even nerdier Harry Potter title.
I'm trying to use AS3's Socket class to write a simple FTP program to export as an AIR app in Flex Builder 3. I'm using an FTP server on my local network to test the program. I can successfully connect to the server (the easy part) but I can't send any commands. I'm pretty sure that you have to use the ByteArray class to send these commands but there's some crucial piece of information that I'm missing apparently. Does anyone know how to do this? Thanks!
Dave | actionscript-3 | ftp | socket | bytearray | null | null | open | AS3 FTP Programming and the Socket and ByteArray Classes
===
Sorry for the subject line sounding like an even nerdier Harry Potter title.
I'm trying to use AS3's Socket class to write a simple FTP program to export as an AIR app in Flex Builder 3. I'm using an FTP server on my local network to test the program. I can successfully connect to the server (the easy part) but I can't send any commands. I'm pretty sure that you have to use the ByteArray class to send these commands but there's some crucial piece of information that I'm missing apparently. Does anyone know how to do this? Thanks!
Dave | 0 |
63,042 | 09/15/2008 13:49:50 | 7,031 | 09/15/2008 13:02:32 | 1 | 0 | How do I learn Java5 or Java6? | I'm a very experienced Java programmer who has spent my entire time working with Java 1.4 and earlier. Where can I find a quick reference that will give me everything I need to know about the new features in Java5 and later in a quick reference? | java | null | null | null | null | null | open | How do I learn Java5 or Java6?
===
I'm a very experienced Java programmer who has spent my entire time working with Java 1.4 and earlier. Where can I find a quick reference that will give me everything I need to know about the new features in Java5 and later in a quick reference? | 0 |
63,043 | 09/15/2008 13:49:51 | 7,375 | 09/15/2008 13:38:04 | 1 | 1 | WCF Datacontract free serialization (3.5 SP1) | Has anybody got this to actually work? Documentation is non existent on how to enable this feature and I get missing attribute exceptions despite having a 3.5 SP1 project. | wcf | documentation | serialization | null | null | null | open | WCF Datacontract free serialization (3.5 SP1)
===
Has anybody got this to actually work? Documentation is non existent on how to enable this feature and I get missing attribute exceptions despite having a 3.5 SP1 project. | 0 |
63,086 | 09/15/2008 13:55:14 | 1,231 | 08/13/2008 14:34:47 | 21 | 3 | Is there a way around coding in Python without the tab, indent & whitespace criteria? | I want to start using Python for small projects but the fact that a misplaced tab or indent can throw a compile error is really getting on my nerves. Is there some type of setting to turn this off?
I'm currently using NotePad++. Is there maybe an IDE that would take care of the tabs and indenting? | python | null | null | null | null | null | open | Is there a way around coding in Python without the tab, indent & whitespace criteria?
===
I want to start using Python for small projects but the fact that a misplaced tab or indent can throw a compile error is really getting on my nerves. Is there some type of setting to turn this off?
I'm currently using NotePad++. Is there maybe an IDE that would take care of the tabs and indenting? | 0 |
63,090 | 09/15/2008 13:55:44 | 4,690 | 09/05/2008 08:18:52 | 11 | 3 | Surrogate Vs. Natural/Business Keys | Here we go again, the old argument still arises... we'd better have a business key as a primary key, or we'd rather have a surrogate id (i.e. an SQL Server identity) with a unique constraint on the business key field? Please, provide examples or proof to support your theory. | database-design | keys | null | null | null | null | open | Surrogate Vs. Natural/Business Keys
===
Here we go again, the old argument still arises... we'd better have a business key as a primary key, or we'd rather have a surrogate id (i.e. an SQL Server identity) with a unique constraint on the business key field? Please, provide examples or proof to support your theory. | 0 |
63,100 | 09/15/2008 13:57:30 | 1,801 | 08/18/2008 16:01:48 | 184 | 21 | Scrum Process Management - tips, pitfalls, ideas | I've been doing scrum with a team for a while, but things seem messy for whatever reasons. I've been thinking on how they can be changed and have a couple of questions that would like to raise here.
First, what should be the role of testers, designers and non-developers as a whole in the scrum process? If they are equal to other team members a couple of issues arise. Designers and testers usually work on a task after development is done, so they cannot adequately plan for a sprint because of this dependency.
Second, we have deadlines. These are strict and have a lot of impact on prioritization. The end result is backlog changes in the middle of a sprint because of deadline changes, or bad results in the end of the sprint.
We also have a lot of non-technical work like customer support that has to be done in the meantime and cannot be planned as it varies a lot.
So I'm thinking that the team structure, culture and practices are kind of not compatible with scrum. Scrum for me is a process management tool for teams working on the development of a single software product.
What do you guys think about applying it in more specific and complicated scenarios, do you have any experience to share? | agile | scrum | process-management | development-process | null | null | open | Scrum Process Management - tips, pitfalls, ideas
===
I've been doing scrum with a team for a while, but things seem messy for whatever reasons. I've been thinking on how they can be changed and have a couple of questions that would like to raise here.
First, what should be the role of testers, designers and non-developers as a whole in the scrum process? If they are equal to other team members a couple of issues arise. Designers and testers usually work on a task after development is done, so they cannot adequately plan for a sprint because of this dependency.
Second, we have deadlines. These are strict and have a lot of impact on prioritization. The end result is backlog changes in the middle of a sprint because of deadline changes, or bad results in the end of the sprint.
We also have a lot of non-technical work like customer support that has to be done in the meantime and cannot be planned as it varies a lot.
So I'm thinking that the team structure, culture and practices are kind of not compatible with scrum. Scrum for me is a process management tool for teams working on the development of a single software product.
What do you guys think about applying it in more specific and complicated scenarios, do you have any experience to share? | 0 |
63,104 | 09/15/2008 13:57:47 | 6,918 | 09/15/2008 12:49:57 | 1 | 1 | Smarter Vim recovery? | When a previous Vim session crashed, you are greeted with the "Swap file ... already exists!" for each and every file that was open in the previous session.
Can you make this Vim recovery prompt smarter? (Without switching off recovery!) Specifically, I'm thinking of:
- If the swapped version does not contain unmodified changes and the editing process is no longer running, can you make Vim automatically delete the swap file?
- Can you automate the suggested process of saving the recovered file under a new name, merging it with file on disk and then deleting the old swap file, so that minimal interaction is required? Especially when the swap version and the disk version are the same, everything should be automatic.
I discovered the `SwapExists` autocommand but I don't know if it can help with these tasks. | vim | recovery | null | null | null | null | open | Smarter Vim recovery?
===
When a previous Vim session crashed, you are greeted with the "Swap file ... already exists!" for each and every file that was open in the previous session.
Can you make this Vim recovery prompt smarter? (Without switching off recovery!) Specifically, I'm thinking of:
- If the swapped version does not contain unmodified changes and the editing process is no longer running, can you make Vim automatically delete the swap file?
- Can you automate the suggested process of saving the recovered file under a new name, merging it with file on disk and then deleting the old swap file, so that minimal interaction is required? Especially when the swap version and the disk version are the same, everything should be automatic.
I discovered the `SwapExists` autocommand but I don't know if it can help with these tasks. | 0 |
63,125 | 09/15/2008 14:00:23 | 7,473 | 09/15/2008 13:48:50 | 1 | 0 | How to remove this parallel heirachy | I'm trying to find the best design for the following scenario - which is an application to store results of dance comeptitions.
An event contains multiple rounds, each round contains a number of performances (one per dance). Each performance is judged by many judges, who return a scoresheet.
There are two types of round, a final round (contain 6 or less dance couples) or a normal round (containing more than 6 dance couples). Each requires slightly different behaviour and data.
In the case of a final round, each scoresheet contains an orderd list of the 6 couples in the final showing which couple the judge placed 1st, 2nd etc. I call these placings "a scoresheet contains 6 placings"
In the case of a normal round, each scoresheet contains a non-ordered set of M couples (M < the number of couples entered into the round - exact value determined by the competition organiser). I call these recalls "a score sheet as M recalls"
My naive-version of this is implemented as
Event - has_one final_round, has_many rounds
final_round - has_many final_performances
final_performance - has_many final_scoresheets
final_scoresheet - has_many placings
round - has_many perforomances
performance has_many scoresheets
scoresheet has_many recalls
However I do not like the duplication that this requires, and I have several parallel hierachies (for round, performance and scoresheet) which is going to be a pain to maintain. | inheritance | oop | null | null | null | null | open | How to remove this parallel heirachy
===
I'm trying to find the best design for the following scenario - which is an application to store results of dance comeptitions.
An event contains multiple rounds, each round contains a number of performances (one per dance). Each performance is judged by many judges, who return a scoresheet.
There are two types of round, a final round (contain 6 or less dance couples) or a normal round (containing more than 6 dance couples). Each requires slightly different behaviour and data.
In the case of a final round, each scoresheet contains an orderd list of the 6 couples in the final showing which couple the judge placed 1st, 2nd etc. I call these placings "a scoresheet contains 6 placings"
In the case of a normal round, each scoresheet contains a non-ordered set of M couples (M < the number of couples entered into the round - exact value determined by the competition organiser). I call these recalls "a score sheet as M recalls"
My naive-version of this is implemented as
Event - has_one final_round, has_many rounds
final_round - has_many final_performances
final_performance - has_many final_scoresheets
final_scoresheet - has_many placings
round - has_many perforomances
performance has_many scoresheets
scoresheet has_many recalls
However I do not like the duplication that this requires, and I have several parallel hierachies (for round, performance and scoresheet) which is going to be a pain to maintain. | 0 |
63,126 | 09/15/2008 14:00:25 | 6,163 | 09/12/2008 18:09:02 | 8 | 0 | Blocking part of a website | I am trying to block Google Reader:
reader.google.com
www.google.com/reader
I blocked reader.google.com by changing my /etc/hosts file (this is for a Mac)
Is there any way to block www.google.com/reader without buying software?
Note this is for Safari so Greasemonkey won't work, and Leopard's Parental Controls throttle the CPU when they are turned on.
Also I've tried OpenDNS, which is awesome, but doesn't work for this...
Any thoughts? | dns | osx-leopard | google | null | null | null | open | Blocking part of a website
===
I am trying to block Google Reader:
reader.google.com
www.google.com/reader
I blocked reader.google.com by changing my /etc/hosts file (this is for a Mac)
Is there any way to block www.google.com/reader without buying software?
Note this is for Safari so Greasemonkey won't work, and Leopard's Parental Controls throttle the CPU when they are turned on.
Also I've tried OpenDNS, which is awesome, but doesn't work for this...
Any thoughts? | 0 |
63,130 | 09/15/2008 14:00:49 | 7,585 | 09/15/2008 14:00:49 | 1 | 0 | Add Custom TextboxCell to a DataGridView control that contains a button to open the FileDialog | I would like to add a DataGridViewTextBoxCell cell to a DataGridViewCell control, but as well as being able to type in the text cell as normal it must also contain a '...' button that once clicks brings up the OpenFileDialog window to allow the user to select a file. Once selected, the text cell will be populated with the full file path.
What is the best way to go about this?
Thanks | .net | .net-2.0 | null | null | null | null | open | Add Custom TextboxCell to a DataGridView control that contains a button to open the FileDialog
===
I would like to add a DataGridViewTextBoxCell cell to a DataGridViewCell control, but as well as being able to type in the text cell as normal it must also contain a '...' button that once clicks brings up the OpenFileDialog window to allow the user to select a file. Once selected, the text cell will be populated with the full file path.
What is the best way to go about this?
Thanks | 0 |
63,142 | 09/15/2008 14:02:00 | 3,012 | 08/26/2008 11:55:24 | 330 | 13 | The Reuse/Release Equivalence Principle | What is the Reuse/Release Equivalence Principle and why is it important? | oop | null | null | null | null | null | open | The Reuse/Release Equivalence Principle
===
What is the Reuse/Release Equivalence Principle and why is it important? | 0 |
63,146 | 09/15/2008 14:02:18 | 4,172 | 09/02/2008 08:54:52 | 38 | 7 | How to handle file uploads to a dedicated image server? | I got a webserver with a running application. There's a webpage with a form: some text data and a file upload field. Now, what I would like to have is it working like this:
The file is sent to the dedicated server, diffrent then the one application is running on. The server should return some kind of path (or anything that identifies the uploaded and saved file and allows to create an URL). Then, both this path and user-filled data should be submitted to the webserver with application, for any kind of database storage.
Problem is, there are 2 diffrent servers, so I can't upload the file with javascript, can I? Another way would be just to use `iframe` and put the upload form in there - but then I think I can't access the result of the upload (still inside the iframe) with javascript to pass the file path to my main server.
I could also just upload the file to same server my application is running on and then just `rsync` it to the other one - but I'd like to avoid it if I can, trying to minimalize the traffic actually :)
How do you handle such thing in your applications? | webserver | file-upload | null | null | null | null | open | How to handle file uploads to a dedicated image server?
===
I got a webserver with a running application. There's a webpage with a form: some text data and a file upload field. Now, what I would like to have is it working like this:
The file is sent to the dedicated server, diffrent then the one application is running on. The server should return some kind of path (or anything that identifies the uploaded and saved file and allows to create an URL). Then, both this path and user-filled data should be submitted to the webserver with application, for any kind of database storage.
Problem is, there are 2 diffrent servers, so I can't upload the file with javascript, can I? Another way would be just to use `iframe` and put the upload form in there - but then I think I can't access the result of the upload (still inside the iframe) with javascript to pass the file path to my main server.
I could also just upload the file to same server my application is running on and then just `rsync` it to the other one - but I'd like to avoid it if I can, trying to minimalize the traffic actually :)
How do you handle such thing in your applications? | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.