instruction stringlengths 27 22.5k | chosen stringlengths 27 28.2k | rejected stringlengths 19 24.9k | __index_level_0__ int64 0 10k |
|---|---|---|---|
<p>I was <a href="https://3dprinting.stackexchange.com/questions/1536/what-does-uses-mains-voltage-mean-on-this-200200mm-square-silicone-heater-pad">advised</a> that it would be possible to use an AC SSR to wire up a Mains Based heat bed. Any idea how one would do this with a RAMPs 1.4 board; Also, what do I hook a he... | <p>If you take a kettle lead with a wall plug and cut off the other end, it will expose 3 wires: earth, live and neutral. These are <a href="https://en.wikipedia.org/wiki/Electrical_wiring" rel="nofollow">color coded</a> depending on your country, usually earth is green (possibly with yellow stripes), neutral is blue, ... | <p>A link to the bed you have/are buying would be very helpful. AC heated beds exist but are fairly uncommon.</p>
<p>As <a href="https://3dprinting.stackexchange.com/a/1548/1404">one of the answers</a> in the question you linked notes, the heat bed is probably not actually intended to use the 110 VAC/220 VAC directly ... | 354 |
<p>My C code snippet takes the address of an argument and stores it in a volatile memory location (preprocessed code):</p>
<pre><code>void foo(unsigned int x) {
*(volatile unsigned int*)(0x4000000 + 0xd4) = (unsigned int)(&x);
}
int main() {
foo(1);
while(1);
}
</code></pre>
<p>I used an SVN version ... | <p>Once you return from <code>foo()</code>, <code>x</code> is gone, and any pointers to it are invalid. Subsequently using such a pointer results in what the C standard likes to call "undefined behavior," which means the compiler is absolutely allowed to assume you won't dereference it, or (if you insist on doing it a... | <blockquote>
<p>Is this just expected/undefined
behaviour? Have I done something wrong
or have I in fact found a Compiler
Bug™?</p>
</blockquote>
<p>No bug just the defined behaviour that optimisation options can produce odd code which might not work :)</p>
<p>EDIT:</p>
<p>If you think you have found a bug i... | 4,816 |
<p>I've build a WCF Service to accept a file and write it to disk. The front-end consists of a page with SWFUpload which is handling the upload on the client side. Apparently, SWFUpload posts the data with a Content Type of: multipart/form-data.</p>
<p>I would think this ok but on the Service side I get an error. The ... | <p>@jdiaz,</p>
<p>@JasonS is right, to upload file you need to transfer it as a byte stream. You need to use <a href="http://msdn2.microsoft.com/en-us/library/ms733742.aspx" rel="noreferrer">WCF streaming</a>. For example on how to upload file via WCF see <a href="http://kjellsj.blogspot.com/2007/02/wcf-streaming-uplo... | <p>I believe you are going to have to tranfer the file as a byte array to WCF. You will need to handle the post from SWFUpload and convert to a byte array before sending to your service.</p>
| 7,425 |
<p>I would like to write a small program in C# which goes through my jpeg photos and, for example, sorts them into dated folders (using MY dating conventions, dammit...). </p>
<p>Does anyone know a relatively easy way to get at the EXIF data such as Date And Time or Exposure programatically?
Thanks!</p>
| <p>Check out this <a href="https://www.drewnoakes.com/code/exif/" rel="noreferrer">metadata extractor</a>. <strike>It is written in Java but has also been ported to C#.</strike> I have used the Java version to write a small utility to rename my jpeg files based on the date and model tags. Very easy to use.</p>
<hr>
<... | <p>Recently, I used this <a href="https://products.groupdocs.com/metadata/net" rel="nofollow noreferrer">.NET Metadata API</a>. I have also written a <a href="https://blog.groupdocs.com/2020/05/13/manage-exif-data-in-csharp-net-for-jpeg-png-tiff-webp-images/" rel="nofollow noreferrer">blog post</a> about it, that shows... | 8,307 |
<p>I understand that there are several ways to blend XNA and WPF within the same application. I find it enticing to use WPF for all GUI and HUD stuff in my XNA games. Does anyone have any practical experience on how well this approach works in real life using .NET 3.5 SP1 ? Any pitfalls (such as the <a href="http://blo... | <p>There is an addition in 3.5 SP1 that allows better interaction between DirectX and WPF (D3DImage), and one way to get to that is through XNA.</p>
<p>Here are some details:</p>
<p><a href="http://jmorrill.hjtcentral.com/Default.aspx?tabid=428&EntryID=259" rel="nofollow noreferrer">http://jmorrill.hjtcentral.com... | <p>I personally would advise against trying to do this integration. I know what you're going for ... the ease of defining GUI/HUD elements in WPF greatly outweighs trying to do the same in just plain old XNA. However, think realistically of the time you'll spend trying to enable this scenario vs. how much you'd save ... | 6,521 |
<p>My team is developing a new service oriented product with a web front-end. In discussions about what technologies we will use we have settled on running a JBoss application server, and Flex frontend (with possible desktop deployment using Adobe AIR), and web services to interface the client and server.</p>
<p>We'v... | <p>There won't be much difference between EJB3 and Spring based on Performance. We chose Spring for the following reasons (not mentioned in the question):</p>
<ul>
<li>Spring drives the architecture in a direction that more readily supports unit testing. For example, inject a mock DAO object to unit test your business... | <p>I think EJB is a good component technology but not a good framework.Spring is the best framework available as of today.So i should consider Spring as the best implementation of JEE in the sense of a framework and my recommendation is to use spring in every project which gives us the flexibility to integrate with an... | 9,400 |
<p>I am doing a quad-copter now.</p>
<p>I am not sure what color is the best to use for outdoor durability, especially in sunlight.</p>
<p>They say PETg is the most durable material amongst cheap ones.</p>
<p>But what color to choose: white or transparent? Or it does not matter?</p>
| <p>Unless you plan to use your copter outside Earth atmosphere or expected lifetime is more than tenths of years, UV degradation should not be a problem for PETG. Some of the net sources indicate the <strong>possibility</strong> of degradation after significant time of <strong>constant</strong> exposure to outdoor cond... | <p>PETG might not be the best for long term UV exposure.</p>
<p>According to Midland Plastics, PETG doesn't hold up well in outdoor applications, and is susceptible to UV degradation. Unless you have an outdoor or UV rated PETG product which will have additional chemicals added to it, it may breakdown more quickly tha... | 536 |
<p>Using <a href="http://www.oracle.com/technology/products/jdev" rel="noreferrer">JDeveloper</a>, I started developing a set of web pages for a project at work. Since I didn't know much about JDev at the time, I ran over to Oracle to follow some tutorials. The JDev tutorials recommended doing <a href="http://www.filei... | <p>The main difference is that a JSPX file (officially called a 'JSP document') may be easier to work with because the requirement for well-formed XML may allow your editor to identify more typos and syntax errors as you type.</p>
<p>However, there are also disadvantages. For example, well-formed XML must escape thing... | <p>Also, another problem I have found with JSPX is when you want to use scriptlets. I agree that clean code is generally good and Java logic in the JSP is generally bad but there are certain instances where you want to use a utility function to return a string value or something where a TagLib or the model (request at... | 4,789 |
<p>Below I have a very simple example of what I'm trying to do. I want to be able to use HTMLDecorator with any other class. Ignore the fact it's called decorator, it's just a name.</p>
<pre><code>import cgi
class ClassX(object):
pass # ... with own __repr__
class ClassY(object):
pass # ... with own __repr__
... | <blockquote>
<p>Very close, but then I lose everything from ClassX. Below is something a collegue gave me that does do the trick, but it's hideous. There has to be a better way.</p>
</blockquote>
<p>Looks like you're trying to set up some sort of proxy object scheme. That's doable, and there are better solutions tha... | <blockquote>
<p>Is what I'm trying to do possible? If so, what am I doing wrong?</p>
</blockquote>
<p>It's certainly possible. What's wrong is that <code>HTMLDecorator.__init__()</code> doesn't accept parameters.</p>
<p>Here's a simple example:</p>
<pre><code>def decorator (func):
def new_func ():
retu... | 5,817 |
<p>While I grew up using MSWindows, I transitioned to my much-loved Mac years ago. I don't want to start a flame war here on operating systems. I do, however, want a terminal a litle closer to what I'm used to.</p>
<p>I'm not asking for full POSIX support - I don't have the patience to install Cygwin - but I miss ta... | <p>Some more options:</p>
<p><a href="http://www.mingw.org" rel="nofollow noreferrer">MSYS</a>: a Minimal SYStem providing a POSIX compatible Bourne shell environment, with a small collection of UNIX command line tools. Primarily developed as a means to execute the configure scripts and Makefiles used to build Open So... | <p><a href="http://www.microsoft.com/windowsserver2003/technologies/management/powershell/default.mspx" rel="nofollow noreferrer">PowerShell</a> is worth looking into. </p>
| 3,136 |
<p>How many ServiceContracts can a WCF service have?</p>
<p>Specifically, since a ServiceContract is an attribute to an interface, how many interfaces can I code into one WCF web service? Is it a one-to-one?</p>
<p>Does it make sense to separate the contracts across multiple web services?</p>
| <p>WCF services can have multiple endpoints, each of which can implement a different service contract.</p>
<p>For example, you could have a service declared as follows:</p>
<pre><code>[ServiceBehavior(Namespace = "DemoService")]
public class DemoService : IDemoService, IDoNothingService
</code></pre>
<p>Which would ... | <p>A service can theoretically have any number of Endpoints, and each Endpoint is bound to a particular contract, or interface, so it is possible for a single conceptual (and configured) service to host multiple interfaces via multiple endpoints or alternatively for several endpoints to host the same interface.</p>
<p... | 5,166 |
<p>I just noticed that there is a large amount of tag wiki excerpts edits in the review queue, all of which are of the form:</p>
<blockquote>
<p>X is for questions about X</p>
</blockquote>
<p>A tag wiki excerpt should define what a term means <em>to our community</em> specifically and give <em>usage advice</em>. I... | <p>Tag excerpts should at least try and give a concise definition as to the subject, and provided any usage guidance <em>if necessary.</em></p>
<p>Therefore, you need to make sure to address a set of key points:</p>
<ul>
<li>Is the tag name ambiguous? Will an amateur be able to understand the subject without having t... | <p>For reference, I would like to propose a copy-paste solution for tags.</p>
<p><strong>Usage Guidance</strong></p>
<p><code>For questions regarding {insert list of applicable topics} of {Tag Name}.</code></p>
<p><strong>Details</strong></p>
<pre><code>{Tag name, unabbreviated}: {Definition}
Examples:
- What is ... | 22 |
<p>I'm attempting to make a DTS package to transfer data between two databases on the same server and I'm getting the following errors. Iv read that the Multiple-step OLE DB operation generated error can occur when you are transferring between different database types and there is loss of precision, but this is not tha... | <p>Take a look at the fields's proprieties (type, length, default value, etc.), they should be the same.</p>
<p>I had this problem with SQL Server 2008 R2 because the fields's length are not equal.</p>
| <p>This error will also occur when trying to do an insert and a field is coded not null and nulls are trying to be inserted.</p>
| 7,474 |
<p>How do you reference a bitmap on the stage in flash using actionscript 3?</p>
<p>I have a bitmap on the stage in flash and at the end of the movie I would like to swap it out for the next in the sequence before the movie loops. in my library i have 3 images, exported for actionscript, with the class name img1/img2/... | <p>To reference something on the stage, you need to give the stage instance a name - not give the symbol in the library a class name.</p>
<p>Click on the item on the stage and look at the properties panel. There should be a text entry box just above the entry boxes for the item's dimensions. Enter a name there.</p>
<... | <p>I would probably do something like this in your document class</p>
<pre><code>for(var i:int=0; i<numChildren; i++){
trace(getChildAt(i),"This is the child at position "+i);
}
</code></pre>
<p>I do this because I still code in the flash IDE and its debugger is so very painful to get working most of the time ... | 6,497 |
<p>How can I go about generating a Friendly URL in C#? Currently I simple replace spaces with an underscore, but how would I go about generating URL's like Stack Overflow?</p>
<p>For example how can I convert:</p>
<blockquote>
<p>How do I generate a Friendly URL in C#?</p>
</blockquote>
<p>Into</p>
<blockquote>
... | <p>There are several things that could be improved in Jeff's solution, though.</p>
<pre><code>if (String.IsNullOrEmpty(title)) return "";
</code></pre>
<p>IMHO, not the place to test this. If the function gets passed an empty string, something went seriously wrong anyway. Throw an error or don't react at all.</p>
<p... | <p>here is a simple function which can convert your string to Url, you just need to pass title or string it will convert it to user friendly Url.</p>
<pre><code> public static string GenerateUrl(string Url)
{
string UrlPeplaceSpecialWords = Regex.Replace(Url, @"&quot;|['"",&?%\.!()@$^_+=*:#/\\-]... | 5,863 |
<p>I've been playing around with PETG for the first time, and everything seemingly worked right just from the start - clean prints, no stringing, no bed adhesion problems, no warping or dimensional accuracy problems, etc. As expected it prints a lot like PLA, and as expected, it's less brittle/stands up much better to ... | <p>What you describe is usually the result of using a too high of a part cooling fan rotational speed. Like ABS, PETG doesn't require much cooling (if needed at all that is). If you do cool too much, layers and perimeters do not bond optimally (you can get string cheese like printed parts on failure). </p>
<p><strong>... | <p>PETG doesn't bond well if the layers aren't both at a fairly high temperature, as noted by the other answers. As mentioned, try reducing or simply turning off layer cooling. Additionally, try printing at a smaller layer height, or increased line width, to force the layers to bond more effectively. A final solution w... | 1,325 |
<p>I'm obviously not talking about a full solution, but just a good starting point for common applications for software architects. It could be for a CMS, e-commerce storefront, address book, etc. A UML diagram is not essential, but a table schema with data types in the least. Thanks!</p>
| <p>Check out the <a href="http://databaseanswers.org/data_models/" rel="noreferrer">Library of Free Data Models</a> from DatabaseAnswers.org -- might be a good starting point. I can't vouch for the quality, but there is a lot here...</p>
| <p>Open source?</p>
<p><a href="https://sourceforge.net/projects/dbuml#item3rd-1" rel="nofollow noreferrer">DB-UML might work for you</a>.</p>
<p>EDIT:</p>
<p>Oh! The <a href="http://dev.mysql.com/workbench/" rel="nofollow noreferrer">MySQL Workbench</a> is good. </p>
| 8,257 |
<p>In a design that I need to prototype, I have a coaxial, rotational joint between 2 cylinders connected to another coaxial rotational joint between 2 cylinders by a hinge. I have attached the individual part files as well as their assembly where you can use your mouse cursor to check how they move.
<a href="https://... | <h3>Consider ball bearings</h3>
<p>Depending on the requirements for your joint, I would consider making a design that utilizes <em>ball bearings</em>. With ball bearings, your join will not wear down as quickly, and also move smoothly.</p>
<h3>Handling dimensional inaccuracy</h3>
<p>The topic of how to achieve dimensi... | <p>Have you considered to use a service to have the part printed? You can print almost anything in one "pass" using selective laser sintering, typically done in nylon. I am currently un-boxing an SLS printer, so I cannot currently offer to print it, but the capabilities of SLS are substantial for parts of this nature. ... | 211 |
<p>For .net 3.5 SP1, Microsoft have the new client profile which installs only a subset of .net 3.5 SP1 on to Windows XP user's machines.</p>
<p>I'm aware of how to make my assemblies client-profile ready. And I've read the articles on how to implement an installer for <a href="http://msdn.microsoft.com/en-us/library/... | <p>Microsoft has now shipped the Client Profile Configuration Designer (Beta).</p>
<p>This designer lets you edit the XML files with some limitations, this isn't a 'Google beta' by any means.</p>
<p><a href="http://windowsclient.net/wpf/wpf35/wpf-35sp1-client-profile-config-overview.aspx" rel="nofollow noreferrer">In... | <p>Can you clarify: Are you trying to write an installer for your app, which depends on the Client-Profile, or are you trying to write a custom installer <em>for</em> the client-profile?</p>
<p>I haven't used it personally, but if it's anything like the dotnetfx 1 and 2 msi's, you basically have to just invoke it's ex... | 3,482 |
<p>Using C#, I need a class called <code>User</code> that has a username, password, active flag, first name, last name, full name, etc. </p>
<p>There should be methods to <em>authenticate</em> and <em>save</em> a user. Do I just write a test for the methods? And do I even need to worry about testing the properties s... | <p>Many great responses to this are also on my question: "<a href="https://stackoverflow.com/questions/24965/beginning-tdd-challenges-solutions-recommendations">Beginning TDD - Challenges? Solutions? Recommendations?</a>"</p>
<p>May I also recommend taking a look at my <a href="http://cantgrokwontgrok.blogspot.com/200... | <p>I can't speak for C# specificly, but when I write unit tests I test EVERY input, even those the user does not do, that way I know how to prevent my own mistakes.</p>
| 8,812 |
<p>PL/SQL is not my native tongue. Oracle supports writing stored procedures in Java. What are the advantages of doing this over writing the stored procedures in PL/SQL</p>
| <p>In the Oracle world the general order of development should be:</p>
<p>Wherever possible do it purely with SQL.
If you need more than SQL do it with PL/SQL.
If you need something that PL/SQL can't do, then use Java.
If all else fails use C.
If you can't do it with C, back slowly away from the problem....</p>
<p>PL... | <p>The answer is <em>NEVER</em>. If you need to write programs to load or process data you need to do it outside of your data tier from another computer on the network.</p>
<p>Running external applications directly on your data tier or god forbid in-process with your data tier or the misapplication of external langua... | 9,546 |
<p>I need to be able to create basic MS Project items (tasks, projects, resources, etc.) programmatically from my app to my Project Server 2003 install, and haven't found any good examples. Can anyone point me to some good references or have some sample code of connecting to the server and creating these items?</p>
| <p>Developing against Project Server 2003 isn't the friendliest experience around, but I have worked a little bit with the PDS (Project Data Services) which is SOAP based</p>
<p><A HRef="http://msdn.microsoft.com/en-us/library/aa204408(office.11).aspx" rel="nofollow noreferrer"><a href="http://msdn.microsoft.com/en-us... | <p>As far as I know, the only programatic access to PS 2003 is through PWS. </p>
<p>I don't know if it would work, but you could try writing a managed extension for Microsoft Project 2003 (The client application) .There <A href="http://msdn.microsoft.com/en-us/library/aa209377(office.11).aspx" rel="nofollow noreferrer... | 3,925 |
<p>How do I turn the following 2 queries into 1 query</p>
<pre><code>$sql = "SELECT level FROM skills WHERE id = $id LIMIT 1;";
$result = $db->sql_query($sql);
$level = (int) $db->sql_fetchfield('level');
$db->sql_freeresult($result);
++$level;
$sql = "UPDATE skills SET level = $level WHERE id = $id;... | <p>I get downmodded for this?</p>
<pre><code>$sql = "UPDATE skills SET level = level+1 WHERE id = $id";
$result = $db->sql_query($sql);
$db->sql_freeresult($result);
</code></pre>
<p>In Teifion's specific case, the phpBB DDL lists that particular field as NOT NULL, so there's no danger of incrementing NULL.</p>... | <p>Mat: That's what pasted in from the question. It hasn't been edited, so I attribute that to a bug in Markdown. But, oddly enough, I have noticed.</p>
<p>Also: yes, <code>mysql_escape_string()</code>!</p>
| 2,768 |
<p>I get an <code>error: printer halted. (kill() called!</code> Any time I home my machine's X or Y axis. I have just installed a 3D touch auto bed level sensor, ironically it works fine. I was using Sprinter firmware but it doesn't support auto bed level, so thus I'm using Marlin. I am using the latest version of Marl... | <p><a href="https://i.stack.imgur.com/gMDDx.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/gMDDx.png" alt="enter image description here"></a></p>
<p>That's a filament cleaner/oiler combo. The black bottle is a variety of machine oil. </p>
<p>The effect of oilers on prints is heavily disputed in th... | <p>For really long Bowden tubes, some people use Teflon lubricant in a cleaner bead.</p>
<p>Never used it myself, since I use a small tube my printer with the stepper on top of one of the Z axis steel rod mounting plates (Anet A8).</p>
<p>Off topic, but by cooking and being a vaper, I vouch that organic compounds lea... | 1,171 |
<p>I have a project where a .master page was created without a code behind page. Now I want to add a code behind page for this .master page and move the "in page" code to the code behind file. What is the best/easiest way to go about doing this? I'm using Visual Studio 2008.</p>
| <p>Create new class file, name it yourmaster.master.cs (Visual Studio will automaticly group it with the .master) and move the code to it, reference it in your masterpage.</p>
<p>Then rightclick on your project and click "Convert to Web Application" and Visual Studio will create the designer file.</p>
| <p>One way to do it, is to create a new empty masterpage/aspx-file and then copy-paste the code you allready have into that page. That will take care of all the wire-up and creating of code-files.</p>
| 6,914 |
<p>I'm looking for a good server/client protocol supported in Python for making data requests/file transfers between one server and many clients. Security is also an issue - so secure login would be a plus. I've been looking into XML-RPC, but it looks to be a pretty old (and possibly unused these days?) protocol.</p>... | <p><a href="http://pyro.sf.net" rel="noreferrer">Pyro</a> (Python Remote Objects) is fairly clever if all your server/clients are going to be in Python. I use <a href="http://www.xmpp.org" rel="noreferrer">XMPP</a> alot though since I'm communicating with hosts that are not always Python. XMPP lends itself to being ext... | <p>In the RPC field, Json-RPC will bring a big performance improvement over xml-rpc:
<a href="http://json-rpc.org/wiki/python-json-rpc" rel="nofollow noreferrer">http://json-rpc.org/wiki/python-json-rpc</a></p>
| 8,996 |
<p>Is it possible in C# to have a Struct with a member variable which is a Class type? If so, where does the information get stored, on the Stack, the Heap, or both?</p>
| <p>Yes, you can. The pointer to the class member variable is stored <strike>on the stack</strike> with the rest of the struct's values, and the class instance's data is stored on the heap.</p>
<p>Structs can also contain class definitions as members (inner classes).</p>
<p>Here's some really useless code that at lea... | <p>It's probably not a recommended practice to do so: see <a href="http://msdn.microsoft.com/en-us/library/ms229017(VS.85).aspx" rel="nofollow noreferrer">http://msdn.microsoft.com/en-us/library/ms229017(VS.85).aspx</a></p>
<blockquote>
<p>Reference types are allocated on the heap, and memory management is
handled... | 9,419 |
<p>I am trying to populate a string with a double value using a <code>sprintf</code> like this:</p>
<pre><code>sprintf(S, "%f", val);
</code></pre>
<p>But the precision is being cut off to six decimal places. I need about 10 decimal places for the precision.</p>
<p>How can that be achieved?</p>
| <p>%[width].[precision]</p>
<p>Width should include the decimal point.</p>
<p>%8.2 means 8 characters wide; 5 digits before the point and 2 after. One character is reserved for the point.</p>
<p>5 + 1 + 2 = 8</p>
| <p>For a more complete reference, see the <a href="http://en.wikipedia.org/wiki/Printf#printf_format_placeholders" rel="nofollow noreferrer">Wikipedia <em>printf</em> article, section "printf format placeholders"</a> and <a href="http://en.wikipedia.org/wiki/Printf#1970s:_C.2C_Lisp" rel="nofollow noreferrer">a good exa... | 9,513 |
<p>There are two weird operators in C#:</p>
<ul>
<li>the <a href="http://msdn.microsoft.com/en-us/library/6x6y6z4d.aspx" rel="noreferrer">true operator</a></li>
<li>the <a href="http://msdn.microsoft.com/en-us/library/6292hy1k.aspx" rel="noreferrer">false operator</a></li>
</ul>
<p>If I understand this right these op... | <p>You can use it to override the <code>&&</code> and <code>||</code> operators.</p>
<p>The <code>&&</code> and <code>||</code> operators can't be overridden, but if you override <code>|</code>, <code>&</code>, <code>true</code> and <code>false</code> in exactly the right way the compiler will call... | <p>It appears from the MSDN article you linked to it was provided to allow for nullable boolean types prior to the Nullable (i.e. int?, bool?, etc.) type being introducted into the language in C#2. Thus you would store an internal value indicating whether the value is true or false or null, i.e. in your example >0 for ... | 5,331 |
<p>If I <em>accidentally</em> reverse the polarity of my power supply to the RAMPS board, what <em>exactly</em> will be damaged?</p>
<p>Will it harm my:</p>
<ul>
<li>RAMPS;</li>
<li>Arduino Mega;</li>
<li>Stepper motor and/or drivers, or; </li>
<li>Any other electronic part(s)?</li>
</ul>
<p>Will all or some of them... | <h3>Polyfuses on the RAMPS</h3>
<p>Fire appears to be the immediate issue, in the poly fuses.</p>
<p>From <a href="https://www.reddit.com/r/Reprap/comments/2gpih3/reversed_polarity_ramps_on_fire/" rel="nofollow noreferrer">Reddit: reversed polarity, RAMPS on fire</a></p>
<blockquote>
<p>Sooo I made the dumb mistake of ... | <h3>Polyfuses on the RAMPS</h3>
<p>Fire appears to be the immediate issue, in the poly fuses.</p>
<p>From <a href="https://www.reddit.com/r/Reprap/comments/2gpih3/reversed_polarity_ramps_on_fire/" rel="nofollow noreferrer">Reddit: reversed polarity, RAMPS on fire</a></p>
<blockquote>
<p>Sooo I made the dumb mistake of ... | 492 |
<p>All the blower fans for part cooling I've seen rotate counter-clockwise when viewed from the intake side. I'm looking to replace mine on an Ender 3 with something stronger, and one of the worst parts of the stock design is that it's offset by about 20 mm versus the nozzle position, requiring awkward duct paths that ... | <p>I see that you have a minimum support angle of 60 degrees -- that may mean Cura Slicer isn't generating supports for that chin. Try changing this minimum to a lower figure -- 51 degrees or lower. From what I've read, most filaments and settings will allow 60 degrees with PLA, but this is the easy first thing to tr... | <p>You need to zoom in on the layers where the support is being generated and check if there is actually support being generated under that area.</p>
<p>Additionally, I noticed your support generation setting is "Touching build plate only". You should change this setting to 'everywhere' because it could be t... | 1,958 |
<p>I would like to add the following MIME type to a site run by <code>Apache</code>:</p>
<pre><code><mime-mapping>
<extension>jnlp</extension>
<mime-type>application/x-java-jnlp-file</mime-type>
</mime-mapping>
</code></pre>
<p><strong>That is the Tomcat format.</strong></p>
<... | <pre><code>AddType application/x-java-jnlp-file .jnlp
</code></pre>
<p>Note that you might not actually be allowed to do that.</p>
<p>See also the <a href="http://HTTPd.Apache.Org/docs/trunk/mod/mod_mime.html#addtype" rel="noreferrer" title="mod_mime - AddType">documentation of the AddType directive</a> and the <a hr... | <p>You should be able to just add this line:</p>
<pre><code>AddType application/x-java-jnlp-file .jnlp
</code></pre>
| 5,384 |
<p>How do I declare "as any" in VB.NET, or what is the equivalent?</p>
| <p>The closest you can get is:</p>
<p><code>Dim var as Object</code></p>
<p>It's not exactly the same as VB6's as Any (which stores values in a Variant) but you can store variables of any type as Object, albeit boxed.</p>
| <p><a href="http://en.wikipedia.org/wiki/Visual_Basic_.NET" rel="nofollow noreferrer">VB.NET</a> doesn't support the "As Any" keyword. You'll need to explicitly specify the type.</p>
| 9,559 |
<p>I know that <code>.NET</code> is <code>JIT</code> compiled to the architecture you are running on just before the app runs, but does the JIT compiler optimize for 64bit architecture at all? </p>
<p>Is there anything that needs to be done or considered when programming an app that will run on a <code>64bit system</... | <p>The <a href="http://blogs.msdn.com/davbr/pages/tail-call-jit-conditions.aspx" rel="nofollow noreferrer">64bit JIT is different</a> from the one for 32bit, so I would expect some differences in the output - but I wouldn't switch to 64bit just for that, and I wouldn't expect to gain much speed (if any) in CPU time by ... | <p>Performance bottlenecks will be the same regardless of whether the architecture is 32- or 64-bit. Performance problems tend to be the result of sub-optimal algorithms — the choice between 32- and 64-bit types won't significantly affect performance.</p>
<p>Most importantly, don't try to improve the performance... | 3,525 |
<p>I've found some examples using the Win32 api or simulating the ^+ button combination (<kbd>ctrl</kbd>-<kbd>+</kbd>) <a href="http://www.codeproject.com/KB/list/AutoResize.aspx" rel="nofollow noreferrer">using SendKeys</a>, but at least with the SendKeys method the listview grabs the cursor and sets it to an hourglas... | <p>Looks like a call to <code>myListView.AutoResizeColumns(ColumnHeaderAutoResizeStyle.ColumnContent)</code> will do what you want. I would think, just call it after adding an item.</p>
<p>More info <a href="https://msdn.microsoft.com/en-us/library/system.windows.forms.listview.autoresizecolumns(v=vs.110).aspx" rel="n... | <p>loop through all columns and set width to -1 after adding content.</p>
| 8,190 |
<p>How is it possible to make prototype methods in C#.Net?</p>
<p>In JavaScript, I can do the following to create a trim method for the string object:</p>
<pre><code>String.prototype.trim = function() {
return this.replace(/^\s+|\s+$/g,"");
}
</code></pre>
<p>How can I go about doing this in C#.Net?</p>
| <p>You can't dynamically add methods to existing objects or classes in .NET, except by changing the source for that class.</p>
<p>You can, however, in C# 3.0, use extension methods, which <em>look</em> like new methods, but are compile-time magic.</p>
<p>To do this for your code:</p>
<pre><code>public static class S... | <p>You need to create an extension method, which requires .NET 3.5. The method needs to be static, in a static class. The first parameter of the method needs to be prefixed with "this" in the signature.</p>
<pre><code>public static string MyMethod(this string input)
{
// do things
}
</code></pre>
<p>You can then ... | 2,658 |
<p>Why are SQL distributions so non-standard despite an ANSI standard existing for SQL? Are there really that many meaningful differences in the way SQL databases work or is it just the two databases with which I have been working: MS-SQL and PostgreSQL? Why do these differences arise?</p>
| <p>It's a form of "Stealth lock-in". Joel goes into great detail here:</p>
<ul>
<li><a href="http://www.joelonsoftware.com/articles/fog0000000056.html" rel="nofollow noreferrer">http://www.joelonsoftware.com/articles/fog0000000056.html</a></li>
<li><a href="http://www.joelonsoftware.com/articles/fog0000000052.html" re... | <p>It's certainly effective lock-in, as 1800 says. But in fairness to the database vendors, the SQL standard is always playing catch-up to current databases' feature sets. Most databases we have today are of pretty ancient lineages. If you trace Microsoft SQL Server back to its roots, I think you'll find Ingres - one o... | 5,811 |
<p>As far as I know resin trays have a Teflon coat that allows prints to stick to the build plate easier than the resin tray but this Teflon coat wears over time. </p>
<p>I am new to the SLA scene and am currently troubleshooting a Draken Facture and trying to hone in my setting but my print keep sticking to the bott... | <p>It depends on tray and resin type you are using.</p>
<p><strong>PDMS</strong></p>
<p>If you are using PDMS (eg. sylgard 184) coating for your tray. (B9 and similar printers using this type of tray). </p>
<p>Life of tray PDMS coating depends mainly on:</p>
<ul>
<li>How long you print without breathing floor.</li>... | <p>I did some research and the life of the resin and resin tray appears to be dependent on how you use it. For example, regarding the resin, 3dfacture states <a href="http://3dfacture.com/faq/" rel="nofollow noreferrer">"We see almost unlimited shelf life of the resin as long as it is kept out of light"</a>.</p>
<p>I... | 640 |
<p>I have to setup team foundation server for a company, something that I don't have any experience in.</p>
<p>The company will have about 5 or so developers that will be using it.</p>
<p>Is this a big task or something that is fairly easy to do (with instructions)?<br>
Any helpful tutorials that you can recommend?</... | <p>Your first step should be to download the latest TFS Installation Guide (TFSInstall.chm) from here: <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=FF12844F-398C-4FE9-8B0D-9E84181D9923&displaylang=en" rel="noreferrer">http://www.microsoft.com/downloads/details.aspx?FamilyID=FF12844F-398C-4FE9-8... | <p>See the link below for a condensed walkthrough:</p>
<p><a href="http://blogs.vertigosoftware.com/teamsystem/archive/2006/04/04/2512.aspx" rel="nofollow noreferrer">Cliff's Notes for a Team System Install</a></p>
| 8,212 |
<p>I have just bought a Creality CR-10 Smart 3D printer, and - as part of the rite of passage of newbies - I am struggling with getting a usable initial layer. Whilst trying to make sense of what I was seeing in the net and correlating it with what I was experiencing with my printer, I thought to check the printer's cr... | <p>I don't think it's because of Cura. You can try if it still works with the older version.</p>
<p>Otherwise, clean your print bed with isopropanol before printing to remove residues or level again. Without pictures of the condition of the print bed or the first layer, it is difficult to help.</p>
| <p>Have tried all the possible answers and found the older version of Cura works better with the Chiron. The printer is 3 months old, bed is cleaned after each print.</p>
<p>I then tried the new Cura version again but with glue for adhesion, that works. It seems that it is changing the bed temperature, and using a l... | 2,100 |
<p>Is it possible to obtain raw logs from Google Analytic? Is there any tool that can generate the raw logs from GA?</p>
| <p>No you can't get the raw logs, but there's nothing stopping you from getting the exact same data logged to your own web server logs. Have a look at the <a href="https://ssl.google-analytics.com/urchin.js" rel="noreferrer">Urchin code</a> and borrow that, changing the following two lines to point to your web server ... | <p>No, but there are other paid services like <a href="https://mixpanel.com/docs/api-documentation/data-export-api" rel="nofollow" title="Mixpanel Data Export API">Mixpanel</a> and <a href="http://support.kissmetrics.com/apis/data/data-export-setup" rel="nofollow" title="KISSmetrics Data Export">KISSmetrics</a> that ha... | 8,319 |
<p>As someone who has spent around 10 years programming web applications with Adobe's ColdFusion, I have decided to add ASP.NET as a string to my bow.</p>
<p>For someone who has spent so long with CF and the underlying Java, ASP.NET seems a little alien to me. How should I go about getting up to speed with ASP.NET so... | <p>I'm only maybe six months down the same path, but here are some thoughts from my experience so far:</p>
<p>The C# language shouldn't give you much problem if you have very much experience with Java at all (or even CFScript). As a reference, though, when I was starting, I found <a href="http://www.csharp-station.co... | <p>Microsoft has a video called <a href="http://www.asp.net/Learn/videos/video-27.aspx" rel="nofollow noreferrer">ASP.NET for ColdFusion developers</a> you may be interested in.</p>
<p>Edit, <a href="http://www.asp.net/learn/videos/video-28.aspx" rel="nofollow noreferrer">here's another</a> </p>
| 8,217 |
<p>I have two unrelated processes that use .NET assemblies as plugins. However, either process can be started/stopped at any time. I can't rely on a particular process being the server. In fact, there may be multiple copies running of one of the processes, but only one of the other.</p>
<p>I initially implemented a so... | <p>Using shared memory is tougher because you'll have to manage the size of the shared memory buffer (or just pre-allocate enough). You'll also have to manually manage the data structures that you put in there. Once you have it tested and working though, it will be easier to use and test because of its simplicity.</p... | <p>Why not host the server and the client on both sides, and whoever comes up first gets to be the server? And if the server drops out, the client that is still active switches roles.</p>
| 6,461 |
<p>I've recently purchased an Elegoo Mars Pro 3d printer, and I was wondering when printing large pieces that need to be printed in different steps: is there some kind of post-processing to make it more suitable for gluing them?</p>
<p>I know of joints and so on, but sometimes pieces are big but not thick enough to be ... | <p>You can definitely use glue - however you can also brush some of the liquid resin along the edges of the two pieces, push them together and cure them, this will fuse them together.</p>
<p>You don't need much, and you need to watch for drip out while curing (don't your fingers in it)</p>
| <p>You can definitely use glue - however you can also brush some of the liquid resin along the edges of the two pieces, push them together and cure them, this will fuse them together.</p>
<p>You don't need much, and you need to watch for drip out while curing (don't your fingers in it)</p>
| 1,729 |
<p>I have Prusa i3 derivative with MK8 extruder and Marlin 1.1RC8 as firmware. I already reduced the default speeds as well as the accelerations. But sometimes when trying to print with BQ PLA filament (220°C), mostly during filling areas, my extruder clicks. The below screenshot of Slic3rs Layers view shows the clicki... | <p>I've tried to reduce the "Extrusion multiplier" from 1 to 0.95, but that caused gaps. Now I've minimized the clicking by setting the Slic3r option "Infill before perimeters" on the "Print Settings > Infill" page.</p>
| <p>I had this issue and it turned out to be the extruder cog rubbing on the inside of the hole in the heatsink, causing the stepper to slip. </p>
| 452 |
<p>I've encountered the following problem pattern frequently over the years:</p>
<ul>
<li><p>I'm writing complex code for a package comprised of a standalone application and also a library version of the core that people can use from inside other apps.</p></li>
<li><p>Both our own app and presumably ones that users cr... | <p>"isn't that [text manipulation] more of something that should be programmed into the application?"</p>
<p>Usually, yes. The generally accepted "<a href="http://en.wikipedia.org/wiki/Multitier_architecture" rel="nofollow noreferrer">three-tier</a>" application design for databases says that your logic should be in t... | <p>I think most additional languages are offered so that if you develop in that language on a regular basis, you can feel comfortable writing db functions, triggers, etc. The usefulness of these features is to provide a control over data as close to the data as possible.</p>
| 6,060 |
<p>Cura is slicing my object (a gear with text) with a partial top layer, and I believe it has to do with layer height and rounding issues. I have been able to solve this at specific heights 10-14mm using a layer height of 0.25 mm, however other heights will cause this issue to arise again. There must be a solution to ... | <p>Your model isn't perfect. I took it into Windows 10 3D Builder for simplicity. I kept clicking the "Mirror" function and noticed as it basically flipped there is some slight movement. I measured some points from bottom to top and noticed some differences. </p>
<p>Try to take your model into some software to fix/fla... | <p>Even though you've selected an answer, here's another viewpoint. Ignoring the brim that I've added by default via my slicer, you can see the first few layers are not complete. This indicates a model that's a fraction of a degree off-plane. </p>
<p><a href="https://i.stack.imgur.com/2VRCT.jpg" rel="nofollow noreferr... | 711 |
<p>When should I include PDB files for a production release? Should I use the <code>Optimize code</code> flag and how would that affect the information I get from an exception?</p>
<p>If there is a noticeable performance benefit I would want to use the optimizations but if not I'd rather have accurate debugging info. ... | <p>When you want to see source filenames and line numbers in your stacktraces, generate PDBs using the pdb-only option. Optimization is separate from PDB generation, i.e. you can optimize <em>and</em> generate PDBs without a performance hit.</p>
<p>From <a href="http://msdn.microsoft.com/en-us/library/8cw0bt21(VS.80).... | <p>There is no need to include them in your distribution, but you should definitely be building them and keeping them. Otherwise debugging a crash dump is practically impossible.</p>
<p>I would also turn on optimizations. Whilst it does make debugging more difficult the performance gains are usually very non-trivial d... | 6,325 |
<p>Is it possible to delete a middle node in the single linked list when the only information available we have is the pointer to the node to be deleted and not the pointer to the previous node?After deletion the previous node should point to the node next to deleted node. </p>
| <p>It's definitely more a quiz rather than a real problem. However, if we are allowed to make some assumption, it can be solved in O(1) time. To do it, the strictures the list points to must be copyable. The algorithm is as the following:</p>
<p>We have a list looking like: ... -> Node(i-1) -> Node(i) -> Node(i+1) -> ... | <pre><code>Void deleteMidddle(Node* head)
{
Node* slow_ptr = head;
Node* fast_ptr = head;
Node* tmp = head;
while(slow_ptr->next != NULL && fast_ptr->next != NULL)
{
tmp = slow_ptr;
slow_ptr = slow_ptr->next;
fast_ptr = fast_ptr->next->next;
}... | 9,464 |
<p>For the past 10 years or so there have been a smattering of articles and papers referencing Christopher Alexander's newer work "The Nature of Order" and how it can be applied to software.</p>
<p>Unfortunately, the only works I can find are from James Coplien and Richard Gabriel; there is nothing beyond that, at lea... | <p>For the sake of completeness I'll repeat the discussion on Reto's post over at the <a href="http://groups.google.com/group/android-developers/browse_thread/thread/36fe0648dabfe745#" rel="noreferrer">Android Groups here</a>.</p>
<p>It seems that if you set the bounds on your drawable it does the trick:</p>
<pre><co... | <p>try :</p>
<pre><code>Drawable defaultMarker = r.getDrawable(R.drawable.icon);
defaultMarker.setBounds(0, 0, defaultMarker.getIntrinsicWidth(),
defaultMarker.getIntrinsicHeight());
MyItemizedOverlay markers = new MyItemizedOverlay(defaultMarker);
overlays.add(markers);
</code></pre>
| 4,593 |
<p>The product we are working on allows the user to easily set it up to run automatically whenever the computer is started. This is helpful because the product is part of the basic work environment of most of our users.<br>
This feature was implemented not so long ago and for a while all was well, but when we started t... | <p>This is the effect of a new feature in Vista called "Boxing":
Windows has several mechanisms that allow the user/admin to set up applications to automatically run when windows starts. This feature is mostly used for one of these purposes:
1. Programs that are part of the basic work environment of the user, such that... | <p>The program probably needs some more info put into its properties. It needs to "Run As", instead of just running.</p>
<p>Maybe this application should be developed as a service, instead of a program to be launched, or you could have service that launches the program when its determined the best window of opportuni... | 3,662 |
<p>Does anyone know of any good tutorials on ADO.NET Entity Framework?</p>
<p>There are a few useful links here at <a href="https://stackoverflow.com/questions/42826/where-to-start-with-entity-framework">Stack OverFlow</a>, and I've found one tutorial at <a href="http://dotnet-architecture-jdo.blogspot.com/2008/08/ado... | <p>Microsoft offers <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=355c80e9-fde0-4812-98b5-8a03f5874e96&displaylang=en" rel="noreferrer">.NET 3.5 Enhancements Training Kit</a> it contains documentation and sample code for ADO.NET EF</p>
| <p>Sample application from <a href="http://msdn.microsoft.com/en-us/library/bb399296.aspx" rel="nofollow noreferrer">MSDN</a></p>
<p>And some inside information from <a href="http://blogs.msdn.com/adonet/" rel="nofollow noreferrer">ADO.NET Team Blog</a></p>
| 8,747 |
<p>I have a console program written in C# that I am using to send faxes. When I step through the program in Visual Studio it works fine. When I double click on the program in Windows Explorer it works fine. When I setup a Windows scheduled task to run the program it fails with this in the event log.</p>
<pre><code>... | <p>I can't explain it - but I have a few ideas.</p>
<p>Most of the times, when a program works fine testing it, and doesn't when scheduling it - security is the case. In the context of which user is your program scheduled? Maybe that user isn't granted enough access.</p>
<p>Is the resource your programm is trying to ... | <p>Check that you set correct working directory for your task</p>
| 5,787 |
<p>My Prusa Mk3 has been making this sort of rough surface on prints, and I'm not sure what caused this. I am printing with PLA Prusament with 0.2 mm layer height at the preset for PLA. What is this, and how can I fix it?</p>
<p><a href="https://i.stack.imgur.com/qRzOM.jpg" rel="nofollow noreferrer"><img src="htt... | <p>The OP was not able to reproduce the problem as can be taken from an edit to his question:</p>
<blockquote>
<p>Changed absolutely nothing, tried again and problem solved!</p>
</blockquote>
<p><em>To honor the Q/A approach used on SE sites, this comment has been converted to a community answer, that once voted fo... | <p>To me this looks like your nozzle is too hot. Try turning the temp down by 5 degrees at a time and see if the issue goes away.</p>
| 1,208 |
<p>It's <a href="http://www.codeproject.com/KB/cs/csharpcasts.aspx" rel="noreferrer">shown</a> that 'as' casting is much faster than prefix casting, but what about 'is' reflection? How bad is it? As you can imagine, searching for 'is' on Google isn't terribly effective.</p>
| <p>There are a few options:</p>
<ol>
<li>The <strong>classic cast</strong>: <code>Foo foo = (Foo)bar</code></li>
<li>The <strong><code>as</code> cast operator</strong>: <code>Foo foo = bar as Foo</code></li>
<li>The <strong><code>is</code> test</strong>: <code>bool is = bar is Foo</code></li>
</ol>
<hr>
<ol>
<li>The... | <p>It should be quick enough to not matter. If you are checking the type of an object enough for it to make a noticeable impact on performance you need to rethink your design</p>
| 8,204 |
<p>I bought a set of 5 <a href="https://a.aliexpress.com/_mL7Tt7b" rel="nofollow noreferrer">stepper motors</a> from Trianglelab's official Aliexpress shop.</p>
<p><a href="https://i.stack.imgur.com/XZDW8.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/XZDW8.jpg" alt="enter image description here" />... | <p>For the AliExpress part, open a dispute and attach pictures to the dispute and ask for a partial, reasonable discount. It always worked for me.</p>
<p>As for how to test the motors themselves, it depends on what other hardware you have.</p>
<p>For example, you could wire the motors to your printer board, and try to ... | <p>I would be far more worried about damage to the wire insulation (i.e. are they nicked/cut at all or just scuffed up?) as that could potentially lead to a short circuit situation against your frame etc. Assuming no serious cable damage, motors can take a fair amount of mechanical abuse so I'd just put them through t... | 1,788 |
<p>I've found a few resources on the subject, but they all require a deep understanding of <a href="http://en.wikipedia.org/wiki/Smalltalk" rel="noreferrer">SmallTalk</a> or <a href="http://en.wikipedia.org/wiki/Haskell_%28programming_language%29" rel="noreferrer">Haskell</a>, neither of which I know.</p>
| <p>Here are some parser combinator libraries in more mainstream languages:</p>
<ul>
<li><a href="http://spirit.sourceforge.net/documentation.html" rel="noreferrer">Spirit</a> (C++)</li>
<li><a href="http://jparsec.codehaus.org/" rel="noreferrer">Jparsec</a> (Java)</li>
</ul>
| <p><s>Cay Horstmann has <a href="http://horstmann.com/sjsu/cs152/schedule.html" rel="nofollow noreferrer">4 combinator parser lectures in Scala</a>, with exercises.</s> There is an example of parsing external DSLs in Scala <a href="http://debasishg.blogspot.com/2008/04/external-dsls-made-easy-with-scala.html" rel="nofo... | 3,843 |
<p>I'm getting seemingly random lines scattered across the top surface of my prints:</p>
<p><img src="https://i.stack.imgur.com/UdXPx.jpg" alt="lines1">
<img src="https://i.stack.imgur.com/gf0OH.jpg" alt="lines2"></p>
<p>Printer: Anycubic i3 mega<br>
Slicer: Cura 3.2.1<br>
Printer chosen in Cura: Prusa i3, <em>Gcode ... | <p>Our local library has a genuine Prusa i3 Mk2.5 that recently had this problem. Because of the number of fingers engaging such a system, it was not immediately discovered that a different profile had been selected in which the Z-hop was turned off.</p>
<p>Z-hop is a feature in which the nozzle lifts slightly (and is... | <p>It seems like the issue may only be that your nozzle has developed a bit of oozing. The g code likes to repeat the same patterns for at least a few layers every time it changes patterns and if it does the same pattern on the top 3-4 layers than by the time it reaches the last layer on the top that pattern will actu... | 840 |
<p>I'm cleaning up some old Maildir folders, and finding messages with names like:</p>
<p>1095812260.M625118P61205V0300FF04I002DC537_0.redoak.cise.ufl.edu,S=2576:2,ST</p>
<p>They don't show up in my IMAP client, so I presume there's some semaphore indicating the message already got moved somewhere else. Is that the c... | <p>The 'M' is just part of the unique filename and has nothing to do with the fact that the mail doesn't show up in mail clients. </p>
<p>The 'T' at the end of the filename, after the ':' sign, however tells the IMAP server that this message is Trashed.</p>
<p>See <a href="http://cr.yp.to/proto/maildir.html" rel="nor... | <p>IMAP, is a protocol for communicating to a message storage, the actual storage is standardised in other ways. The filename looks like a <a href="http://en.wikipedia.org/wiki/Maildir" rel="nofollow noreferrer">Maildir</a> filename where I think does not put any meaning into the first part of the filename, but you hav... | 9,553 |
<p>I've created some MbUnit Test Fixtures that have SetUp methods marked with the SetUp attribute. These methods run before the tests just fine using the MbUnit GUI, the console runner, and the ReSharper MbUnit plugin. However, when I run the tests with TestDriven.NET it does not run the SetUp methods at all. </p>
... | <p>No longer an issue with recent versions of Gallio since v3.0.4. Just make sure to use the 64-bit installer.</p>
| <p>I came across a similar issue with NUnit and TestDriven.NET that took me hours to figure out.
I installed the Visual Studio Extension below and it hit breakpoint in the Tests but skipped the one in the one in the [TestFixtureSetUp].</p>
<p><a href="https://i.stack.imgur.com/sl5xw.png" rel="nofollow noreferrer"><img... | 2,601 |
<ol>
<li>Is it possible to capture Python interpreter's output from a Python script?</li>
<li>Is it possible to capture Windows CMD's output from a Python script?</li>
</ol>
<p>If so, which librar(y|ies) should I look into?</p>
| <p>If you are talking about the python interpreter or CMD.exe that is the 'parent' of your script then no, it isn't possible. In every POSIX-like system (now you're running Windows, it seems, and that might have some quirk I don't know about, YMMV) each process has three streams, standard input, standard output and sta... | <p>In which context are you asking?</p>
<p>Are you trying to capture the output from a program you start on the command line?</p>
<p>if so, then this is how to execute it:</p>
<pre><code>somescript.py | your-capture-program-here
</code></pre>
<p>and to read the output, just read from standard input.</p>
<p>If, on ... | 4,457 |
<p>I'm having a really hard time printing on my aluminum heated bed... Cleaning it just results in it being scratched (trying to scrape dried hairspray/glue/etc off) and I don't think it is particularly flat either.</p>
<p>I was thinking of stopping by the dollar store on my way home and getting several picture frames... | <p>Picture frame glass (generally float glass) will work well enough, but count on it eventually cracking/getting chipped. It's always very flat (due to the way the production process works).</p>
<p>Taking it up to 100-110C for printing ABS should not be a problem, but you'll want to avoid sharp changes in temperature... | <p>I was driving down the street the other day and saw a very nice OLD and LARGE mirror on a lawn at a garage sale. It was about 36" x 28". </p>
<p>Sale price? $5.00</p>
<p>I'm going to be using it for my MPCNC machine to allow me to print large prints on glass. The reason I like the OLD mirrors is that they are ... | 360 |
<p>I have a perl variable <code>$results</code> that gets returned from a service. The value is supposed to be an array, and <code>$results</code> should be an array reference. However, when the array has only one item in it, <code>$results</code> will be set to that value, and not a referenced array that contains th... | <p>im not sure there's any other way than:</p>
<blockquote>
<pre><code>$result = [ $result ] if ref($result) ne 'ARRAY';
foreach .....
</code></pre>
</blockquote>
| <p>I've just tested this with:</p>
<blockquote>
<pre><code>#!/usr/bin/perl -w
use strict;
sub testit {
my @ret = ();
if (shift){
push @ret,1;
push @ret,2;
push @ret,3;
}else{
push @ret,"oneonly";
}
return \@ret;
}
foreach my $r (@{testit(1)}){
print $r." test1\n";
}
foreach my $r (@{testit()}){
p... | 2,527 |
<p>This should be fine seeing as the CLR hasn't actually changed?</p>
<p>The boxes running the C# 2.0 code <strong>have</strong> had .NET 3.5 rolled out.</p>
<p>The background is that we have a windows service (.NET 2.0 exe built with VS2005, deployed to ~150 servers) that dynamically loads assemblies (almost like pl... | <p>C#3 and .Net 3.5 adds new assemblies, but the IL is unchanged.</p>
<p>This means that with .Net 2 assemblies you can compile and use C#3, as long as you don't use Linq or anything else that references System.Linq or System.Core</p>
<p><code>yield</code>, <code>var</code>, lambda syntax, anon types and initialisers... | <p>This is interesting stuff. I was looking at <a href="http://www.albahari.com/nutshell/linqbridge.html" rel="nofollow noreferrer">LinqBridge</a> yesterday after someone on this forum suggested it to me and they are doing a similar thing.</p>
<p>I find it strange that Microsoft named the frameworks 2.0, 3.0 and 3.5 w... | 3,092 |
<p>I'm almost certain I know the answer to this question, but I'm hoping there's something I've overlooked.</p>
<p>Certain applications seem to have the Vista Aero look and feel to their caption bars and buttons even when running on Windows XP. (Google Chrome and Windows Live Photo Gallery come to mind as examples.) ... | <p>Here's an article with full code sample on how to use your own custom "chrome" for an application:</p>
<p><a href="https://web.archive.org/web/20200718062913/http://geekswithblogs.net:80/kobush/articles/CustomBorderForms3.aspx" rel="nofollow noreferrer">http://geekswithblogs.net/kobush/articles/CustomBorde... | <p>Nope, I am afraid, there is no other easy way of doing this. </p>
<p>You are on the right track. You will need to create a custom Winform and then proceed as illustrated in this <a href="http://codemaverick.blogspot.com/2007/02/creating-custom-winforms-in-net-20-yes.html" rel="nofollow noreferrer">example</a>.</p>
| 6,394 |
<p>I made a torus that was 1 on the x and y axes, and 3 on the z axis in Blender. It is supposed to be a bead for a beaded necklace. It was exported to Cura as an .stl, then printed on a Lulzbot Mini. It worked fine in plastic, but when we tried it with bronze filament the nozzle clogged and it didn't start printing.<b... | <p>We print a lot of stuff in a variety of materials, and I think it is likely what you are experiencing is a problem caused by some combination of the following: Object size overall, object detail size, wall thickness, or span width/thickness.</p>
<p>Blender gives pretty clean stls, but the last-mile needed to get ou... | <p>We print a lot of stuff in a variety of materials, and I think it is likely what you are experiencing is a problem caused by some combination of the following: Object size overall, object detail size, wall thickness, or span width/thickness.</p>
<p>Blender gives pretty clean stls, but the last-mile needed to get ou... | 260 |
<p>How do you determine when to use <a href="http://www.iselfschooling.com/mc4articles/mc4cluster.htm" rel="noreferrer">table clusters</a>? There are two types, index and hash, to use for different cases. In your experience, have the introduction and use of table clusters paid off?</p>
<p>If none of your tables are se... | <p>The killer feature of table clusters is that you can store <strong>related rows of different tables</strong> at the same physical location.</p>
<p>That can improve join performance by an order of magnitude. However, it doesn't pay of so often as it sounds.</p>
<p>The only time I used it was a three-table join, exe... | <p>I haven't used Oracle's table clusters myself, but I understand that its index table clusters are very much like MS SQL Server's clustered indexes. That is, the row data is physically organized by the clustered index's key.</p>
<p>That makes one ideal for a heavily-accessed column that has a reasonably small number... | 4,769 |
<p>I'd like to create a progress bar to indicate the status of an a batch job in <code>Ruby</code>. </p>
<p>I've read some <a href="http://tldp.org/HOWTO/NCURSES-Programming-HOWTO/" rel="noreferrer" title="NCURSES Programming HOWTO">tutorials</a> / <a href="http://ncurses-ruby.berlios.de/" rel="noreferrer" title="ncur... | <p>You might be able to get some implementation ideas from the <a href="http://0xcc.net/ruby-progressbar/" rel="noreferrer" title="Ruby/ProgressBar">Ruby/ProgressBar library</a>, which generates text progress bars. I stumbled across it a couple of months back but haven't made any use of it.</p>
| <p>On windows, curses works out of the box, ncurses doesn't, and for a progress bar curses should be sufficient. So, use curses instead of ncurses.</p>
<p>Also, both curses and ncurses are wafer-thin wrappers around the c library - that means you don't really need Ruby-specific tutorials.</p>
<p>However, on the <a hr... | 2,371 |
<p>I am slicing with Cura and Slic3r and one important thing that I recently took my attention is that cura positions head in start point of the new layer and then lifts the nozzle. That caused my few printouts to fall as they collided with the nozzle. </p>
<p>Slic3r behavior is different: it raises the nozzle in last... | <p>To lift the head to prevent the nozzle to tip over your print you could use an option called <code>Z hop</code> in Cura. Just enter `hop' in the search box on the right side to make those options magically appear (in a recent version of Cura, e.g. version 3.x.x).</p>
<p>Other than <code>Z hop</code> there is no def... | <p>OK, after going via all the options I found that CURA has a combing mode which reduces retraction and offers another option which is <code>Avoid Printed Parts When Traveling</code>.</p>
<p>That solves my problem.</p>
| 954 |
<p>We are using SourceForge Enterprise Edition 4.4 in one of our project.</p>
<p>My question is, in CollabNet SFEE (SourceForge Enterprise Edition 4.4), how will we get attachments associated with an Artifacts Using SFEE SOAP API?</p>
<p>We have made our own .net 2.0 client. We are not using .net SDK provided by Coll... | <p>If you commit with a message you can add "[artf1000]" (where artf1000 is your artifact number) to the beginning or end of your commit message. Then it will associate to that artifact you can also do this with documents using doc1000, to get the id of the item you can use the URL it is what is after the <a href="http... | <p>You can cheat a little bit and have a look at the scripts from SFEE. Log into your SFEE via SSH and take a look at the following script: </p>
<pre><code>/usr/local/sourceforge/sourceforge_home/integration/post-commit.py
</code></pre>
<p>Maybe it helps...</p>
| 5,885 |
<p>How can I format Floats in Java so that the float component is displayed only if it's not zero? For example:</p>
<pre>
123.45 -> 123.45
99.0 -> 99
23.2 -> 23.2
45.0 -> 45
</pre>
<p>Edit: I forgot to mention - I'm still on Java 1.4 - sorry!</p>
| <p>If you use <a href="http://java.sun.com/j2se/1.4.2/docs/api/java/text/DecimalFormat.html" rel="nofollow noreferrer">DecimalFormat</a> and specify # in the pattern it only displays the value if it is not zero.</p>
<p>See my question <a href="https://stackoverflow.com/questions/50532/how-do-i-format-a-number-in-java"... | <pre><code>new Formatter().format( "%f", myFloat )
</code></pre>
| 7,809 |
<p>I decided to finally purchase an Ender 3 v2. It arrived today and after a few hours of making sure everything is straight, I tried to power it and do a test print...</p>
<p>I was disappointed to see that the screen stays black after more than 10 seconds from power on.</p>
<p>I did not insert any SD card in the print... | <p>What seems to be a difficulty is the stabilizers for plastic absorb UV. So if added to UV resin, they probably greatly increase the exposure time needed.</p>
<p>The following show characteristics of some plastics, taken from <a href="https://www.coleparmer.com/tech-article/uv-properties-of-plastics" rel="nofollow n... | <p>Sunlight contains the full spectrum of electromagnetic radiation, including the wavelength to photoinitiate your resin. Most UV-curable materials are kept in opaque containers for this reason. The extent to which your material is crosslinked will depend on your material and how much sunlight it receives.</p>
| 1,880 |
<p>Several questions are related to first layer calibration or issues: I found 43 of them with "first layer" in the title alone, 150 with "first layer" anywhere (no duplicates).</p>
<p>I propose adding a "first-layer" tag to more easily retrieve said questions.</p>
<p>I already applied it to my latest question withou... | <p>I think the <a href="https://3dprinting.stackexchange.com/questions/tagged/adhesion" class="post-tag" title="show questions tagged 'adhesion'" rel="tag">adhesion</a> tag should be used instead.</p>
| <p>Yes, I support this idea. A <a href="https://3dprinting.stackexchange.com/questions/tagged/first-layer" class="post-tag" title="show questions tagged 'first-layer'" rel="tag">first-layer</a> tag would be useful.</p>
| 76 |
<p>I've heard that unit testing is "totally awesome", "really cool" and "all manner of good things" but 70% or more of my files involve database access (some read and some write) and I'm not sure how to write a unit test for these files.</p>
<p>I'm using PHP and Python but I think it's a question that applies to most/... | <p>I would suggest mocking out your calls to the database. Mocks are basically objects that look like the object you are trying to call a method on, in the sense that they have the same properties, methods, etc. available to caller. But instead of performing whatever action they are programmed to do when a particular... | <p>You could use <strong>mocking frameworks</strong> to abstract out the database engine. I don't know if PHP/Python got some but for typed languages (C#, Java etc.) there are plenty of choices</p>
<p>It also depends on how you designed those database access code, because some design are easier to unit test than other... | 5,058 |
<p>How do you insert invisible watermarks in images for copyright purposes? I'm looking for a python library.</p>
<p>What algorithm do you use? What about performance and efficiency?</p>
| <p>You might want to look into Steganography; that is hiding data inside of images. There are forms that won't get lost if you convert to a lossier format or even crop parts of the image out.</p>
| <p>I was going to post an answer similar to Ugh. I would suggest putting a small TXT file describing the image source (and perhaps a small copyright statement, if one applies) into the image in a manner that is difficult to detect and break.</p>
| 6,575 |
<p>Are there any free tools available to view the contents of the solution user options file (the .suo file that accompanies solution files)?</p>
<p>I know it's basically formatted as a file system within the file, but I'd like to be able to view the contents so that I can figure out which aspects of my solution and c... | <p>The .SUO file is effectively disposable. If it's getting too large, just delete it. Visual Studio will create a fresh one.</p>
<p>If you <em>do</em> want to go poking around in it, it looks like an OLE Compound Document File. You should be able to use the StgOpenStorage function to get hold of an IStorage pointer.<... | <p>I don't know any tool, but you can try to access user settings via <a href="http://msdn.microsoft.com/en-us/library/microsoft.visualstudio.shell.interop.ivspersistsolutionopts_members%28VS.80%29.aspx" rel="nofollow noreferrer">IVsPersistSolutionOpts</a> interface</p>
| 7,766 |
<p>Is it possible in a large GWT project, load some portion of JavaScript lazy, on the fly?
Like overlays. </p>
<p>PS: Iframes is not a solution.</p>
| <p>Check out <code>GWT.runAsync</code> as well as the Google I/O talk below, which goes into lazy loading of <code>JavaScript</code> in <code>GWT</code> projects.</p>
<ul>
<li><a href="http://code.google.com/p/google-web-toolkit/wiki/CodeSplitting" rel="nofollow noreferrer">http://code.google.com/p/google-web-toolkit/... | <p>I think this is what you are looking for.</p>
<pre><code><body onload="onloadHandler();">
<script type="text/javascript">
function onloadHandler() {
if (document.createElement && document.getElementsByTagName) {
var script = document.createElement('script');
script.type = 'te... | 9,809 |
<p>Is there a way to detect if a flash movie contains any sound or is playing any music?<br>
It would be nice if this could be done inside a webbrowser (actionscript <strong>from another flash object</strong>, javascript,..) and could be done <em>before</em> the flash movie starts playing.</p>
<p>However, I have my do... | <p>Yes, on the server side for sure. Client side? I don't know. (I'm a serverside kind of guy.) </p>
<p>On the server side, one would have to parse the file, read the header and/or look for audio frames. (I've ported a haskel FLV parser to Java for indexing purposes myself, and there are other parsing utilities ou... | <p>With the <a href="https://web.archive.org/web/20080917191415/http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/utils/ByteArray.html" rel="nofollow noreferrer">ByteArray</a> you can do pretty much what you want. Before starting playback you can analyze the bytes of the FLV header (use byteArray.readByte... | 6,508 |
<p>For part of my application I have a need to create an image of a certain view and all of its subviews.</p>
<p>To do this I'm creating a context that wraps a bitmap with the same-size as the view, but I'm unsure how to draw the view hierarchy into it. I can draw a single view just be setting the context and explicit... | <p>I found that writing the drawing code myself was the best way to:</p>
<ul>
<li>deal with potential transparency issues (some of the other options do add a white background to the whole image)</li>
<li>performance was much better</li>
</ul>
<p>The code below is not perfect, because it does not deal with scaling iss... | <p>You can use <a href="http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Classes/NSBitmapImageRep_Class/Reference/Reference.html#//apple_ref/occ/instm/NSBitmapImageRep/initWithFocusedViewRect:" rel="nofollow noreferrer" title="-[NSBitmapImageRep initWithFocusedViewRect:]"><code>-[NSBitmapImageRep... | 3,566 |
<p>I have developed a high speed transactional server for transfering data over the internet so I do not need to rely upon a database implementation like MySQL to provide this. That opens up the question of which SQL version to use?</p>
<p>I really like SQLite, but I am not convinced it is industrial strength yet
What... | <p>SQLite is used in more applications than any other DB. (Citation required).</p>
<p>There are some issues with MySQL, like that it doesn't respect foreign integrity constraints.</p>
<p>I'm currently a fan of PostgreSQL, which is also freely available (and, I think if you read the licensing of MySQL, actually turns... | <p>Sorry to be pedantic, but the title should really be "Which RDBMS?" - the way it's phrased makes about as much sense as "Which Java?" or "<a href="http://thedailywtf.com/Articles/Which-Internet.aspx" rel="nofollow noreferrer">Which Internet?</a>"...</p>
| 3,993 |
<p>I have a 200+ case statement in Classic ASP which is getting out of control. It sets 5 variables, based on which case is selected. Address, Phone, Name etc. Just sets the variables and nothing else in each case.</p>
<p>Databases or files are not an option for this application.</p>
<p>Coming from the Perl world I w... | <p>Brian, the classic ASP equivalent of a Perl hash is the <a href="http://www.microsoft.com/technet/scriptcenter/guide/sas_scr_ildk.mspx?mfr=true" rel="nofollow noreferrer">Scripting.Dictionary</a> object.</p>
| <p>This should be done with a database, but since you said that is not an option, nothing you will write will be any less complex than a switch statement, since it's all required to live in your code (according to your terms of no db and no files).</p>
<p>I mean, you could use an Excel Spreadsheet if the idea of a <st... | 7,279 |
<p>I'm interested in looking at Erlang and want to follow the path of least resistance in getting up and running.</p>
<p>At present, I'm planning on installing <a href="http://www.erlang.org/download.html" rel="noreferrer">Erlang R12B-3</a> and <a href="http://erlide.sourceforge.net/" rel="noreferrer">Erlide</a> (<a h... | <p>I've only done a small bit of coding in Erlang but I found the most useful method was just to write the code in a text editor and have a terminal open ready to build my code as I need to (this was in Linux, but a similar idea would work in Windows, I'm sure).</p>
<p>Your question didn't mention it, but if you're lo... | <p>From what i've tried (and are still up to do), a good addition to an erlang dev. environment would be a virtual machine running ubuntu/yaws/erlang. Perhaps <a href="http://feeds.feedburner.com/10xSoftwareDevelopment?format=xml" rel="nofollow noreferrer">Erlyweb</a> (erlang/yaws framework) would be nice checking out ... | 2,484 |
<p>In C#, (and feel free to answer for other languages), what order does the runtime evaluate a logic statement?</p>
<p>Example:</p>
<pre><code>DataTable myDt = new DataTable();
if (myDt != null && myDt.Rows.Count > 0)
{
//do some stuff with myDt
}
</code></pre>
<p>Which statement does the runtime eva... | <p>C# : Left to right, and processing stops if a non-match (evaluates to false) is found.</p>
| <p>I have heard somewhere that compilers work backwards, but I am unsure how true this is.</p>
| 2,725 |
<p>I'm not a math guy in the least but I'm interested in learning about rigid body physics (for the purpose of implementing a basic 3d physics engine). In school I only took Maths through Algebra II, but I've done 3d dev for years so I have a fairly decent understanding of vectors, quaternions, matrices, etc. My real... | <p><a href="https://rads.stackoverflow.com/amzn/click/com/159059472X" rel="nofollow noreferrer" rel="nofollow noreferrer">Physics for Game Programmers</a> I think is better than <a href="https://rads.stackoverflow.com/amzn/click/com/0596000065" rel="nofollow noreferrer" rel="nofollow noreferrer">Physics for Game Develo... | <p>Trying not to get you to rip off your hair with frustration (well, Baraff's/Witkin great math articles with the multi-dimensional matrices would do that sometimes), you can look at the easier online articles such as the ones published in Gamasutra.
Here are two of them:</p>
<ol>
<li><a href="http://www.gamasutra.co... | 8,513 |
<p>Is there an easy way to convert a string from csv format into a string[] or list? </p>
<p>I can guarantee that there are no commas in the data.</p>
| <p>String.Split is just not going to cut it, but a Regex.Split may - Try this one:</p>
<pre><code>using System.Text.RegularExpressions;
string[] line;
line = Regex.Split( input, ",(?=(?:[^\"]*\"[^\"]*\")*(?![^\"]*\"))");
</code></pre>
<p>Where 'input' is the csv line. This will handle quoted delimiters, and should ... | <pre><code>CsvString.split(',');
</code></pre>
| 9,906 |
<p>Is there anything which can help with msmq monitoring? I'd like to get some event/monit when a message appears in queue and the same on leave.</p>
| <p>Check out the Windows Management Performance counters.</p>
<p>If you look in your Administrative Tools and find "Performance Counters", you will be able to dig through there and find detailed metrics on what is happening on each message queue. This can also work for remote servers.</p>
<p>Should you wish to create... | <p>You can achieve this by using <a href="https://msdn.microsoft.com/en-us/library/ms703197%28v=vs.85%29.aspx" rel="nofollow"><strong>MSMQ</strong> triggers</a></p>
| 5,864 |
<p>I am the web guy for a large TV station. Our site is cached by Akamai. Pages render perfectly in our testing environment (not cached) and on our "origin" page (again, not cached), but when they are viewed on our live environment (the cached site), they do not render exactly the same as how I coded them. Maybe it's a... | <p>I've been working on sites behind Akamai and can honestly say they don't mess with your code, so that's not the issue. It's more than likely one of the following:</p>
<p><strong>You have a cache latency issue</strong> - You updated your html and css, and one of the two updated while the other is still cached by Ak... | <p>Perhaps Akamaia isn't seeing the updated versions of your CSS files that are <link />'d in your HTML code? It might be a good idea to embed a version number in the URL so that when you release an updated version of the HTML, it's always going to ask Akamai for a new version of the CSS as well (this applies to... | 9,069 |
<blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="https://stackoverflow.com/questions/9/how-do-i-calculate-someones-age-in-c">How do I calculate someone's age in C#?</a> </p>
</blockquote>
<p>Maybe this could be silly but and I don't have issues with my age but sometimes it is good to calcul... | <blockquote>
<p>Maybe this could be silly but and I don't have issues with my age but sometimes it is good to calculate the exact age of someone, I have introduced my birthdate in my profile (01/12/1975) "dd/mm/yyyy" and it calculated 33 and I'm 32 actually still, doesn't it better to calculate the exact age? </p>
<... | <p>Actually, because of leap years, your code would be off. Since the timespan object has no TotalYears property the best way to get it would be this</p>
<p>Pardon the VB.Net</p>
<pre><code>Dim myAge AS Integer = DateTime.Now.year - BirthDate.year
If Birthdate.month < DateTime.Now.Month _
OrElse BirthDate.Month =... | 3,911 |
<p>I was recently tasked with coming up with an offsite backup strategy. We have about 2TB of data that would need to be backed up so our needs are a little out of the norm. </p>
<p>I looked into Iron Mountain and they wanted $12,000 a month! </p>
<p>Does anyone have any suggestions on how best to handle backing up t... | <p>You can buy external eSATA RAID boxes in the 8TB capacity range <a href="http://www.newegg.com/Product/Product.aspx?Item=N82E16822101110" rel="nofollow noreferrer">for $2600</a>. I'm not saying that particular product is the right choice, but that's the kind of box that will do 6TB in RAID5 and still be portable eno... | <p>I've used <a href="http://bqbackup.com" rel="nofollow noreferrer">bqbackup.com</a> for 1-2 years no problem. You can do a sync using rsync nightly. Wanted to add that their prices are dirt cheap, and I now have close to 1TB with them.</p>
| 3,064 |
<p>My Rails-app has a sign in box with a "remember me" checkbox. Users who check that box should remain logged in even after closing their browser. I'm keeping track of whether users are logged in by storing their id in the user's session. </p>
<p>But sessions are implemented in Rails as session cookies, which are not... | <p>You should almost certainly not be extending the session cookie to be long lived.</p>
<p>Although not dealing specifically with rails <a href="http://fishbowl.pastiche.org/2004/01/19/persistent_login_cookie_best_practice" rel="noreferrer">this article</a> goes to some length to explain 'remember me' best practices.... | <p>This worked like a charm for me:</p>
<p><a href="http://squarewheel.wordpress.com/2007/11/03/session-cookie-expiration-time-in-rails/" rel="nofollow noreferrer">http://squarewheel.wordpress.com/2007/11/03/session-cookie-expiration-time-in-rails/</a></p>
<p>Now my CookieStore sessions expire after two weeks, whereb... | 2,290 |
<p>I acquired an Anycubic Chiron yesterday. I went through the leveling procedure and I think the level test print came out okay so I printed a 20 mm calibration cube and a benchy. Both of these came out with a sort of spongy consistency.</p>
<p>I have no idea what could be causing this so some advice would be ap... | <p>It turned out I had the wrong filament size set in Ultimaker Cura. Fixing this resolved the issue. </p>
<p><a href="https://i.stack.imgur.com/3KFlw.jpg" rel="noreferrer"><img src="https://i.stack.imgur.com/3KFlw.jpg" alt="under extruded calibration cube"></a></p>
| <p>I would lay odds on it being your filament is moisture saturated. You don't state what type of filament you're using, but to my understanding this is what happens when it is saturated. The water evaporates as it goes through the nozzle, which causes the filament to puff up, which leaves voids in your print. </p>
<p... | 1,287 |
<p>What are some macros that you have found useful in Visual Studio for code manipulation and automation? </p>
| <p>This is one of the handy ones I use on HTML and XML files:</p>
<pre><code>''''replaceunicodechars.vb
Option Strict Off
Option Explicit Off
Imports EnvDTE
Imports System.Diagnostics
Public Module ReplaceUnicodeChars
Sub ReplaceUnicodeChars()
DTE.ExecuteCommand("Edit.Find")
ReplaceAllChar(ChrW(8... | <p>You might want to add in code snippets as well, they help to speed up the development time and increase productivity.</p>
<p>The standard VB code snippets come with the default installation. The C# code snippets must be downloaded and added seperately. (Link below for those)</p>
<p>As far as macros go, I generally... | 3,584 |
<p>I'm using a Flashforge Pro and attempting to print a wheel about 6mm thick to serve as a platform. In other words, the wheel doesn't have to be solid, but spokes won't do the job. I've experimented with different temperatures, but, because of ABS' thermal expansion, I don't think that will solve the problem. Also... | <p>If you can, set your slicer to do honeycomb fill. Depending on the weight requirement choose maybe 10% - 20% fill. That ought to do the trick. It won't be solid, but it should be strong enough.</p>
<p>What are you going to put on the platform?</p>
| <p>So you just want a short, wide cylinder? Just print that, with low density infill (20-30%) and 6-8 solid top layers, three bottom, and three perimeters, and you'll be fine. For bed adhesion with something this wide, use a 10mm brim, one layer thick. And a heated chamber will help a lot.</p>
| 484 |
<p>In the <a href="http://herdingcode.com/" rel="nofollow noreferrer">herding code</a> podcast 14 someone mentions that stackoverflow displayed the queries that were executed during a request at the bottom of the page. </p>
<p>It sounds like an excellent idea to me. Every time a page loads I want to know what sql stat... | <p>If you put .ToString() to a var query variable you get the sql. You can laso use this in Debug en VS2008. <a href="http://weblogs.asp.net/scottgu/archive/2007/07/31/linq-to-sql-debug-visualizer.aspx" rel="nofollow noreferrer">Debug Visualizer</a></p>
<p>ex:</p>
<pre><code>var query = from p in db.Table
... | <p>From Linq in Action</p>
<blockquote>
<p>Microsoft has a Query Visualizer tool that can be downloaded separetly from VS 2008. it is at <a href="http://weblogs.asp.net/scottgu/archive/2007/07/31/linq-to-sql-debug-visualizer.aspx" rel="nofollow noreferrer">http://weblogs.asp.net/scottgu/archive/2007/07/31/linq-to-s... | 4,895 |
<p>I've been asked to create a Delphi compatible dll in C++ to do simple 64bit memory management.</p>
<p>The background is that the system in Delphi needs to allocate a lots of chunks of memory that would go well outside 32bit addressable space. The Delphi developer explained to me that he could not allocate memory wi... | <p>Only 64 bit processes can address 64 bit memory. A 64 bit process can only load 64 bit dlls and 32 bits processes can only load 32 bits dlls. Delphi's compiler can only make 32 bits binaries.</p>
<p>So a 32 bits Delphi exe can not load your 64 bit c++ dll. It could load a 32 bit c++ dll, but then that dll wouldn't ... | <p>You might also want to add a way to pin and unpin that 64-bit pointer to a 32-bit memory address. Since this is Delphi, I'm pretty sure it's Windows specific, so you might as well use <a href="http://msdn.microsoft.com/en-us/library/aa366527(VS.85).aspx" rel="nofollow noreferrer">Address Windowing Extensions</a>. Th... | 5,448 |
<p>If someone creates a 3D model of a character for 3D printing can I import that model into Unreal engine or Unity 3D for use in a video game? Also is the inverse true? Can I get 3D model of Mario and send that to a 3D printer?</p>
<p>Specifically, it’s more important to know if I can pull a 3D printer model into an u... | <p>The only time I've seen lifting, away from the edges of the part like this, is when the bed is contaminated with something which will stop the print sticking, like fingerprints and such.</p>
<p>A thorough wipe-down with IPA on the heated bed is usually enough to stop it.</p>
| <p>I haven't seen lifts that aren't on the edge of the print, such as warping, or the entire printed surface lifts. When I get something like in your photograph, it's because the print surface isn't flat and the first layer matches the surface topology. If the second image shows the print surface, it looks like blobs... | 1,875 |
<p>I have a ASP.net 2.0 app and I have made some changes the the source file ( cs files ). I uploaded the changes with the belief that it would auto-recompile. I also have the compiled dll in MY_APP/bin. I checked it and noticed that it did not recompile. Please understand I am new to this.</p>
| <p>my #1 way to do this, add white space to the top of the web config file, after the xml declaration tag.</p>
<p>It forces the node to re-cache and recompile. We even have a page deep in the admin called Flush.aspx that does it for us.</p>
| <p>In VS menu you have Build -> Rebuild Solution</p>
| 7,508 |
<p>I'm accessing an Ubuntu machine using PuTTY, and using gcc.</p>
<p>The default <code>LANG</code> environment variable on this machine is set to <code>en_NZ.UTF-8</code>, which causes GCC to think PuTTY is capable of displaying UTF-8 text, which it doesn't seem to be.
Maybe it's my font, I don't know - it does this... | <p><code>LANG=en_NZ</code> is correct. However, you must make locale files for <code>en_NZ</code>.</p>
<p>For Ubuntu, edit <code>/var/lib/locales/supported.d/local</code> and add <code>en_NZ ISO-8859-1</code> to the file. If your system is another distribution (including Debian), the location will be different. Look a... | <p>For Debian 5.0 Lenny:</p>
<pre><code>aptitude install locales
</code></pre>
<p>If that's already installed:</p>
<pre><code>dpkg-reconfigure locales
</code></pre>
| 4,669 |
<p>Is there any way to launch IE Mobile's "Favorites" screen directly by
specifying any command line parameter?</p>
| <p>How about running IE with the HTML favorites file as a parameter?</p>
<blockquote>
<p>IExplore file://\windows\fav.htm</p>
</blockquote>
| <p>I think this is going to be quite difficult without code. </p>
<p>Two options come to mind:</p>
<ul>
<li>Find out what Windows messages IE sends to open the favorites screen and replay these in your application. You would first need to see if IE is running and if it is bring it to the foreground. If not then start... | 2,289 |
<p>I broke up my electronics and now the output for X is not working. The stepper is OK. </p>
<p>There is any simple solution to remap the output pins? I want the E1 output to act as the X output.</p>
| <p>When using <a href="http://marlinfw.org/" rel="noreferrer">Marlin firmware</a> you could easily change the pin layout of the extra extruder (E1) with the broken X stepper pins by changing the <a href="https://github.com/MarlinFirmware/Marlin/blob/1.1.x/Marlin/pins_RAMPS.h" rel="noreferrer">pins_RAMPS.h</a> file.</p>... | <p>you can find pin.h in marlin directory and in pin.h file change # define pinout of z motor and extruder motor</p>
| 581 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.