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
8,142
08/11/2008 19:50:31
380
08/05/2008 10:39:18
355
48
When should I use Compiled LINQ vs Normal LINQ
I just read up on a performance of LINQ, and there is a HUGE amount to be gained by using Compiled LINQ. Now, why won't I always use compiled LINQ?
.net
linq
null
null
null
null
open
When should I use Compiled LINQ vs Normal LINQ === I just read up on a performance of LINQ, and there is a HUGE amount to be gained by using Compiled LINQ. Now, why won't I always use compiled LINQ?
0
8,145
08/11/2008 19:53:16
685
08/07/2008 19:18:05
1
0
How do I find the high water mark (for sessions) on Oracle 9i
How can I find the high water mark (the historical maximum number of concurrent users) in an oracle database (9i).
oracle
null
null
null
null
null
open
How do I find the high water mark (for sessions) on Oracle 9i === How can I find the high water mark (the historical maximum number of concurrent users) in an oracle database (9i).
0
8,147
08/11/2008 19:54:20
193
08/03/2008 10:44:38
186
22
How do you get a custom id to render using HtmlHelper in MVC
Using preview 4 of [ASP.NET MVC][1] Code like: <%= Html.CheckBox( "myCheckBox", "Click Here", "True", false ) %> only outputs: <input type="checkbox" value="True" name="myCheckBox" /> There is a `name` there for the form post back but no `id` for javascript or labels :-( I was hoping that changing it to: Html.CheckBox( "myCheckBox", "Click Here", "True", false, new { id="myCheckBox" } ) would work - but instead I get an exception: System.ArgumentException: An item with the same key has already been added. As if there was already an id somewhere in a collection somewhere - I'm stumped! The full exception for anyone interested follows (hey - wouldn't it be nice to attach files in here): System.ArgumentException: An item with the same key has already been added. at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add) at System.Web.Routing.RouteValueDictionary.Add(String key, Object value) at System.Web.Mvc.TagBuilder2.CreateInputTag(HtmlInputType inputType, String name, RouteValueDictionary attributes) at System.Web.Mvc.CheckBoxBuilder.CheckBox(String htmlName, RouteValueDictionary htmlAttributes) at System.Web.Mvc.CheckBoxBuilder.CheckBox(String htmlName, String text, String value, Boolean isChecked, RouteValueDictionary htmlAttributes) at System.Web.Mvc.CheckBoxExtensions.CheckBox(HtmlHelper helper, String htmlName, String text, String value, Boolean isChecked, Object htmlAttributes) at ASP.views_account_termsandconditions_ascx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in c:\dev\myProject\Views\Account\Edit.ascx:line 108 at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Control.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Page.Render(HtmlTextWriter writer) at System.Web.Mvc.ViewPage.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) [1]: http://asp.net/mvc
asp.netmvc
null
null
null
null
null
open
How do you get a custom id to render using HtmlHelper in MVC === Using preview 4 of [ASP.NET MVC][1] Code like: <%= Html.CheckBox( "myCheckBox", "Click Here", "True", false ) %> only outputs: <input type="checkbox" value="True" name="myCheckBox" /> There is a `name` there for the form post back but no `id` for javascript or labels :-( I was hoping that changing it to: Html.CheckBox( "myCheckBox", "Click Here", "True", false, new { id="myCheckBox" } ) would work - but instead I get an exception: System.ArgumentException: An item with the same key has already been added. As if there was already an id somewhere in a collection somewhere - I'm stumped! The full exception for anyone interested follows (hey - wouldn't it be nice to attach files in here): System.ArgumentException: An item with the same key has already been added. at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add) at System.Web.Routing.RouteValueDictionary.Add(String key, Object value) at System.Web.Mvc.TagBuilder2.CreateInputTag(HtmlInputType inputType, String name, RouteValueDictionary attributes) at System.Web.Mvc.CheckBoxBuilder.CheckBox(String htmlName, RouteValueDictionary htmlAttributes) at System.Web.Mvc.CheckBoxBuilder.CheckBox(String htmlName, String text, String value, Boolean isChecked, RouteValueDictionary htmlAttributes) at System.Web.Mvc.CheckBoxExtensions.CheckBox(HtmlHelper helper, String htmlName, String text, String value, Boolean isChecked, Object htmlAttributes) at ASP.views_account_termsandconditions_ascx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in c:\dev\myProject\Views\Account\Edit.ascx:line 108 at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Control.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) at System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) at System.Web.UI.Page.Render(HtmlTextWriter writer) at System.Web.Mvc.ViewPage.Render(HtmlTextWriter writer) at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) at System.Web.UI.Control.RenderControl(HtmlTextWriter writer) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) [1]: http://asp.net/mvc
0
8,154
08/11/2008 19:59:32
736
08/08/2008 13:06:17
1
0
Pylons error - 'MySQL server has gone away'
[I hope this isn't too obscure&hellip; I'll ask the newsgroup if nobody knows here] I'm using Pylons (a python framework) to serve a simple web application, but it seems to die from time to time, with this in the error log: (2006, 'MySQL server has gone away') I did a bit of checking, and saw that this was because the connections to MySQL were not being renewed. This shouldn't be a problem though, because the sqlalchemy.pool_recycle in the config file should automatically keep it alive. The default was 3600, but I dialed it back to 1800 because of this problem. It helped a bit, but 3600 *should* be fine according to the docs. The errors still happen semi-regularly. I don't want to lower it too much though and DOS my own database :). Maybe something in my MySQL config is goofy? Not sure where to look exactly. Other relevant details: Python 2.5 Pylons: 0.9.6.2 (w/ sql_alchemy) MySQL: 5.0.51
python
mysql
pylons
null
null
null
open
Pylons error - 'MySQL server has gone away' === [I hope this isn't too obscure&hellip; I'll ask the newsgroup if nobody knows here] I'm using Pylons (a python framework) to serve a simple web application, but it seems to die from time to time, with this in the error log: (2006, 'MySQL server has gone away') I did a bit of checking, and saw that this was because the connections to MySQL were not being renewed. This shouldn't be a problem though, because the sqlalchemy.pool_recycle in the config file should automatically keep it alive. The default was 3600, but I dialed it back to 1800 because of this problem. It helped a bit, but 3600 *should* be fine according to the docs. The errors still happen semi-regularly. I don't want to lower it too much though and DOS my own database :). Maybe something in my MySQL config is goofy? Not sure where to look exactly. Other relevant details: Python 2.5 Pylons: 0.9.6.2 (w/ sql_alchemy) MySQL: 5.0.51
0
8,166
08/11/2008 20:08:03
547
08/06/2008 16:09:22
117
15
MySQL replication: if i don't specify any databases, will log_bin log EVERYTHING? (i want that)
I'm setting up replication for a server which runs a bunch of databases (one per client) and plan on adding more all the time, on my.cnf, Instead of having: binlog-do-db = databasename 1 binlog-do-db = databasename 2 binlog-do-db = databasename 3 ... binlog-do-db = databasename n can I rather just have binlog-ignore-db = mysql binlog-ignore-db = informationschema (and no database to log specified) and assume that everything else is logged? cheers, /mp
mysql
replication
null
null
null
null
open
MySQL replication: if i don't specify any databases, will log_bin log EVERYTHING? (i want that) === I'm setting up replication for a server which runs a bunch of databases (one per client) and plan on adding more all the time, on my.cnf, Instead of having: binlog-do-db = databasename 1 binlog-do-db = databasename 2 binlog-do-db = databasename 3 ... binlog-do-db = databasename n can I rather just have binlog-ignore-db = mysql binlog-ignore-db = informationschema (and no database to log specified) and assume that everything else is logged? cheers, /mp
0
8,170
08/11/2008 20:10:38
92
08/01/2008 17:55:41
1,814
52
Best MS DOS tutorial for beginners?
I'm trying to find a well written understandable MS DOS tutorial for beginners trying to use the command prompt. I'm working with one such beginner and they keep calling me with questions about commands, and I want a concise tutorial or reference to send them to. I tried google, with many combinations of the likely search terms, and got nothing but garbage. There's a lot of documents out there, but none of them are what I'd call *good*. Does anyone happen to know of a great tutorial for how to use the windows command prompt?
tutorial
resources
teaching
null
null
null
open
Best MS DOS tutorial for beginners? === I'm trying to find a well written understandable MS DOS tutorial for beginners trying to use the command prompt. I'm working with one such beginner and they keep calling me with questions about commands, and I want a concise tutorial or reference to send them to. I tried google, with many combinations of the likely search terms, and got nothing but garbage. There's a lot of documents out there, but none of them are what I'd call *good*. Does anyone happen to know of a great tutorial for how to use the windows command prompt?
0
8,213
08/11/2008 20:59:11
727
08/08/2008 12:16:17
41
7
Generate Insert SQL statements from a csv file
I need to import a csv file into Firebird and I've spent a couple of hours trying out some tools and none fit my needs. The main problem is that all the tools I've been trying like [EMS Data Import][1] and [Firebird Data Wizard][2] expect that my csv file contains all the information needed by my Table. I need to write some custom SQL in the insert statement, for example, I have a cvs file with the city name, but as my database already has all the cities in another table (normalized), I need to write a subselect in the insert statement to lookup for the city and write its ID, also I have a stored procedure to cread GUIDS. My Insert statement would be something like this: INSERT INTO PERSON (ID, NAME, CITY_ID) VALUES((SELECT NEW_GUID FROM CREATE_GUID), :NAME, (SELECT CITY_ID FROM CITY WHERE NAME = :CITY_NAME) I know that it is very easy to write an application to do this, but I don't like to reinvent the wheel, and I'm sure that there are some tools out there to do it. Can you guys give me some advice? [1]: http://www.sqlmanager.net/products/ibfb/dataimport [2]: http://www.sqlmaestro.com/products/firebird/datawizard/help/06_01_05_csv/
sql
csv
firebird
null
null
null
open
Generate Insert SQL statements from a csv file === I need to import a csv file into Firebird and I've spent a couple of hours trying out some tools and none fit my needs. The main problem is that all the tools I've been trying like [EMS Data Import][1] and [Firebird Data Wizard][2] expect that my csv file contains all the information needed by my Table. I need to write some custom SQL in the insert statement, for example, I have a cvs file with the city name, but as my database already has all the cities in another table (normalized), I need to write a subselect in the insert statement to lookup for the city and write its ID, also I have a stored procedure to cread GUIDS. My Insert statement would be something like this: INSERT INTO PERSON (ID, NAME, CITY_ID) VALUES((SELECT NEW_GUID FROM CREATE_GUID), :NAME, (SELECT CITY_ID FROM CITY WHERE NAME = :CITY_NAME) I know that it is very easy to write an application to do this, but I don't like to reinvent the wheel, and I'm sure that there are some tools out there to do it. Can you guys give me some advice? [1]: http://www.sqlmanager.net/products/ibfb/dataimport [2]: http://www.sqlmaestro.com/products/firebird/datawizard/help/06_01_05_csv/
0
8,214
08/11/2008 21:00:40
708
08/08/2008 06:10:02
15
0
Instrumenting a UI
How are you instrumenting your UI's? In the past I've read that people have instrumented their user interfaces, but what I haven't found is examples or tips on *how* to instrument a UI. - How are you instrumenting your UI? - What format are you storing the instrumentation? - How are you processing the instrumented data? - How are you keeping your UI code clean with this instrumentation logic? Specifically, I am implementing my UI in WPF, so this will provide extra challenges compared to instrumenting a web-based application. (i.e. need to transfer the instrumented data back to a central location, etc). That said, I feel the technology may provide an easier implementation of instrumentation via concepts like attached properties. - Have you instrumented a WPF application? Do you have any tips on how this can be achieved?
ui
gui
wpf
null
null
null
open
Instrumenting a UI === How are you instrumenting your UI's? In the past I've read that people have instrumented their user interfaces, but what I haven't found is examples or tips on *how* to instrument a UI. - How are you instrumenting your UI? - What format are you storing the instrumentation? - How are you processing the instrumented data? - How are you keeping your UI code clean with this instrumentation logic? Specifically, I am implementing my UI in WPF, so this will provide extra challenges compared to instrumenting a web-based application. (i.e. need to transfer the instrumented data back to a central location, etc). That said, I feel the technology may provide an easier implementation of instrumentation via concepts like attached properties. - Have you instrumented a WPF application? Do you have any tips on how this can be achieved?
0
8,219
08/11/2008 21:07:44
782
08/08/2008 21:30:06
143
7
Test Distribution
At my work we are running a group of tests that consist of about 3,000 separate test cases. Previously we were running this entire test suite on one machine, which took about 24-72 hours to complete the entire test run. We now have created our own system for grouping and distributing the tests among about three separate machines and the tests are prioritized so that the core tests get run first for more immediate results and the extra tests run when there is an available machine. I am curious if anyone has found a good way to distribute their tests among several machines to reduce total test time for a complete run and what tools were used to achieve that. I've done some research and it looks like TestNG is [moving in this direction][1], but it looks like it is still under quite a bit of development. We don't plan on rewriting any of our tests, but as we add new tests and test new products or add-ons I'd like to be able to deal with the fact that we are working with very large numbers of tests. On the other hand, if we can find a tool that would help distribute our Junit 3.x tests even in a very basic fashion, that *would* be helpful since we wouldn't have to maintain our own tooling to do that. [1]: http://beust.com/weblog/archives/000362.html
testing
distributedtesting
java
enterprise
null
null
open
Test Distribution === At my work we are running a group of tests that consist of about 3,000 separate test cases. Previously we were running this entire test suite on one machine, which took about 24-72 hours to complete the entire test run. We now have created our own system for grouping and distributing the tests among about three separate machines and the tests are prioritized so that the core tests get run first for more immediate results and the extra tests run when there is an available machine. I am curious if anyone has found a good way to distribute their tests among several machines to reduce total test time for a complete run and what tools were used to achieve that. I've done some research and it looks like TestNG is [moving in this direction][1], but it looks like it is still under quite a bit of development. We don't plan on rewriting any of our tests, but as we add new tests and test new products or add-ons I'd like to be able to deal with the fact that we are working with very large numbers of tests. On the other hand, if we can find a tool that would help distribute our Junit 3.x tests even in a very basic fashion, that *would* be helpful since we wouldn't have to maintain our own tooling to do that. [1]: http://beust.com/weblog/archives/000362.html
0
8,223
08/11/2008 21:10:32
72
08/01/2008 15:09:58
601
30
Connection Pooling in .NET/MSSQL?
Is it necessary or advantageous to write custom connection pooling code when developing applications in .NET with an MSSQL database? I know that ADO.NET gives you the option to enable/disable connection pooling -- does that mean that it's built into the framework and I don't need to worry about it? Why do people talk about writing their own connection pooling software and how is this different than what's built into ADO.NET?
c#
.net
database
connectionpooling
null
null
open
Connection Pooling in .NET/MSSQL? === Is it necessary or advantageous to write custom connection pooling code when developing applications in .NET with an MSSQL database? I know that ADO.NET gives you the option to enable/disable connection pooling -- does that mean that it's built into the framework and I don't need to worry about it? Why do people talk about writing their own connection pooling software and how is this different than what's built into ADO.NET?
0
8,228
08/11/2008 21:13:59
703
08/08/2008 04:25:11
35
2
Entourage with Exchange 07
So this is IT more than programming but google found nothing, and you guys are just the right kind of geniuses. **My Exchange Server 2007 and Entourage clients don't play nice.** Right now the big issue is that the entourage client will not connect to exchange 2007 ( entourage 2004 or 2008) The account settings are correct and use the proper format of https://exchange2007.mydomain.com/exchange/[email protected] The issue is with a dll called **davex.dll** when it is where it belongs, the owa application pool crashes a whole bunch of nasty things happen. When it isn’t there, I can connect to everything fine - and the owa app pool doesn’t crash - but entourage never propogates the folders in the mailbox and doesn’t send or receive. Any help or ideas would be appreciated: Microsoft support is silent on the issue, and google doesn't turn up much.
email
dll
exchange
entourage
null
null
open
Entourage with Exchange 07 === So this is IT more than programming but google found nothing, and you guys are just the right kind of geniuses. **My Exchange Server 2007 and Entourage clients don't play nice.** Right now the big issue is that the entourage client will not connect to exchange 2007 ( entourage 2004 or 2008) The account settings are correct and use the proper format of https://exchange2007.mydomain.com/exchange/[email protected] The issue is with a dll called **davex.dll** when it is where it belongs, the owa application pool crashes a whole bunch of nasty things happen. When it isn’t there, I can connect to everything fine - and the owa app pool doesn’t crash - but entourage never propogates the folders in the mailbox and doesn’t send or receive. Any help or ideas would be appreciated: Microsoft support is silent on the issue, and google doesn't turn up much.
0
8,236
08/11/2008 21:16:30
432
08/05/2008 17:18:46
536
31
How do you determine the size of a file in C?
How can I figure out the size of a file, in bytes? unsigned int fsize(char* file){ //what goes here? }
c
io
null
null
null
null
open
How do you determine the size of a file in C? === How can I figure out the size of a file, in bytes? unsigned int fsize(char* file){ //what goes here? }
0
8,263
08/11/2008 21:51:06
179
08/03/2008 02:38:27
11
3
I can't get my debugger to stop breaking on first-chance exceptions
I'm using Visual C++ 2003 to debug a program remotely via TCP/IP. I had set the Win32 exception c00000005, "Access violation," to break into the debugger when thrown. Then, I set it back to "Use parent setting." The setting for the parent, Win32 Exceptions, is to continue when the exception is thrown. Now, when I debug the program, it breaks each time that exception is thrown, forcing me to click Continue to let it keep debugging. How do I get it to stop breaking like this?
c++
visual-studio
exception
debugging
vs2003
null
open
I can't get my debugger to stop breaking on first-chance exceptions === I'm using Visual C++ 2003 to debug a program remotely via TCP/IP. I had set the Win32 exception c00000005, "Access violation," to break into the debugger when thrown. Then, I set it back to "Use parent setting." The setting for the parent, Win32 Exceptions, is to continue when the exception is thrown. Now, when I debug the program, it breaks each time that exception is thrown, forcing me to click Continue to let it keep debugging. How do I get it to stop breaking like this?
0
8,265
08/11/2008 21:53:58
1,052
08/11/2008 21:48:53
1
0
Unit of Work Pattern in .Net
Does anyone have any concrete examples of a simple Unit of Work pattern in C# or Visual Basic that would handle the following scenario? I'm writing a WinForms application in which a customer can have multiple addresses associated with it. The user can add, edit and delete addresses belonging to the customer before the customer is saved back to the database. Therefore, at the time of saving, all the original addresses need to be deleted from the database and the new addresses added in a single transaction.
.net
designpatterns
unitofwork
null
null
12/06/2011 03:02:09
not constructive
Unit of Work Pattern in .Net === Does anyone have any concrete examples of a simple Unit of Work pattern in C# or Visual Basic that would handle the following scenario? I'm writing a WinForms application in which a customer can have multiple addresses associated with it. The user can add, edit and delete addresses belonging to the customer before the customer is saved back to the database. Therefore, at the time of saving, all the original addresses need to be deleted from the database and the new addresses added in a single transaction.
4
8,276
08/11/2008 22:12:04
923
08/10/2008 14:25:39
11
1
Class::DBI-like library for php?
I have inherited an old crusty PHP application, and I'd like to refactor it into something a little nicer to deal with, but in a gradual manner. In perl's CPAN, there is a series of classes around Class::DBI that allow you to use database rows as the basis for objects in your code, with the library generating accessor methods etc as appropriate, but also allowing you to add additional methods. Does anyone know of something like this for PHP? Especially something that doesn't require wholesale adoption of a "framework"... bonus points if it works in PHP4 too, but to be honest, I'd love to have another reason to ditch that. :-)
perl
php
null
null
null
null
open
Class::DBI-like library for php? === I have inherited an old crusty PHP application, and I'd like to refactor it into something a little nicer to deal with, but in a gradual manner. In perl's CPAN, there is a series of classes around Class::DBI that allow you to use database rows as the basis for objects in your code, with the library generating accessor methods etc as appropriate, but also allowing you to add additional methods. Does anyone know of something like this for PHP? Especially something that doesn't require wholesale adoption of a "framework"... bonus points if it works in PHP4 too, but to be honest, I'd love to have another reason to ditch that. :-)
0
8,284
08/11/2008 22:20:04
519
08/06/2008 14:09:46
105
6
Generating Icon Files
I'm looking for an online solution for generating .ICO files. I'd like the ICO files to have the ability to have transparency as well. What software or web site do you use to create them?
design
icons
favicons
null
null
null
open
Generating Icon Files === I'm looking for an online solution for generating .ICO files. I'd like the ICO files to have the ability to have transparency as well. What software or web site do you use to create them?
0
8,306
08/11/2008 22:37:47
277
08/04/2008 10:55:22
93
2
Subversion Repository Redundancy
What is the best way to create redundant subversion repositories? I have a subversion repository (linked through apache2 and WebDAV) and would like to create a mirror repository on a different server in the event of outages, but I am not certain of the best way to proceed. I am thinking that post-commit scripts could be used to propagate changes, but I am not sure if this is the best way to go, anyone have any input
subversion
repository
redundancy
null
null
null
open
Subversion Repository Redundancy === What is the best way to create redundant subversion repositories? I have a subversion repository (linked through apache2 and WebDAV) and would like to create a mirror repository on a different server in the event of outages, but I am not certain of the best way to proceed. I am thinking that post-commit scripts could be used to propagate changes, but I am not sure if this is the best way to go, anyone have any input
0
8,318
08/11/2008 22:53:50
1,054
08/11/2008 22:38:05
1
1
Resolving Session Fixation in JBoss
I need to prevent [Session Fixation][1], a particular type of session hijacking, in a Java web application running in JBoss. However, it appears that the standard idiom [doesn't work in JBoss][2]. Can this be worked around? [1]: http://www.owasp.org/index.php/Session_Fixation [2]: http://www.owasp.org/index.php/Session_Fixation_in_Java
java
security
jboss
null
null
null
open
Resolving Session Fixation in JBoss === I need to prevent [Session Fixation][1], a particular type of session hijacking, in a Java web application running in JBoss. However, it appears that the standard idiom [doesn't work in JBoss][2]. Can this be worked around? [1]: http://www.owasp.org/index.php/Session_Fixation [2]: http://www.owasp.org/index.php/Session_Fixation_in_Java
0
8,348
08/11/2008 23:49:32
940
08/10/2008 19:58:38
11
3
Using unhandled exceptions instead of Contains()?
Imagine an object you are working with has a collection of other objects associated with it, for example the Controls collection on a WinForm. You want to check for a certain object in the collection, but the collection doesn't have a Contains() method. There are several ways of dealing with this. - Implement your own Contains() method by looping through all items in the collection to see if one of them is what you are looking for. This seems to be the "best practice" approach. - I recently came across some code where instead of a loop, there was an attempt to access the object inside a try statement, as follows: > try > { > Object aObject = myCollection[myObject]; > } > catch(Exception e) > { > //if this is thrown, then the object doesn't exist in the collection > } My question is how poor of a programming practice do you consider the second option be and why? How is the performance of it compared to a loop through the collection?
c#
.net
bestpractices
error-handling
null
null
open
Using unhandled exceptions instead of Contains()? === Imagine an object you are working with has a collection of other objects associated with it, for example the Controls collection on a WinForm. You want to check for a certain object in the collection, but the collection doesn't have a Contains() method. There are several ways of dealing with this. - Implement your own Contains() method by looping through all items in the collection to see if one of them is what you are looking for. This seems to be the "best practice" approach. - I recently came across some code where instead of a loop, there was an attempt to access the object inside a try statement, as follows: > try > { > Object aObject = myCollection[myObject]; > } > catch(Exception e) > { > //if this is thrown, then the object doesn't exist in the collection > } My question is how poor of a programming practice do you consider the second option be and why? How is the performance of it compared to a loop through the collection?
0
10,701,491
05/22/2012 11:51:11
1,399,620
05/16/2012 21:01:24
42
0
Different text formats in UITextView ? Or something else?
I want to set different text formats (normal, bold, italic...) in the same text view. Is it possible with UITextView ? Or what else ? Thanks for your advices
objective-c
ios
format
uitextview
null
null
open
Different text formats in UITextView ? Or something else? === I want to set different text formats (normal, bold, italic...) in the same text view. Is it possible with UITextView ? Or what else ? Thanks for your advices
0
10,701,493
05/22/2012 11:51:18
1,383,645
05/09/2012 04:21:06
51
0
How to get div id using div class and passing it function jquery
I need to get div id and its child class name by using div name . But div Id will be different and unique all the time. **HTML** <div class="diagram" id="12" > <div class="121"> ... </div> </div> <div class="diagram" id="133" > <div class="33"> ... </div> </div> <div class="diagram" id="199" > <div class="77"> ... </div> </div> So on.. JQUERY $(function(){ //i need to pass to values to the function in the following way o.circle("12","121"); o.circle("133","33"); o.circle("199","77"); //So on.. }); Please help me out
jquery
null
null
null
null
null
open
How to get div id using div class and passing it function jquery === I need to get div id and its child class name by using div name . But div Id will be different and unique all the time. **HTML** <div class="diagram" id="12" > <div class="121"> ... </div> </div> <div class="diagram" id="133" > <div class="33"> ... </div> </div> <div class="diagram" id="199" > <div class="77"> ... </div> </div> So on.. JQUERY $(function(){ //i need to pass to values to the function in the following way o.circle("12","121"); o.circle("133","33"); o.circle("199","77"); //So on.. }); Please help me out
0
10,701,457
05/22/2012 11:49:31
441,467
09/07/2010 13:20:28
256
6
Guice Assisted Injection with custom Annotations
At the moment I use Assisted Injection with Named Parameters like this: public interface Factory { public MyObject create(@Assisted("string1") String string1, @Assisted("string2") String string2); } This works great. But I think it is a bit ugly to use Strings as Identifier for my parameters. What I would want to do is the following: public interface Factory { public MyObject create(@String1 String string1, @String2 String string2); } So essentially I want custom Assisted Annotations. Is there a way to do this?
dependency-injection
guice
guice-3
assisted-inject
null
null
open
Guice Assisted Injection with custom Annotations === At the moment I use Assisted Injection with Named Parameters like this: public interface Factory { public MyObject create(@Assisted("string1") String string1, @Assisted("string2") String string2); } This works great. But I think it is a bit ugly to use Strings as Identifier for my parameters. What I would want to do is the following: public interface Factory { public MyObject create(@String1 String string1, @String2 String string2); } So essentially I want custom Assisted Annotations. Is there a way to do this?
0
10,701,499
05/22/2012 11:51:51
1,285,928
03/22/2012 12:39:23
94
6
Bug in a delete button in JSF page
I'm trying to implement JSF table with delete button. This is the JavaScript which displays the dialog: function dialog(a){ $("<div />", { text: a }).dialog({ width: 600, buttons: { "Ok": function() { $("#myHiddenButtonID").click(); $(this).dialog("close"); }, "Cancel": function(event) { $(this).dialog("close"); event.preventDefault(); } } }); } I use second hidden button to delete the rows when the user confirms from the dialog: <!-- hidden button --> <h:commandButton id="myHiddenButtonID" value="DeleteHiddenButton" action="#{bean.deleteSelectedIDs}" style="display:none"> <f:ajax render="@form" ></f:ajax> </h:commandButton> <!-- the button --> <h:commandButton value="Delete"> <f:ajax execute="@form" onevent="dialog('demo test')"></f:ajax> </h:commandButton> When I click on the delete button the dialog appears to confirm the deletion of the table rows. Then I click YES nothing happens. I suppose that the hidden button id is the problem but when I try to fix it nothing happens. The managed bean method is not called.
java
javascript
jsf
jsf-2.0
jquery-dialog
null
open
Bug in a delete button in JSF page === I'm trying to implement JSF table with delete button. This is the JavaScript which displays the dialog: function dialog(a){ $("<div />", { text: a }).dialog({ width: 600, buttons: { "Ok": function() { $("#myHiddenButtonID").click(); $(this).dialog("close"); }, "Cancel": function(event) { $(this).dialog("close"); event.preventDefault(); } } }); } I use second hidden button to delete the rows when the user confirms from the dialog: <!-- hidden button --> <h:commandButton id="myHiddenButtonID" value="DeleteHiddenButton" action="#{bean.deleteSelectedIDs}" style="display:none"> <f:ajax render="@form" ></f:ajax> </h:commandButton> <!-- the button --> <h:commandButton value="Delete"> <f:ajax execute="@form" onevent="dialog('demo test')"></f:ajax> </h:commandButton> When I click on the delete button the dialog appears to confirm the deletion of the table rows. Then I click YES nothing happens. I suppose that the hidden button id is the problem but when I try to fix it nothing happens. The managed bean method is not called.
0
10,701,500
05/22/2012 11:51:55
1,355,245
12/08/2010 15:29:05
1
0
how to implement infinite scroll masonry
I have used masonry js for showing content on my site. I want to implement infinite scrolling functionality using this file. I have see this demo http://masonry.desandro.com/demos/infinite-scroll.html but i can't understand how I can implement this demo in my website. This is my website http://www.techmodi.com/demo/lookandpin_demo/ I have used these js files, 1) jquery-ui.min.js 2) jquery.masonry.min.js Please give me solution if anyone have. Thanks
php
javascript
jquery
null
null
null
open
how to implement infinite scroll masonry === I have used masonry js for showing content on my site. I want to implement infinite scrolling functionality using this file. I have see this demo http://masonry.desandro.com/demos/infinite-scroll.html but i can't understand how I can implement this demo in my website. This is my website http://www.techmodi.com/demo/lookandpin_demo/ I have used these js files, 1) jquery-ui.min.js 2) jquery.masonry.min.js Please give me solution if anyone have. Thanks
0
10,701,503
05/22/2012 11:52:04
1,121,571
12/29/2011 16:42:50
55
5
Asynchronous serialization process produces incomplete bean
I have a class with object initialized to null : public class MyClass extends MySuperClass implements Serializable { private AnotherClass anotherClass = null; public AnotherClass getAnotherClass() { if(anotherClass == null) { anotherClass = new AnotherClass(); anotherClass.setTitle("My Title"); Category category = CategoryFactory.getInstance("AnotherClass"); // long process anotherClass.setCategoryId(category.getId()); anotherClass.setDesc("This my desc"); } return anotherClass; } } I am using a library that cache (serializing) my beans asynchronously (ScheduledFuture / FutureTask). I do not have control to this process... Sometimes, my bean `AnotherClass` is (de)serialized with half content (for example, title is well set but not Desc or CategoryId... I think that serialization process run during the `AnotherClass` bean initialization. I Also think that I need to `synchronize` serialization process, but what is the best practice (note `synchronized` keywords) ? I implement these methods : private synchronized void writeObject(ObjectOutputStream oos) throws IOException { oos.defaultWriteObject(); } private synchronized void readObject(ObjectInputStream ois) throws ClassNotFoundException, IOException { ois.defaultReadObject(); } And I put a double-checked locking on method getAnotherClass() : public AnotherClass getAnotherClass() { if(anotherClass == null) { synchronized (this) { if(anotherClass == null) { anotherClass = new AnotherClass(); anotherClass.setTitle("My Title"); Category category = CategoryFactory.getInstance("AnotherClass"); // long process anotherClass.setCategoryId(category.getId()); anotherClass.setDesc("This my desc"); } } } return anotherClass; } Is it the good practice ? Another question : All the beans that must be cached extends same super class. Is it possible to define `writeObject` et `readObject` in super class to not duplicate this code in inherited classes ?
java
serialization
asynchronous
synchronization
lifecycle
null
open
Asynchronous serialization process produces incomplete bean === I have a class with object initialized to null : public class MyClass extends MySuperClass implements Serializable { private AnotherClass anotherClass = null; public AnotherClass getAnotherClass() { if(anotherClass == null) { anotherClass = new AnotherClass(); anotherClass.setTitle("My Title"); Category category = CategoryFactory.getInstance("AnotherClass"); // long process anotherClass.setCategoryId(category.getId()); anotherClass.setDesc("This my desc"); } return anotherClass; } } I am using a library that cache (serializing) my beans asynchronously (ScheduledFuture / FutureTask). I do not have control to this process... Sometimes, my bean `AnotherClass` is (de)serialized with half content (for example, title is well set but not Desc or CategoryId... I think that serialization process run during the `AnotherClass` bean initialization. I Also think that I need to `synchronize` serialization process, but what is the best practice (note `synchronized` keywords) ? I implement these methods : private synchronized void writeObject(ObjectOutputStream oos) throws IOException { oos.defaultWriteObject(); } private synchronized void readObject(ObjectInputStream ois) throws ClassNotFoundException, IOException { ois.defaultReadObject(); } And I put a double-checked locking on method getAnotherClass() : public AnotherClass getAnotherClass() { if(anotherClass == null) { synchronized (this) { if(anotherClass == null) { anotherClass = new AnotherClass(); anotherClass.setTitle("My Title"); Category category = CategoryFactory.getInstance("AnotherClass"); // long process anotherClass.setCategoryId(category.getId()); anotherClass.setDesc("This my desc"); } } } return anotherClass; } Is it the good practice ? Another question : All the beans that must be cached extends same super class. Is it possible to define `writeObject` et `readObject` in super class to not duplicate this code in inherited classes ?
0
10,701,504
05/22/2012 11:52:05
1,353,660
04/24/2012 12:24:45
370
46
Command working in terminal, but not via QProcess
ifconfig | grep 'inet' is working when executed via terminal. But not via QProcess My sample code is QProcess p1; p1.start("ifconfig | grep 'inet'"); p1.waitForFinished(); QString output(p1.readAllStandardOutput()); textEdit->setText(output); Nothing is getting displayed on textedit. but when I use just `ifconfig` in start of qprocess, output is getting displayed on textedit. Did I miss any trick to construct the command `ifconfig | grep 'inet'` , like use `\'` for `'` and `\|` for `|`? for special characters? but I tried that as well:(
c
linux
qt
terminal
pipe
null
open
Command working in terminal, but not via QProcess === ifconfig | grep 'inet' is working when executed via terminal. But not via QProcess My sample code is QProcess p1; p1.start("ifconfig | grep 'inet'"); p1.waitForFinished(); QString output(p1.readAllStandardOutput()); textEdit->setText(output); Nothing is getting displayed on textedit. but when I use just `ifconfig` in start of qprocess, output is getting displayed on textedit. Did I miss any trick to construct the command `ifconfig | grep 'inet'` , like use `\'` for `'` and `\|` for `|`? for special characters? but I tried that as well:(
0
10,701,513
05/22/2012 11:52:31
1,409,903
05/22/2012 10:01:59
1
0
How to modify a query to force use of an left prefix of an index?
I have SQL queries of the following kind:<br> SELECT * FROM data_table WHERE col2 >= x AND col2 < x+y There is an index_1(col1, col2, col3) present on data_table whereas column one to three hold integer values greater than zero while null values aren't allowed. Since every left prefix of an index in MySQL is an index again my first approch was to modify the query in the hope that MySQL will use index_1 and the query speeds up. The modified query looks like this: <br> SELECT * FROM data_table WHERE col2 >= x AND col2 < x+y OR col1 >0 My thought was when I add something that is always true but doesn't change the result MySQL would use the left prefix of index_1(col1, col2) but by a quick glance on EXPLAIN it unfortunately doesn't. Does anyone know how to modify the query so that index_1 is used? Or is it just not possible? For your information: data_table is really large and creating a new index with col2 is not an proper option due to the long creation time.
mysql
null
null
null
null
null
open
How to modify a query to force use of an left prefix of an index? === I have SQL queries of the following kind:<br> SELECT * FROM data_table WHERE col2 >= x AND col2 < x+y There is an index_1(col1, col2, col3) present on data_table whereas column one to three hold integer values greater than zero while null values aren't allowed. Since every left prefix of an index in MySQL is an index again my first approch was to modify the query in the hope that MySQL will use index_1 and the query speeds up. The modified query looks like this: <br> SELECT * FROM data_table WHERE col2 >= x AND col2 < x+y OR col1 >0 My thought was when I add something that is always true but doesn't change the result MySQL would use the left prefix of index_1(col1, col2) but by a quick glance on EXPLAIN it unfortunately doesn't. Does anyone know how to modify the query so that index_1 is used? Or is it just not possible? For your information: data_table is really large and creating a new index with col2 is not an proper option due to the long creation time.
0
10,701,518
05/22/2012 11:52:59
865,188
07/27/2011 10:48:00
696
1
Can I run fortify on single class file?
I installed [Fortify](https://www.fortify.com) and it's eclipse plugin to scan my application. Scanning the whole application takes close to an hour. I don't see an option to scan individual files when I right click on them. Is there an option to run fortify on individual files that we created/modified (in eclipse plugin) ?
java
eclipse-plugin
fortify360
source-code-quality
null
null
open
Can I run fortify on single class file? === I installed [Fortify](https://www.fortify.com) and it's eclipse plugin to scan my application. Scanning the whole application takes close to an hour. I don't see an option to scan individual files when I right click on them. Is there an option to run fortify on individual files that we created/modified (in eclipse plugin) ?
0
8,351
08/12/2008 00:02:42
680
08/07/2008 17:29:04
73
7
Firebug for IE
Trying to fix JavaScript bugs is huge pain as is determining the styles applied to an element. Firebug makes these issues a lot easier when working on Firefox, but when do you do when the code works fine on Firefox but IE is complaining?
ie
internet-explorer
firebug
webdevelopment
debugging
null
open
Firebug for IE === Trying to fix JavaScript bugs is huge pain as is determining the styles applied to an element. Firebug makes these issues a lot easier when working on Firefox, but when do you do when the code works fine on Firefox but IE is complaining?
0
8,355
08/12/2008 00:06:36
277
08/04/2008 10:55:22
98
3
URL Redirection for SSL virtual hosts
What is the best way to transparently rewrite a URL over an SSL connection with Apache 2.2? Apache 2 does not natively support multiple name-based virtual hosts for an SSL connection and I have heard that mod_rewrite can help with this. I would like to do something like this: I have set up the server so that the sites can be accessed by https://secure.example.com/dbadmin but I would like to have this as https://dbadmin.example.com How do I set it up so that the Rewrite rule will rewrite dbadmin.example.com to secure.example.com/dbadmin, but without displaying the rewrite on the client's address bar (i.e. the client will still just see dbadmin.example.com), all over https?
apache
mod-rewrite
https
null
null
null
open
URL Redirection for SSL virtual hosts === What is the best way to transparently rewrite a URL over an SSL connection with Apache 2.2? Apache 2 does not natively support multiple name-based virtual hosts for an SSL connection and I have heard that mod_rewrite can help with this. I would like to do something like this: I have set up the server so that the sites can be accessed by https://secure.example.com/dbadmin but I would like to have this as https://dbadmin.example.com How do I set it up so that the Rewrite rule will rewrite dbadmin.example.com to secure.example.com/dbadmin, but without displaying the rewrite on the client's address bar (i.e. the client will still just see dbadmin.example.com), all over https?
0
8,365
08/12/2008 00:21:58
547
08/06/2008 16:09:22
132
16
MySQL Administrator Backups: "Compatibility Mode", What Exactly is this doing?
In Mysql Administrator, when doing backups, what exactly is "Compatibility Mode"? I'm trying to bridge backups generated by [webmin][1] with the upload tool available inside [mysql administrator][2]. My data already has a couple of inconsistencies (ticks, commas, etc, I think) I just wont try to kink out (they might just reappear in the future anyways). These kinks generate errors when I try to restore out of my backups. Now, if I generate backups from webmin, and then use MySQL administrator to restore them, they fail. But if I generate the backups using MySQL Administrator AND tick "Compatibility Mode", then head over to MySQL administrator (another instance) and restore... it works! According to MySQL, "Compatibility Mode" is; > Compatibility mode creates backup files that are compatible with older versions of MySQL Administrator. Webmin, on the other hand, gives me the following options for compatibility: - ANSI - MySQL 3.2.3 - MySQL 4.0 - PostgreSQL - Oracle - Microsoft SQL - DB2 - MaxDB Which would you say is a best fit? My data set is very large, so it would take quite some time to experiment one by one (specially whence thinking might beat brute-forcing it). Cheers, /mp [1]: http://www.webmin.com/ [2]: http://www.mysql.com/products/tools/administrator/
mysql
backup
null
null
null
null
open
MySQL Administrator Backups: "Compatibility Mode", What Exactly is this doing? === In Mysql Administrator, when doing backups, what exactly is "Compatibility Mode"? I'm trying to bridge backups generated by [webmin][1] with the upload tool available inside [mysql administrator][2]. My data already has a couple of inconsistencies (ticks, commas, etc, I think) I just wont try to kink out (they might just reappear in the future anyways). These kinks generate errors when I try to restore out of my backups. Now, if I generate backups from webmin, and then use MySQL administrator to restore them, they fail. But if I generate the backups using MySQL Administrator AND tick "Compatibility Mode", then head over to MySQL administrator (another instance) and restore... it works! According to MySQL, "Compatibility Mode" is; > Compatibility mode creates backup files that are compatible with older versions of MySQL Administrator. Webmin, on the other hand, gives me the following options for compatibility: - ANSI - MySQL 3.2.3 - MySQL 4.0 - PostgreSQL - Oracle - Microsoft SQL - DB2 - MaxDB Which would you say is a best fit? My data set is very large, so it would take quite some time to experiment one by one (specially whence thinking might beat brute-forcing it). Cheers, /mp [1]: http://www.webmin.com/ [2]: http://www.mysql.com/products/tools/administrator/
0
8,371
08/12/2008 00:36:32
547
08/06/2008 16:09:22
134
16
How do you redirect https to http
that is, the opposite of what (seemingly) everyone teaches. I have a server on https for which I paid an SSL cert for and a mirror for which I haven't and keep around for just for emergencies so it doesn't merit getting a cert for. On my client's desktops I have SOME shortcuts which point to http://production_server and https://production_server (both work), however; I know that if my prod. server goes down, then DNS forwarding kicks in and those clients which have https on their shortcut will be staring at https://mirror_server (Which doesnt work) and a big fat IE7 red screen of uneasyness for my company. Unfortunately, I can't just switch this around at the client level. These users are very computer illiterate: and are very likely to freak out from seeing https "insecurity" errors (specially the way FFX3 and IE7 handle it nowadays: FULL STOP, kinda thankfully, but not helping me here LOL). It's [very][1] [easy][2] [to find][3] [apache solutions][4] for [http->https redirection][5], but for the life of me I can't do the opposite. Ideas? Cheers, /mp [1]: http://www.cyberciti.biz/tips/howto-apache-force-https-secure-connections.html [2]: http://bytes.com/forum/thread54801.html [3]: http://support.jodohost.com/showthread.php?t=6678 [4]: http://wikis.sun.com/display/About/2008/04/30/HTTP-HTTPS+Redirection+Enabled [5]: http://www.google.com/search?q=https+redirection&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a
apache
ssl
https
redirect
null
null
open
How do you redirect https to http === that is, the opposite of what (seemingly) everyone teaches. I have a server on https for which I paid an SSL cert for and a mirror for which I haven't and keep around for just for emergencies so it doesn't merit getting a cert for. On my client's desktops I have SOME shortcuts which point to http://production_server and https://production_server (both work), however; I know that if my prod. server goes down, then DNS forwarding kicks in and those clients which have https on their shortcut will be staring at https://mirror_server (Which doesnt work) and a big fat IE7 red screen of uneasyness for my company. Unfortunately, I can't just switch this around at the client level. These users are very computer illiterate: and are very likely to freak out from seeing https "insecurity" errors (specially the way FFX3 and IE7 handle it nowadays: FULL STOP, kinda thankfully, but not helping me here LOL). It's [very][1] [easy][2] [to find][3] [apache solutions][4] for [http->https redirection][5], but for the life of me I can't do the opposite. Ideas? Cheers, /mp [1]: http://www.cyberciti.biz/tips/howto-apache-force-https-secure-connections.html [2]: http://bytes.com/forum/thread54801.html [3]: http://support.jodohost.com/showthread.php?t=6678 [4]: http://wikis.sun.com/display/About/2008/04/30/HTTP-HTTPS+Redirection+Enabled [5]: http://www.google.com/search?q=https+redirection&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a
0
8,383
08/12/2008 00:54:52
713
08/08/2008 06:44:13
48
5
Reading recommendations for: SQL Server 2005 Reporting Services
I have been shuffled around at work. Can anyone recommend a quick book/site to get me up to speed on SQL Server 2005 Reporting Services. Additionally; I have the following books available, a quick rating would be handy. > **Professional SQL Server 2005 Reporting Services** <br> > by Paul Turley, Todd Bryant, James Counihan and Dave > DuVarney >**SQL Server 2005 Bible**<br> >by Paul Nielsen >**Mastering SQL Server 2005 Reporting Services Infrastructure Design**<br> >by Joseph L. Jorden Cheers!
mssql
reporting-services
vs2005
bookrecommendations
help
null
open
Reading recommendations for: SQL Server 2005 Reporting Services === I have been shuffled around at work. Can anyone recommend a quick book/site to get me up to speed on SQL Server 2005 Reporting Services. Additionally; I have the following books available, a quick rating would be handy. > **Professional SQL Server 2005 Reporting Services** <br> > by Paul Turley, Todd Bryant, James Counihan and Dave > DuVarney >**SQL Server 2005 Bible**<br> >by Paul Nielsen >**Mastering SQL Server 2005 Reporting Services Infrastructure Design**<br> >by Joseph L. Jorden Cheers!
0
8,398
08/12/2008 01:22:38
396
08/05/2008 12:46:44
172
13
How do I debug Javascript in Visual Studio?
I just saw this mentioned in this [thread][1] and didn't know it could be done. I'm a VS newbie, so how do you do it? Is there a separate debugger for Javascript? I know how to work the one for code-behind pages... I usually use Firebug to deal with debugging JS. [1]: http://stackoverflow.com/questions/7975/best-css-editor
javascript
visual-studio
howto
debugging
null
null
open
How do I debug Javascript in Visual Studio? === I just saw this mentioned in this [thread][1] and didn't know it could be done. I'm a VS newbie, so how do you do it? Is there a separate debugger for Javascript? I know how to work the one for code-behind pages... I usually use Firebug to deal with debugging JS. [1]: http://stackoverflow.com/questions/7975/best-css-editor
0
8,422
08/12/2008 02:39:06
571
08/06/2008 20:19:59
399
34
How do you handle audit logging with SSRS?
I have some reports in SQL Server Reporting Services 2005 that I need to keep audit logs for. The audit log should include who ran what report with what parameters. I can't use Windows authentication. What is the best way to log this information?
reporting-services
sqlserver2005
ssrs
null
null
null
open
How do you handle audit logging with SSRS? === I have some reports in SQL Server Reporting Services 2005 that I need to keep audit logs for. The audit log should include who ran what report with what parameters. I can't use Windows authentication. What is the best way to log this information?
0
8,435
08/12/2008 03:26:38
733
08/08/2008 12:53:16
23
5
How do you get the icons out of shell32.dll?
I'd like to get the Tree icon to use for a homegrown app. Does anyone know how to extrace the images out as .icon files? I'd like both the 16x16 and 32x32, or I'd just do a screen capture.
icon
shell32.dll
null
null
null
null
open
How do you get the icons out of shell32.dll? === I'd like to get the Tree icon to use for a homegrown app. Does anyone know how to extrace the images out as .icon files? I'd like both the 16x16 and 32x32, or I'd just do a screen capture.
0
8,439
08/12/2008 03:46:11
233
08/03/2008 20:19:32
168
17
Conditional Visibility and Page Breaks with SQL Server 2005 Reporting Services
I know there's a bug with conditional visibility and page breaks with SQL 2005, but I wonder if anyone has come up with a work around. I have a table that has a conditional visibility expression, and I need a page break at the end of the table. - If I set the PageBreakAtEnd property to true. It is ignored no matter what. Remove the visibility condition and it works. - If I place the table inside a rectangle with the conditional visibility on the table, and the page break on the table. Same result. The page break property is ignored. - If I set the rectangle with the PageBreakAtEnd property and the table with the visibility condition, then I still get a page break even when the table isn't shown. Any other ideas on what to try? I'm almost at the point where I need a separate report rather than conditional visibility :(
reporting-services
sql2005
null
null
null
null
open
Conditional Visibility and Page Breaks with SQL Server 2005 Reporting Services === I know there's a bug with conditional visibility and page breaks with SQL 2005, but I wonder if anyone has come up with a work around. I have a table that has a conditional visibility expression, and I need a page break at the end of the table. - If I set the PageBreakAtEnd property to true. It is ignored no matter what. Remove the visibility condition and it works. - If I place the table inside a rectangle with the conditional visibility on the table, and the page break on the table. Same result. The page break property is ignored. - If I set the rectangle with the PageBreakAtEnd property and the table with the visibility condition, then I still get a page break even when the table isn't shown. Any other ideas on what to try? I'm almost at the point where I need a separate report rather than conditional visibility :(
0
8,440
08/12/2008 03:53:53
493
08/06/2008 10:25:05
886
71
Visual Studio Optimizations
Visual studio is a pretty awesome IDE, but sometimes you just wish it would go faster. I was wondering if people have any tips or tricks to help speed up visual studio in day to day use. Things that I'm particularly interested in are speeding up build times and switching aspx files from source to design view seem to bring it to a grinding halt. Having said that, I'd be keen to hear anything that anyone uses to make VS run that little bit faster.
.net
visual-studio
null
null
null
09/12/2011 16:44:58
not constructive
Visual Studio Optimizations === Visual studio is a pretty awesome IDE, but sometimes you just wish it would go faster. I was wondering if people have any tips or tricks to help speed up visual studio in day to day use. Things that I'm particularly interested in are speeding up build times and switching aspx files from source to design view seem to bring it to a grinding halt. Having said that, I'd be keen to hear anything that anyone uses to make VS run that little bit faster.
4
8,441
08/12/2008 03:58:21
57
08/01/2008 13:53:49
1
0
Mod-Rewrite loading files behind the DocumentRoot
I'm using htaccess and mod_rewrite to point to files that reside behide the DocumentRoot. My folder structure looks like this: <pre> home/ webroot/ other_files/ </pre> I have a <code>.htaccess</code> file in webroot with the following: <pre> RewriteEngine on RewriteRule ^(.*)$ /home/other_files/$1 </pre> If I try and access http://mysite.com/file.html I am receive the following error: <pre>The requested URL /home/other_files/file.html was not found on this server.</pre> Is it even possible to load files that are behind the DocumentRoot? If so, can someone point me in the right direction? Thanks in advance.
mod-rewrite
.htaccess
null
null
null
null
open
Mod-Rewrite loading files behind the DocumentRoot === I'm using htaccess and mod_rewrite to point to files that reside behide the DocumentRoot. My folder structure looks like this: <pre> home/ webroot/ other_files/ </pre> I have a <code>.htaccess</code> file in webroot with the following: <pre> RewriteEngine on RewriteRule ^(.*)$ /home/other_files/$1 </pre> If I try and access http://mysite.com/file.html I am receive the following error: <pre>The requested URL /home/other_files/file.html was not found on this server.</pre> Is it even possible to load files that are behind the DocumentRoot? If so, can someone point me in the right direction? Thanks in advance.
0
8,443
08/12/2008 04:00:13
257
08/04/2008 07:30:01
308
29
MSVC6: Breakpoint stops program - WTF?
Using Microsoft Visual Studio 98, Microsoft Visual C++ 6.0 SP6 When running under the debugger, there's only one problem. If I pause the program and resume, everything's fine. The problem? When I hit a breakpoint, my program stops. But not in a good way; execution halts, I'm thrown out of debug mode into edit mode. All's fine until a breakpoint is hit. And I know it's hitting the breakpoint - I see a flash of the little yellow arrow pointing at the right line of code, local variables in the inspect window and the call stack in that window. And then I'm staring at the editor. This happens in all projects. I've uninstalled and re-installed MSVC6. It didn't help. I'm about to start over on a new PC; before I go that far, anyone know what I've done to this one?
c++
windows
msvc
debugging
null
null
open
MSVC6: Breakpoint stops program - WTF? === Using Microsoft Visual Studio 98, Microsoft Visual C++ 6.0 SP6 When running under the debugger, there's only one problem. If I pause the program and resume, everything's fine. The problem? When I hit a breakpoint, my program stops. But not in a good way; execution halts, I'm thrown out of debug mode into edit mode. All's fine until a breakpoint is hit. And I know it's hitting the breakpoint - I see a flash of the little yellow arrow pointing at the right line of code, local variables in the inspect window and the call stack in that window. And then I'm staring at the editor. This happens in all projects. I've uninstalled and re-installed MSVC6. It didn't help. I'm about to start over on a new PC; before I go that far, anyone know what I've done to this one?
0
8,447
08/12/2008 04:09:16
580
08/06/2008 22:30:28
76
11
Enum Flags Attribute
Anyone have a good explanation or example they could post?
c#
null
null
null
null
null
open
Enum Flags Attribute === Anyone have a good explanation or example they could post?
0
8,448
08/12/2008 04:11:15
580
08/06/2008 22:30:28
76
11
F# curried function
Anyone have a decent example, preferably practical/useful, they could post demonstrating the concept?
f#
null
null
null
null
null
open
F# curried function === Anyone have a decent example, preferably practical/useful, they could post demonstrating the concept?
0
8,451
08/12/2008 04:18:09
716
08/08/2008 06:57:38
29
5
Secure Memory Allocator in C++
I want to create an allocator which provides memory with the following attributes: - cannot be paged to disk. - is incredibly hard to access through an attached debugger The idea is that this will contain sensitive information (like licence information) which should be inaccessible to the user. I have done the usual research online and asked a few other people about this, but I cannot find a good place start on this problem. On a side note, what other methods are there of accessing the memory of a process other than attaching a debugger?
c++
memoryallocation
null
null
null
null
open
Secure Memory Allocator in C++ === I want to create an allocator which provides memory with the following attributes: - cannot be paged to disk. - is incredibly hard to access through an attached debugger The idea is that this will contain sensitive information (like licence information) which should be inaccessible to the user. I have done the usual research online and asked a few other people about this, but I cannot find a good place start on this problem. On a side note, what other methods are there of accessing the memory of a process other than attaching a debugger?
0
8,452
08/12/2008 04:18:30
580
08/06/2008 22:30:28
76
11
I don't grok the WPF command pattern
I've done some WPF programing and one thing I never got was the command pattern. Every example seems to be for built in ones, edit, cut, paste. Anyone have an example or suggestion of best practice for custom commands?
wpf
null
null
null
null
null
open
I don't grok the WPF command pattern === I've done some WPF programing and one thing I never got was the command pattern. Every example seems to be for built in ones, edit, cut, paste. Anyone have an example or suggestion of best practice for custom commands?
0
8,472
08/12/2008 04:59:35
1
07/31/2008 14:22:31
2,409
72
Best non-image based CAPTCHA?
It looks like we'll be adding [CAPTCHA](http://en.wikipedia.org/wiki/Captcha) support to Stack Overflow. This is necessary to prevent bots, spammers, and other malicious scripted activity. We only want human beings to post or edit things here! We'll be using a JavaScript (JQuery) CAPTCHA as a first line of defense <http://docs.jquery.com/Tutorials:Safer_Contact_Forms_Without_CAPTCHAs> The advantage of this approach is that, **for most people, the CAPTCHA won't ever be visible!** However, for people with JavaScript disabled, we still need a fallback -- and this is where it gets tricky. I have written a [traditional CAPTCHA control for ASP.NET](http://www.codeproject.com/KB/custom-controls/CaptchaControl.aspx) which we can re-use. <img src="http://www.codeproject.com/KB/custom-controls/CaptchaControl/CaptchaImage-medium.jpg"/> However, I'd prefer to go with something textual to avoid the overhead of creating all these images on the server with each request. I've seen things like.. - ASCII text captcha: `\/\/(_)\/\/` - math puzzles: what is 7 minus 3 times 2? - trivia questions: what tastes better, a toad or a popsicle? Maybe I'm just tilting at windmills here, but I'd like to have a less resource intensive, non-image based `<noscript>` compatible CAPTCHA if possible. Ideas?
captcha
null
null
null
null
null
open
Best non-image based CAPTCHA? === It looks like we'll be adding [CAPTCHA](http://en.wikipedia.org/wiki/Captcha) support to Stack Overflow. This is necessary to prevent bots, spammers, and other malicious scripted activity. We only want human beings to post or edit things here! We'll be using a JavaScript (JQuery) CAPTCHA as a first line of defense <http://docs.jquery.com/Tutorials:Safer_Contact_Forms_Without_CAPTCHAs> The advantage of this approach is that, **for most people, the CAPTCHA won't ever be visible!** However, for people with JavaScript disabled, we still need a fallback -- and this is where it gets tricky. I have written a [traditional CAPTCHA control for ASP.NET](http://www.codeproject.com/KB/custom-controls/CaptchaControl.aspx) which we can re-use. <img src="http://www.codeproject.com/KB/custom-controls/CaptchaControl/CaptchaImage-medium.jpg"/> However, I'd prefer to go with something textual to avoid the overhead of creating all these images on the server with each request. I've seen things like.. - ASCII text captcha: `\/\/(_)\/\/` - math puzzles: what is 7 minus 3 times 2? - trivia questions: what tastes better, a toad or a popsicle? Maybe I'm just tilting at windmills here, but I'd like to have a less resource intensive, non-image based `<noscript>` compatible CAPTCHA if possible. Ideas?
0
8,485
08/12/2008 05:16:01
364
08/05/2008 05:33:41
188
12
Use the routing engine for form submissions in ASP.NET MVC Preview 4
I'm using ASP.NET MVC Preview 4 and would like to know how to use the routing engine for form submissions. For example, I have a route like this: routes.MapRoute( "TestController-TestAction", "TestController.mvc/TestAction/{paramName}", new { controller = "TestController", action = "TestAction", id = "TestTopic" } ); And a form declaration that looks like this: <% using (Html.Form("TestController", "TestAction", FormMethod.Get)) { %> <input type="text" name="paramName" /> <input type="submit" /> <% } %> which renders to: <form method="get" action="/TestController.mvc/TestAction"> <input type="text" name="paramName" /> <input type="submit" /> </form> The resulting URL of a form submission is: **localhost/TestController.mvc/TestAction?paramName=value** Is there any way to have this form submission route to the desired URL of: **localhost/TestController.mvc/TestAction/value** Thanks in advance for any assistance.
asp.net
mvc
forms
routing
null
null
open
Use the routing engine for form submissions in ASP.NET MVC Preview 4 === I'm using ASP.NET MVC Preview 4 and would like to know how to use the routing engine for form submissions. For example, I have a route like this: routes.MapRoute( "TestController-TestAction", "TestController.mvc/TestAction/{paramName}", new { controller = "TestController", action = "TestAction", id = "TestTopic" } ); And a form declaration that looks like this: <% using (Html.Form("TestController", "TestAction", FormMethod.Get)) { %> <input type="text" name="paramName" /> <input type="submit" /> <% } %> which renders to: <form method="get" action="/TestController.mvc/TestAction"> <input type="text" name="paramName" /> <input type="submit" /> </form> The resulting URL of a form submission is: **localhost/TestController.mvc/TestAction?paramName=value** Is there any way to have this form submission route to the desired URL of: **localhost/TestController.mvc/TestAction/value** Thanks in advance for any assistance.
0
8,496
08/12/2008 05:25:21
708
08/08/2008 06:10:02
15
2
Shelve in TortoiseSVN?
I've moved from TFS to SVN (TortoiseSVN) with my current company. I really miss the "Shelve" feature of TFS. I've read various articles on how to "Shelve" with SVN, but I've read nothing that gives a very simple experience to "shelve" work. Ideally, I'd like extra items added to the TortoiseSVN context menu - "Shelve" & "Unshelve". "Shelve" would remove the current shelve-set, and upload the working directory under a suitable path defined by user options. "Unshelve" would merge the set with the working copy. Does something like this exist? Can anyone suggest any ways to "hack" this feature in the GUI? Note: The following links don't really make it as easy as I'd like:<br /> [http://geekswithblogs.net/flanakin/archive/2005/12/02/61929.aspx][1]<br /> [http://mikemason.ca/2005/03/30/][2] [1]: http://geekswithblogs.net/flanakin/archive/2005/12/02/61929.aspx [2]: http://mikemason.ca/2005/03/30/
svn
tortoisesvn
null
null
null
null
open
Shelve in TortoiseSVN? === I've moved from TFS to SVN (TortoiseSVN) with my current company. I really miss the "Shelve" feature of TFS. I've read various articles on how to "Shelve" with SVN, but I've read nothing that gives a very simple experience to "shelve" work. Ideally, I'd like extra items added to the TortoiseSVN context menu - "Shelve" & "Unshelve". "Shelve" would remove the current shelve-set, and upload the working directory under a suitable path defined by user options. "Unshelve" would merge the set with the working copy. Does something like this exist? Can anyone suggest any ways to "hack" this feature in the GUI? Note: The following links don't really make it as easy as I'd like:<br /> [http://geekswithblogs.net/flanakin/archive/2005/12/02/61929.aspx][1]<br /> [http://mikemason.ca/2005/03/30/][2] [1]: http://geekswithblogs.net/flanakin/archive/2005/12/02/61929.aspx [2]: http://mikemason.ca/2005/03/30/
0
8,508
08/12/2008 05:40:49
459
08/05/2008 21:54:42
11
4
How should I monitor potential threats to my site?
By looking at our DB's error log, we found that there was a constant stream of almost successful SQL injection attacks. Some quick coding avoided that, but how could I have setup a monitor for both the DB and Web server (including POST requests) to check for this? By this I mean if there are off the shelf tools for script-kiddies, are there off the shelf tools that will alert you to their sudden random interest in your site?
monitor
alert
null
null
null
null
open
How should I monitor potential threats to my site? === By looking at our DB's error log, we found that there was a constant stream of almost successful SQL injection attacks. Some quick coding avoided that, but how could I have setup a monitor for both the DB and Web server (including POST requests) to check for this? By this I mean if there are off the shelf tools for script-kiddies, are there off the shelf tools that will alert you to their sudden random interest in your site?
0
8,517
08/12/2008 05:51:01
459
08/05/2008 21:54:42
11
4
Lucene exact ordering
I've had this long term issue in not quite understanding how to implement a decent Lucene sort or ranking. Say I have a list of cities and their populations. If someone searches "new" or "london" I want the list of prefix matches ordered by population, and I have that working with a prefix search and an sort by field reversed, where there is a population field, IE New Mexico, New York; or London, Londonderry. However I also always want the exact matching name to be at the top. So in the case of "London" the list should show "London UK, London CT, Londonderry" even if Londonderry has a higher population than London CT. Does anyone have a single searcher solution?
lucene
null
null
null
null
null
open
Lucene exact ordering === I've had this long term issue in not quite understanding how to implement a decent Lucene sort or ranking. Say I have a list of cities and their populations. If someone searches "new" or "london" I want the list of prefix matches ordered by population, and I have that working with a prefix search and an sort by field reversed, where there is a population field, IE New Mexico, New York; or London, Londonderry. However I also always want the exact matching name to be at the top. So in the case of "London" the list should show "London UK, London CT, Londonderry" even if Londonderry has a higher population than London CT. Does anyone have a single searcher solution?
0
8,532
08/12/2008 06:04:48
459
08/05/2008 21:54:42
11
5
With Lucene: Why do I get a Too Many Clauses error if I do a prefix search?
I've had an app doing prefix searches for a while. Recently the index size was increased and it turned out that some prefixes were too darned numerous for lucene to handle. It kept throwing me a [Too Many Clauses][1] error, which was very frustrating as I kept looking at my JARs and confirming that none of the included code actually used a boolean query. Why doesn't it throw something like a Too Many Hits exception? And why does increasing the boolean query's static max clauses integer actually make this error go away, when I'm definitely only using a prefix query? Is there something fundamental to how queries are run that I'm not understanding; is it that they secretly become Boolean queries? [1]: http://lucene.apache.org/java/2_3_2/api/core/org/apache/lucene/search/BooleanQuery.TooManyClauses.html
exception
lucene
null
null
null
null
open
With Lucene: Why do I get a Too Many Clauses error if I do a prefix search? === I've had an app doing prefix searches for a while. Recently the index size was increased and it turned out that some prefixes were too darned numerous for lucene to handle. It kept throwing me a [Too Many Clauses][1] error, which was very frustrating as I kept looking at my JARs and confirming that none of the included code actually used a boolean query. Why doesn't it throw something like a Too Many Hits exception? And why does increasing the boolean query's static max clauses integer actually make this error go away, when I'm definitely only using a prefix query? Is there something fundamental to how queries are run that I'm not understanding; is it that they secretly become Boolean queries? [1]: http://lucene.apache.org/java/2_3_2/api/core/org/apache/lucene/search/BooleanQuery.TooManyClauses.html
0
8,545
08/12/2008 06:18:08
1,063
08/12/2008 05:40:42
11
3
Closet server versus Colo?
As a programmer I need a place to store my stuff. I've been running a server in my parents closet for a long time, but I recently came across a decent 2U server. I have no experience dealing with hosting companies, beyond the very cheap stuff, and I'm wondering what I should look for in a colo or if I should just keep my closet server.
hardware
storage
null
null
null
null
open
Closet server versus Colo? === As a programmer I need a place to store my stuff. I've been running a server in my parents closet for a long time, but I recently came across a decent 2U server. I have no experience dealing with hosting companies, beyond the very cheap stuff, and I'm wondering what I should look for in a colo or if I should just keep my closet server.
0
8,546
08/12/2008 06:19:38
195
08/03/2008 11:02:15
45
3
is there a "try to lock, skip if timed out" operation in C# ?
<p>I need to try to lock on an object, and if its already locked just continue (after time out, or without it).</p> <p>the C# lock statement is blocking.</p>
c#
multithreading
null
null
null
null
open
is there a "try to lock, skip if timed out" operation in C# ? === <p>I need to try to lock on an object, and if its already locked just continue (after time out, or without it).</p> <p>the C# lock statement is blocking.</p>
0
8,549
08/12/2008 06:22:06
1,065
08/12/2008 05:47:43
3
0
Visual Studio refactoring: Remove method
Is there any Visual Studio Add-In that can do the remove method refactoring? Suppose you have the following method: Result DoSomething(parameters) { return ComputeResult(parameters); } Or the variant where Result is void. The purpose of the refactoring is to replace all the calls to DoSomething with calls to ComputeResult or the expression that uses the parameters if ComputeResult is not a method call.
visual-studio
refactoring
methods
remove
null
null
open
Visual Studio refactoring: Remove method === Is there any Visual Studio Add-In that can do the remove method refactoring? Suppose you have the following method: Result DoSomething(parameters) { return ComputeResult(parameters); } Or the variant where Result is void. The purpose of the refactoring is to replace all the calls to DoSomething with calls to ComputeResult or the expression that uses the parameters if ComputeResult is not a method call.
0
8,566
08/12/2008 07:32:32
551
08/06/2008 16:24:59
65
4
Best way to access a control on another form in c#?
First off, this is a question about a desktop app using Windows Forms, not an ASP.Net question. I need to interact with controls on other forms. Trying to access the controls by using, for example, the following... otherForm.Controls["nameOfControl"].Visible = false; ...doesn't work the way I would expect. I end up with an exception thrown from `Main`. However, if I make the controls `public` instead of `private`, I can then access them directly, as so... otherForm.nameOfControl.Visible = false; But is that the best way to do it? Is making the controls `public` on the other form considered "best practice"? Is there a "better" way to access controls on another form?
windowsforms
c#
controls
bestpractices
null
null
open
Best way to access a control on another form in c#? === First off, this is a question about a desktop app using Windows Forms, not an ASP.Net question. I need to interact with controls on other forms. Trying to access the controls by using, for example, the following... otherForm.Controls["nameOfControl"].Visible = false; ...doesn't work the way I would expect. I end up with an exception thrown from `Main`. However, if I make the controls `public` instead of `private`, I can then access them directly, as so... otherForm.nameOfControl.Visible = false; But is that the best way to do it? Is making the controls `public` on the other form considered "best practice"? Is there a "better" way to access controls on another form?
0
8,569
08/12/2008 07:36:14
834
08/09/2008 07:29:24
11
3
What's your "best practice" for the first Java EE Spring project?
I'm currently trying to get into the Java EE development with the Spring framework. As I'm new to Spring, it is hard to imaging how a good running project should start off. Do you have any *best practices*, tipps or major *DO NOTs* for a starter? How did you start with Spring - big project or small tutorial-like applications? Which technology did you use right away: AOP, complex Hibernate...
java-ee
spring
aop
null
null
null
open
What's your "best practice" for the first Java EE Spring project? === I'm currently trying to get into the Java EE development with the Spring framework. As I'm new to Spring, it is hard to imaging how a good running project should start off. Do you have any *best practices*, tipps or major *DO NOTs* for a starter? How did you start with Spring - big project or small tutorial-like applications? Which technology did you use right away: AOP, complex Hibernate...
0
8,585
08/12/2008 07:53:40
143
08/02/2008 12:45:43
216
7
Watch for change in ip address status
Is there a way to watch for changes in the ip-address much the same as it is possible to watch for changes to files using the FileSystemWatcher? I'm connecting to a machine via tcp/ip but it takes a while until it gives me an ip-address. I would like to dim out the connect button until I have a valid ip-address.
windows
dotnet
null
null
null
null
open
Watch for change in ip address status === Is there a way to watch for changes in the ip-address much the same as it is possible to watch for changes to files using the FileSystemWatcher? I'm connecting to a machine via tcp/ip but it takes a while until it gives me an ip-address. I would like to dim out the connect button until I have a valid ip-address.
0
8,599
08/12/2008 08:08:11
974
08/11/2008 09:02:40
1
0
Best binary XML format for JavaME
Can anyone recommend a good binary XML format? It's for a JavaME application, so it needs to be a) Easy to implement on the server, and b) Easy to write a low-footprint parser for on a low-end JavaME client device. And it goes without saying that it needs to be smaller than XML, and faster to parse.
java
xml
mobile
java-me
null
null
open
Best binary XML format for JavaME === Can anyone recommend a good binary XML format? It's for a JavaME application, so it needs to be a) Easy to implement on the server, and b) Easy to write a low-footprint parser for on a low-end JavaME client device. And it goes without saying that it needs to be smaller than XML, and faster to parse.
0
8,604
08/12/2008 08:20:15
33
08/01/2008 12:32:10
242
22
HTML Email Editor in a Windows Forms Application
We are looking for a WYSIWYG editor control for our windows application (vb.net or c#) so that users can design HTML emails (to send using the SMTP objects in the dot net framework) before sending. Currently all the available editors we can find have one of the following issues: a)They rely on mshtml.dll or the web browser control which as proven for us to be unreliable as the html code and the editor get out of sync under windows 2000 (IE6) b)They are web based not a windows form control c)They place styles in the head of the document (see note below). Unfortunately as this [HTML email article][1] descries the only sure way of making HTML emails to work with styles is to use them inline which now seems to be unsupported in many editors. Does any one have any experience in this or could suggest a solution. [1]: http://www.xavierfrenette.com/articles/css-support-in-webmail/
c#
.net
vb.net
windowsforms
controls
null
open
HTML Email Editor in a Windows Forms Application === We are looking for a WYSIWYG editor control for our windows application (vb.net or c#) so that users can design HTML emails (to send using the SMTP objects in the dot net framework) before sending. Currently all the available editors we can find have one of the following issues: a)They rely on mshtml.dll or the web browser control which as proven for us to be unreliable as the html code and the editor get out of sync under windows 2000 (IE6) b)They are web based not a windows form control c)They place styles in the head of the document (see note below). Unfortunately as this [HTML email article][1] descries the only sure way of making HTML emails to work with styles is to use them inline which now seems to be unsupported in many editors. Does any one have any experience in this or could suggest a solution. [1]: http://www.xavierfrenette.com/articles/css-support-in-webmail/
0
8,607
08/12/2008 08:35:07
609
08/07/2008 10:26:12
16
1
Any good way to use Emacs for C# development?
Looking at the various C# modes for Emacs, I've found some very out of date packages: <ul> <li><a href="http://mfgames.com/linux/csharp-mode">C# Mode for Emacs</a></li> <li><a href="http://sourceforge.net/projects/csde/>CSDE - C# for Emacs</a></li> </ul> Is anybody using Emacs for C# development? What Emacs libraries do you use?
c#
emacs
null
null
null
null
open
Any good way to use Emacs for C# development? === Looking at the various C# modes for Emacs, I've found some very out of date packages: <ul> <li><a href="http://mfgames.com/linux/csharp-mode">C# Mode for Emacs</a></li> <li><a href="http://sourceforge.net/projects/csde/>CSDE - C# for Emacs</a></li> </ul> Is anybody using Emacs for C# development? What Emacs libraries do you use?
0
8,609
08/12/2008 08:40:42
116
08/02/2008 05:51:57
1,705
104
any sample MySQL databases I can download?
I'm doing some inter-database operational research... e.g. synchronizing Oracle, MySQL, etc. Are there any nice MySQL databases that I can download, so that I can test some importing on real-world cases? I'm thinking of some open project that might have a weekly data dump available for download. Of course, anything similar for Oracle, Sql Server, etc is welcome as well. Many TIA!
sql
database
mysql
null
null
null
open
any sample MySQL databases I can download? === I'm doing some inter-database operational research... e.g. synchronizing Oracle, MySQL, etc. Are there any nice MySQL databases that I can download, so that I can test some importing on real-world cases? I'm thinking of some open project that might have a weekly data dump available for download. Of course, anything similar for Oracle, Sql Server, etc is welcome as well. Many TIA!
0
8,622
08/12/2008 08:59:59
1,007
08/11/2008 12:50:43
1
1
Any good book on best practice and guidelines in developing a SDK in C?
I'm developing a small SDK in C, is there any good book or article on best practice and guidelines in the subject? I mean functions design, source code organization, portability issues etc.
c
sdk
null
null
null
null
open
Any good book on best practice and guidelines in developing a SDK in C? === I'm developing a small SDK in C, is there any good book or article on best practice and guidelines in the subject? I mean functions design, source code organization, portability issues etc.
0
8,624
08/12/2008 09:08:05
982
08/11/2008 12:08:33
3
2
Best format for displaying rendered time on a webpage
I've started to add the time taken to render a page to the footer of our internal web applications. Currently it appears like this > Rendered in 0.062 seconds Occasionally I get rendered times like this > Rendered in 0.000 seconds Currently it's only meant to be a guide for users to judge whether a page is quick to load or not, allowing them to quickly inform us if a page is taking 17 seconds rather than the usual 0.5. My question is what format should the time be in? At which point should I switch to a statement such as > Rendered in less than a second I like seeing the tenths of a second but the second example above is of no use to anyone, in fact it just highlights the limits of the calculation I use find the render time. I'd rather not let the users see that at all! Any answers welcome, including whether anything should be included on the page. Thanks
render
null
null
null
null
null
open
Best format for displaying rendered time on a webpage === I've started to add the time taken to render a page to the footer of our internal web applications. Currently it appears like this > Rendered in 0.062 seconds Occasionally I get rendered times like this > Rendered in 0.000 seconds Currently it's only meant to be a guide for users to judge whether a page is quick to load or not, allowing them to quickly inform us if a page is taking 17 seconds rather than the usual 0.5. My question is what format should the time be in? At which point should I switch to a statement such as > Rendered in less than a second I like seeing the tenths of a second but the second example above is of no use to anyone, in fact it just highlights the limits of the calculation I use find the render time. I'd rather not let the users see that at all! Any answers welcome, including whether anything should be included on the page. Thanks
0
8,625
08/12/2008 09:13:23
832
08/09/2008 06:51:40
137
24
Generic Type Conversion FROM String
Here is the problem I am having, I have a class that I want to use to store "properties" for another class, these properties simply have a name and a value. Ideally, what I would like is to be able to add _typed_ properties, so that the "value" returned is always of the type that I want it to be. The type should always be a primitive. This class subclasses an abstract class which basically stores the name and value as string. The idea being that this subclass will add some type-safety to the base class (as well as saving me on some conversion). So, I have created a class which is (roughly) this: public class Property<DataType> : Property { public DataType TypedValue { get { // Having problems here! } set { base.Value = value.ToString();} } } So the question is: **Is there a "generic" way to convert from string back to a primitive?** I can't seem to find any generic interface that links the conversion across the board (something like _ITryParsable_ would have been ideal!).
c#
generics
primitives
type-safety
null
null
open
Generic Type Conversion FROM String === Here is the problem I am having, I have a class that I want to use to store "properties" for another class, these properties simply have a name and a value. Ideally, what I would like is to be able to add _typed_ properties, so that the "value" returned is always of the type that I want it to be. The type should always be a primitive. This class subclasses an abstract class which basically stores the name and value as string. The idea being that this subclass will add some type-safety to the base class (as well as saving me on some conversion). So, I have created a class which is (roughly) this: public class Property<DataType> : Property { public DataType TypedValue { get { // Having problems here! } set { base.Value = value.ToString();} } } So the question is: **Is there a "generic" way to convert from string back to a primitive?** I can't seem to find any generic interface that links the conversion across the board (something like _ITryParsable_ would have been ideal!).
0
8,626
08/12/2008 09:13:40
1,065
08/12/2008 05:47:43
30
3
Globus Toolkit virtual machine
Is there anyplace where one can download a virtual machine containing a working install of some Linux distro with Globus Toolkit and some development tools (Java) for testing purposes? A real deployment of a grid is more complicated but I just need something portable, for development.
linux
globustoolkit
virtual-machine
null
null
null
open
Globus Toolkit virtual machine === Is there anyplace where one can download a virtual machine containing a working install of some Linux distro with Globus Toolkit and some development tools (Java) for testing purposes? A real deployment of a grid is more complicated but I just need something portable, for development.
0
8,648
08/12/2008 10:32:40
254
08/04/2008 05:45:21
26
0
How can I empty the recycle bin for all users from a Windows service application in c#
I'm looking for a c# snippet which I can insert in a Windows service. The code must empty the recycle bin for all users on the computer. I have previously tried using SHEmptyRecycleBin (ref http://www.codeproject.com/KB/cs/Empty_Recycle_Bin.aspx) however the code doesn't work when ran from a windows service as the service is running with local system privileges.
c#
recycle-bin
null
null
null
null
open
How can I empty the recycle bin for all users from a Windows service application in c# === I'm looking for a c# snippet which I can insert in a Windows service. The code must empty the recycle bin for all users on the computer. I have previously tried using SHEmptyRecycleBin (ref http://www.codeproject.com/KB/cs/Empty_Recycle_Bin.aspx) however the code doesn't work when ran from a windows service as the service is running with local system privileges.
0
8,651
08/12/2008 10:37:50
383
08/05/2008 10:46:37
1,454
163
Import Namespace System.Query
I am trying to load Linq on my .Net 3.5 enabled web server by adding the following to my .aspx page: <%@ Import Namespace="System.Query" %> However, this fails and tells me it cannot find the namespace. > The type or namespace name 'Query' does not exist in the namespace 'System' I have also tried with no luck: - System.Data.Linq - System.Linq - System.Xml.Linq I believe that .Net 3.5 is working because **var hello = "Hello World"** seems to work. Can anyone help please? Cheers, Stephen
asp.net
linq
null
null
null
null
open
Import Namespace System.Query === I am trying to load Linq on my .Net 3.5 enabled web server by adding the following to my .aspx page: <%@ Import Namespace="System.Query" %> However, this fails and tells me it cannot find the namespace. > The type or namespace name 'Query' does not exist in the namespace 'System' I have also tried with no luck: - System.Data.Linq - System.Linq - System.Xml.Linq I believe that .Net 3.5 is working because **var hello = "Hello World"** seems to work. Can anyone help please? Cheers, Stephen
0
8,653
08/12/2008 10:40:05
1,076
08/12/2008 10:25:44
1
0
Numerical formatting using String.Format
Are there any codes that allow for numerical formatting of data when using string.format?
c#
null
null
null
null
null
open
Numerical formatting using String.Format === Are there any codes that allow for numerical formatting of data when using string.format?
0
8,669
08/12/2008 10:54:54
1,030
08/11/2008 15:40:52
36
2
Is there some way of recycling a Crystal Reports dataset?
I'm trying to write a Crystal Report which has totals grouped in a different way to the main report. The only way I've been able to do this so far is to use a subreport for the totals, but it means having to hit the data source again to retrieve the same data, which seems like nonsense. Here's a simplified example: date name earnings source location ----------------------------------------------------------- 12-AUG-2008 Tom $50.00 washing cars uptown 12-AUG-2008 Dick $100.00 washing cars downtown { main report } 12-AUG-2008 Harry $75.00 mowing lawns around town total earnings for washing cars: $150.00 { subreport } total earnings for mowing lawns: $75.00 date name earnings source location ----------------------------------------------------------- 13-AUG-2008 John $95.00 dog walking downtown 13-AUG-2008 Jane $105.00 washing cars around town { main report } 13-AUG-2008 Dave $65.00 mowing lawns around town total earnings for dog walking: $95.00 total earnings for washing cars: $105.00 { subreport } total earnings for mowing lawns: $65.00 In this example, the main report is grouped by 'date', but the totals are grouped additionally by 'source'. I've looked up examples of using running totals, but they don't really do what I need. Isn't there some way of storing the result set and having both the main report and the subreport reference the same data?
crystalreports11
subreport
grouping
dataset
null
null
open
Is there some way of recycling a Crystal Reports dataset? === I'm trying to write a Crystal Report which has totals grouped in a different way to the main report. The only way I've been able to do this so far is to use a subreport for the totals, but it means having to hit the data source again to retrieve the same data, which seems like nonsense. Here's a simplified example: date name earnings source location ----------------------------------------------------------- 12-AUG-2008 Tom $50.00 washing cars uptown 12-AUG-2008 Dick $100.00 washing cars downtown { main report } 12-AUG-2008 Harry $75.00 mowing lawns around town total earnings for washing cars: $150.00 { subreport } total earnings for mowing lawns: $75.00 date name earnings source location ----------------------------------------------------------- 13-AUG-2008 John $95.00 dog walking downtown 13-AUG-2008 Jane $105.00 washing cars around town { main report } 13-AUG-2008 Dave $65.00 mowing lawns around town total earnings for dog walking: $95.00 total earnings for washing cars: $105.00 { subreport } total earnings for mowing lawns: $65.00 In this example, the main report is grouped by 'date', but the totals are grouped additionally by 'source'. I've looked up examples of using running totals, but they don't really do what I need. Isn't there some way of storing the result set and having both the main report and the subreport reference the same data?
0
8,676
08/12/2008 11:04:11
475
08/06/2008 07:16:20
192
16
Entity Framework vs LINQ to SQL
Now that .NET v3.5 SP1 has been released (along with VS2008 SP1), we now have access to the .NET entity framework. My question is this. When trying to decide between using the Entity Framework and LINQ to SQL as an ORM, what's the difference?! The way I understand it, the Entity Framework (when used with LINQ to Entities) is a 'big brother' to LINQ to SQL? If this is the case - what advantages does it have? What can it do that LINQ to SQL can't do on its own? Any help would be greatly appreciated! Thanks in advance...
.net
linq-to-sql
entityframework
null
null
null
open
Entity Framework vs LINQ to SQL === Now that .NET v3.5 SP1 has been released (along with VS2008 SP1), we now have access to the .NET entity framework. My question is this. When trying to decide between using the Entity Framework and LINQ to SQL as an ORM, what's the difference?! The way I understand it, the Entity Framework (when used with LINQ to Entities) is a 'big brother' to LINQ to SQL? If this is the case - what advantages does it have? What can it do that LINQ to SQL can't do on its own? Any help would be greatly appreciated! Thanks in advance...
0
8,685
08/12/2008 11:14:27
1,149
08/12/2008 20:58:23
1
0
Advancing through relative dates with strtotime()
I'm trying to use strtotime() to respond to a button click to advance -1 and +1 days (two buttons) relative to the day advanced to on the previous click. Example: It's the 10th of the month, I click "-1 day" button, and now the date reads as the 9th. I click the "-1 day" button again and now the readout states the 8th day. I click the "+1 day" button and now the readout states it's the 9th. I understand the buttons and the displaying the date, and using $_GET and php to pass info, but how do I get strtotime() to work on the relative date from the last time the time travel script was called. My work so far has let me show yesterday and today relative to *now* but not relative to, for example, the day before yesterday, or the day after tomorrow. Or if I use my "last monday" button, the day before or after whatever that day is.
php
null
null
null
null
null
open
Advancing through relative dates with strtotime() === I'm trying to use strtotime() to respond to a button click to advance -1 and +1 days (two buttons) relative to the day advanced to on the previous click. Example: It's the 10th of the month, I click "-1 day" button, and now the date reads as the 9th. I click the "-1 day" button again and now the readout states the 8th day. I click the "+1 day" button and now the readout states it's the 9th. I understand the buttons and the displaying the date, and using $_GET and php to pass info, but how do I get strtotime() to work on the relative date from the last time the time travel script was called. My work so far has let me show yesterday and today relative to *now* but not relative to, for example, the day before yesterday, or the day after tomorrow. Or if I use my "last monday" button, the day before or after whatever that day is.
0
8,688
08/12/2008 11:20:43
1,075
08/12/2008 10:13:30
11
3
Install Visual Studio 2008 Sp1 on "D" Drive
I am trying to install VS2008 sp1 to my work machine - it has a pathetic 10Gb C drive. The SP1 bootstrapper doesn't give the option to install items to D, only C. It needs 3Gb free and the machine only has about 700Mb. VS allowed me to install to D originally why not the SP. The only thing I can think of that it requires system files installed in Windows etc, but I can't believe there are 3Gb worth of system files?
vs2008
sp1
null
null
null
null
open
Install Visual Studio 2008 Sp1 on "D" Drive === I am trying to install VS2008 sp1 to my work machine - it has a pathetic 10Gb C drive. The SP1 bootstrapper doesn't give the option to install items to D, only C. It needs 3Gb free and the machine only has about 700Mb. VS allowed me to install to D originally why not the SP. The only thing I can think of that it requires system files installed in Windows etc, but I can't believe there are 3Gb worth of system files?
0
8,691
08/12/2008 11:25:41
194
08/03/2008 10:56:49
457
37
User Control Property Designer Properties
For a C# UserControl on Windows Mobile (though please answer if you know it for full Windows...it might work) how do you change what shows up in the Designer Properties window for one of the Control's public Properties. For example: private Color blah = Color.Black; public Color Blah { get { return this.blah; } set { this.blah = value; } } This shows up for the control, but it's in the "Misc" category and has no description or default value. I've tried using the settings in System.ComponentModel like "DesignerCategory", such as: [DesignerCategory("Custom")] But says this is only valid for class declarations... could've sworn it was the System.ComponentModel items I used before...
c#
windows-mobile
usercontrols
null
null
null
open
User Control Property Designer Properties === For a C# UserControl on Windows Mobile (though please answer if you know it for full Windows...it might work) how do you change what shows up in the Designer Properties window for one of the Control's public Properties. For example: private Color blah = Color.Black; public Color Blah { get { return this.blah; } set { this.blah = value; } } This shows up for the control, but it's in the "Misc" category and has no description or default value. I've tried using the settings in System.ComponentModel like "DesignerCategory", such as: [DesignerCategory("Custom")] But says this is only valid for class declarations... could've sworn it was the System.ComponentModel items I used before...
0
8,715
08/12/2008 12:01:01
908
08/10/2008 09:52:02
11
1
Instrumenting Database Access
Jeff mentioned in one of the podcasts that one of the things he always does is put in instrumentation for database calls, so that he can tell what queries are causing slowness etc. This is something I've measured in the past using SQL Profiler, but I'm interested in what strategies other people have used to include this as part of the application. Is it simply a case of including a timer across each database call and logging the result, or is there a 'neater' way of doing it? Maybe there's a framework that does this for you already, or is there a flag I could enable in e.g. Linq-to-SQL that would provide similar functionality. I mainly use c# but would also be interested in seeing methods from different languages.
database
logging
instrumentation
null
null
null
open
Instrumenting Database Access === Jeff mentioned in one of the podcasts that one of the things he always does is put in instrumentation for database calls, so that he can tell what queries are causing slowness etc. This is something I've measured in the past using SQL Profiler, but I'm interested in what strategies other people have used to include this as part of the application. Is it simply a case of including a timer across each database call and logging the result, or is there a 'neater' way of doing it? Maybe there's a framework that does this for you already, or is there a flag I could enable in e.g. Linq-to-SQL that would provide similar functionality. I mainly use c# but would also be interested in seeing methods from different languages.
0
8,722
08/12/2008 12:04:14
51
08/01/2008 13:31:13
959
50
How do you use PowerShell?
[Windows PowerShell][1] came out last year and got great reviews from many .net bloggers ([Hanselman][2] comes to mind). It seemed to be touted as a great new utility that somehow made everything that you would ever do on the command line easier, and integrated with .Net. However, the more I read about it, the more it seems to be a tool that is great for IT professionals, and not much use for developers. Do you use PowerShell in your dev work? If so, how? Is it worth learning? [1]: http://www.microsoft.com/windowsserver2003/technologies/management/powershell/default.mspx [2]: http://www.hanselman.com/blog/CategoryView.aspx?category=PowerShell
.net
shell
powershell
scripting
command-line
null
open
How do you use PowerShell? === [Windows PowerShell][1] came out last year and got great reviews from many .net bloggers ([Hanselman][2] comes to mind). It seemed to be touted as a great new utility that somehow made everything that you would ever do on the command line easier, and integrated with .Net. However, the more I read about it, the more it seems to be a tool that is great for IT professionals, and not much use for developers. Do you use PowerShell in your dev work? If so, how? Is it worth learning? [1]: http://www.microsoft.com/windowsserver2003/technologies/management/powershell/default.mspx [2]: http://www.hanselman.com/blog/CategoryView.aspx?category=PowerShell
0
8,742
08/12/2008 12:20:29
1,108
08/12/2008 12:16:28
1
0
Getting accurate ticks from a timer in C#
I'm trying to rebuild an old metronome application that was originally written using MFC in C++ to be written in .NET using C#. One of the issues I'm running into is getting the timer to "tick" accurately enough. For example, assuming an easy BPM (beats per minute) of 120, the timer should tick every .5 seconds (or 500 milliseconds). Using this as the basis for the ticks, however, isn't entirely accurate as .NET only guarantees that your timer will not tick before the elapsed time has passed. Currently, to get around this for the same 120 BPM example used above, I am setting the ticks to something like 100 milliseconds and only playing the click sound on every 5th timer tick. This does improve the accuracy quite a bit, but if feels like a bit of a hack. So, what is the best way to get accurate ticks? I know there are more timers available than the windows forms timer that is readily available in Visual Studio, but I'm not really familiar with them.
.net
timer
null
null
null
null
open
Getting accurate ticks from a timer in C# === I'm trying to rebuild an old metronome application that was originally written using MFC in C++ to be written in .NET using C#. One of the issues I'm running into is getting the timer to "tick" accurately enough. For example, assuming an easy BPM (beats per minute) of 120, the timer should tick every .5 seconds (or 500 milliseconds). Using this as the basis for the ticks, however, isn't entirely accurate as .NET only guarantees that your timer will not tick before the elapsed time has passed. Currently, to get around this for the same 120 BPM example used above, I am setting the ticks to something like 100 milliseconds and only playing the click sound on every 5th timer tick. This does improve the accuracy quite a bit, but if feels like a bit of a hack. So, what is the best way to get accurate ticks? I know there are more timers available than the windows forms timer that is readily available in Visual Studio, but I'm not really familiar with them.
0
8,747
08/12/2008 12:24:11
614
08/07/2008 10:47:20
21
5
Learning Version Control, and learning it good
Where should I start learning about version control systems? I've used SVN, Team Foundation, and Sourcesafe in the past but I don't really feel like I grasp it completely, and my team doesn't seem to grasp it either. Which points are the most important to master? I realise this differs from VCS to VCS, but for the sake of this question we can assume that Subversion is the VCS I'm the most interested in learning about. Also, if you could, please recommend any books on the subject that you find useful.
subversion
version-control
null
null
null
null
open
Learning Version Control, and learning it good === Where should I start learning about version control systems? I've used SVN, Team Foundation, and Sourcesafe in the past but I don't really feel like I grasp it completely, and my team doesn't seem to grasp it either. Which points are the most important to master? I realise this differs from VCS to VCS, but for the sake of this question we can assume that Subversion is the VCS I'm the most interested in learning about. Also, if you could, please recommend any books on the subject that you find useful.
0
8,748
08/12/2008 12:24:41
1,061
08/12/2008 01:10:24
1
4
Should I move from C++ to Python? ... Or another language?
In the company I work for, we do a lot of file-based transaction processing. The processing centers around the conversion of files between numerous formats to suit numerous systems in numerous companies. The processing almost always involves an XML stage and can include a lot of text parsing, database lookups, data conversion and data validation. Currently the programs performing all these tasks are written in C++ and they perform quite quickly all on one average server. I'm investigating the possibilities of using a more "modern" language that newer graduate programmers are more likely to be familiar with. (Correct memory allocation in C++ seems to causes problems with a lot of newer programmers these days) Based on the brief information provided, would a language such as python provide the required functionality and performance, as well as addressing the memory allocation (and various other C++ related) problems which arise? I like the idea of not needing to compile the programs each time we make a change. I understand that the interpreted languages probably wont hit the same performance we currently get. Our systems are Linux based which also restrict some options. Any comments on the functionality and performance available with Python or suggestions of alternative languages would be much appreciated.
c++
python
null
null
null
null
open
Should I move from C++ to Python? ... Or another language? === In the company I work for, we do a lot of file-based transaction processing. The processing centers around the conversion of files between numerous formats to suit numerous systems in numerous companies. The processing almost always involves an XML stage and can include a lot of text parsing, database lookups, data conversion and data validation. Currently the programs performing all these tasks are written in C++ and they perform quite quickly all on one average server. I'm investigating the possibilities of using a more "modern" language that newer graduate programmers are more likely to be familiar with. (Correct memory allocation in C++ seems to causes problems with a lot of newer programmers these days) Based on the brief information provided, would a language such as python provide the required functionality and performance, as well as addressing the memory allocation (and various other C++ related) problems which arise? I like the idea of not needing to compile the programs each time we make a change. I understand that the interpreted languages probably wont hit the same performance we currently get. Our systems are Linux based which also restrict some options. Any comments on the functionality and performance available with Python or suggestions of alternative languages would be much appreciated.
0
8,749
08/12/2008 12:26:50
96
08/01/2008 18:33:48
161
12
Printing a PDF in .NET
It's the "printing question guy" again. Looking for a third-party solution to print PDFs, preferable from a service. I have seen some arguments against it, but due to our use case, this really is the preferred solution - the service will be receiving messages from a messaging bus, and there shouldn't be any sort of delay between the receipt of that message and the printing of the report. So far, I've found 1 solution from [PDF Tools][1] that seems very nice, and very flexible. The problem is that it's licensed per server. If anyone knows of any third-party solutions that have a seat license (per developer, unlimited runtime distribution), that would be ***much*** preferred. [1]: http://www.pdf-tools.com/asp/products.asp?name=PRNA
printing
pdf
.net
service
null
null
open
Printing a PDF in .NET === It's the "printing question guy" again. Looking for a third-party solution to print PDFs, preferable from a service. I have seen some arguments against it, but due to our use case, this really is the preferred solution - the service will be receiving messages from a messaging bus, and there shouldn't be any sort of delay between the receipt of that message and the printing of the report. So far, I've found 1 solution from [PDF Tools][1] that seems very nice, and very flexible. The problem is that it's licensed per server. If anyone knows of any third-party solutions that have a seat license (per developer, unlimited runtime distribution), that would be ***much*** preferred. [1]: http://www.pdf-tools.com/asp/products.asp?name=PRNA
0
8,756
08/12/2008 12:29:32
267
08/04/2008 10:11:06
1,147
72
iPhone web applications, templates, frameworks?
Does anyone have any good starting points for me when looking at making web pages/sites/applications specifically for viewing on the iPhone? I've looked at templates like the one [Joe Hewitt](http://blog.wired.com/monkeybites/2007/07/meet-joe-hewitt.html) has made, and also seen some templates I can purchase, which I haven't done yet. I figured someone else had already started on this track and decided that I could probably leech on their newfound knowledge :) So, does anyone have any pointers? I'm well aware of the problem that the more such a template/framework makes a web app look like a native iPhone app, the more likely I'm going to get into trouble because it just isn't, but for now I want a framework I can start building on, and then in the process figure out how to make it distinctive enough to be perceived as a web app as well as looking like a native iPhone application. Specifically I'm looking for features like: * stylesheets set up, or pointers to how to do them for iPhone * page flipping animation, ie. pick an item in a list, list scrolls out of view to the left and information for item scrolls in from the right * the animation part would have to work with dynamic pages, ie. not just one big page that has divs set up for each sub-item, which at least one such framework had as a sort of quick fix, I would need to have list item picking load the *page* for that item, and then when loaded, scroll to it
iphone
web-applications
null
null
null
02/12/2012 19:52:58
not constructive
iPhone web applications, templates, frameworks? === Does anyone have any good starting points for me when looking at making web pages/sites/applications specifically for viewing on the iPhone? I've looked at templates like the one [Joe Hewitt](http://blog.wired.com/monkeybites/2007/07/meet-joe-hewitt.html) has made, and also seen some templates I can purchase, which I haven't done yet. I figured someone else had already started on this track and decided that I could probably leech on their newfound knowledge :) So, does anyone have any pointers? I'm well aware of the problem that the more such a template/framework makes a web app look like a native iPhone app, the more likely I'm going to get into trouble because it just isn't, but for now I want a framework I can start building on, and then in the process figure out how to make it distinctive enough to be perceived as a web app as well as looking like a native iPhone application. Specifically I'm looking for features like: * stylesheets set up, or pointers to how to do them for iPhone * page flipping animation, ie. pick an item in a list, list scrolls out of view to the left and information for item scrolls in from the right * the animation part would have to work with dynamic pages, ie. not just one big page that has divs set up for each sub-item, which at least one such framework had as a sort of quick fix, I would need to have list item picking load the *page* for that item, and then when loaded, scroll to it
4
8,761
08/12/2008 12:33:10
1,078
08/12/2008 10:39:00
1
0
Find out which colours are being used with the MFC Feature pack Office 2007 application style
I'm updating some of our legacy C++ code to use the "MFC feature pack" that Microsoft released for Visual Studio 2008. We've used the new classes to derive our application from CFrameWndEx, and are applying the Office 2007 styles to give our application a more modern appearance. This gives us gradient filled window titles, status bars etc, and the use of the ribbon toolbars. However, our application contains some owner drawn controls, and I'd like to update these to match the color scheme used by the feature pack. Ideally I'd like to know the light and shaded toolbar colors that are currently in use. I've had a hunt around the documentation and web and have not yet found anything. Does anyone know how to find this information out?
mfc
feature
pack
colors
application
null
open
Find out which colours are being used with the MFC Feature pack Office 2007 application style === I'm updating some of our legacy C++ code to use the "MFC feature pack" that Microsoft released for Visual Studio 2008. We've used the new classes to derive our application from CFrameWndEx, and are applying the Office 2007 styles to give our application a more modern appearance. This gives us gradient filled window titles, status bars etc, and the use of the ribbon toolbars. However, our application contains some owner drawn controls, and I'd like to update these to match the color scheme used by the feature pack. Ideally I'd like to know the light and shaded toolbar colors that are currently in use. I've had a hunt around the documentation and web and have not yet found anything. Does anyone know how to find this information out?
0
8,763
08/12/2008 12:34:07
1,108
08/12/2008 12:16:28
1
0
Best way to play MIDI sounds using C#
'm trying to rebuild an old metronome application that was originally written using MFC in C++ to be written in .NET using C#. One of the issues I'm running into is playing the midi files that are used to represent the metronome "clicks". I've found a few articles online about playing MIDI in .NET, but most of them seem to rely on custom libraries that someone has cobbled together and made available. I'm not averse to using these, but I'd rather understand for myself how this is being done, since it seems like it *should* be a mostly trivial exercise. So, am I missing something? Or is it just difficult to use MIDI inside of a .NET application?
c#
.net
midi
null
null
null
open
Best way to play MIDI sounds using C# === 'm trying to rebuild an old metronome application that was originally written using MFC in C++ to be written in .NET using C#. One of the issues I'm running into is playing the midi files that are used to represent the metronome "clicks". I've found a few articles online about playing MIDI in .NET, but most of them seem to rely on custom libraries that someone has cobbled together and made available. I'm not averse to using these, but I'd rather understand for myself how this is being done, since it seems like it *should* be a mostly trivial exercise. So, am I missing something? Or is it just difficult to use MIDI inside of a .NET application?
0
8,790
08/12/2008 13:04:28
292
08/04/2008 13:14:31
260
13
Ant build scripts, antcall, dependancies, etc
I have a build script and as part of that script it copies a jar file to a directory, for ease lets call it the utils jar. the utils jar is built by another build script sitting in another directory. What im trying to do have my build script run the utils build script so that I can ensure the utils jar is up to date. So I know I need to import the utils build file. <import file="../utils/build/build.xml" /> Which doesn't work because the import task, unlike almost every other ant taks, doesn't run from basedir, it runs from the pwd. So to get around that I have this little ditty, which does successfully import the build file <property name="baseDirUpOne" location=".." /> <import file="${baseDirUpOne}/utils/build/build.xml" /> So now that ive solved my import problem I need to call the task, well that should be easy right: <antcall target="utils.package" /> *note that in the above, utils is the project name of ../utils/build/build.xml* the problem I'm now running into is that ant call doesn't execute in ../utils/build so what I need, and cant find, is a runat property or something similar, essentially: <antcall target="utils.package" runat="../utils/build" /> The reason I need this is that in my utils build file the step to select which code to copy to the jar is based on relative paths so as to avoid hardcoding paths in my ant file. Any ideas?
buildprocess
ant
null
null
null
null
open
Ant build scripts, antcall, dependancies, etc === I have a build script and as part of that script it copies a jar file to a directory, for ease lets call it the utils jar. the utils jar is built by another build script sitting in another directory. What im trying to do have my build script run the utils build script so that I can ensure the utils jar is up to date. So I know I need to import the utils build file. <import file="../utils/build/build.xml" /> Which doesn't work because the import task, unlike almost every other ant taks, doesn't run from basedir, it runs from the pwd. So to get around that I have this little ditty, which does successfully import the build file <property name="baseDirUpOne" location=".." /> <import file="${baseDirUpOne}/utils/build/build.xml" /> So now that ive solved my import problem I need to call the task, well that should be easy right: <antcall target="utils.package" /> *note that in the above, utils is the project name of ../utils/build/build.xml* the problem I'm now running into is that ant call doesn't execute in ../utils/build so what I need, and cant find, is a runat property or something similar, essentially: <antcall target="utils.package" runat="../utils/build" /> The reason I need this is that in my utils build file the step to select which code to copy to the jar is based on relative paths so as to avoid hardcoding paths in my ant file. Any ideas?
0
8,795
08/12/2008 13:09:22
1,109
08/12/2008 12:16:58
1
3
Is there any list datatype in MySQL stored procedures, or a way to emulate them?
I would like to create a stored procedure in MySQL that took a list as argument. For example, say that I would like to be able to set multiple tags for an item in one call, then what I want to do is to define a procedure that takes the ID of the item and a list of tags to set. However, I can't seem to find any way to do this, there is no list datatype, as far as I'm aware, but can it be emulated somehow? Could the list of tags be a comma-separated string, which can somehow be split and looped over? How do you usually work with lists in MySQL stored procedures?
mysql
storedprocedures
null
null
null
null
open
Is there any list datatype in MySQL stored procedures, or a way to emulate them? === I would like to create a stored procedure in MySQL that took a list as argument. For example, say that I would like to be able to set multiple tags for an item in one call, then what I want to do is to define a procedure that takes the ID of the item and a list of tags to set. However, I can't seem to find any way to do this, there is no list datatype, as far as I'm aware, but can it be emulated somehow? Could the list of tags be a comma-separated string, which can somehow be split and looped over? How do you usually work with lists in MySQL stored procedures?
0
8,800
08/12/2008 13:12:50
61
08/01/2008 14:21:00
418
38
[C#] Best implementation for Key Value Pair Data Structure?
So I've been poking around with C# a bit lately, and all the Generic Collections have me a little confused. Say I wanted to represent a data structure where the head of a tree was a key value pair, and then there is one optional list of key value pairs below that (but no more levels than these). Would this be suitable? public class TokenTree { public TokenTree() { /* I must admit to not fully understanding this, * I got it from msdn. As far as I can tell, IDictionary is an * interface, and Dictionary is the default implementation of * that interface, right? */ SubPairs = new Dictionary<string, string>(); } public string Key; public string Value; public IDictionary<string, string> SubPairs; } It's only really a simple shunt for passing around data.
c#
datastructure
collections
null
null
null
open
[C#] Best implementation for Key Value Pair Data Structure? === So I've been poking around with C# a bit lately, and all the Generic Collections have me a little confused. Say I wanted to represent a data structure where the head of a tree was a key value pair, and then there is one optional list of key value pairs below that (but no more levels than these). Would this be suitable? public class TokenTree { public TokenTree() { /* I must admit to not fully understanding this, * I got it from msdn. As far as I can tell, IDictionary is an * interface, and Dictionary is the default implementation of * that interface, right? */ SubPairs = new Dictionary<string, string>(); } public string Key; public string Value; public IDictionary<string, string> SubPairs; } It's only really a simple shunt for passing around data.
0
8,807
08/12/2008 13:15:46
31,505
2008-09-01
1
0
Cannot add WebViewer of ActiveReports to an ASP.NET page
I installed ActiveReports from their site. The version was labeled as ".NET 2.0 build 5.2.1013.2 (for Visual Studio 2005 and 2008)". I have an ASP.NET project in VS 2008 which has 2.0 as target framework. I added all the tools in the DataDynamics namespace to the toolbox, created a new project, added a new report. When I drag and drop the WebViewer control to a page in the design view, nothing happens. No mark up is added, no report viewer is displayed on the page. Also I noticed that there are no tags related to DataDynamics components in my web.config file. Am I missing some configuration?
activereports
null
null
null
null
null
open
Cannot add WebViewer of ActiveReports to an ASP.NET page === I installed ActiveReports from their site. The version was labeled as ".NET 2.0 build 5.2.1013.2 (for Visual Studio 2005 and 2008)". I have an ASP.NET project in VS 2008 which has 2.0 as target framework. I added all the tools in the DataDynamics namespace to the toolbox, created a new project, added a new report. When I drag and drop the WebViewer control to a page in the design view, nothing happens. No mark up is added, no report viewer is displayed on the page. Also I noticed that there are no tags related to DataDynamics components in my web.config file. Am I missing some configuration?
0
8,830
08/12/2008 13:43:30
738
08/08/2008 13:15:44
1
0
Not showing Dialog when opening file in Acrobat Pro using Applescript
When opening Adobe Acrobat Pro, whether it be through Applescript or finder, the introductory dialog is shown. Is there a way to not show this dialog without already having checked the "Don't Show Again" option when opening a document using Applescript? Photoshop and Illustrator Applescript libraries have ways of setting interaction levels and not showing dialogs, but I can't seem to find the option in Acrobat.
osx
adobe
applescript
acrobat
null
null
open
Not showing Dialog when opening file in Acrobat Pro using Applescript === When opening Adobe Acrobat Pro, whether it be through Applescript or finder, the introductory dialog is shown. Is there a way to not show this dialog without already having checked the "Don't Show Again" option when opening a document using Applescript? Photoshop and Illustrator Applescript libraries have ways of setting interaction levels and not showing dialogs, but I can't seem to find the option in Acrobat.
0
8,832
08/12/2008 13:44:06
1,025
08/11/2008 14:56:52
1
0
mod_rewrite to alias one file suffix type to another
I hope I can explain this clearly enough, but if not let me know and I'll try to clarify. I'm currently developing a site using ColdFusion and have a mod_rewrite rule in place to make it look like the site is using PHP. Any requests for index.php get processed by index.cfm (the rule maps *.php to *.cfm). This works great - so far, so good. The problem is that I want to return a 404 status code if index.cfm (or any ColdFusion page) is requested directly. If I try to block access to *.cfm files using mod_rewrite it also returns a 404 for requests to *.php. I figure I might have to change my Apache config rather than use .htaccess, but any help is greatly appreciated. Thanks, James
apache
mod-rewrite
null
null
null
null
open
mod_rewrite to alias one file suffix type to another === I hope I can explain this clearly enough, but if not let me know and I'll try to clarify. I'm currently developing a site using ColdFusion and have a mod_rewrite rule in place to make it look like the site is using PHP. Any requests for index.php get processed by index.cfm (the rule maps *.php to *.cfm). This works great - so far, so good. The problem is that I want to return a 404 status code if index.cfm (or any ColdFusion page) is requested directly. If I try to block access to *.cfm files using mod_rewrite it also returns a 404 for requests to *.php. I figure I might have to change my Apache config rather than use .htaccess, but any help is greatly appreciated. Thanks, James
0
8,842
08/12/2008 13:53:25
1,121
08/12/2008 13:53:25
1
0
Ajax project suggestion.
Yesterday, a friend of mine asked me to suggest to him an interesting Ajax based project to do in his spare. I first thought that it'll be an easy task but no idea came out! So is there any interesting idea out there? The difficulty level wouldn't be a problem as he is willing to learn Ajax and for me, nothing better than a hard one to start with.
ajax
project
suggestion
null
null
11/07/2011 11:05:50
not constructive
Ajax project suggestion. === Yesterday, a friend of mine asked me to suggest to him an interesting Ajax based project to do in his spare. I first thought that it'll be an easy task but no idea came out! So is there any interesting idea out there? The difficulty level wouldn't be a problem as he is willing to learn Ajax and for me, nothing better than a hard one to start with.
4
8,849
08/12/2008 13:57:04
1,048
08/11/2008 19:34:31
1
0
SharePoint - Connection String dialog box during FeatureActivated event
Does anyone know if it is possible to display a prompt to a user/administrator when activating or installing a sharepoint feature? I am writing a custom webpart and it is connecting to a separate database, I would like to allow the administrator to select or type in a connection string when installing the .wsp file or activating the feature. I am looking inside the FeatureActivated event and thinking of using the SPWebConfigModification class to actually write the connection string to the web.config files in the farm. I do not want to hand edit the web.configs or hard code the string into the DLL. If you have other methods for handling connection strings inside sharepoint I would be interested in them as well. Thank you, Keith
sharepoint
connectionstring
null
null
null
null
open
SharePoint - Connection String dialog box during FeatureActivated event === Does anyone know if it is possible to display a prompt to a user/administrator when activating or installing a sharepoint feature? I am writing a custom webpart and it is connecting to a separate database, I would like to allow the administrator to select or type in a connection string when installing the .wsp file or activating the feature. I am looking inside the FeatureActivated event and thinking of using the SPWebConfigModification class to actually write the connection string to the web.config files in the farm. I do not want to hand edit the web.configs or hard code the string into the DLL. If you have other methods for handling connection strings inside sharepoint I would be interested in them as well. Thank you, Keith
0
8,864
08/12/2008 14:08:23
58
08/01/2008 13:56:33
1,807
84
Difference between NULL and null in PHP
Is there a difference between NULL and null in PHP? Sometimes they seem to be interchangeable and sometimes not. I know that you must set a variable to NULL in order for it to be considered "null", but what about when testing it for... nullity... Do you have to say "$var == NULL" or can you say "$var == null"?
php
null
null
null
null
null
open
Difference between NULL and null in PHP === Is there a difference between NULL and null in PHP? Sometimes they seem to be interchangeable and sometimes not. I know that you must set a variable to NULL in order for it to be considered "null", but what about when testing it for... nullity... Do you have to say "$var == NULL" or can you say "$var == null"?
0
8,876
08/12/2008 14:16:41
31,505
2008-09-01
1
0
Evidence Base Scheduling Tool
Are there any free tools that implement evidence based scheduling that [joel talks about][1]? There lies fogbugz of course but I am looking for a simple and free tool that can apply ebs on some tasks that I give estimates (and actual times which are complete) for. [1]: http://www.joelonsoftware.com/items/2007/10/26.html
evidence-based-scheduling
null
null
null
null
null
open
Evidence Base Scheduling Tool === Are there any free tools that implement evidence based scheduling that [joel talks about][1]? There lies fogbugz of course but I am looking for a simple and free tool that can apply ebs on some tasks that I give estimates (and actual times which are complete) for. [1]: http://www.joelonsoftware.com/items/2007/10/26.html
0
8,880
08/12/2008 14:20:31
672
08/07/2008 16:18:07
1
3
Get list of domains on the network
Using the Windows API, how can I get a list of domains on my network?
winapi
null
null
null
null
null
open
Get list of domains on the network === Using the Windows API, how can I get a list of domains on my network?
0
8,893
08/12/2008 14:35:39
733
08/08/2008 12:53:16
51
8
Anyone know of an on-line free database?
I wrote an application that currently runs against a local instance of MySql. I would like to centralize the DB somewhere on the Net, and share my application. But, I'm cheap, and don't want to pay for it. Does anyone know of a free on-line relational DB service that I could connect to via C#?
c#
database
null
null
null
null
open
Anyone know of an on-line free database? === I wrote an application that currently runs against a local instance of MySql. I would like to centralize the DB somewhere on the Net, and share my application. But, I'm cheap, and don't want to pay for it. Does anyone know of a free on-line relational DB service that I could connect to via C#?
0
8,894
08/12/2008 14:35:46
277
08/04/2008 10:55:22
102
4
PostGRESQL's phppgadmin Reports Database
phppgadmin comes with instructions for creating a reports database on the system for use with phppgadmin. The instructions describe how to set it up, but do not really give any indication of what its purpose is, and the phppgadmin site was not very helpful either. It seems to allow you to store SQL queries, so is it for storing admin queries accessing tables like pg_class etc?
database
php
postgresql
phppgadmin
null
null
open
PostGRESQL's phppgadmin Reports Database === phppgadmin comes with instructions for creating a reports database on the system for use with phppgadmin. The instructions describe how to set it up, but do not really give any indication of what its purpose is, and the phppgadmin site was not very helpful either. It seems to allow you to store SQL queries, so is it for storing admin queries accessing tables like pg_class etc?
0
8,896
08/12/2008 14:37:28
1,107
08/12/2008 12:14:29
1
1
Memcached on Windows (x64)
Does anyone know **IF**, **WHEN** or **HOW** I can get [Memcached][1] running on a Windows 64bit environment? I'm setting up a new hosting solution and would much prefer to run a 64bit OS, and since it's an ASP.Net MVC solution with SQL Server DB, the OS is either going to be Windows Server 2003 or (hopfully!) 2008. I know that this could spill over into a debate regarding 32bit vs 64bit on servers, but let's just say that my preference is 64bit and that I have some [very][2] [good][3] reasons. So far, I've tried a number of options and found a [bit][4] of [help][6] related to getting this up on a 32bit machine (and succeeded I might add), but since the original [Windows port][5] is Win32 specific, this is hardly going to help when installing as a service on x64. It also has a dependency on the [libevent][7] for which I can only get a Win32 compiled version. I suspect that simply loading all this up in C++ and hitting "compile" (for 64bit) wouldn't work, not least because of the intricate differences in 32 and 64bit architectures, but I'm wondering if anyone is workng on getting this off the ground? Unfortunately, my expertise lie in managed code (C#) only, otherwise I would try and take this on myself, but I can't believe I'm the only guy out there trying to get [memcached][1] running on a 64 bit Windows server....am I?? Any help or recommendations appreciated... [1]: http://www.danga.com/memcached/ [2]: http://blogs.technet.com/mscom/archive/2005/09/26/411568.aspx [3]: http://www.codinghorror.com/blog/archives/000435.html [4]: http://blog.rakeshxp.com/2007/09/running-memcached-on-windows.html [5]: http://jehiah.cz/projects/memcached-win32/ [6]: http://www.splinedancer.com/memcached-win32/ [7]: http://www.monkey.org/~provos/libevent/
memcached
64bit
c#
c++
null
null
open
Memcached on Windows (x64) === Does anyone know **IF**, **WHEN** or **HOW** I can get [Memcached][1] running on a Windows 64bit environment? I'm setting up a new hosting solution and would much prefer to run a 64bit OS, and since it's an ASP.Net MVC solution with SQL Server DB, the OS is either going to be Windows Server 2003 or (hopfully!) 2008. I know that this could spill over into a debate regarding 32bit vs 64bit on servers, but let's just say that my preference is 64bit and that I have some [very][2] [good][3] reasons. So far, I've tried a number of options and found a [bit][4] of [help][6] related to getting this up on a 32bit machine (and succeeded I might add), but since the original [Windows port][5] is Win32 specific, this is hardly going to help when installing as a service on x64. It also has a dependency on the [libevent][7] for which I can only get a Win32 compiled version. I suspect that simply loading all this up in C++ and hitting "compile" (for 64bit) wouldn't work, not least because of the intricate differences in 32 and 64bit architectures, but I'm wondering if anyone is workng on getting this off the ground? Unfortunately, my expertise lie in managed code (C#) only, otherwise I would try and take this on myself, but I can't believe I'm the only guy out there trying to get [memcached][1] running on a 64 bit Windows server....am I?? Any help or recommendations appreciated... [1]: http://www.danga.com/memcached/ [2]: http://blogs.technet.com/mscom/archive/2005/09/26/411568.aspx [3]: http://www.codinghorror.com/blog/archives/000435.html [4]: http://blog.rakeshxp.com/2007/09/running-memcached-on-windows.html [5]: http://jehiah.cz/projects/memcached-win32/ [6]: http://www.splinedancer.com/memcached-win32/ [7]: http://www.monkey.org/~provos/libevent/
0
8,919
08/12/2008 14:53:58
178
08/03/2008 02:21:57
1
0
Looking for best practice for doing a "Net Use" in C#
I'd rather not have to resort to calling the command line. I'm looking for code that can map/disconnect a drive, while also having exception handling. Any ideas?
c#
.net-1.1
null
null
null
null
open
Looking for best practice for doing a "Net Use" in C# === I'd rather not have to resort to calling the command line. I'm looking for code that can map/disconnect a drive, while also having exception handling. Any ideas?
0
8,939
08/12/2008 15:03:40
1,088
08/12/2008 11:11:16
1
1
ActionScript 3.0 sockets can't reconnect
I'm having trouble connecting (via the Socket and XMLSocket classes) to a TCP listener after a connect timeout. I have a flash applet that needs to maintain a TCP connection to a server. I have implemented timeouts using Timers, a ping-pong system, etc. However, there's a problem. Upon calling Socket.connect(), the flash player (9.0.115 and many other stables before that) sends 3 connection requests by way of SYN packets, with some time in between. If none of those are replied to (e.g. because the server is down), I cannot get the applet to [attempt to] connect to the server. Ever. That is, within the lifetime of the applet. To clarify and/or summarize: For any host/port pair given to Socket.connect() or XMLSocket.connect(), if the call fails, any subsequent connect() calls to any other Socket (or XMLSocket) instances **within the lifetime of the Flash applet** to the same host/port pair get ignored. (At least as far as I can tell using a packet sniffer.) I have tried calling numerous Socket methods, destroying¹ and recreating the objects, using a pool of Sockets, and various other methods I can't remember right now; all to no avail. My current solution is to notify the parent webpage through a JavaScript call and let it reload my applet. It's not a pretty solution, and I'm not about to implement workarounds for the problems *it* causes, just because Flash can't handle socket connections properly. I must be missing something very simple. Any ideas? ---------- 1: I know you can't really destroy objects; I just remove all references to them and hope for the best. I haven't tried to explicitly invoke the GC in this case. (Though I think I did try putting the Socket inside an Array and using *delete*.)
flash
actionscript-3
sockets
xmlsocket
null
null
open
ActionScript 3.0 sockets can't reconnect === I'm having trouble connecting (via the Socket and XMLSocket classes) to a TCP listener after a connect timeout. I have a flash applet that needs to maintain a TCP connection to a server. I have implemented timeouts using Timers, a ping-pong system, etc. However, there's a problem. Upon calling Socket.connect(), the flash player (9.0.115 and many other stables before that) sends 3 connection requests by way of SYN packets, with some time in between. If none of those are replied to (e.g. because the server is down), I cannot get the applet to [attempt to] connect to the server. Ever. That is, within the lifetime of the applet. To clarify and/or summarize: For any host/port pair given to Socket.connect() or XMLSocket.connect(), if the call fails, any subsequent connect() calls to any other Socket (or XMLSocket) instances **within the lifetime of the Flash applet** to the same host/port pair get ignored. (At least as far as I can tell using a packet sniffer.) I have tried calling numerous Socket methods, destroying¹ and recreating the objects, using a pool of Sockets, and various other methods I can't remember right now; all to no avail. My current solution is to notify the parent webpage through a JavaScript call and let it reload my applet. It's not a pretty solution, and I'm not about to implement workarounds for the problems *it* causes, just because Flash can't handle socket connections properly. I must be missing something very simple. Any ideas? ---------- 1: I know you can't really destroy objects; I just remove all references to them and hope for the best. I haven't tried to explicitly invoke the GC in this case. (Though I think I did try putting the Socket inside an Array and using *delete*.)
0
8,940
08/12/2008 15:04:29
1,111
08/12/2008 12:40:23
1
0
VMWare Server Under Linux Secondary NIC connection
With VMWare Server running under Linux (Debain), I would like to have the following setup: - 1st NIC being used by many of the images running under VMWare, as well as being used by the Linux OS - 2nd NIC being used by only 1 image and to be unused by the Linux OS (as its part of a DMZ) Although the second NIC won't be used by Linux, it is certainly recognised as a NIC (e.g. eth1). Is this possible under VMWare Server, and if so, is it as simple as not binding eth1 under Linux and then bridging it to the image under VMWare Server?
linux
vmware
sysadmin
nic
null
null
open
VMWare Server Under Linux Secondary NIC connection === With VMWare Server running under Linux (Debain), I would like to have the following setup: - 1st NIC being used by many of the images running under VMWare, as well as being used by the Linux OS - 2nd NIC being used by only 1 image and to be unused by the Linux OS (as its part of a DMZ) Although the second NIC won't be used by Linux, it is certainly recognised as a NIC (e.g. eth1). Is this possible under VMWare Server, and if so, is it as simple as not binding eth1 under Linux and then bridging it to the image under VMWare Server?
0
8,941
08/12/2008 15:07:40
832
08/09/2008 06:51:40
259
31
Generic Type Checking
OK, here we go again! Following on from my [previous question](http://stackoverflow.com/questions/8625/generic-type-conversion-from-string) on Converting to a Generic Type from String, I thought I would ask another Generics-related question! This time, **is there a way to enforce/limit the types that are passed to PRIMITIVE's?** _(bool, int, string, etc)_ Now, I know you can limit the generic type parameter to a type or interface implementation via the _where_ clause, however, this doesn't fit the bill for primitives (AFAIK) because the do not all have common ground (apart from _object_ before someone says! :P). So, my current thoughts are to just grit my teeth and do a big _switch_ statement and throw an _ArgumentException_ on failure.. Just thought I would check here to see if the awesome pool of wisdom that is StackOverflow could offer any better ideas? :) Many thanks.
c#
generics
type-safety
primitive
null
null
open
Generic Type Checking === OK, here we go again! Following on from my [previous question](http://stackoverflow.com/questions/8625/generic-type-conversion-from-string) on Converting to a Generic Type from String, I thought I would ask another Generics-related question! This time, **is there a way to enforce/limit the types that are passed to PRIMITIVE's?** _(bool, int, string, etc)_ Now, I know you can limit the generic type parameter to a type or interface implementation via the _where_ clause, however, this doesn't fit the bill for primitives (AFAIK) because the do not all have common ground (apart from _object_ before someone says! :P). So, my current thoughts are to just grit my teeth and do a big _switch_ statement and throw an _ArgumentException_ on failure.. Just thought I would check here to see if the awesome pool of wisdom that is StackOverflow could offer any better ideas? :) Many thanks.
0
8,948
08/12/2008 15:16:00
145
08/02/2008 14:40:17
209
13
Accessing mp3 Meta-Data with Python
What is the best way to retrieve mp3 metadata in python? I've seen a couple frameworks out there, but I'm unsure as to which would be the best to use.... Any ideas?
python
mp3
metadata
null
null
null
open
Accessing mp3 Meta-Data with Python === What is the best way to retrieve mp3 metadata in python? I've seen a couple frameworks out there, but I'm unsure as to which would be the best to use.... Any ideas?
0