instruction
stringlengths
27
22.5k
chosen
stringlengths
27
28.2k
rejected
stringlengths
19
24.9k
__index_level_0__
int64
0
10k
<p>I am currently trying to print a gear with the possibility to connect it to the shaft of a DC motor. The following picture best describes what the shaft of the motor looks like by showing the hole printed in the gear:</p> <p><a href="https://i.stack.imgur.com/UNHn5.png" rel="nofollow noreferrer"><img src="https://i....
<blockquote> <p>Design a different connection to the shaft, however I don't know of any</p> </blockquote> <p>Use a shaft/flange coupler to be fastened to your shaft and to your printed part.</p> <hr /> <p>Without knowing the length of the shaft, you could connect a flange/coupler to design this into your gear. This is ...
<p>A good option would be to use a (set-)screw to press against the flat of the motor shaft, similar to how pulleys are mounted on stepper motors.</p>
1,733
<p>Using Microsoft Visual Studio 98, Microsoft Visual C++ 6.0 SP6</p> <p>When running under the debugger, there's only one problem. If I pause the program and resume, everything's fine.</p> <p>The problem? When I hit a breakpoint, my program stops. But not in a good way; execution halts, I'm thrown out of debug mo...
<p>Stop beating on VC6. It's old. The STL was updated in 1996 from HP code written in 1994. C++ was ratified in 1998.</p> <p>What is the code doing when you are breaking? Can you reduce the situation into a simple test. When I try that I usually find the cause. If you can do that so it still happens then I'll take a l...
<p>I haven't used MSVC6 in years, but I remember the debugger basically being a flaky piece of crap. Things like this would regularly happen for no apparent reason because it just didn't like your code that day.</p> <p>In addition to the debugger being a flaky piece of crap, the rest of it was too.</p> <p>It's STL im...
2,986
<p>I am building a toolchanger CoreXY 3D printer. I am in big trouble to find mic-6 aluminium toolplate in my country. Can you suggest me an alternative to mic-6? In my country, I can find easily 5083, 6082, 7005, etc. I don't think, that theese aluminium plates are suitable as heated bed. The design of the bed is the ...
<p>This is probably caused by too few top layers in combination with a too low infill percentage. Increase skin layers and increase infill percentage.</p> <p>If you have multiple layers already (at least about 4 for 0.2 mm layer height, for smaller layer heights even more), you might be printing at a too high temperatu...
<p>To combat the bad top layers, I usually use usually 5 top layers for any model of layer height 0.1 to 0.3 mm. I generally don't print with less than 9 % infill for PLA, which I have found sufficient to support even complex geometry on top.</p> <p>Also, I generally use a mixed setup of layers: the outermost layers I ...
1,815
<p>From what I understand, it takes a really long time for the heated bed to heat up using an MK2a heated bed. I've heard some people suggest that using <a href="http://forums.reprap.org/read.php?4,584582" rel="nofollow">Polyisocyanurate (PIR) foam</a> (insulation that takes quite a bit of heat to catch on fire) can b...
<p>An alternative solution that is used with some <a href="https://www.think3dprint3d.com/3D-Printer-Kits/complete-3D-printer-kits/Kossel-Mini-3dPrinter-Kit" rel="nofollow">Kossel Mini</a> models, is a simple <a href="https://lh4.googleusercontent.com/RNWfKpkiA_cg16D6gPqcQ4e1uCFmW4-lIV-KVZYnFJyn3EtbCrsH_sXHKXZxkrlPjnHD...
<p>If you use a seperate powersupply for your bed (or if your controller has a built in voltage regulator so it doesn't damage at higher voltages) you can sometimes find an small potentiometer near the connection terminals of your powersupply, turning this potentiometer up can raise the outputvoltage of your powersuppl...
185
<p>I'm trying to write a RegEx for a code generator (in C#) to determine a proper class or package name of an AS3 class.</p> <p>I know that class names</p> <ul> <li>must start with a letter (capital or otherwise)</li> <li>any other digit can be alphanumeric</li> <li>cannot have spaces</li> </ul> <p>Is there anything...
<p>Although you can start class names with lower case letters and include underscores and dollar signs, the "naming <strong>convention</strong>" is to start the class name and each separate word with a capital letter (e.g. UsefulThing), and not include underscores. When I see classes like <code>useful_thing</code>, it ...
<p>Here are some more valid classes. </p> <p>Actionscript 3 classes (and packages) must start with a letter, "_", or "$". They may also contain (but not start with) a number.</p> <pre><code>public class $Test {} public class _Test {} public class test {} </code></pre>
4,182
<ol> <li>Specifically getting on Windows the "..\Documents &amp; Settings\All Users, basicaly any path that needs the front end to be dynamically derived based on the OS your software is running on. <strong>(Now I need the answer to this)</strong></li> <li>the current users My Documents dirctory <strong>(okay this has...
<p>My docs would probably best be handled by accessing:</p> <pre><code>System.getProperty("user.home"); </code></pre> <p>Look up the docs on <a href="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/System.html" rel="noreferrer">System.getProperty</a>.</p>
<blockquote> <p>Specifically getting on Windows the "..\Documents &amp; Settings\All Users, basicaly any path that needs the front end to be dynamically derived based on the OS your software is running on. (Now I need the answer to this)</p> </blockquote> <p>The folders below the All Users dir are variable directori...
5,788
<p>I'm new to NHibernate (my 1st big project with it).<br> I had been using a simple method of data access by creating the ISession object within a using block to do my grab my Object or list of Objects, and in that way the session was destroyed after exiting the code block. </p> <p>This doesn't work in a situation w...
<p>Session management:</p> <p><a href="http://code.google.com/p/dot-net-reference-app/source/browse/trunk/src/Infrastructure/Impl/HybridSessionBuilder.cs" rel="nofollow noreferrer">http://code.google.com/p/dot-net-reference-app/source/browse/trunk/src/Infrastructure/Impl/HybridSessionBuilder.cs</a></p> <p>Session per...
<p>Since you are developing a Web App (presumably with ASP.NET), check out <a href="http://www.codeproject.com/KB/architecture/NHibernateBestPractices.aspx" rel="nofollow noreferrer">NHibernate Best Practices with ASP.NET</a> at CodeProject.</p>
5,257
<p>I think that java executables (jar files) are trivial to decompile and get the source code.</p> <p>What about other languages? .net and all?</p> <p>Which all languages can compile only to a decompile-able code?</p>
<p>In general, languages like Java, C#, and VB.NET are relatively easy to decompile because they are compiled to an intermediary language, not pure machine language. In their IL form, they retain more metadata than C code does when compiled to machine language. </p> <p>Technically you aren't getting the original sourc...
<p>Most languages can be decompiled but some are easier to decompile than others. .Net and Java put more information about the original program in the executables (method names, variable names etc.) so you get more of your original information back. </p> <p>C++ for example will translate variables and functions etc. ...
6,526
<p>Have you guys had any experiences (positive or negative) by placing your source code/solution on a network drive for Visual Studio 2005 or 2008? Please note I am not referring to placing your actual source control system on that drive, but rather your working folder.</p> <p>Thanks</p>
<p>Without any more information it is difficult to pinpoint the problem, but the root cause is that you most likely have compiled a class against a different version of the class that is missing a method, than the one you are using when running it.</p> <p>Look at the stack trace ... If the exception appears when calli...
<p>If your file name is different than the class name which contain main method then it may be the possibility that this error may cause.</p>
5,563
<p>I know you should, like an infant, never leave your printer without surveillance.</p> <p>But sometimes we all do, trusting our double thermistors and heat runaway configurations. But electronics fry and who says there is no danger even after the print job has finished and it's cooling down, still hooked up?</p> <p...
<p>Disclaimer: I am not affiliated with any linked brand or company, I just link to them for reference of the suggested print settings.</p> <h1>What is PLA?</h1> <p>PLA is, by its definition PolyLacticAcid, a polymer of entwined lactic acids. It is commonly made from fermenting starch - not via Type I (alcohol) but Typ...
<p>Adding this as a new answer since it doesn't seem to be covered in existing ones:</p> <p>Despite &quot;PLA+&quot; being a marketing term without a specific definition, I've found that many (most?) filament vendors don't seem to be doing their own secret-sauce blending to make it, and most premium filament vendors wh...
747
<p>In a stored procedure, when is #Temptable created in SQL Server 2005? When creating the query execution plan or when executing the stored procedure?</p> <pre><code>if (@x = 1) begin select 1 as Text into #Temptable end else begin select 2 as Text into #Temptable end </code></pre>
<p>It's created when it's executed and dropped when the session ends.</p>
<p>Whilst it may be automatically dropped at the end of a session, it is good practice to drop the table yourself when you're done with it.</p>
6,553
<p>The compiler usually chokes when an event doesn't appear beside a <code>+=</code> or a <code>-=</code>, so I'm not sure if this is possible.</p> <p>I want to be able to identify an event by using an Expression tree, so I can create an event watcher for a test. The syntax would look something like this:</p> <pre><c...
<p><strong>Edit:</strong> As <a href="https://stackoverflow.com/questions/35211/identify-an-event-via-a-linq-expression-tree#36255">Curt</a> has pointed out, my implementation is rather flawed in that it can only be used from within the class that declares the event :) Instead of "<code>x =&gt; x.MyEvent</code>" return...
<p>While Emperor XLII already gave the answer for this, I thought it was worth while to share my rewrite of this. Sadly, no ability to get the Event via Expression Tree, I'm using the name of the Event.</p> <pre><code>public sealed class EventWatcher : IDisposable { private readonly object _target; private ...
5,565
<p><strong><em>Note</strong>: Before any negative flagging, we asked permission on Meta prior to posting &amp; got a YES: <strong><a href="https://3dprinting.meta.stackexchange.com/questions/281/could-this-printing-material-recommendation-question-be-or-shaped-to-be-valid-on/283#283">Could this Printing Material Recomm...
<h2>No FDM print at all.</h2> <p>The problem of your design will not be the materials, but a basic property of FDM printing: FDM Printers do create a structure by placing a long string of filament next to itself and ontop of itself, creating tons of boudaries.</p> <p>These boundaries between the layers are the weak poi...
<h2>No FDM print at all.</h2> <p>The problem of your design will not be the materials, but a basic property of FDM printing: FDM Printers do create a structure by placing a long string of filament next to itself and ontop of itself, creating tons of boudaries.</p> <p>These boundaries between the layers are the weak poi...
941
<p>I'm trying to subtract a polyhedron from a cube, but it is not working (the cube remains solid). However, I can see the cut-out poly in preview mode (but not after a full render).</p> <p><strong>Preview</strong> -- poly cutout shows on the top (and bottom).</p> <p><a href="https://i.stack.imgur.com/Zk1Z5.png" rel="n...
<p>Usually when there's an overlap in two objects during a difference action, F6 render will resolve the problem. There's something more than that involved here, as reducing the height of the cube creates a non-manifold object from the difference. user R..'s answer has merit but is not going to solve the problem.</p> <...
<p>If the polyhedron surface and top surface of the cube are exactly coplanar, which they seem to be, it won't work; OpenSCAD operates numerically rather than analytically and which is &quot;inside&quot; or &quot;outside&quot; the other is subject to numerical instability. Whenever using differences you need to make th...
1,784
<p>To commemorate the public launch of Stack Overflow, what's the shortest code to cause a stack overflow? Any language welcome.</p> <p>ETA: Just to be clear on this question, seeing as I'm an occasional Scheme user: tail-call "recursion" is really iteration, and any solution which can be converted to an iterative sol...
<p>All these answers and no Befunge? I'd wager a fair amount it's shortest solution of them all:</p> <pre><code>1 </code></pre> <p>Not kidding. Try it yourself: <a href="http://www.quirkster.com/iano/js/befunge.html" rel="nofollow noreferrer">http://www.quirkster.com/iano/js/befunge.html</a></p> <p>EDIT: I guess I n...
<p>Ruby:</p> <pre><code>def i()i()end;i() </code></pre> <p>(17 chars)</p>
8,755
<p>New version of Management Studio (i.e. the one that ships with SQL Server 2008) finally has a Transact-SQL IntelliSense feature. However, out-of-the-box it only works with SQL Server 2008 instances.</p> <p>Is there some workaround for this?</p>
<p>There's no known trick 'in the wild' for getting around this, other than using CTP-6 of SQL Server 2008 (in favour of the RTM).</p> <p>the reasons for removing backward compatability (and a lot more discussion besides) are provided at the <a href="https://connect.microsoft.com/SQLServer/feedback/ViewFeedback.aspx?F...
<p>Has anyone tried either patching SSMS not to check the version (perhaps try looking at the binary differences between CTP 6 and RTM?), or patching SS 2005 to pretend to be 2008?</p> <p>Unclean, I know, but I don't see any other way.</p>
2,649
<p>I'm working on getting an Introduction to <a href="http://en.wikipedia.org/wiki/Groovy_%28programming_language%29" rel="nofollow noreferrer">Groovy</a> presentation ready for my local Java User's Group and I've pretty much got it together. What I'd like to see is what you all think I just have to cover. </p> <p>R...
<p>I don't know anything about groovy so in a sense I've qualified to answer this...</p> <p>I would want you to:</p> <ul> <li>Tell me why I would want to use Scripting (in general) as opposed to Java-- what does it let me do quicker (as in development time), what does it make more readable. Give tantalising examples ...
<p>You should definitely show them how to create a quick Grails application. Two domain classes that are related. Build a basic CRUD app. Explain that tables are being created behind the scenes using GORM(Hibernate). Then explain that you can create a war file and deploy it as you would any other Java war file. You...
4,911
<p>We use SAX to parse XML because it does not require the entire XML document to be read into memory in order to parse a single value. I read many articles that insisted SAX can only be used to parse/decode XML and not create it. Is this true?</p>
<p>No, it isn't true, you can encode XML to any Writer in Java using something similar to:</p> <pre><code>char[] ch; AttributesImpl atts = new AttributesImpl(); Writer writer = new StringWriter(); StreamResult streamResult = new StreamResult(writer); SAXTransformerFactory tf = (SAXTransformerFactory) TransformerFactor...
<p>The SAX handler interfaces were designed to be easy to implement. It's easy to write a class with similar (perhaps wrapping a SAX interface) to make it easy to call - chaining, remembering which element to close, easier attributes, etc.</p>
9,915
<p>I am currently creating a master ddl for our database. Historically we have used backup/restore to version our database, and not maintained any ddl scripts. The schema is quite large.</p> <p>My current thinking:</p> <ul> <li><p>Break script into parts (possibly in separate scripts):</p> <ol> <li>table creation<...
<p>I think the basic idea is good. </p> <p>The nice thing about building all the tables first and then building all the constraints, is that the tables can be created in any order. When I've done this I had one file per table, which I put in a directory called "Tables" and then a script which executed all the files ...
<p>I previously organised my DDL code organised by one file per entity and made a tool that combined this into a single DDL script.</p> <p>My former employer used a scheme where all table DDL was in one file (stored in oracle syntax), indicies in another, constraints in a third and static data in a fourth. A change sc...
2,697
<p>I've recently come to maintain a large amount of scientific calculation-intensive FORTRAN code. I'm having difficulties getting a handle on all of the, say, nuances, of a forty year old language, despite google &amp; two introductory level books. The code is rife with "performance enhancing improvements". Does an...
<p>You kind of have to get a "feel" for what programmers had to do back in the day. The vast majority of the code I work with is older than I am and ran on machines that were "new" when my parents were in high school.</p> <p>Common FORTRAN-isms I deal with, that hurt readability are:</p> <ul> <li>Common blocks</li> <...
<p>Here's another one that has bit me from time to time. When you are working on FORTRAN code make sure you skip all six initial columns. Every once and a while, I'll only get the code indented five spaces and nothing works. At first glance everything seems okay and then I finally realize that all the lines are star...
5,160
<p>I am trying to get some accurate runtime comparisons of PHP vs Python (and potentially any other language that I have to include). Timing within a script is not my problem but timing within a script does not account for everything from the moment the request is made to run the script to output.</p> <blockquote> <...
<p>If your idea is to compare the languages, I'd say anything outside them is not relevant for comparison purposes. </p> <p>Nonetheless you can use the time command to measure everything and can compare it with the timing within a script.</p> <p>Like this:</p> <pre><code>$ time script.php HI! real 0m3.218s user ...
<ol> <li><p>It's worth taking speed into account if you're optimizing code. You should generally know why you're optimizing code (as in: a specific task in your existing codebase is taking too long, not "I heard PHP is slower than Python"). It's <em>not</em> worth taking speed into account if you don't actually plan on...
8,743
<p>In analogy to: <a href="https://3dprinting.stackexchange.com/q/6723/4762">What glues for bonding printed PLA to injection-molded plastic?</a>, what are the best glues to use for PETG?</p> <p>I mostly print in PETG and have occasional failed prints which I usually reprint. But what if I'd like to repair a print e.g. ...
<p>From <a href="https://forum.simplify3d.com/viewtopic.php?t=9281" rel="nofollow noreferrer">forum</a></p> <blockquote> <p>Bison plastic - works great for me, only it's not "quick dry" but it's very strong, not brittle, holds PETG and PLA very strongly. Buy paint stripper that is/contains methylene chloride (di...
<p>If Carl's answer that cyanoacrylate glue works is accurate, I would suggest Loctite 420 or equivalent. It's diluted with solvents sufficiently to behave as a liquid rather than a gel, and in my experience on PLA it not only bonds the joint, but wicks between the extrusions and bonds walls/layers together much more s...
1,578
<p>How can I determine if a string is an IP address? Either <em>IPv4</em> or <em>IPv6</em>?</p> <p>What is the least and most number of characters?</p> <p>I assume this would be a <strong>regex</strong> answer.</p>
<p>In .NET there's an IPAddress type which has a handy method <a href="http://msdn.microsoft.com/en-us/library/system.net.ipaddress.tryparse.aspx" rel="noreferrer">TryParse</a>.</p> <p>Example: </p> <pre><code>if(System.Net.IPAddress.TryParse(PossibleIPAddress, validatedIPAddress)){ //validatedIPAddress is good }...
<p>IPv4 becomes: <code>/\d\d?\d?.\d\d?\d?.\d\d?\d?.\d\d?\d?/</code></p> <p>I'm not sure about the IPv6 rules.</p>
6,379
<p>Are there any free tools that implement evidence-based scheduling like <a href="http://www.joelonsoftware.com/items/2007/10/26.html" rel="nofollow noreferrer">Joel talks about</a>? There is 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 act...
<p>FogBugz is free for up to 2 users by the way. As far I know this is the only tool that does EBS.</p> <p>See here <a href="http://www.workhappy.net/2008/06/get-fogbugz-for.html" rel="noreferrer">http://www.workhappy.net/2008/06/get-fogbugz-for.html</a></p>
<p><a href="http://en.wikipedia.org/wiki/Evidence_Based_Scheduling" rel="nofollow noreferrer">According to Wikipedia</a>, Fogbugz is the only product currently offering EBS.</p>
3,035
<p>For a person without a comp-sci background, what is a lambda in the world of Computer Science?</p>
<p>Lambda comes from the <a href="http://en.wikipedia.org/wiki/Lambda_calculus" rel="noreferrer">Lambda Calculus</a> and refers to anonymous functions in programming.</p> <p>Why is this cool? It allows you to write quick throw away functions without naming them. It also provides a nice way to write closures. With that...
<p>A lambda function can take any number of arguments, but they contain only a single expression. ... Lambda functions can be used to return function objects. Syntactically, lambda functions are restricted to only a single expression.</p>
3,724
<p>I am looking to stream a file housed in a SharePoint 2003 document library down to the browser. Basically the idea is to open the file as a stream and then to "write" the file stream to the reponse, specifying the content type and content disposition headers. Content disposition is used to preserve the file name, ...
<p>It might be something really simple, believe it or not I coded exactly the same thing today, i think the issue might be that the content disposition doesnt tell the browser its an attachment and therefore able to be saved.</p> <pre><code> Response.AddHeader("Content-Disposition", "attachment;filename=myfile.doc"); ...
<p>It might be something really simple, believe it or not I coded exactly the same thing today, i think the issue might be that the content disposition doesnt tell the browser its an attachment and therefore able to be saved.</p> <pre><code> Response.AddHeader("Content-Disposition", "attachment;filename=myfile.doc"); ...
7,596
<p>Debugging in visual studio seems to have been broken with sp1. Single stepping randomly does not work and just starts to run. Sometimes breakpoints are ignored. It is unpredictable and unusable. It will generally hit the first break point but after that it is totally unpredictable. </p> <p>Any idea what needs to b...
<p>Make sure you are debuging using the debug configuration, not the release one. Also make sure optimizations are disabled in debug configuration.</p> <p>Optimizations must be off when you debug else it can lead to very erratic behaviours like these.</p> <hr> <p>For C# projects, which I am assuming the question is ...
<p>We are using c# as a language.</p> <p>The problem has been identified by microsoft.</p> <p>quote from forums:</p> <blockquote> <p>We have identified the root cause of this issue and are currently working on a solution. We apologize for the inconvenience that this is causing you. We will let you know as soon as ...
4,305
<p>I'm having trouble writing a regular expression that matches valid IPv6 addresses, including those in their compressed form (with <code>::</code> or leading zeros omitted from each byte pair). </p> <p>Can someone suggest a regular expression that would fulfill the requirement?</p> <p>I'm considering expanding eac...
<p>I was unable to get @Factor Mystic's answer to work with POSIX regular expressions, so I wrote one that works with POSIX regular expressions and PERL regular expressions.</p> <p>It should match:</p> <ul> <li>IPv6 addresses</li> <li>zero compressed IPv6 addresses (<a href="https://www.rfc-editor.org/rfc/rfc5952#secti...
<p>The regex allows the use of leading zeros in the IPv4 parts.</p> <p>Some Unix and Mac distros convert those segments into octals.</p> <p>I suggest using <code>25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d</code> as an IPv4 segment.</p>
7,698
<p>I am looking for a <strong>3rd party solution to integrate a <a href="http://en.wikipedia.org/wiki/QR_Code" rel="nofollow noreferrer">QR code</a> reader</strong> in Windows Mobile Applications (.NET Compact Framework). The component should <strong>integrate Reader (camera) and Decoder (algorithm)</strong>.</p> <p>I...
<p><a href="http://www.codeproject.com/KB/cs/qrcode.aspx" rel="nofollow noreferrer">Here</a> is an open source C# port of the Java QR Code <a href="http://qrcode.sourceforge.jp/" rel="nofollow noreferrer">library</a>.</p>
<p>Did you try this one: <a href="http://webscripts.softpedia.com/script/E-Commerce/QRCode-NET-Compact-Framework-Package--30802.html" rel="nofollow noreferrer">QRCode .NET Compact Framework Package</a> ?</p>
8,754
<p>As far as I can tell, this is isn't possible, so I'm really just hoping for a left field undocumented allocation hook function.<br> I want a way to track allocations like in <a href="http://msdn.microsoft.com/en-us/library/cy8c7wz5.aspx" rel="nofollow noreferrer">_CrtSetAllocHook</a>, but for <code>C#/.NET</code>.<b...
<p>The CLR has a 'profiling API' that hooks into pretty much everything - it is what the commercial .NET memory profiling products use, I believe. Here is an MSDN link to the top level of the documentation: <a href="http://msdn.microsoft.com/en-us/library/bb384547.aspx" rel="noreferrer">.NET Framework General Reference...
<p>I would just use Red Gate's ANTS Profiler. It will tell you a lot about what's going on in memory without you having to learn the profiling API yourself.</p>
7,318
<p>I have a class to parse a matrix that keeps the result in an array member:</p> <pre><code>class Parser { ... double matrix_[4][4]; }; </code></pre> <p>The user of this class needs to call an API function (as in, a function I have no control over, so I can't just change its interface to make things work more ea...
<p>Here's a nice, clean way:</p> <pre><code>class Parser { public: typedef double matrix[4][4]; // ... const matrix&amp; getMatrix() const { return matrix_; } // ... private: matrix matrix_; }; </code></pre> <p>Now you're working with a descriptive type name rather than an array, but sin...
<p>I've used a union like this to pass around matrices in the past:</p> <pre><code>union matrix { double dflat[16]; double dmatr[4][4]; }; </code></pre> <p>Then pass a pointer in to your setter and copy the data into the matrix in your class.</p> <p>There are ways of handling this otherwise (that are more ge...
7,880
<p>Many websites, including this one, add what are apparently called <em>slugs</em> - descriptive but as far as I can tell useless bits of text - to the end of URLs.</p> <p>For example, the URL the site gives for this question is:</p> <p><a href="https://stackoverflow.com/questions/47427/why-do-some-websites-add-slug...
<p>The slugs make the URL more user-friendly and you know what to expect when you click a link. Search engines such as Google, rank the pages higher if the searchword is in the URL.</p>
<p>Ideally, the "slug" should be the only identifier needed. In practice, on dynamic sites such as this, you either have to have a unique numerical identifier or start appending/incrementing numbers to the "slug" like Digg does.</p>
6,966
<p>I want to get started on HMM's, but don't know how to go about it. Can people here, give me some basic pointers, where to look?</p> <p>More than just the theory, I like to do a lot of hands-on. So, would prefer resources, where I can write small code snippets to check my learning, rather than just dry text.</p>
<p>Have you tried: Russel and Norvig's Artificial Intelligence: A Modern Approach. </p> <p>I realise that this is heavy on theory, but it also contains useful code samples that can be used to help your learning.</p> <p>You can also check out: <a href="http://www.kanungo.com/software/software.html" rel="nofollow noref...
<p>Great videos as of Stanford Online AI course are available: See unit 11.</p> <p><a href="https://www.ai-class.com/course/video/videolecture/138" rel="nofollow">https://www.ai-class.com/course/video/videolecture/138</a></p>
9,537
<p>I have to choose an online WYSIWYG editor. I'm pending between <a href="http://tinymce.moxiecode.com/" rel="nofollow noreferrer">TinyMCE</a> and <a href="http://trac.xinha.org/" rel="nofollow noreferrer">Xinha</a>. My application is developed in Asp.Net 3.5. Could you help me with with some pros and cons? </p>
<p>Haven't tried Xihna myself, but I have experience with TinyMCE and FCKeditor. In my company we switched to TinyMce (from FCKeditor) due to the superior support for pasting from word documents and the (relatively easy to work with) plugin architecture which we used to add some custom modules (links browser, simple fi...
<p>I've never used Xinha, but I can vouch for TinyMCE. It's fast, scales well, and is infinitely customizable. I particularly like the dynamic loading of functionality, which means you only take the performance hit for the stuff you use.</p> <p>It also includes language-specific <a href="http://wiki.moxiecode.com/inde...
7,124
<p>I'm looking at adding scripting functionality to an existing codebase and am weighing up the pros/cons of various packages. Lua is probably the most obvious choice, but I was wondering if people have any other suggestions based on their experience.</p> <p>Scripts will be triggered upon certain events and may stay r...
<p>Based on my own experience:</p> <ul> <li>Python. IMHO this is a good choice. We have a pretty big code base with a lot of users and they like it a lot.</li> <li>Ruby. There are some really nice apps such as Google Sketchup that use this. I wrote a Sketchup plugin and thought it was pretty nice.</li> <li>Tcl. T...
<p>There were some excellent suggestions already, but I just wanted to mention that Perl can also be called / can call to C/C++.</p>
3,616
<p>Let's say we have a simple function defined in a pseudo language.</p> <pre><code>List&lt;Numbers&gt; SortNumbers(List&lt;Numbers&gt; unsorted, bool ascending); </code></pre> <p>We pass in an unsorted list of numbers and a boolean specifying ascending or descending sort order. In return, we get a sorted list of num...
<p>Don't waste too much time trying to think of <em>every</em> boundry condition. Your tests won't be able to catch <em>every</em> bug first time around. The idea is to have tests that are <em>pretty good</em>, and then each time a bug <em>does</em> surface, write a new test specifically for that bug so that you neve...
<p>A good code coverage tool really helps.</p> <p>100% coverage doesn't mean that it definitely is adequately tested, but it's a good indicator.</p> <p>For .Net NCover's quite good, but is no longer open source.</p> <hr> <p>@Mike Stone - Yeah, perhaps that should have been "high coverage" - we aim for 80% minimum,...
3,359
<p>Right now, I'm particularly interested in reading the data from MP3 files (ID3 tags?), but the more it can do (eg EXIF from images?) the better without compromising the ID3 tag reading abilities.</p> <p>I'm interested in making a script that goes through my media (right now, my music files) and makes sure the file ...
<p>There is a great post on using PowerShell and TagLibSharp on Joel "Jaykul" Bennet's <a href="http://huddledmasses.org/editing-media-tags-from-powershell/" rel="nofollow noreferrer">site</a>. You could use TagLibSharp to read the metatdata with any .NET based language, but PowerShell is quite appropriate for what yo...
<p>@Thomas Owens PowerShell is now part of the Common Engineering Criteria (as of Microsoft's 2009 Product Line) and starting with Serve 2008 is included as a feature. It stands as much of a chance to be installed as Python or Ruby. You also mentioned that you were willing to go to C#, which could use TagLibSharp. O...
4,828
<p>The 'click sound' in question is actually a system wide preference, so I only want it to be disabled when my application has focus and then re-enable when the application closes/loses focus.</p> <p>Originally, I wanted to ask this question here on stackoverflow, but I was not yet in the beta. So, after googling for...
<p>I've noticed that if you use WebBrowser.Document.Write rather than WebBrowser.DocumentText then the click sound doesn't happen.</p> <p>So instead of this:</p> <pre><code>webBrowser1.DocumentText = "&lt;h1&gt;Hello, world!&lt;/h1&gt;"; </code></pre> <p>try this:</p> <pre><code>webBrowser1.Document.OpenNew(true); ...
<p>Definitely feels like a hack, but having done some research on this a long time ago and not finding any other solutions, probably your best bet.</p> <p>Better yet would be designing your application so it doesn't require many annoying page reloads.. for example, if you're refreshing an iframe to check for updates o...
3,163
<p>I need to build something that starts serving a H.264 encoded video to a flash player halfway through the file (to support skipping to a point in the video that has not been buffered yet). </p> <p>Currently, the videos are in the FLV container format, but transcoding is an option. I managed to re-write the file hea...
<p>The flash player can only start playing H.264 video once it's downloaded the MOOV atom. Existing pseudo-streaming providers just give you an FLV header - either the first 13 bytes of the file or a hardcoded one - and then serve the file from the given offset. If you want to make an H.264 pseudo-streamer, you'll ne...
<p>two things you can do:</p> <p>1) use lighttpd and it's mp4 streaming plug-in that'll generate the required streaming container on the fly</p> <p>2) create a keyframed FLV and use a psuedo-streaming script (like XMOOV) to stream your file.</p> <p>if you need mp4/aac you can just put them inside the FLV container, ...
8,740
<p>In relation to this question on <a href="https://stackoverflow.com/questions/14413/using-opengl-extensions-on-windows">Using OpenGL extensions</a>, what's the purpose of these extension functions? Why would I want to use them? Further, are there any tradeoffs or gotchas associated with using them?</p>
<p>The OpenGL standard allows individual vendors to provide additional functionality through extensions as new technology is created. Extensions may introduce new functions and new constants, and may relax or remove restrictions on existing OpenGL functions. </p> <p>Each vendor has an alphabetic abbreviation that is u...
<p><strong>OpenGL Extensions</strong> are new features added to the <strong>OpenGL specification</strong>, they are added by the OpenGL standards body and by the various graphics card vendors. These are exposed to the programmer as new function calls or variables. Every new version of the OpenGL specification ships wit...
3,801
<p>What is a good way to remove the code from display pages when developing with PHP. Often the pages I work on need to be editted by an outside person. This person is often confused by lots of blocks of PHP, and also likes to break my code.</p> <p>I've tried moving blocks of code out into functions, so now there are ...
<p>You don't need a "system" to do templating. You can do it on your own by keeping presentation &amp; logic separate. This way the designer can screw up the display, but not the logic behind it.</p> <p>Here's a simple example:</p> <pre><code>&lt;?php $people = array('derek','joel','jeff'); $people[0] = 'martin'; //...
<p>There's a lot that can be said on this topic but a very basic starting point would be to move as much code as possible out into separate files and then use include statements.</p>
5,703
<p>How can I monitor an SQL Server database for changes to a table without using triggers or modifying the structure of the database in any way? My preferred programming environment is <a href="http://en.wikipedia.org/wiki/.NET_Framework" rel="noreferrer">.NET</a> and C#.</p> <p>I'd like to be able to support any <a h...
<p>Take a look at the CHECKSUM command:</p> <pre><code>SELECT CHECKSUM_AGG(BINARY_CHECKSUM(*)) FROM sample_table WITH (NOLOCK); </code></pre> <p>That will return the same number each time it's run as long as the table contents haven't changed. See my post on this for more information:</p> <p><a href="http://msdn.mic...
<p>Check the last commit date. Every database has a history of when each commit is made. I believe its a standard of ACID compliance.</p>
2,242
<p>I have a very large cascading menu system with over 300 items in it. <em>(I know it's large but it's a requirement.)</em><br> Currently, it's written in javascript so the external file is cached by browsers. </p> <p>To improve search engine results I need to convert this to a css menu system.<br> I realize the bro...
<p>The best way to accomplish what you want to do is using <a href="https://www.google.com/webmasters/tools/docs/en/protocol.html" rel="nofollow noreferrer">SiteMaps</a> to inform Google about the urls for your web site. Basically you will want to translate your hierarchial data for the menus into a SiteMap.</p>
<p>You could generate the menus beforehand into static html / javascript files, and have all the pages pull the site from the same URL on your site. That way, the client side browser will do the caching. You'll just have to have a step in your deployment that generates the html files for the menu.</p> <p>Try to have...
7,958
<p>How would you dynamically subscribe to a C# event so that given a Object instance and a String name containing the name of the event, you subscribe to that event and do something (write to the console for example) when that event has been fired?</p> <p>It would seem using Reflection this isn't possible and I would ...
<p>You can compile expression trees to use void methods without any arguments as event handlers for events of any type. To accommodate other event handler types, you have to map the event handler's parameters to the events somehow. </p> <pre><code> using System; using System.Linq; using System.Linq.Expressions; u...
<p>Do you mean something like:</p> <pre><code>//reflect out the method to fire as a delegate EventHandler eventDelegate = ( EventHandler ) Delegate.CreateDelegate( typeof( EventHandler ), //type of event delegate objectWithEventSubscriber, //instance of the object with the matching method e...
6,777
<p>That's my first 3d printer. I'm using Repetier Host as the brand recomends, and set all the configuration as the recommended one. I decided to print one STL file but the result is not the best one. That's what I was trying to print: <a href="https://i.stack.imgur.com/f1V22.jpg" rel="nofollow noreferrer"><img src="ht...
<p>From the video it is very clear there is <strong>a major problem with bed adhesion</strong>.</p> <p>It also looks like you are printing on bare metal (aluminium?) which I never saw anybody doing. I must admit I don't know it is impossible or simply very rare, but the first thing I would try in your case is <strong>...
<p>I would suggest buying Buildtak, which is a high-quality adhesion surface. This surface is almost guaranteed to make your prints stick to your bed. If Buildtak is outside of your budget, I would suggest using a relatively high grade painters tape combined with either purple gluestick or hairspray applied to your bed...
818
<p>What tools are people using for testing SQL Server databases?</p> <p>By this I mean all parts of the database:</p> <ul> <li>configuration</li> <li>tables</li> <li>column type</li> <li>stored procedures</li> <li>constraints</li> </ul> <p>Most likely, there is not one tool to do it all.</p>
<p>How do you mean "Test the database"? </p> <p>If you are testing foreign keys, a simply script to insert invalid data is all you should need.</p> <p>Testing a database could imply a great number of issues. Does it have all the tables? Are the tables correct? Are the indexes in place? Did the latest updates get...
<p>I personally use NHibernate with SqlCe, this provides a "throw-away" database that doesn't need any specialized tear down after the tests are run.</p> <p>It also provides a good way to test your nhibernate mappings if applicable.</p> <p>Here is a link to an article I wrote awhile ago on how to accomplish this: <a ...
4,758
<p>What is the fastest method of parsing an XML file in C#? I'm using .Net 2.0 </p>
<p>If you're using .Net 2 then the XmlReader and XmlDocument are about it.</p> <p>If you can use .Net 3.5 then the new Linq to Xml methods are a big improvement.</p>
<p>I haven't benched-marked it myself, but when I've asked about it in the past I've been told that XmlDocument is supposed to be faster. I have my doubts, though, since XmlDocument would need to create a DOM while XmlReader does not.</p>
6,340
<p>I want something that looks like a file handle but is really backed by an in-memory buffer to use for I/O redirects. How can I do this?</p>
<p>I just wrote a library which provides this, called "knob" [<a href="http://hackage.haskell.org/package/knob">hackage</a>]. You can use it to create <code>Handle</code>s which reference/modify a <code>ByteString</code>:</p> <pre><code>import Data.ByteString (pack) import Data.Knob import System.IO main = do kno...
<p>It's not possible without modifying the compiler. This is because Handle is an abstract data type, not a typeclass.</p>
8,547
<p>What kind of execution rate do you aim for with your unit tests (# test per second)? How long is too long for an individual unit test? </p> <p>I'd be interested in knowing if people have any specific thresholds for determining whether their tests are too slow, or is it just when the friction of a long running test ...
<p>All unit tests should run in under a second (that is all unit tests combined should run in 1 second). Now I'm sure this has practical limits, but I've had a project with a 1000 tests that run this fast on a laptop. You'll really want this speed so your developers don't dread refactoring some core part of the model...
<p>I judge my unit tests on a per test basis, not by by # of tests per second. The rate I aim for is 500ms or less. If it is above that, I will look into the test to find out why it is taking so long.</p> <p>When I think a test is to slow, it usually means that it is doing too much. Therefore, just refactoring the ...
3,168
<p>When opening a file from your hard drive into your browser, where is the document root? To illustrate, given the following HTML code, if the page is opened from the local machine <code>(file:///)</code> then where should the <code>css</code> file be for the browser to find it?</p> <pre><code>&lt;link href="/temp/t...
<p>You <i>can</i>, but probably don't want to, set the document root on a per-file basis in the head of your file:</p> <pre> &lt;base href="my-root"&gt; </pre>
<p>Eric, the document root is the folder in which your file is, wherever it may be.</p>
3,943
<p>One of the things that has been talked about a few times on the podcast is whether menu items should always be enabled to prevent "WHY ISN'T THIS AVAILABLE!" frustration for the end user.</p> <p>This strikes me as a good idea, but then there's the issue of communicating the lack of availability (and the reason why)...
<p>One thing I've seen a printer manufacturer do with their printer properties dialog is to have a little help baloon icon beside disabled items that display a tooltip when hovered over.</p> <p>Another thing you can do with disabled items is to add in parenthesis why it's disabled or what the user would have to do to ...
<p>Joel has a post on that <a href="http://www.joelonsoftware.com/items/2008/07/01.html" rel="nofollow noreferrer">http://www.joelonsoftware.com/items/2008/07/01.html</a> which might be a good place to start thinking about this.</p>
3,959
<p>I'm using PHP's PDO layer for data access in a project, and I've been reading up on it and seeing that it has good innate support for persistent DB connections. I'm wondering when/if I should use them. Would I see performance benefits in a CRUD-heavy app? Are there downsides to consider, perhaps related to security?...
<p>You could use this as a rough "ruleset":</p> <p><strong>YES</strong>, use persistent connections, if:</p> <ul> <li>There are only few applications/users accessing the database, i.e. you will not result in 200 open (but probably idle) connections, because there are 200 different users shared on the same host.</li> ...
<p>I was going to ask this same question but rather than ask the same question again I'll just add some information that I've found.</p> <ul> <li><a href="http://www.mysqlperformanceblog.com/2006/11/12/are-php-persistent-connections-evil/" rel="nofollow noreferrer">Are PHP persistent connections evil ?</a></li> <li><a...
7,301
<p>Currently I have two Linux servers running MySQL, one sitting on a rack right next to me under a 10 Mbit/s upload pipe (main server) and another some couple of miles away on a 3 Mbit/s upload pipe (mirror).</p> <p>I want to be able to replicate data on both servers continuously, but have run into several roadblocks...
<p>We at Percona offer free tools to detect discrepancies between master and server, and to get them back in sync by re-applying minimal changes.</p> <ul> <li><a href="http://www.percona.com/doc/percona-toolkit/pt-table-checksum.html" rel="nofollow">pt-table-checksum</a></li> <li><a href="http://www.percona.com/doc/pe...
<p><a href="http://www.goldengate.com/" rel="nofollow noreferrer">GoldenGate</a> is a very good solution, but probably as expensive as the MySQL replicator.</p> <p>It basically tails the journal, and applies changes based on what's committed. They support bi-directional replication (a hard task), and replication betw...
2,583
<p>I have a repeater that is bound to some data.</p> <p>I bind to the <strong>ItemDataBound</strong> event, and I am attempting to <strong>programmatically</strong> create a <strong>UserControl</strong>:</p> <p>In a nutshell:</p> <pre><code>void rptrTaskList_ItemDataBound(object sender, RepeaterItemEventArgs e) { ...
<p>Eh, figured out one way to do it:</p> <pre><code>ExecTaskControl foo = (ExecTaskControl)LoadControl("tasks\\ExecTaskControl.ascx"); </code></pre> <p>It seems silly to have a file depedancy like that, but maybe thats how UserControls must be done.</p>
<p>I think that @Craig is on the right track depending on the details of the problem you are solving. Add it to the repeater and remove it or set Visible="false" to hide it where needed. Viewstate gets tricky with dynamically created controls/user controls, so google that or check <a href="http://www.aspnet4you.com/a...
4,874
<p>How can I have SQL repeat some set-based operation an arbitrary number of times without looping? How can I have SQL perform an operation against a range of numbers? I'm basically looking for a way to do a set-based for loop.<p> I know I can just create a small table with integers in it, say from 1 to 1000 and then u...
<p>I think the very short answer to your question is to use WITH clauses to generate your own.</p> <p>Unfortunately, the big names in databases don't have built-in queryable number-range pseudo-tables. Or, more generally, easy pure-SQL data generation features. Personally, I think this is a <strong>huge</strong> fai...
<p>If using SQL Server 2000 or greater, you could use the <strong>table datatype</strong> to avoid creating a normal or temporary table. Then use the normal table operations on it.</p> <p>With this solution you have essentially a table structure in memory that you can use almost like a real table, but much more perfor...
8,277
<p>Which way do you prefer to create your forms in MVC?</p> <pre><code>&lt;% Html.Form() { %&gt; &lt;% } %&gt; </code></pre> <p>Or</p> <pre><code>&lt;form action="&lt;%= Url.Action("ManageImage", "UserAccount") %&gt;" method="post"&gt; &lt;/form&gt; </code></pre> <p>I understand that Html.Form() as of PR5 now just ...
<p>The second way, definitely. The first way is programmer-centric, which is not what the V part of MVC is about. The second way is more designer centric, only binding to the model where it is necessary, leaving the HTML as natural as possible.</p>
<p>The reason for using helpers is that they allow you to encapsulate common patterns in a consistent and DRY fashion. Think of them as a way of refactoring views to remove duplication just as you would with regular code. </p> <p>For example, I <a href="http://andrewpeters.net/2008/08/21/nhaml-block-methods-and-restfu...
6,372
<p>(This is a followup to my <a href="https://stackoverflow.com/questions/42468/how-do-i-measure-bytes-inout-of-an-ip-port-used-for-net-remoting">previous question</a> about measuring .NET remoting traffic.)</p> <p>When I am testing our Windows service / service controller GUI combination, it is often most convenient ...
<p>What you should do is to run RawCap, which is a sniffer that can capture traffic to/from the loopback interface in Windows. Just start it with "RawCap.exe 127.0.0.1 loopback.pcap".</p> <p>You can then open up loopback.pcap in Wireshark or <a href="http://www.netresec.com/?page=NetworkMiner" rel="noreferrer">Network...
<p>You should definitely try Npcap, it works perfectly with Wireshark to capture loopback traffic in Windows, see here: <a href="https://wiki.wireshark.org/CaptureSetup/Loopback" rel="nofollow">https://wiki.wireshark.org/CaptureSetup/Loopback</a></p>
6,848
<p>I'd like to buy a 3D printer and use it as a &quot;platform&quot; for an <strong>external</strong> optical sensor. The idea is to mount an optical sensor on the Z-axis and to put a workpiece on the X-Y table. Now, I'd like to move the sensor across the workpiece and trigger the measurement of the optical sensor. He...
<p>A flexible material, such as PETG or ABS, is probably the best. PLA is brittle, especially after absorbing moisture, and probably would crack under continued use.</p> <p>Nylon is good, but not easy to use. With PETG in an enclosure, I end up running fans to avoid heat creep; so PETG may actually do better without ...
<p>PETG, ABS and NYLON would work great for press-fit or snap-fit connections. If you really can't build a (cardboard) enclosure I would go for PETG as it has good repeatable mechanical properties and does not require an enclosure.</p>
1,905
<p>For more information - <a href="http://en.wikipedia.org/wiki/Personal_Software_Process" rel="noreferrer">Personal Software Process on Wikipedia</a> and <a href="http://en.wikipedia.org/wiki/Team_Software_Process" rel="noreferrer">Team Software Process on Wikipedia</a>.</p> <p>I have two questions:</p> <ol> <li>Wha...
<p>I went through the training and then my company paid for me to go to Carnegie Mellon and go through the PSP instructor training course to get certified as an instructor. I think the goal was to use this as part of our company's CMM/CMMI effort. I met Watts Humphrey and found him to be a kind, gentle soul with some...
<p>I used it during university but at work we really don't have a process at all. Only recently have we started using version control.</p> <p>My experience with it was that it seemed far too tedious to be useful. If it's not automated, then it can go away.</p>
4,784
<p>I have a 3D printer and I have printed some models with castable resin. When I burn one of these models in the oven and then do the metal casting, the surface of the metal piece is not smooth.</p> <p>I did a test with a pan. I put a model of wax and a model of castable resin to heat in a pan, and the wax model melt...
<p>Factually, the correct process is to heat up the mold hot enough to evaporate the positive. </p> <p>In <a href="https://en.wikipedia.org/wiki/Investment_casting" rel="nofollow noreferrer">investment casting</a> the process to remove the wax or plastic positive is called the <code>"Dewax"</code> and <code>"Burnout p...
<h2>Traditional lost molds.</h2> <p>The reason many jewelers use wax for making the molds for lost mold casting is, that it has (compared to plastic molding materials) a very low melting and boiling point, allowing to create molds with much lower temperature equipment.</p> <p>A variant of green sand casting is done wit...
1,264
<p>ASP.NET 2.0 web application, how to implement shortcut key combination of <kbd>CTRL + Letter</kbd>, preferably through JavaScript, to make web application ergonomically better? How to capture multiple-key keyboard events through JavaScript?</p>
<p>Your event listener function, gets passed an Event object. That has a lot of useful information on it, including the properties "altKey", "ctrlKey", "shiftKey" and "metaKey". If any of the modifier keys are being held down when that event fires, the corresponding property is set to true.</p> <p>This applies to keyb...
<p>I know this is not answering the orginal question, but here is my advice: Don't Use Key Combination Shortcuts In A Web Application!</p> <p>Why? Because it might break de the usability, instead of increasing it. While it's generally accepted that "one-key shortcut" are not used in common browsers (Opera remove it as...
9,043
<p>I expected the two <code>span</code> tags in the following sample to display next to each other, instead they display one below the other. If I set the <code>width</code> of the class <code>span</code>.right to 49% they display next to each other. I am not able to figure out why the right span is pushed down like th...
<pre><code>float: left; </code></pre> <p>Try adding that to span.left</p> <p>It will cause it to float to the left (as suggested by the syntax).</p> <hr> <p>I am not a CSS expert by any means so please don't take this as unarguable fact but I find that when something is floated, it makes no difference to the vertic...
<p>I don't like this hack but it seems to do the job both in Firefox and IE6:</p> <pre class="lang-css prettyprint-override"><code>span.right { vertical-align:top; display:inline-block; text-align:right; height:80px; width:50%; *width:100%; background-color:red; } </code></pre> <p>Note the <code>*width...
5,489
<p>I need to convert latitude/longitude coordinates into Easting/Northing coordinates in the Alberta 10 TM Projection.</p> <p>The 10 TM projection is similar to UTM, but it is a custom projection for the province of Alberta, Canada. I think (with some effort) I could code it myself but would rather not reinvent the w...
<p>Grab <a href="https://proj.org" rel="nofollow noreferrer">PROJ Cartographic Projections library</a> - open source library.</p> <p>Suggested parameters for 10TM:</p> <blockquote> <p>+proj=tmerc +lon_0=-115 +k_0=0.9992 +x_0=500000 +datum=NAD27</p> </blockquote> <p>According to <a href="http://mapserver.gis.umn.edu/dat...
<p>You can also use <a href="http://code.google.com/p/android-openmap-framework/" rel="nofollow">http://code.google.com/p/android-openmap-framework/</a> which can convert an Android Location to a LatLonPoint, UTMPoint, or MGRSPoint.</p>
6,335
<p>I've run into a problem where I make changes to a few JavaScript files that are referenced in an HTML file, but the browser doesn't see the changes. It holds onto the copy cached in the browser, even though the web server has a newer version.</p> <p>Not until I force the browser to clear the cache do I see the chan...
<p>We append a product build number to the end of all Javascript (and CSS etc.) like so:</p> <pre><code>&lt;script src="MyScript.js?4.0.8243"&gt; </code></pre> <p>Browsers ignore everything after the question mark but upgrades cause a new URL which means cache-reload.</p> <p>This has the additional benefit that you ...
<p>I am also of the method of just renaming things. It never fails, and is fairly easy to do.</p>
7,807
<p>I want to be able to do:</p> <pre><code>For Each thing In things End For </code></pre> <p>CLASSIC ASP - NOT .NET!</p>
<p>Something like this?</p> <pre><code>dim cars(2),x cars(0)=&quot;Volvo&quot; cars(1)=&quot;Saab&quot; cars(2)=&quot;BMW&quot; For Each x in cars response.write(x &amp; &quot;&lt;br /&gt;&quot;) Next </code></pre> <p>See <a href="http://web.archive.org/web/20140305020029/http://www.w3schools.com/vbscript/vbscript_l...
<p>As Brett said, its better to use a vb component to create collections. Dictionary objects are not very commonly used in ASP unless for specific need based applications. </p>
2,446
<p>I've seen several questions about dyes in regards to food-safety, with no conclusive answers, as well as anecdotes on the RepRap wiki about how the mechanical properties of dyed PLA tend to vary by color. The general unsatisfactory answer is that dyes and additives used are proprietary secrets of filament manufactur...
<p>I spoke with a chemist tonight. He said to start with the SDS (or MSDS) for the filament, which is required to be available for most materials. It should list the pigments and additives if they are not recognized as safe. If they are safe, non-toxic, not flammable, non-reactive, they might not be disclosed on...
<p>I fear your supposition about <em>secret</em> --> <em>open secret</em> is too optimistic. Manufacturers are very unlikely to reveal their components, or the mix ratio, used to create a given color. </p> <p>Consider the Coca-cola formula. It's been a secret for over a hundred years, despite a number of competin...
1,366
<p>I've put together a flashlight mount for a camera coldshoe in OpenSCAD. I originally modeled it in FreeCAD and it was easy to round the edges of the clamp with a fillet and that makes it a little easier to get the light in and out of the mount.</p> <p>I'm not sure how to do it in OpenSCAD. Naively, I'm sure I coul...
<p>I'm far from a wizard with OpenSCAD, but enjoy using the program, learning something new every time. In your case, it's likely that you can use the <a href="https://github.com/Irev-Dev/Round-Anything" rel="nofollow noreferrer">roundanything library</a> to accomplish your objective.</p> <p>The library will present va...
<p>I ended up taking a third option I suppose. I decided I was cutting the gap wrong. I was using <code>difference</code> to take a rectangle out of the ring.</p> <p>I decided I'd simplify that and take out an extruded triangle.</p> <pre><code>ringRadius = radius + thickness; verticalOffset = tan(gapAngle / 2) * ring...
1,865
<p>Let's compile a list of tips.</p> <p>(Understandably there will be some subjectivity involved, but some pointers would be useful to someone overwhelmed by tackling a large project within the Flash framework.)</p>
<p>These are just scattered thoughts on organization for projects being worked on mostly with the Flash IDE.</p> <p>First, I highly recommend using source control, like Subversion, CVS, or Git. </p> <p>Organization of filesystem folder structure is subjective, but I generally have a "src" folder for all my source FLA...
<p>A complex project will have many dependencies. In my Flash projects, I put all my libraries in a version controlled location as they are. Third party libraries are usually a mishmash of assets, code, demos and docs. </p> <p>I keep a small yaml file that keeps track of the location of each type of resource associate...
6,841
<p>I'm trying to print a large piece with polycarbonate but it keeps warping, I'm using a Taz 5 printer and setting 290 C in the extruder and 145 C in the heating bed. </p> <p>Other setting I have are:</p> <ol> <li>printing speed: 20 mm/s</li> <li>layer height: 2.5mm</li> <li>infil: 20%</li> <li>brim: 15mm</li> </ol>...
<p>Adjusting the design may also be able to help limit the amount of warping you get.</p> <p>One of the major causes of warping is upper layers contracting while cooling when laid down over now-cool(er) lower layers which no longer contract so much but are still thin enough to flex when subject to tension along their ...
<p>I would take a look <a href="http://reprap.org/wiki/Polycarbonate" rel="nofollow noreferrer">here</a> and <a href="https://www.matterhackers.com/articles/how-to-succeed-when-printing-with-polycarbonate-filament" rel="nofollow noreferrer">here</a>. Literally the first two results of Google.</p> <p>To summarize what ...
739
<p>I'd like to build a pretty simple plug-in for Visual Studio, but I don't really know how this has to be done. Is this doable in (non-managed) C++? </p> <p>I'd like to know what resources you'd recommend me.</p>
<p>I've never tried, so I don't know about doing it in C++, but this website has loads of information: <a href="http://msdn.microsoft.com/en-us/vsx/default.aspx" rel="nofollow noreferrer">http://msdn.microsoft.com/en-us/vsx/default.aspx</a></p>
<p>Found this MSDN tutorial: <a href="http://msdn.microsoft.com/en-us/library/aa699351%28VS.60%29.aspx" rel="nofollow noreferrer">Creating Add-ins Using Visual C++</a>. Thanks Matt.</p>
6,554
<p>Are there any noted differences in appearance rendering of HTML and XHTML in Google Chrome from Firefox? From IE? From other browsers? What browser does it render the code the most similar to?</p>
<p>Since it's based on WebKit, its rendering will most closely resemble Safari and Konqueror.</p>
<p>There are <a href="http://www.flickr.com/photos/kurafire/2822606444/" rel="nofollow noreferrer">anti-aliasing differences</a> between Safari 3.1 and Google Chrome, for whatever that's worth. This will doubtless be because Safari on Windows uses its own text-rendering and anti-aliasing layer instead of Windows's GDI....
9,528
<p>What can I do to increase the performance/speed of my PHP scripts without installing software on my servers?</p>
<p>Profile. Profile. Profile. I'm not sure if there is anything out there for PHP, but it should be simple to write a little tool to insert profiling information in your code. You will want to profile function times and SQL query times.</p> <p>So where you have a function:</p> <pre><code>function foo($stuff) { .....
<p>Whenever I look at performance problems, I think the best thing to do is time how long your pages take to run, and then look at the slowest ones. When you get these real metrics, you can often improve performance on the slowest ones by orders of magnitude, either by fixing a slow SQL query or perhaps tightening up ...
3,360
<p>I've been here for a little while. I am still a low-reputation of SE, with most of my involvement being here. I know that each SE has it's own personality, somewhat derived from the charter, somewhat from the written standards, and somewhat determined by the customary practices in the community.</p> <p>I have foun...
<p>I struggled with the same question since I saw the edit, good that you brought this to Meta! Thanks!</p> <p>As the community of regular and active members is limited, I think it is okay to welcome people in a comment or an answer. It would be a shame to scare people away after their first question, resulting in aban...
<p>I struggled with the same question since I saw the edit, good that you brought this to Meta! Thanks!</p> <p>As the community of regular and active members is limited, I think it is okay to welcome people in a comment or an answer. It would be a shame to scare people away after their first question, resulting in aban...
77
<p>If I have a trigger before the update on a table, how can I throw an error that prevents the update on that table?</p>
<p><a href="https://web.archive.org/web/20180330233216/http://www.brokenbuild.com/blog/2006/08/15/mysql-triggers-how-do-you-abort-an-insert-update-or-delete-with-a-trigger/" rel="noreferrer">Here is one hack</a> that may work. It isn't clean, but it looks like it might work:</p> <p>Essentially, you just try to update ...
<pre><code>DELIMITER @@ DROP TRIGGER IF EXISTS trigger_name @@ CREATE TRIGGER trigger_name BEFORE UPDATE ON table_name FOR EACH ROW BEGIN --the condition of error is: --if NEW update value of the attribute age = 1 and OLD value was 0 --key word OLD and NEW let you distinguish between the old and new value of a...
2,239
<p>I am a bit confused about socket programming in C.</p> <p>You create a socket, bind it to an interface and an IP address and get it to listen. I found a couple of web resources on that, and understood it fine. In particular, I found an article <s><a href="http://users.actcom.co.il/~choo/lupg/tutorials/internetworki...
<p>Short answer is that you have to do all the heavy lifting yourself. You can be notified that there is data available to be read, but you won't know how many bytes are available. In most IP protocols that use variable length packets, there will be a header with a known fixed length prepended to the packet. This he...
<p>Sockets operate at a higher level than raw packets - it's like a file you can read/write from. Also, when you try to read from a socket, the operating system will block (put on hold) your process until it has data to fulfill the request.</p>
7,132
<p>The <a href="https://help.prusa3d.com/article/6Gtws6Yqjg-pei-print-surface-preparation" rel="noreferrer">Prusa3d knowledge base</a> mentions that acetone will "rejuvenate" PEI in addition to cleaning oil and grease from the surface.</p> <blockquote> <p>About once a week, or when <strong>prints stop sticking</stro...
<p>Rejuvenate is probably a bit of an exaggerated term. The number one adhesion suppressor is grease. The stuff that comes off of the fingers used to handle the sheet. Even if you are careful and only handle the sides, the grease will be carried to the center of the plate next time its cleaned with less aggressive solv...
<p>Acetone is smelly nasty stuff. Here's a sample recommendation for PEI maintenance from one of a few (million?) 3d printing help sites. </p> <blockquote> <p>Use isopropyl alcohol, methyl alcohol, soap, Heptane, Hexane, or Naphtha. Avoid ketones (such as MEK) or strong bases (such as sodium hydroxide).</p> </b...
1,283
<p>Is this possible? Does the .NET framework depend on the meta data in the bytecode? I'd like to have an application i write not work in reflector or a similar .NET decompiler.</p>
<p>If you remove the metadata the framework won't be able to load your code, or figure out which other assemblies it references, or anything like that, so no, that's not a good idea.</p> <p>Obfuscators will make it a lot harder for an 'attacker' to decompile your code, but at the end of the day if someone is motivated...
<p>I don't think you can remove the meta data, but you can obfuscate your code if you're looking to protect your IP. </p>
5,159
<p>I've created an "attached behaviour" in my WPF application which lets me handle the Enter keypress and move to the next control. I call it EnterKeyTraversal.IsEnabled, and you can see the code on my blog <a href="http://www.madprops.org/blog/enter-to-tab-as-an-attached-property/" rel="noreferrer">here</a>.</p> <p>M...
<p>I do not agree DannySmurf</p> <p>Some WPF layout objects can clog up your memory and make your application really slow when they are not garbage collected. So I find the choice of words to be correct, you are leaking memory to objects you no longer use. You expect the items to be garbage collected, but they aren't,...
<p>Well that (the manager bit) I can certainly understand, and sympathize with.</p> <p>But whatever Microsoft calls it, I don't think a "new" definition is appropriate. It's complicated, because we don't live in a 100% managed world (even though Microsoft likes to pretend that we do, Microsoft itself does not live in ...
3,492
<p>I recently purchased a BIGTREETECH SKR mini E3 V1.2 and need to adjust some of the settings in configuration h to accommodate for my custom built 3d printer. In the past I've used the RAMPS 1.4 board and adjusted the firmware in the arduino IDE. What is the best way/recommended way to do this for the mini E3 V1.2.</...
<h1>Basics</h1> <p>Firmware can be distributed in 2 ways:</p> <ul> <li>As a compiled file (for example as .hex).</li> <li>As an uncompiled repository (as in a preconfigured marlin distribution) that needs to be compiled at the users' side.</li> </ul> <h1>compiled file</h1> <p>Compiled files <strong>can't</strong> be al...
<h1>Basics</h1> <p>Firmware can be distributed in 2 ways:</p> <ul> <li>As a compiled file (for example as .hex).</li> <li>As an uncompiled repository (as in a preconfigured marlin distribution) that needs to be compiled at the users' side.</li> </ul> <h1>compiled file</h1> <p>Compiled files <strong>can't</strong> be al...
1,645
<p>Actionscript 3.0 (and I assume Javascript and ECMAScript in general) lacks pass-by-reference for native types like ints. As a result I'm finding getting values back from a function really clunky. What's the normal pattern to work around this? </p> <p>For example, is there a clean way to implement <em>swap( intA, ...
<p>I Believe the best you can do is pass a container object as an argument to a function and change the values of some properties in that object:</p> <pre><code>function swapAB(aValuesContainer:Object):void { if (!(aValuesContainer.hasOwnProperty("a") &amp;&amp; aValuesContainer.hasOwnProperty("b"))) throw...
<p>If ActionScript works like Javascript,</p> <pre><code>[a,b] = [b,a] </code></pre>
7,152
<p>I have a collection of objects to which I'd like to just add a new property. How do I do that with LINQ?</p>
<pre><code>var a = from i in ObjectCollection select new {i.prop1, i.prop2, i.prop3, ..., newprop = newProperty} </code></pre>
<p>I don't think that you can using pure LINQ. However, if you're doing this sort of thing a lot in your code you may be able to make this work with reflection.</p>
6,825
<p>Can someone suggest some good automated test suite framework for Perl?</p>
<p>It really depends on what you're trying to do, but here's some background for much of this.</p> <p>First, you would generally write your test programs with Test::More or Test::Simple as the core testing program:</p> <pre><code>use Test::More tests =&gt; 2; is 3, 3, 'basic equality should work'; ok !0, '... and ze...
<p>I'd go for Test::More, or in general, anything that outputs <a href="http://en.wikipedia.org/wiki/Test_Anything_Protocol" rel="nofollow noreferrer">TAP</a></p>
7,227
<p>I'd like to use the camera in my Macbook in a program. I'm fairly language agnostic - C, Java, Python etc are all fine. Could anyone suggest the best place to look for documents or "Hello world" type code?</p>
<p>The ImageKit framework in Leopard has an <a href="http://developer.apple.com/documentation/GraphicsImaging/Reference/IKImagePicker_Class/IKImagePicker_Reference.html#//apple_ref/occ/cl/IKPictureTaker" rel="nofollow noreferrer"><code>IKPictureTaker</code></a> class that will let you run the standard picture-taking sh...
<p>Quartz Composer is also a pleasant way to capture and work with video, when it's applicable. There's a video input patch.</p> <p>Quartz Composer is a visual programming environment that integrates into a larger Cocoa program if need be.</p> <p><a href="http://developer.apple.com/graphicsimaging/quartz/quartzcompo...
8,165
<p>I have been using PHP and JavaScript for building my dad's website. He wants to incorporate a login system into his website, and I have the design for the system using PHP. My problem is how do I show buttons if the person is logged in?­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­...
<p>Regarding security, <strong>you cannot trust what comes from the client</strong>:</p> <ul> <li>The visitor can see all your code (HTML and Javascript, not PHP) and try stuff</li> <li>The visitor may not even use a browser; it's trivially easy to send a request with a script</li> </ul> <p>This means hiding the butt...
<p>Basically where you have your menu in html, say as a list <code>&lt;ul&gt; &lt;li&gt;Home&lt;/li&gt; &lt;/ul&gt;</code> you add php after <code>&lt;/li&gt;</code> of the last item:</p> <pre><code>&lt;?php if($session-logged_in) { ?&gt; &lt;li&gt;My Account&lt;/li&gt; &lt;?php } ?&gt; </code></pre>
2,868
<p>I've seen many references to a FDM print being weakest in the Z axis, due to poor bonding between layers compared to the extruded walls. </p> <p>Thinking about optimising this for a specific material (excluding temperature and geometry), is there an optimum layer height? It seems obvious that too thick a layer will...
<p>My3dmatter.com performed a <a href="http://my3dmatter.com/influence-infill-layer-height-pattern//influence-infill-layer-height-pattern/" rel="nofollow noreferrer">series of tests</a> with PLA, using "a universal testing machine". They conclude:</p> <blockquote> <p>Layer height influences the strength of a printed...
<p>Just adding another datapoint. CNCKitchen has a new <a href="https://youtu.be/fbSQvJJjw2Q" rel="nofollow noreferrer">video</a> where he analyses this for cross layer and between layer tension. He also references some other research (which is rather inconclusive). He supports the coarse estimate of 'no more than 50% ...
1,010
<p>Kicked off the second long print in a series (printing Lack enclosure components). First 10 hour print was flawless. Started this one, saw the first layer laid down well, went to bed. Woke up to this (you can see the successful prints in the background):</p> <p><a href="https://i.stack.imgur.com/HYYcU.jpg" rel="nor...
<h2>Yes</h2> <p>I had a somewhat similar clog once, and I could fix it back up. However, it is a lot of work.</p> <h2>Hobbyist Way</h2> <h3>Step 1: heat</h3> <p>As long as the heater cartridge is still ok, just fire up the printer, move up the print head by 50 mm and wait some two or three minutes till the goop is warm...
<p>If you can remove the hot-end it is easier. If not, carefully use hot air to soften (not melt) the PLA so you can more easily pull away chunks.</p> <p>When the hot-end is removed from the other plastic parts, you can get more aggressive with hot air. BUT, be careful of the thermistor and heater wires. They are f...
1,220
<p>When using Resharper to encapsulate a class's properties, is there a way to get it to do more than one property at a time?</p>
<p>You might or might not already know this (R# does suffer from a lack of discoverability, unless you get the one-page key-shortcut page printed out), but ALT-INS opens a box which can at least mass-generate properties for fields.</p> <p>Not sure if that's any use - it's not the same as a retrospective encapsulation....
<p>I don't think there such a feature out of the box.</p> <p>However, you could write a RS plugin that does this. But this would be another question...</p>
5,588
<p>I'm just wondering if there's a better way of doing this in SQL Server 2005.</p> <p>Effectively, I'm taking an originator_id (a number between 0 and 99) and a 'next_element' (it's really just a sequential counter between 1 and 999,999). We are trying to create a 6-character 'code' from them. </p> <p>The originator...
<p>Seeing as it's SQL Server 2005, any reason not to use a CLR stored procedure? You could use your CLR language of choice then and it'd probably be a relatively direct port of your existing Delphi code.</p>
<p>Although it can clearly be done in SQL Server 2005, I think that it's of sufficient 'non-database-ness' that some kind of precompiled, high-level language routine makese sense.</p> <p>I've written DLLs for Interbase/Firebird, and T-SQL sprocs for SQL Server, but never a CLR routine. It will be an interesting exerci...
7,907
<p>So far I have encountered adjacency list, nested sets and nested intervals as models for storing tree structures in a database. I know these well enough and have migrated trees from one to another.</p> <p>What are other popular models? What are their characteristics? What are good resources (books, web, etc) on thi...
<p>A variation is where you use a direct hierarchical representation (ie. parent link in node), but also store a path value.</p> <p>ie. for a directory tree consisting of the following:</p> <pre><code>C:\ Temp Windows System32 </code></pre> <p>You would have the following nodes</p> <pre><code>Key N...
<p>A variation is where you use a direct hierarchical representation (ie. parent link in node), but also store a path value.</p> <p>ie. for a directory tree consisting of the following:</p> <pre><code>C:\ Temp Windows System32 </code></pre> <p>You would have the following nodes</p> <pre><code>Key N...
4,752
<p>I haven't used <code>C++</code> since college. Even though I've wanted to I haven't needed to do any until I started wanting to write plugins for <code>Launchy</code>. </p> <blockquote> <p>Is there a good book to read to get back into it?</p> </blockquote> <p>My experience since college is mainly <code>C#</code...
<p>The best way to get back into C++ is to jump in. You can't learn a real language without spending any serious time in a country where they speak it. I wouldn't try to learn a programming language without spending time coding in it either.</p> <p>I wouldn't recommend learning C first though. That's a good way to ...
<p><a href="https://rads.stackoverflow.com/amzn/click/com/0201700735" rel="nofollow noreferrer" rel="nofollow noreferrer">The C++ Programming Language</a> by Bjarne Stroustrup covers C++ in depth. Bjarne is the inventor of C++. It also provides insights into why the language is the way it is. Some people find the book ...
5,810
<p>Ok, so I want an autocomplete dropdown with linkbuttons as selections. So, the user puts the cursor in the "text box" and is greated with a list of options. They can either start typing to narrow down the list, or select one of the options on the list. As soon as they click (or press enter) the dataset this is linke...
<p>This widget can be made with three items: a text input, button input, and an unordered list to hold the results.</p> <pre><code> __________ _ |__________||v|__ &lt;-- text and button | | &lt;-- ul (styled to appear relative to text input) | | | | ...
<p>In my opinion, you shouldn't use AJAX for this at all. </p> <p>here's why:</p> <p>(1) On focus: ALL the options that he can select are shown in the dropdown. This means that all possible options are already sent to the client.</p> <p>(2) If the user types something in, the number of entries in the drop down are f...
6,165
<p>How do I create a branch in subversion that is deeper' than just the 'branches' directory?</p> <p>I have the standard <code>trunk</code>, <code>tags</code> and <code>branches</code> structure and I want to create a branch that is several directories deeper than the 'branches' tag.</p> <p>Using the standard svn mov...
<pre><code>svn copy --parents http://url/to/subproject http://url/to/repository/branches/version_1/project/subproject </code></pre> <p>That should create the directory you want to put the subproject in (<code>--parents</code> means "create the intermediate directories for me").</p>
<p>If you're using <code>TortoiseSVN</code>, you can use its <strong>Repository Explorer</strong> to do such things. Makes it all pretty <code>WYSIWYG</code> simple.</p>
7,610
<p>When you have Auto Mesh Bed Leveling enabled on your printer, it's not possible to continue a failed print, is it?</p>
<p>Continuing a failed print has nothing to do with automatic bed leveling. It has everything to do with knowing which line failed, repositioning to resume from that point, and resuming from that line of code.</p>
<p>So like resuming any print, if you've already done the work to find the layer you failed at, edited the G-code to start from that layer. But now you feel stuck because to start a print you need to home your printer right? And homing with a BLTouch makes it probe the center of your bed... which happens to be where yo...
595
<p>How do you generate and analyze a thread dump from a running JBoss instance?</p>
<p>There is a JBoss-specific method that is slightly more user-friendly:</p> <p><a href="http://community.jboss.org/wiki/GenerateAThreadDumpWithTheJMXConsole" rel="nofollow noreferrer">http://community.jboss.org/wiki/GenerateAThreadDumpWithTheJMXConsole</a></p> <p>This is especially useful when you don't have direct ...
<p>Sometimes JBoss locks so much that even jmx-concole doesn't respond. In such case use kill -3 on Linux and <a href="http://www.latenighthacking.com/projects/2003/sendSignal/" rel="nofollow">SendSignal</a> on Windows.</p>
8,448
<p>Any recommendations for a javascript form validation library. I could try and roll my own (but I'm not very good at javascript). Needs to support checking for required fields, and preferably regexp validation of fields.</p>
<p>I am about to start implementing javascript validation in my forms using <a href="http://bassistance.de/jquery-plugins/jquery-plugin-validation/" rel="noreferrer">jQuery Validation</a>. I think that StackOverflow users this jQuery plugin as well. It seems to be a very mature validation library, however it does build...
<p>I've used <a href="http://tetlaw.id.au/view/javascript/really-easy-field-validation" rel="nofollow noreferrer">this library</a> for a couple of personal projects. It's pretty good, though I have had to make my own modifications to it a couple of times - nothing major, though, and it's easy enough to do so.</p> <p>I...
3,841
<p>Are there any lists of default CSS stylesheets for different browsers? (browser stylesheets in tabular form)</p> <p>I want to know the default font of text areas across all browsers for future reference.</p>
<p>Not tabular, but the source CSS may be helpful if you're looking for something specific:</p> <ul> <li><a href="http://hg.mozilla.org/mozilla-central/file/tip/layout/style/res/html.css" rel="nofollow noreferrer">Firefox default HTML stylesheet</a></li> <li><a href="http://trac.webkit.org/browser/trunk/Source/WebCore...
<p>There was some discussion and testing done on www-style not too long ago:</p> <p><a href="http://lists.w3.org/Archives/Public/www-style/2008Jul/0124.html" rel="nofollow noreferrer">http://lists.w3.org/Archives/Public/www-style/2008Jul/0124.html</a></p> <p><a href="http://lists.w3.org/Archives/Public/www-style/2008...
5,287
<p>I'm looking for a way to redirect all the stderr streams in interactive bash (ideally to its calling parent process).</p> <p>I don't want to redirect stderr stream from each individual command, which I could do by appending <code>2&gt; a_file</code> to each command.</p> <p>By default, these stderr streams are redi...
<p>Use the <code>exec</code> builtin in bash:</p> <p><code>exec 2&gt; /tmp/myfile</code></p>
<p>Tried <code>ssh -t</code> to create a pseudo-TTY at the remote end?</p>
4,992
<p>Modern database systems today come with loads of features. And you would agree with me that to learn one database you must unlearn the concepts you learned in another database. For example, each database would implement locking differently than others. So to carry the concepts of one database to another would be a r...
<p>I think these are the most important things (from most important to least, IMO):</p> <ul> <li><strong>SQL (obviously)</strong> - It helps to know how to at least do basic queries, aggregates (sum(), etc), and inner joins</li> <li><strong>Normalization</strong> - DB design skills are an major requirement</li> <li><s...
<p>Basic things about Sql queries are must. then you can develop simple system. but when you are going to implement Complex systems you should know Normalization, Procedures, Functions, etc.</p>
4,381
<p>Recently, the ticking sounds started to come from feeder of my UM2. Inspecting it I have noticed that once in a while stepper motor jumps back for few steps. I have an idea of what can be the reason, but I just want to hear what you can think of. That is the video of feeder during the printing :) <a href="https://yo...
<p>Ultimately, your stepper motor is unsuccessful in driving the filament through the extruder. A couple potential reasons:</p> <ul> <li>extruder temperature isn't high enough. This could either be operator error from not setting the temperature correctly or your machine is getting a false reading. Typically, for ABS/...
<p>Oh yeah that is way too low for the ultimaker.</p> <p>That temp is a general "this is what PLA melts at" so if you took plastic, heated it up to that temp it would melt.</p> <p>However, you don't heat all the plastic at once. Your hotend it at that temp and if you let it sit it would heat up (fairly quickly). Prin...
240
<p>Today I was working on a tab navigation for a webpage. I tried the <a href="http://www.alistapart.com/articles/slidingdoors2/" rel="noreferrer">Sliding Doors</a> approach which worked fine. Then I realized that I must include an option to delete a tab (usually a small X in the right corner of each tab). </p> <p>I w...
<p>They must be doing some really crazy stuff with JavaScript to get it to work (notice how neither the parent nor the nested anchor tags have a name or href attribute - all functionality is done through the class name and JS).</p> <p>Here is what the html looks like:</p> <pre><code>&lt;a class="page_tab page_tab"&gt...
<p>Actually, the code I had pasted previously was the generated DOM, after all JS manipulation. If you don't have the <a href="https://addons.mozilla.org/en-US/firefox/addon/1843" rel="nofollow noreferrer">Firebug</a> extension for Firefox, you should get it now.</p> <p>Edit: Deleted the old post, it was no longer us...
4,130