input
stringlengths
51
42.3k
output
stringlengths
18
55k
Is there step-by-step tutorial on setting up CruiseControl.NET? <p>What to do automatic nightly build of .NET web application and upload to the test server. </p> <p>Or, if this tool is overkill, please suggest something else.</p>
<p>I have found this great tutorial: <a href="http://weblogs.asp.net/jdanforth/pages/How-to-Hook-Up-a-VS.NET-2005-Solution-With-CruiseControl.NET-in-a-Few-Minutes.aspx">How to Hook Up a VS.NET 2005 Solution With CruiseControl.NET in a Few Minutes</a>. It's short but uses a real .Net project to illustrate the set up.</p...
Special Characters in URL <p>We're currently replacing all special characters and spaces in our URLs with hypens (-). From an SEO and readability point-of-view this works fine. However, in some cases, we are feeding parts of the URL into a search after stripping the hyphens out. The problem occurs when the search term ...
<p>Would ~ (<a href="http://en.wikipedia.org/wiki/Tilde" rel="nofollow">tilde</a>) work?</p> <p>Edit: Google now treats <a href="http://news.cnet.com/8301-10784_3-9748779-7.html" rel="nofollow">underscores and dashes as word separators</a> so you can use dashes as dashes and underscores as spaces.</p>
Is it better to have one UpdatePanel around multiple controls or separate UpdatePanels? <p>I have a web form that has multiple ListBoxes, TextBoxes, DropDowns. If I put one UpdatePanel around the whole page, I noticed the page is slower. Is this because, every control is being updated? If I put different UpdatePanel...
<p>each update panel generates a round-trip to the server (i assume you're using a timer or something to cause this)</p> <p>the general rule would be to group controls in an update panel that <em>must</em> change together, otherwise separate update panels makes more sense</p>
Using Lists in C# <p>I am an upper level Software Engineering student currently in a Data Structures and Algorithms class. Our professor wants us to write a program using the List structure found in the C++ STL. I have been trying to use C# more and more, and was wondering if the ArrayList structure in .NET is a good...
<p>Unless you're stuck with .NET 1.1, use <code>List&lt;T&gt;</code> instead of <code>ArrayList</code>. But what are you fundamentally concerned about? Suppose you didn't have List to refer to - what do you need the appropriate data structure to do?</p>
What's the best way for a .NET Compact Framework executable to delete itself? <p>I'd like my .NET Compact Framework app to delete itself after it finishes executing. What's the best way to do this?</p> <p>On a Windows machine it's possible to do this using a .bat file, but that's not an option on mobile devices.</p>
<p>In Windows Mobile there is the directory:</p> <p>\application data\volatile</p> <p>This directory is kept for as long as the device has power.</p> <p>So what we do is:</p> <ol> <li>copy a exe over to this directory, or a sub-directory (I normally use a sub-directory to make sure we don't clash with another appli...
Why does Hibernate/JDBC/MySQL drop connections after a day or so? <p>I have several server processes that once in a while respond to messages from the clients and perform read-only transactions.</p> <p>After about a few days that the servers are running, they stop working correctly and when I check it turns out that t...
<p>The MySQL JDBC driver times out after 8 hours of inactivity and drops the connection.</p> <p>You can set <code>autoReconnect=true</code> in your JDBC URL, and this causes the driver to reconnect if you try to query after it has disconnected. But this has side effects; for instance session state and transactions ca...
SharePoint searching external database <p>We're looking at doing a MOSS 2007 site which will have a fairly dynamic component (an external product catalog). The external produces will be stored in a database (not managed by SharePoint) and all interaction will occur via Web Parts.</p> <p>Is it possible to configure the...
<p>The Business Data Catalog is intended as the solution in this case. A BDC solution is crawlable out of the box. </p> <p>Unfortunately the BDC requires the Enterprise licence for SharePoint, a hefty price increase.</p> <p>Any other solution will require an html interface to the database either by including the data...
PageRequestManager is undefined <p>I am seeing this error intermittently. My app throws PageRequestManager is undefined and so fails to load. Oddly enough this only happens in firefox, ie loads fine. Anyone know what this error means. I've been working on the app for some time and I just started seeing this today.<...
<p>It probably means that there is a javascript error somewhere on the page that hits FF but not IE. Do you have FireBug installed in FF and can you see if there a javascript error that is causing the javascript to fail to be completely parsed?</p>
Using Emacs to recursively find and replace in text files not already open <p>As a follow-up to <a href="http://stackoverflow.com/questions/269812/how-to-quickly-get-started-at-using-and-learning-emacs">this question</a>, it's trying to find out how to do something like this which should be easy, that especially stops ...
<ol> <li><code>M-x find-name-dired</code>: you will be prompted for a root directory and a filename pattern.</li> <li>Press <code>t</code> to "toggle mark" for all files found.</li> <li>Press <code>Q</code> for "Query-Replace in Files...": you will be prompted for query/substitution regexps.</li> <li>Proceed as with <c...
MySQL C API using results <p>I am using the MySQL C API to query the database and I have the results stored in MYSQL_ROW types. I am able to print the results to the console with</p> <pre><code>printf("%s", row[0]); </code></pre> <p>however, according to the MySQL C API documentation, I cannot use them as null-termi...
<p>Basically, you call mysql_store_result() or mysql_use_result() to access the result set, the former loads all the rows into memory on the client side, the latter accesses rows one at a time from the server. If you use mysql_use_result(), you need to call mysql_fetch_row() to access each row until the function retur...
LinkedList remove method <p>What is a doubly linked list's remove method?</p>
<p>The same algorithm that <a href="http://stackoverflow.com/questions/270950/linkedlist-remove-method#270962">Bill the Lizard</a> said, but in a graphical way :-)</p> <p><img src="http://www.jaffasoft.co.uk/feature/ll/fig4.gif" alt="Remove From Linked List" /></p>
Automate SSH without using public key authentication or expect(1) <p>Is there a way to pass a password to ssh automatically. I would like to automatically ssh to a server <b>without</b> using public key authentication or expect scripts, by somehow getting ssh to read the password from stdin or a file.</p> <p>The reaso...
<blockquote> <p>expect is out of the question because I would like to run it as a cron job, and since cron jobs don't run under a terminal the combination of expect/ssh just doesn't work</p> </blockquote> <p>You can run expect scripts from cron, at least you can with expect libraries like "pexpect" for Python. I...
jetty - reload tag file in jar <p>I have my main web project and a common project which houses my tag files. Currently I use jetty in exploded structure and I jar up my common project with my tag files and place into <code>web-inf/lib</code>.</p> <p>When I make a change to my tag file, I can rejar and place into <code...
<p>A possible reason Jetty is unable to compile the JSP file is because it's running under a JRE instead of a JDK. It needs access to the compiler (which is not part of the JRE just the JDK) to turn JSP source into bytecode (with a Servlet step in between).</p>
Ruby on Rails plugin for showing line numbers in log for SQL queries <p>Does anybody know any plugin, that can show line numbers for SQL queries in Rails logs? Something like this:</p> <pre><code>User Load (0.003154) SELECT * FROM `users` WHERE (`users`.`id` = 1) - (user.rb, line 24) </code></pre> <p>Thanks!</p>
<p>This plugin puts the stack trace in your logs. As Daniel mentions it would be tricky to determine the line you wanted but I suspect you could work something out, and the trace itself may be good enough.</p> <p><a href="https://github.com/ruckus/active-record-query-trace" rel="nofollow">https://github.com/ruckus/ac...
How can I make datagrid height is equal to data content in Adobe Flex <p>In adobe Flex datagrid height is equally to fix height . I want to make datagrid height is depend data . </p>
<p>You can set each row of the datagrid to fit based on the contents of a particular column of that row by setting the "variableRowHeight" attribute to true on the datagrid and setting the "wordWrap" attribute to true on the dataGridColumn that will contain the variable height content.</p>
What is the most useful type of java.awt.image.BufferedImage for off-screen rendering? <p>I am creating a buffered image that is going to be a snapshot of a JComponent (via paint()) and rendered inside an <a href="http://java.sun.com/j2se/1.5.0/docs/api/javax/swing/ImageIcon.html" rel="nofollow">ImageIcon</a>. There a...
<p>See <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/awt/GraphicsConfiguration.html#createCompatibleImage(int,%20int)">GraphicsConfiguration.createCompatibleImage(int, int)</a> for a helper to create a BufferedImage of a "good" type among the many available types.</p> <p>How to get your hands on a GraphicsConf...
How to configure CruiseControl.NET to build one project on a remote server <p>I have a build server running CruiseControl.NET. It works well for the 7 projects that are configured to run on that server (let's call it server A).</p> <p>Now I have a new project that I wish to build on a different server (server B), but ...
<p>In <code>dashboard.config</code> (default location is <code>c:\Program Files\CruiseControl.NET\webdashboard\dashboard.config</code>) take a look at the <a href="http://confluence.public.thoughtworks.org/display/CCNET/Servers+Configuration+Block" rel="nofollow">Servers Configuration Block</a>:</p> <pre><code> &lt;...
GZipStream And DeflateStream will not decompress all bytes <p>I was in need of a way to compress images in .net so i looked into using the .net GZipStream class (or DeflateStream). However i found that decompression was not always successful, sometimes the images would decompress fine and other times i would get a GDI+...
<p>You need to <code>Close()</code> the <code>ZipStream</code> after adding all the data you want to compress; it retains a buffer of unwritten bytes internally (even if you <code>Flush()</code>) that needs to be written.</p> <p>More generally, <code>Stream</code> is <code>IDisposable</code>, so you should also be <co...
Can Visual Studio 2008 Standard create a single EXE that does not require .NET framework? <p>This is truly a beginner question, so I apologize in advance.</p> <p>I have Visual Studio 2008 Standard installed and would like to create a small Windows application that does NOT require any .NET framework when run on comput...
<p>Sure, you can definitely do this. You'll have to write your application in C++, though.</p> <p>To get started, go to File | New, and under Project Types pick one of the options under Visual C++. For the minimal dependencies, I would suggest one of the Win32 options. Both the "Win32 Console Application" and the "Win...
How to trigger rendering of JQuery treeview <p>I use Jquery tree plugin (<a href="http://docs.jquery.com/Plugins/Treeview" rel="nofollow">http://docs.jquery.com/Plugins/Treeview</a>) to render hierarchical data. I have coded additional functions which would allow user to interact with this data (like adding/deleting no...
<p>I found some workaround as given below,</p> <p>Once the node is swapped up, virtually add its previous node to its child,</p> <p>$("#browser").treeview({add:$("#topnd2").insertBefore(previous).next()});</p> <p>If node is swapped down, virtuall add the current node to its next node.</p> <p>$("#browser").treeview(...
Dynamic url for dojo combobox source <p>I'm trying to use a dojo combobox with an Ajax data source. What I have is </p> <pre><code>&lt;div dojoType="dojo.data.ItemFileReadStore" jsId="tags" url="&lt;%=ResolveClientUrl("~/Tag/TagMatches")%&gt;" &gt; &lt;/div&gt; &lt;select dojoType="dijit.form.ComboBox" ...
<p>If I understand you correctly, you want the client to load different set of data from the server based on some general condition defined elsewhere.</p> <p>Basically there is no need to have a <code>&lt;div&gt;</code> pre-defined. You can also create the <code>ItemFileReadStore</code> directly in JavaScript:</p> <p...
Image loading icon for flash/flex? <p>You often see those little 'petal' animations while an image or .swf file is loading in a Flash / Flex application.</p> <p>Do I have to steal this from someone or is there a standard one available from somewhere. i would think there is somethin standard because everyones looks the...
<p>You can download that and other icons (as animated gifs) at <a href="http://www.ajaxload.info" rel="nofollow">AjaxLoad</a>.</p>
SVN - How to make an older revision the head revision? <p>One of the files in my current head revision got corrupted. I want to make an older revision of that file the head revision as usually people sync to head revsion in my project. How to do that?</p>
<p>You should revert all changes since that old reversion. In principle,</p> <pre><code>svn merge -rHEAD:oldrev filename svn commit -m "rolled back to oldrev" </code></pre> <p>should do. The later revisions are still there, but reverted.</p>
Captured variable in a loop in C# <p>I met an interesting issue about C#. I have code like below.</p> <pre><code>List&lt;Func&lt;int&gt;&gt; actions = new List&lt;Func&lt;int&gt;&gt;(); int variable = 0; while (variable &lt; 5) { actions.Add(() =&gt; variable * 2); ++ variable; } foreach (var act in actions)...
<p>Yes - take a copy of the variable inside the loop:</p> <pre><code>while (variable &lt; 5) { int copy = variable; actions.Add(() =&gt; copy * 2); ++ variable; } </code></pre> <p>You can think of it as if the C# compiler creates a "new" local variable every time it hits the variable declaration. In fact ...
What should be included in a C# Programming Standard? <p>I've been tasked to write our department's C# Programming Standard (including guidelines). What sort of standards/guidelines should I include? I've already taken bits from various standards around the net (and pieces from Code Complete), but I'd like hear from ...
<p>Have you already suggested that everyone reads the "<a href="http://msdn.microsoft.com/en-us/library/czefa0ke.aspx" rel="nofollow">Design Guidelines for Class Library Developers</a>"? That covers the bulk of it. Other than that, I'd want to hammer home:</p> <ul> <li>You should very rarely be creating your own struc...
Automatic casting to string in C# and VB.NET <p>I could do this in C#..</p> <pre><code>int number = 2; string str = "Hello " + number + " world"; </code></pre> <p>..and str ends up as "Hello 2 world".</p> <p>In VB.NET i could do this..</p> <pre><code>Dim number As Integer = 2 Dim str As String = "Hello " + number +...
<p>In VB I believe the string concatenation operator is &amp; rather than + so try this:</p> <pre><code>Dim number As Integer = 2 Dim str As String = "Hello " &amp; number &amp; " world" </code></pre> <p>Basically when VB sees + I suspect it tries do numeric addition or use the addition operator defined in a type (or...
Cross-references and garbage collection <p>There is an application with an extensive object graph. This graph mainly consists of a set of subgraphs which are connected to the rest of the graph through the only reference. But internally each such subgraph has some number of cross-references among objects. Once in a whil...
<p>As stated in this <a href="http://stackoverflow.com/questions/176745/circular-references-in-java">SO question</a>, circular reference is well managed.</p> <p>Java does not do reference counting, it does "mark and sweep" garbage collecting. If follows all the active references to find out what objects are "reachable...
Firefox 3 doesn't allow 'Back' to a form if the form result in a redirect last time <p>Greetings,</p> <p>Here's the problem I'm having. I have a page which redirects directly to another page the first time it is visited. If the user clicks 'back', though, the page behaves differently and instead displays content (tr...
<p>I think the Mozilla team takes a step into the right direction by breaking this particularly annoying pattern. Finding a way around it somehow defies the purpose, doesn't it?</p> <p>Instead of redirecting on first encounter, you could simply make your page render differently when a user hits it the first time. Shou...
WIX: How can the registry key be changed based on the OS on which the installer is running? <p>I want to set registry keys in following way</p> <p>if OS is Vista then HKLM\MyKey1\MyValue=1 else HKLM\MyKey2\MyValue=1</p> <p>I know how to set Registry keys in WIX but it seems the condition cannot be set on ele...
<p>Technically speaking, you should use two different Components to install those Registry keys since they are completely different paths. Then you can Condition the Components with the VersionNT property.</p>
Strategy for Offline/Online data synchronization <p>My requirement is I have server J2EE web application and client J2EE web application. Sometimes client can go offline. When client comes online he should be able to synchronize changes to and fro. Also I should be able to control which rows/tables need to be synchroni...
<p>There are a number of Java libraries for data synchronizing/replication. Two that I'm aware of are <a href="http://opensource.replicator.daffodilsw.com/">daffodil</a> and <a href="http://symmetricds.sourceforge.net/">SymmetricDS</a>. In a previous life I foolishly implemented (in Java) my own data replication proces...
C# in linux environment <p>I am currently working in C/C++ in a Unix environment and am new to Linux environments. I would like to learn about the Linux OS and learn C# as the next level of programming language for my career.</p> <p>I decided to put Ubuntu Linux on my laptop. But I am not sure whether we can write, co...
<p>Learn <a href="http://www.mono-project.com/Main_Page">Mono</a>.</p> <blockquote> <p>The Mono Project is an open development initiative sponsored by Novell to develop an open source, UNIX version of the Microsoft .NET development platform. Its objective is to enable UNIX developers to build and deploy ...
JBoss AS / Wildfly community version corresponding to Red Hat EAP version? <p>As far as i know the EAP editions of JBoss Application Server (AS) are just a bunch of community edition JBoss projects with some sugar.</p> <p>So, what is the <strong>community edition</strong> of the JBoss Application Server that <strong>J...
<p>This response is really late but I came across the unanswered question in a Google search and I wanted to make sure there's a correct response. I work for JBoss support so you can consider this a qualified answer.</p> <p>JBoss EAP is the only commercially supported version of JBoss. It contains JBoss AS and JBoss...
Collection<T> versus List<T> what should you use on your interfaces? <p>The code looks like below:</p> <pre><code>namespace Test { public interface IMyClass { List&lt;IMyClass&gt; GetList(); } public class MyClass : IMyClass { public List&lt;IMyClass&gt; GetList() { ...
<p>To answer the "why" part of the question as to why not <code>List&lt;T&gt;</code>, The reasons are future-proofing and API simplicity.</p> <p><strong>Future-proofing</strong></p> <p><code>List&lt;T&gt;</code> is not designed to be easily extensible by subclassing it; it is designed to be fast for internal implemen...
How to select maximum 3 items per users in MySQL? <p>I run a website where users can post items (e.g. pictures). The items are stored in a MySQL database. </p> <p>I want to query for the last ten posted items BUT with the constraint of a maximum of 3 items can come from any single user. </p> <p>What is the best way o...
<p>It's pretty easy with a correlated sub-query:</p> <pre><code>SELECT `img`.`id` , `img`.`userid` FROM `img` WHERE 3 &gt; ( SELECT count( * ) FROM `img` AS `img1` WHERE `img`.`userid` = `img1`.`userid` AND `img`.`id` &gt; `img1`.`id` ) ORDER BY `img`.`id` DESC LIMIT 10 </code></pre> <p>The query assumes that larger ...
Java: Determine receiving address when receiving with MulticastSocket <p>I am using MulticastSocket to receive UDP Multicast packets. How can I determine to which address such a packet was sent? With the methods provided, I am only able to determine the sender address.</p> <p>Of course, I am the one who sets the To-Ad...
<p>I'm a bit fuzzy on the details but a multicast packet will have been sent to the ip/port combo you subscribed to (and this info will be in the packet, somewhere), assuming you managed to have a clear path of intermediary routers that understand multicast. If you want to make sure the multicastsocket is receiving fro...
How to track down tricky memory leak with fastMM? <p>After upgrading a project from Delphi 2007 to Delphi 2009 I'm getting an Unknown memory leak, so far I've been tryin to track it down using fastMM, here is what fastMM stack trace reports:</p> <pre><code>A memory block has been leaked. The size is: 20 This block wa...
<p>This memory leak was being caused by a Delphi bug, QC <a href="http://qc.embarcadero.com/wc/qcmain.aspx?d=67709">#67709</a></p> <p>It was fixed by the last Delphi 2009 update, no wonder I wasn't able to fix it.</p>
Enabling controls at moment of opening a form in Access <p>I have a form whose controls I want to enable/disable depending on the values in a ComboBox control. This ComboBox control is linked, like all the other controls in the form, to a table. Inside the ComboBox's Change event, I placed the code that enables/disab...
<p>Most Access control events are not triggered by programmatic changes to the control. You may wish to call the code to enable the control(s) from the load event of the form.</p> <p>You do not mention the version of Access that you are using, but I do not believe that any version has a Recordset property for combobox...
Signing a desktop application <p>I'd like to know how to have a desktop application signed as a product from my company. I'm not sure of the details.I think the process is I have to purchase a certificate from a company like verisign Thanks</p>
<p>You need to sign the code with an Authenticode certificate.</p> <p>Full information here: <a href="http://msdn.microsoft.com/en-us/library/ms537359" rel="nofollow">http://msdn.microsoft.com/en-us/library/ms537359</a>(VS.85).aspx</p>
Searching for the best PHP nested sets class (PEAR class excluded) <p>I'm looking for a PHP (with MYSQL) nested sets class with all needed functions. For example:</p> <p>createLeftNode, createRightNode,createRootNode, createSubNode,deleteNode and <strong>moveTree</strong>. Not only 1 left, 1 right, 1 up and 1 down bu...
<p>look at the <a href="http://docs.doctrine-project.org/projects/doctrine1/en/latest/en/manual/behaviors.html#nesting-behaviors" rel="nofollow">nested behavior</a> of Doctrine </p>
Shadow Copying, and mixed C# and C++ DLLs loading from arbitrary folders <p>I have a VS 2005 C# project that uses a special Plugin folder to load extra DLLs (for use as nodes in an asset conversion process).</p> <p>I have a mixture of C# and C++ DLLs in this folder.</p> <p>The issue I have is that when Shadow Copying...
<p>Sounds like a trust issue. Try getting a Fusion log (see <a href="http://blogs.msdn.com/suzcook/archive/2003/05/29/57120.aspx" rel="nofollow">this blog post</a>). Your C++ DLLs are unverifiable since they weren't compiled with <code>/clr:safe</code>, so they can only be loaded as full trust. Presumably when shadow c...
How to put BIDS solutions under source control? <p>I am starting to work with Microsoft BI suite: Analysis services 2005, Business Intelligence Development Studio 2005, stuff like that. Of course my first wish was to set up the same source control/automated testing environment I have for my .NET projects. </p> <p>Bu...
<p>We have a feature in <a href="http://www.codeplex.com/bidshelper">BIDS Helper</a> (a free open source add-in) that does a "smart diff". We can't stop all the reformatting that goes on, but the smart diff feature strips out as much of the presentation details as we can which usually lets you see the important details...
SQL: Complex Deletion <p>I basically created some tables to play around with: I have Two main tables, and a Many-Many join table. Here is the DDL: (I am using HSQLDB)</p> <pre><code>CREATE TABLE PERSON ( PERSON_ID INTEGER GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY, NAME VARCHAR(50), MAIN_PERSON_ID INTEGE...
<p>I'm not following.</p> <p>You cannot delete <code>JOB</code> rows which have <code>JOB_PERSON</code> rows (even one) because of your FK contraints. Thus there is no way to delete <code>JOB</code> rows based on <code>PERSON</code> rows.</p> <p><code>JOB_PERSON</code> rows have to be deleted before either a <code>J...
SQL Statement indentation good practice <p>What is the accepted practice for indenting SQL statements? For example, consider the following SQL statement:</p> <pre><code>SELECT column1, column2 FROM table1 WHERE column3 IN ( SELECT TOP(1) column4 FROM table2 INNER JOIN table3 ON table2.column1 = table3.column1 ) </cod...
<pre><code>SELECT column1 , column2 FROM table1 WHERE column3 IN ( SELECT TOP(1) column4 FROM table2 INNER JOIN table3 ON table2.column1 = table3.column1 ) </code></pre> <p>I like to have all <strong>"," in front</strong>, this way I never search them when an error at line X from the SQL editor.</p> <p><hr/>...
How might I update this code <pre><code> &lt;object height="25" width="75" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"&gt; &lt;param value="http://click-here-to-listen.com/players/iaPlay13.swf?x=1058286910FTRZ...
<p>You can nest object elements to display alternatives. The W3C explains it <a href="http://www.w3.org/TR/html401/struct/objects.html#h-13.3" rel="nofollow">here</a>. I copied a snippet below:</p> <blockquote> <p>One significant consequence of the OBJECT element's design is that it offers a mechanism for specifying...
XMPP Server-to-Server for Gmail.com/Jabber.org <p>I'm in the phase of implementing the server-to-server communication part of a XMPP Server.</p> <p>I'm testing my implementation with Gmail.com and Jabber.org but both seem to use the dialback protocol. Does anyone know more information about this protocol related to th...
<p><a href="http://xmpp.org/extensions/xep-0220.html" rel="nofollow">XEP-220</a> specifies the dialback protocol. </p> <p>Keep in mind in your implementation that you may get asked for dialback on a socket that has already been fully set up and had traffic come across it.</p>
Does opacity:0 have exactly the same effect as visibility:hidden <p>If so, does it effectively deprecate the <code>visibility</code> property?</p> <p>(I realize that Internet Explorer does not yet support this CSS2 property.) <br/> <a href="http://en.wikipedia.org/wiki/Comparison_of_layout_engines_(CSS)#Properties">Co...
<p>Here is a compilation of verified information from the various answers.</p> <p>Each of these CSS properties is in fact unique. In addition to rendering an element not visible, they have the following additional effect(s):</p> <ol> <li><strong>Collapses</strong> the space that the element would normally occupy</li>...
How to add button to other apps window title bar (XP/Vista) <p>I have the handler of an open window which wasn't necessarily open by my process. How can I add a button to that window and make the button call a certain application (.exe) when clicked? The button could be next to the system menu or the minimize button. T...
<p>The standard approach is to inject a DLL into the process with SetWindowsHookEx, hooking WH_CALLWNDPROC to monitor the WM_NCPAINT message. That used to work pretty well but no more. Visual Styles and Vista UAC will make you grow a pretty long beard. Common in the Windows 3.x days, I haven't seen this done in quit...
What's the best static analysis tool for NetBeans 6.1? <p>I'm finding a couple for Java in general but no plugins for netbeans that I can see.</p> <p>Thanks</p>
<p>I've used the <a href="http://sourceforge.net/project/showfiles.php?group_id=56262&amp;package_id=63621" rel="nofollow">PMD NetBeans plugin</a>, and <a href="http://pmd.sourceforge.net/integrations.html#netbeans" rel="nofollow">here</a> are the installation instructions (may be a little outdated, due to the speed of...
NullReferenceException when hosting WPF in a System.AddIn <p>We are developing a WPF application that uses the System.AddIn framework to host add-ins that display additional WPF content. Everything seems to be working fine, but overnight, the application threw the following NullReferenceException:</p> <pre> Message: ...
<p>In addition the above answer by Steve Massing it will likely help to disable the "Just My Code" option, enable the "Enable source server support" option and setup your debugging symbols in order to break into and debug the framework code,</p> <p>It's easier than it sounds, follow these 3 step directions</p> <p>Red...
WCF javascript proxy not found when endpoint address is not blank <p>I am trying to setup a WCF service with multiple endpoints with one of the endpoints using the enableWebScript endpoint behavior so that a Javascript proxy will be created on the client (jsdebug/js).</p> <p>When adding the Service Reference to my AJA...
<p><code>&lt;enableWebScript /&gt;</code> also known as AJAX-enabled endpoints essentially hard-codes everything to do with address so you can generate the client-side code.</p> <p>The way it's hard-coded is that everything is directly relative to the .svc file.</p> <p>See <a href="http://msdn.microsoft.com/en-us/lib...
How to move documents from SharePoint 2003 to SharePoint 2007 with versioning? <p>I'm desperately searching for a tool allowing me to copy documents with their old versions from a SharePoint 2003 to a SharePoint 2007 site.<br /> Do you know about any simple (and preferably free) tool which does this?<br /></p>
<p>This may be too late for you, but I needed to migrate from a SharePoint 2003 site to a SharePoint 2007 site and keep not only versions, but also the file metadata from all of the document libraries. The official methods of migrating or upgrading failed, so I ended up writing a tool that must run on the destination S...
Do I have to learn Objective-C for professional Mac Development? <p>Do I really have to learn Objective-C to develop solid Mac Apps?</p> <p>As Mac users tend to use only applications that have a nice (native) GUI, i don't think that Mono and GTK+ or any Java GUI (Swing) will fit their needs.</p> <p>There are projects...
<p>Objective-C <em>is</em> a dynamic language, as far as the Objective-C parts go. Here's a little summary article: <a href="http://www.macdevcenter.com/pub/a/mac/2003/04/28/objective-c.html">http://www.macdevcenter.com/pub/a/mac/2003/04/28/objective-c.html</a></p> <p>The syntax is scary at first, but it grows on yo...
SQL Server Profiler - How to filter trace to only display events from one database? <p>How do I limit a SQL Server Profiler trace to a specific database? I can't see how to filter the trace to not see events for all databases on the instance I connect to.</p>
<p>Under Trace properties > Events Selection tab > select show all columns. Now under column filters, you should see the database name. Enter the database name for the Like section and you should see traces only for that database.</p>
Kill a blocked Boost::Thread <p>I am writing an application which blocks on input from two <code>istreams</code>.</p> <p>Reading from either <code>istream</code> is a synchronous (blocking) call, so, I decided to create two <code>Boost::thread</code>s to do the reading.</p> <p>Either one of these threads can get to t...
<p>I don't think there is a way to do it cross platform, but pthread_cancel should be what you are looking for. With a boost thread you can get the <a href="http://www.boost.org/doc/libs/1_37_0/doc/html/thread/thread_management.html#thread.thread_management.thread.nativehandle" rel="nofollow">native_handle</a> from a t...
Migrating content from OpenWiki to ScrewTurn Wiki <p>We have a large OpenWiki powered wiki. OpenWiki appears to be a dead project, and ScrewTurn the next best option.</p> <p>Is anyone aware of a data migration route to move our content from the OpenWiki SQL Server format to the ScrewTurn wiki SQL Server format?</p> <...
<p>Are you sure about the "dead" status?</p> <p><a href="http://www.facebook.com/pages/OpenWiki-The-Post-It-Note-of-the-Web/145492998806288" rel="nofollow">http://www.facebook.com/pages/OpenWiki-The-Post-It-Note-of-the-Web/145492998806288</a></p>
Does the brand name matter for a SSL EV certificate? <p>Do end users really care if a SSL EV certificate is from VeriSign, Thwate, DigiCert, or etc.? A certificate from VeriSign can cost up to 3x the cost from DigiCert for the same basic features. VeriSign is probably the most recognizable brand name though.</p> <p>I'...
<p>No. The reason Verisign can charge more is that as one of the very first CAs they are recognised by more legacy and obscure browsers.</p>
Undefined reference to static class member <p>Can anyone explain why following code won't compile? At least on g++ 4.2.4.</p> <p>And more interesting, why it will compile when I cast MEMBER to int?</p> <pre><code>#include &lt;vector&gt; class Foo { public: static const int MEMBER = 1; }; int main(){ ...
<p>You need to actually define the static member somewhere (after the class definition). Try this:</p> <pre><code>class Foo { /* ... */ }; const int Foo::MEMBER; int main() { /* ... */ } </code></pre> <p>That should get rid of the undefined reference.</p>
In Java when does a URL connection close? <p>When does java let go of a connections to a URL? I don't see a close() method on either URL or URLConnection so does it free up the connection as soon as the request finishes? I'm mainly asking to see if I need to do any clean up in an exception handler.</p> <pre><code>try ...
<p>It depends on the specific protocol specified in the protocol. Some maintain persistent connections, other close their connections when your call close in the input or outputstream given by the connection. But other than remembering to closing the streams you opened from the URLConnection, there is nothing else you ...
What's "in" and "out" of OpenGL-ES? (Porting from OpenGL) <p>It seems that all of the documentation I can find about OpenGL-ES says something to the effect of "OpenGL-ES is just like OpenGL, but without a lot of stuff. For example, there's no glBegin or glEnd."</p> <p>Ok, that's great. So, what ELSE isn't there any ...
<p>Part of the problem in answering your question is there are many things missing and often it's a set of rarely used or non-applicable bit flags. The best document describing the differences is actually the implementation headers.</p> <p>For the framework I'm working on I decided to make it completely cross platform...
Testing Web Services Consumer <p>Here are some tools that I have found to test web services consumers:</p> <p><a href="http://www.soapui.org/" rel="nofollow">http://www.soapui.org/</a> https://wsunit.dev.java.net/</p> <p>Are there any others? I would prefer testing frameworks that are written in Java or Python.</p>
<p>I have used soapui by a maven plugin. It can create junit-linke reports to be run and analysed like unit tests. This can be easily integrated in continious build, also with the free distribution of soapui.</p>
UPS Worldship Integration and .net <p>Are there any UPS WorldShip integration APIS or Libraries out there for .net? I've been tasked with integrating our Sample Order application (A VB.Net/SQL Server app) with UPS, and having it write .xml files for the auto import feature though serialization has gotten my foot in the...
<p>Check here:<br /> <a href="http://www.ups.com/content/us/en/bussol/offering/technology/alliances/technology_tools.html" rel="nofollow">http://www.ups.com/content/us/en/bussol/offering/technology/alliances/technology_tools.html</a></p> <p>Look at the NexxStatus and ShipRush products at the bottom. Hopefully between...
WPF TreeView Binding <p>I've got a class with Parent and Children properties.</p> <p><img src="http://img148.imageshack.us/img148/6802/edmxxe8.gif" alt="ADO.NET Entity Framework Hierarchical Page Class" /></p> <p>I want to display this hierarchy in a WPF treeview.</p> <p>Here's my XAML...</p> <pre><code>&lt;TreeVie...
<p>You need to define an xmlns mapping to your Page class in the XAML file and use that in your Type declaration. The reason why you aren't getting a compile error is that the Page class is already defined in WPF.</p> <p>So, if your Page class was defined in the Zack namespace, in the TreeViewBinding assembly, you wo...
Help with using LD_PRELOAD <p>I want to create a library with a modified version of printf and then call LD_PRELOAD so when my program calls printf it uses my version. Can someone explain to me how to use LD_PRELOAD and if there is a something special I need to do in my code or my library? </p>
<p>You just set the environment variable <code>LD_PRELOAD</code> to the full path to the replacement library. Since all programs you launch after that point will attempt to use this library, you may want to make a wrapper script that sets <code>LD_PRELOAD</code> then calls the program you want to run.</p>
iPhone and HTML5 Cache Manifest <p>I am trying to build an iPhone web application using ASP.NET. The page is dynamically rendered once for each visitor. At this point the page can be bookmarked and it will never change again for that visitor. For this reason it should be cached locally from that point on so the applic...
<p>The cache manifest file has to be served with a 'text/cache-manifest' mime-type. This is absolutely critical, it will not work without it. If you navigate to the url of your manifest file, it should trigger a download...</p> <p>Also, I've found that putting the manifest location in the tag as an absolute location,...
Sharepoint: Is it possible to make subgroups in top navigation menu? <p>I need to make subgroups in the top navigation menu, like: </p> <p>Home -Group --Subgroup</p> <p></p> <p>Is it possible? I can not make more than two levels!</p>
<p>See this <a href="http://www.heathersolomon.com/blog/archive/2007/05/15/SharePoint-Tip--How-to-Activate-the-Drop-Down-Menu.aspx" rel="nofollow">blog entry</a> by Heather Solomon.</p> <p>You need to modify your Master Page to set your <strong>MaximumDynamicDisplayLevels</strong> property of the <strong>SharePoint:As...
How many dimensions in my array or get the last one <p>How can I find out the number of dimensions in an array in Classic ASP ( VBScript ) .</p> <p>I am being passed an Array with multiple dimensions but I only want to look at the last. Seems easy in other languages.</p>
<pre><code>Ubound(MySingleDimensionalArray, 2) ' Number of Array Elements Ubound(MyMultiDimensionalArray, 1) ' Number of Columns Ubound(MyMultiDimensionalArray, 2) ' Number of Rows </code></pre>
iPhone: Detecting user inactivity/idle time since last screen touch <p>Has anybody implemented a feature where if the user has not touched the screen for a certain time period, you take a certain action? I'm trying to figure out the best way to do that.</p> <p>There's this somewhat-related method in UIApplication:</p>...
<p>Here's the answer I had been looking for:</p> <p>Have your application delegate subclass UIApplication. In the implementation file, override the sendEvent: method like so:</p> <pre><code>- (void)sendEvent:(UIEvent *)event { [super sendEvent:event]; // Only want to reset the timer on a Began touch or an En...
Designing a Wiki, design considerations and feedback <p>When designing a wiki application, what things should I take into consideration?</p> <p>So far I have:</p> <ol> <li>revisions</li> <li>parsing some sort of markup text</li> <li>keeping track of links in wikis, and pages that link to other pages.</li> <li>related...
<p>If it's helpful, here is the database schema for Wikipedia (actually MediaWiki, the engine behind Wikipedia):</p> <p><img src="http://upload.wikimedia.org/wikipedia/commons/4/41/Mediawiki-database-schema.png?" alt="alt text" /></p> <p><a href="http://upload.wikimedia.org/wikipedia/commons/4/41/Mediawiki-database-s...
Java image library to deskew and crop images <p>Does anybody have a suggestion for a java library that performs automatic cropping and deskewing of images (like those retrieved from a flatbed scanner)?</p>
<p><a href="http://www.imagemagick.org" rel="nofollow">ImageMagick</a> can do that; you can use the <a href="http://sourceforge.net/projects/jmagick/" rel="nofollow">ImageMagick Java bindings</a>. The <a href="http://www.imagemagick.org/Usage/crop/#trim" rel="nofollow">auto-crop</a> operator is probably what you're lo...
Decoding a PRF file <p>Is there any way to decode a PICS Rules File? Contains settings and preferences used by the Windows operating system.</p> <p>The file is given by:</p> <p>Q:F]9y3n5|dp:n4hU)qbs;!&amp;-bzh</p>
<p>The <a href="http://www.w3.org/TR/REC-PICSRules" rel="nofollow">PICSRules spec</a> defines what PICS rules should look like. I don't think your file is one of those.</p> <p>Is that the <em>entire</em> file contents above?</p> <p>Are you sure that it's definitely a PICS rules file? There are many file types which u...
C# 4.0 Feedback <p>Does anyone know the official method for submitting feedback on C# 4.0 so that Anders and his team will get the feedback and be able to respond to the submission?</p>
<p>Probably the forums <a href="http://social.msdn.microsoft.com/Forums/en-US/vs2010ctpvbcs/threads/" rel="nofollow">here</a>, or (for bugs) <a href="https://connect.microsoft.com/VisualStudio/Feedback" rel="nofollow">connect</a> (they've added options for .NET 4.0 CTP and VS2010 CTP)</p>
If I use explicit constructor, do I need to put the keyword in both .h and .cpp files? <p>Actually my question is all in the title.<br> Anyway:<br> I have a class and I use explicit constructor: <br>.h<br></p> <pre><code>class MyClass { public: explicit MyClass(const string&amp; s): query(s) {} private: str...
<p>No, it is not. The <code>explicit</code> keyword is only permitted in the header. My gcc says:</p> <pre><code>test.cpp:6: error: only declarations of constructors can be 'explicit' </code></pre> <p>for the following code:</p> <pre><code>class foo { public: explicit foo(int); }; explicit foo::foo(int) {} </co...
designing a distributed (over many servers) error logging feature, WCF or? <p>I am designing a error logging feature so our servers (each donig different things) can have a central data store for logging errors.</p> <p>Would it be a good idea to have the various applications writing to the error log file using a WCF s...
<p>I'd say just log to your local data store. The advantages are :</p> <ol> <li>Speed - it's pretty rapid to just dump your chosen error report to an existing data connection.</li> <li>Tracability - What happens if you have an error in your service? You lose all ability to chase down errors on all servers. </li> ...
Singleton Destructors <p>Should Singleton objects that don't use instance/reference counters be considered memory leaks in C++?</p> <p>Without a counter that calls for explicit deletion of the singleton instance when the count is zero, how does the object get deleted? Is it cleaned up by the OS when the application i...
<p>As so often, "it depends". In any operating system worthy of the name, when your process exits, all memory and other resources used locally within the process WILL be released. You simply don't need to worry about that.</p> <p>However, if your singleton is allocating resources with a lifetime outside it's own proce...
HTTP status for functional redirect <p>Right now we've got web pages that show UI elements, and web pages that just process form submissions, and then redirect back to the UI pages. They do this using PHP's header() function:</p> <pre><code>header("Location: /other_page.php"); </code></pre> <p>This causes a 302 Foun...
<p>You can use either, but the proper statuscode to use for redirect-after-post is 303.</p> <p>The confusion has a historical explanation. Originally, 302 specified that the browser mustn't change the method of the redirected request. This makes it unfit for redirect-after-post, where you want the browser to issue a G...
Crystal Reports 8.5 grouping <p>I am grouping using a formula fCity which goes like this If {X.MailingCity} > "" Then {X.MailingCity} Else {X.City} I have two different fields in my view (Home City and Mailing City)</p> <p>Now, these fields contain many rural communities and in my report I want to have these smaller r...
<p>You need to relate rural cities and major cities somehow, then you can just group by major cities (or by formula, returning major city for rural one).</p>
Where do I start designing when using O/R mapping? Objects or database tables? <p>I'm starting a new database application and I wonder if it would be better to start the design at the objects (with UML) and build the database schema accordingly, or start at the design of the database (with ER) and create the objects ac...
<p>Depends on whether your application is designed to meet user needs, or to meet the needs of developers.</p> <p>Start with the user stories, and get the OOP Classes straight. And your users will love you.</p> <p>Otherwise you end up with an application that turns users into data entry clerks. (You'll have lots of c...
Does Castle-Windsor support ForwardedTypes via XML configuration <p>I have a class that implements multiple interfaces. I would like to register these interfaces via XML. All I've found is documentation for the new Fluent Interface. Is this option supported via XML? What would be involved in adding this feature?</p>
<p>[<strong>Update</strong>] This is now possible in Windsor 2.1 or newer. See the documentation for syntax <a href="http://stw.castleproject.org/Windsor.Registering-components.ashx?NoRedirect=1#Component_with_multiple_services_forwarded_types_5" rel="nofollow">here</a>.</p> <hr> <p>This feature has not been implemen...
What are the best free software products that improve productivity? <p>What are the best free software products that improve productivity?</p>
<p>One of the best compilation of productivity tools for developers -- at least for Windows -- is</p> <p><a href="http://www.hanselman.com/tools" rel="nofollow"> Scott Hanselman's Ultimate Developer and Power Users Tool List for Windows</a></p> <p>Many, but not all of them, are free.</p>
Any big sites using Client Side XSLT? <p>Lately, I've been pondering the somewhat non-mainstream architecture of building raw XML on the server side, and then using an XSLT stylesheet on the client to transform the XML into the full UI. Of course, a fallback mechanism would have to exist if the client was not capable ...
<p>Like other people have mentioned, Blizzard has many sites that are client side xsl. I would recommend avoiding client side xsl. It is a really cool idea, but there are many unusual bugs that you need to work around.</p> <p>In Firefox, any javascript that uses document.write will destroy the DOM. Also, the noscript ...
Checking if an instance's class implements an interface? <p>Given a class instance, is it possible to determine if it implements a particular interface? As far as I know, there isn't a built-in function to do this directly. What options do I have (if any)?</p>
<pre><code>interface IInterface { } class TheClass implements IInterface { } $cls = new TheClass(); if ($cls instanceof IInterface) echo "yes" </code></pre> <p>You can use the "instanceof" operator. To use it, the left operand is a class instance and the right operand is an interface. It returns true if the obje...
OpenGL background transparency? <p>I'm using QT's QGLFramebufferObject for off-screen rendering.<br /> After rendering to the buffer I read the result using glReadPixels()<br /> The problem is that sometimes the background color I read is just 0 (transparent black) and sometimes it is 0xFF000000 (opaque black)<br /> Th...
<p>Do you set up the correct clear color (glClearColor) and actually do a clear (glClear)? Are you making sure that your color write (glColorMask) mask is fully enabled (it also affects clears). Next you can check if QT sets up some weird pixel copy transfer (other than the default, see glPixelStore, glPixelTransfer an...
Creating a DLNA server/service in VB.NET <p>I would like to create a DLNA server in VB.NET. Since a lot of multimedia devices start supporting DLNA, i would like to see what is possible. Not only streaming video/audio and pictures but see what else can be done.</p> <h2>Anybody any starting points? protocol info, some ...
<p><a href="http://www.mperfect.net/whsUpnp360/">UPnP MediaServer using Intels SDK for Windows Home Server and Xbox 360</a> is written in C# and does not have all the functionallity required but it is a start.</p> <p>I'd like to see an open source implementation of DLNA in .NET</p>
Parallel quicksort: recursion using Boost Bind? <p>I am working on making quicksort parallel, threads being the first attempt. The non threaded version sorts correctly but the threaded doesn't (no surprise there). What I found interesting was when I removed the threads but kept the boost::bind calls it still doesn't ...
<p>Boost bind more or less creates a functor that when called, will call the function you want with the arguments you want. In this case you are creating the functor but never calling it. Try:</p> <pre><code>boost::bind( &amp;Quicksort, Array, Left, pivotNewIndex - 1 )(); boost::bind( &amp;Quicksort, Array, pivotNewIn...
How to publish our Webservices <p>I have created an web service I need to publish this service. I need to host and authenticated users need to access my services using ASP.net 2.0</p>
<p>I'm not sure if you are asking for an alternative, but I've been experimenting with <a href="http://www.codeproject.com/KB/WCF/generic_wcf_host.aspx" rel="nofollow">this code</a> that seems to work well on codeproject.com (CP). <br><br> If your question is on security, perhaps <a href="http://www.codeproject.com/KB/...
How do you test a public/private DSA keypair? <p>Is there an easy way to verify that a given private key matches a given public key? I have a few *.pub, and a few *.key files, and I need to check which go with which.</p> <p>Again, these are pub/key files, DSA.</p> <p>I would really prefer a one-liner of some sort......
<p>I found a way that seems to work better for me:</p> <pre><code>ssh-keygen -y -f &lt;private key file&gt; </code></pre> <p>that command will output the public key for the given private key, so then just compare the output to each *.pub file.</p>
System Calls: UNIX, Linux, BSD and Solaris variations <h3>Are there differences between the amount of syscalls in the major *NIX variants ?</h3> <h3>Which syscalls would be supported universally ?</h3>
<p>Anything that is not a posix standard may be an additional system call, or it maybe additional library functionality above the system call layer. If your goal is to write portable code stick to posix, and use the c library (as opposed to direct system calls) as much as possible.</p> <p>If you are just curious, they...
Session is lost with login control in Internet Explorer 7 <p>After logging in using the Login control the browser loses the session. This only occurs in Internet Explorer 7. Has anyone else run into this problem? If so, do you know a work around?</p>
<p>I would suggest downloading a tool like <a href="http://www.blunck.se/iehttpheaders/download.html" rel="nofollow">ieHTTPHeaders</a> to trace the request/respnonse headers in IE and seeing at what point either IE stops sending the cookie or the server clears it. </p> <p>You should see a POST to your login page and t...
How can I call Perl from Java? <p>I have a Perl module that I would like to use from Java. Is there a way to call this code using either ActiveState Perl on Windows or the generic Perl that comes with Linux? I have found references to JPL but it doesn’t appear to be maintained anymore.</p>
<p><a href="http://search.cpan.org/~patl/Inline-Java-0.52/Java.pod">Inline-Java</a> is the usual library to call java from Perl, and this <a href="http://www.piersharding.com/blog/archives/2004/04/calling_perl_fr.html">post propose a <strong>org.perl.java</strong></a> module which should allow calling Perl from Java, a...
Style for web application grid <p>I'm working on a small bugtracking system which shows a list of bugs. For the overview I want to use a grid - now I only need a style. </p> <p>Of course I won't copy the whole style from anyone else, but I just want to know which type of styles you like. Do you have any other great st...
<p><a href="http://icant.co.uk/csstablegallery/" rel="nofollow">CSS table gallery</a> can be a great source of inspiration.</p> <p>The CSS Table Gallery is a showcase of how CSS and data tables can work together to create usable and pretty results. </p>
Wheel Reinvention Avoidance for Web Rating Feature <p>I have a need to implement a rating feature and would like to do it the mouse-over stars way similar to netflix.</p> <p>What is my best approach? Here are some that come to mind.</p> <ul> <li>code it up by hand in HTML and javascript</li> <li>use flash or a java a...
<p>I really like <a href="http://www.fyneworks.com/jquery/star-rating/" rel="nofollow">jQuery Star Rating Plugin</a>, non-obstrusive, will work even if JavaScript is disabled, its based on a set of radio input boxes, and its very easy to use.</p>
Accessing the value of a session variable of a specific session <p>I'm trying to integrate a public message board service into an existing web site. </p> <p>The handshaking between the apps goes like this:</p> <p>1) File on my web site loads a flash file. The Flash reads a local variable that is the Session ID, or so...
<p>I'm not aware of any way to retrieve Session details for a particular instance or ID. However, you could utilise the Application object to store the information you need using the Session.SessionID value:</p> <p>Application(Session.SessionID &amp; tag) = myTagValue</p> <p>This way you are not creating a new GUID, ...
Java: How do I know which jar file to use given a class name? <p>Given a class, <a href="http://help.eclipse.org/stable/index.jsp?topic=/org.eclipse.platform.doc.isv/reference/api/org/eclipse/ui/views/navigator/ResourceNavigator.html">org.eclipse.ui.views.navigator.ResourceNavigator</a> for example, how do I find out w...
<p>If you have the jar in your class path / project path hit CTRL-SHIFT-T and type the name ... the jar will be displayed at the bottom.</p> <p>If you haven't the class in your build path a) put together a dummy project containing all the jars b) I think there is a plugin to find jars from IBM Alphaworks (but that mi...
Shutterfly Order API . <p>I found this site</p> <p><a href="http://www.shutterfly.com/documentation/api_OrderImage.sfly" rel="nofollow">http://www.shutterfly.com/documentation/api_OrderImage.sfly</a></p> <p>but there are no examples of actually walking through the whole process. Does anyone have any good documentat...
<p>I went through these steps:</p> <ul> <li><a href="https://www.shutterfly.com/signup/viewSignup.sfly">Sign up for an account</a></li> <li><a href="https://www.shutterfly.com/developer/apps.sfly">Sign up as a developer</a></li> </ul> <p>Create an application (I called mine Test). Note the generated <strong>Applicati...
XHTML and & (Ampersand) encoding <p>My website is XHTML Transitional compliant <strong>except for one thing</strong>: the &amp; (ampersand) in the URL are written as it is, instead of <code>&amp;amp;</code></p> <p>That is, all the urls in my pages are usually like this:</p> <pre><code>&lt;a href="http://www.foo.com/p...
<p>I have just tried this. What you attempted to do is correct. In HTML if you are writing a link the <code>&amp;</code> characters should be encoded as <code>&amp;amp;</code> You would only encode the <code>&amp;</code> as <code>%26</code> if you wanted a parameter value to contain an ampersand. I just wrote a simp...
Regex for names <p>Just starting to explore the 'wonders' of regex. Being someone who learns from trial and error, I'm really struggling because my trials are throwing up a disproportionate amount of errors... My experiments are in PHP using ereg().</p> <p>Anyway. I work with first and last names separately but for...
<p>This regex is perfect for me.</p> <pre><code>^([ \u00c0-\u01ffa-zA-Z'\-])+$ </code></pre> <p>It works fine in php environments using preg_match(), but doesn't work everywhere.</p> <p>It matches <code>Jérémie O'Co-nor</code> so I think it matches all UTF-8 names.</p>
Excel / Quickbooks data to c# <p>I know how to use the OleDbConnection class to open an excel file and select from it, but is there a simple method to read the data from an excel file that has been read into a Stream? And is there also a similar method for QuickBooks?</p>
<p>Stream? No, Excel files are a complicated mess. Quickbooks, yeah. I found this <a href="http://www.synergration.com/accessbooksrt/" rel="nofollow">ODBC driver</a>, it should support OdbcDataAdapter.</p>
How can I increase the stack size with runhaskell? <p>I'm writing some disposable Haskell scripts to solve some of the <a href="http://projecteuler.net">Project Euler</a> problems. I don't really want to have to compile them because of the number of changes I'm constantly having to make, but in a few cases I've found t...
<p>I'm guessing you're using GHC. Chapter 4 of the User's Guide of the newly released 6.10.1 says: </p> <blockquote> <p>The only runghc flag currently is -f /path/to/ghc, which tells runghc which GHC to use to run the program.</p> </blockquote> <p>I don't see a bug logged at <a href="http://hackage.haskell.org...
Best practices for project organization with ASP.NET MVC <p>I recently downloaded Rob Conery's excellent <a href="http://blog.wekeroad.com/mvc-storefront/">ASP.NET Storefront reference application</a> and am finding it incredibly instructive. One question that comes to mind is where one should place the Model classes ...
<p>It really depends on the size of the project. There's no inherent value in having a separate "models" assembly, as you can unit test a Web Application project (including MVC projects).</p>
Top-level .mak file for Visual Studio? <p>I've inherited a body of Visual C++ source that consists of about a dozen sub-projects. One of these is an empty "MakeAll" project that depends on all the others, so I can build the entire project by setting the MakeAll project active and selecting "Build All."</p> <p>I'd lik...
<p>You don't have to use make - if you have everything as solution files (.sln) then you can automate the build by using <a href="http://msdn.microsoft.com/en-us/library/0k6kkbsd.aspx" rel="nofollow">the msbuild tool</a>:</p> <pre><code>msbuild solution.sln </code></pre> <p>Also, why do you have a "MakeAll" project? ...