qid
int64
4
22.2M
question
stringlengths
18
48.3k
answers
list
date
stringlengths
10
10
metadata
list
370,878
<p>Does anyone know how to get a service ticket from the Key Distribution Center (KDC) using the Java GSS-API?</p> <p>I have a thick-client-application that first authenticates via JAAS using the Krb5LoginModule to fetch the TGT from the ticket cache (background: Windows e.g. uses a kerberos implementation and stores ...
[ { "answer_id": 377108, "author": "Roland Schneider", "author_id": 16515, "author_profile": "https://Stackoverflow.com/users/16515", "pm_score": 5, "selected": true, "text": " GSSManager manager = GSSManager.getInstance();\n GSSName clientName = manager.createName(\"clientUser\", GS...
2008/12/16
[ "https://Stackoverflow.com/questions/370878", "https://Stackoverflow.com", "https://Stackoverflow.com/users/16515/" ]
370,884
<p>I understand that you can use forms authentication to grant/deny access to certain pages based on the criteria of your choosing.</p> <p>However I wish to go in a little more specific than that and say, have different buttons appear for users based on thier permissions.</p> <p>I know I could do something like</p> ...
[ { "answer_id": 371376, "author": "Craig Stuntz", "author_id": 7714, "author_profile": "https://Stackoverflow.com/users/7714", "pm_score": 3, "selected": false, "text": "if (ViewContext.HttpContext.User.IsInRole(\"vEmployee\") {\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/370884", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3193/" ]
370,890
<p>I have to display marks of my students through my site. The database is created using <a href="http://en.wikipedia.org/wiki/Microsoft_Access" rel="noreferrer">Microsoft Access</a>. How can I display the marks of each student in a table, as they enter the registration number?</p>
[ { "answer_id": 371583, "author": "Diodeus - James MacFarlane", "author_id": 12579, "author_profile": "https://Stackoverflow.com/users/12579", "pm_score": 0, "selected": false, "text": "<%\nSet Conn = Server.CreateObject(\"ADODB.Connection\")\nConn.Open \"Provider=Microsoft.Jet.OLEDB.4.0;...
2008/12/16
[ "https://Stackoverflow.com/questions/370890", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
370,892
<p>Please follow the link <a href="http://msdn.microsoft.com/hi-in/default.aspx" rel="noreferrer">http://msdn.microsoft.com/hi-in/default.aspx</a> and see the top right corner of the page. </p> <p>There you will find a "Microsoft.com" expander. When you move the mouse over it, it displays as a popup and grows. When yo...
[ { "answer_id": 370964, "author": "Kent Boogaart", "author_id": 5380, "author_profile": "https://Stackoverflow.com/users/5380", "pm_score": 2, "selected": false, "text": "Popup" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/370892", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46607/" ]
370,913
<p>I have been playing with the Linq to Sql and I was wondering if it was possible to get a single result out? For example, I have the following:</p> <pre><code>using(DataClassContext context = new DataClassContext()) { var customer = from c in context.table where c.ID = textboxvalue ...
[ { "answer_id": 370924, "author": "Paul Nearney", "author_id": 24071, "author_profile": "https://Stackoverflow.com/users/24071", "pm_score": 2, "selected": false, "text": "var customer = context.table.SingleOrDefault(c => c.ID == textboxvalue);\n" }, { "answer_id": 370930, "au...
2008/12/16
[ "https://Stackoverflow.com/questions/370913", "https://Stackoverflow.com", "https://Stackoverflow.com/users/36243/" ]
370,925
<p>I have a method I want to unittest that has filesystem calls in it and am wondering how to go about it. I have looked at <a href="https://stackoverflow.com/questions/129036/unit-testing-code-with-a-file-system-dependency">Unit testing code with a file system dependency</a> but it does not answer my question.</p> <p...
[ { "answer_id": 370955, "author": "Dan Vinton", "author_id": 21849, "author_profile": "https://Stackoverflow.com/users/21849", "pm_score": 3, "selected": false, "text": "interface FileProvider {\n public Reader getContentReader(String file);\n // notice use of the Reader interfa...
2008/12/16
[ "https://Stackoverflow.com/questions/370925", "https://Stackoverflow.com", "https://Stackoverflow.com/users/32313/" ]
370,943
<p>How can I use multiple keys in WSH Script like (ALT,CTRL,DELETE)? How can i take a screenshot of an application and paste it in MSWord using WSH SCript?</p>
[ { "answer_id": 370963, "author": "Tomalak", "author_id": 18771, "author_profile": "https://Stackoverflow.com/users/18771", "pm_score": 2, "selected": false, "text": "SendKeys()" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/370943", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46565/" ]
370,944
<p>I am using a DropDownList as </p> <pre><code>&lt;asp:DropDownList ID="ddlLocationName" runat="server" DataValueField="Guid" DataTextField="LocationName" AppendDataBoundItems="false" AutoPostBack="false" onchange="LocationChange()" &gt;&lt;/asp:DropDownList&gt; </code></pre> <p>and when I selec...
[ { "answer_id": 370980, "author": "Aaron Powell", "author_id": 11388, "author_profile": "https://Stackoverflow.com/users/11388", "pm_score": 2, "selected": false, "text": "<option />" }, { "answer_id": 371041, "author": "Devashri B.", "author_id": 43886, "author_profil...
2008/12/16
[ "https://Stackoverflow.com/questions/370944", "https://Stackoverflow.com", "https://Stackoverflow.com/users/43886/" ]
370,954
<p>I have a KTextEdit, filled with some text. </p> <p>When I put lots of text, the KTextEdit will be scrolled automatically to the end (obviously). </p> <p>My question is: how can I scroll to the start (viz to the first line of the KTextEdit) ?!?</p>
[ { "answer_id": 370988, "author": "user11323", "author_id": 11323, "author_profile": "https://Stackoverflow.com/users/11323", "pm_score": 0, "selected": false, "text": "KTextEdit *kte;\n...\nkte->append(\"some huge text\");\nkte->verticalScrollBar()->setValue(0);\n" }, { "answer_i...
2008/12/16
[ "https://Stackoverflow.com/questions/370954", "https://Stackoverflow.com", "https://Stackoverflow.com/users/39339/" ]
370,962
<p>The question is in Java why can't I define an abstract static method? for example</p> <pre><code>abstract class foo { abstract void bar( ); // &lt;-- this is ok abstract static void bar2(); //&lt;-- this isn't why? } </code></pre>
[ { "answer_id": 371011, "author": "Mnementh", "author_id": 21005, "author_profile": "https://Stackoverflow.com/users/21005", "pm_score": 1, "selected": false, "text": "foo var = new ImplementsFoo();\nvar.bar();\n" }, { "answer_id": 372544, "author": "Jared", "author_id": 4...
2008/12/16
[ "https://Stackoverflow.com/questions/370962", "https://Stackoverflow.com", "https://Stackoverflow.com/users/42303/" ]
370,978
<p>I have an application that uses a cron like job to update a set of data. The update process happens once a minute and doesn't last long. A servlet exposes this data set to the users. My problem is that during the update process, the servlet requests should block and wait for the process to complete. </p> <p>In bott...
[ { "answer_id": 370995, "author": "Bombe", "author_id": 43582, "author_profile": "https://Stackoverflow.com/users/43582", "pm_score": 0, "selected": false, "text": "public void updateData() {\n synchronized (updateLock) {\n /* do stuff. */\n }\n}\n\n\npublic List getData() {\...
2008/12/16
[ "https://Stackoverflow.com/questions/370978", "https://Stackoverflow.com", "https://Stackoverflow.com/users/24054/" ]
371,005
<p>I have a class</p> <pre><code>public class Broker { public Broker(string[] hosts, string endPoint, string port, Type remoteType) { } } </code></pre> <p>Which I want to configure using Unity XML Configuration, I can configure it using code in C# as follows already, where "container" is my Unity containe...
[ { "answer_id": 398214, "author": "Bruno Shine", "author_id": 28294, "author_profile": "https://Stackoverflow.com/users/28294", "pm_score": 1, "selected": false, "text": "<unity>\n<typeAliases>\n <typeAlias alias=\"IMyBrokeredObject\" type=\"MyAssembly.IMyBrokeredObject, MyAssembly\" />\...
2008/12/16
[ "https://Stackoverflow.com/questions/371005", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,018
<p>I using the Win32 API and C/C++. I have a HFONT and want to use it to create a new HFONT. The new font should use the exact same font metrics except that it should be bold. Something like:</p> <pre><code>HFONT CreateBoldFont(HFONT hFont) { LOGFONT lf; GetLogicalFont(hFont, &amp;lf); lf.lfWeight = FW_BOL...
[ { "answer_id": 371052, "author": "arul", "author_id": 15409, "author_profile": "https://Stackoverflow.com/users/15409", "pm_score": 6, "selected": true, "text": "GetObject ( hFont, sizeof(LOGFONT), &lf );\n" }, { "answer_id": 372678, "author": "Johann Gerell", "author_id"...
2008/12/16
[ "https://Stackoverflow.com/questions/371018", "https://Stackoverflow.com", "https://Stackoverflow.com/users/20398/" ]
371,019
<p>In the javadoc it says that EventListener is </p> <blockquote> <p>"A tagging interface that all event listener interfaces must extend."</p> </blockquote> <p>Why is that? What's the significance of making a custom listener implement EventListner? Is there any special handling for EventListner somewhere?</p>
[ { "answer_id": 371256, "author": "asalamon74", "author_id": 21348, "author_profile": "https://Stackoverflow.com/users/21348", "pm_score": 4, "selected": true, "text": "extends EventListener" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371019", "https://Stackoverflow.com", "https://Stackoverflow.com/users/931/" ]
371,026
<p>What's the shortest way to get an Iterator over a range of Integers in Java? In other words, implement the following:</p> <pre><code>/** * Returns an Iterator over the integers from first to first+count. */ Iterator&lt;Integer&gt; iterator(Integer first, Integer count); </code></pre> <p>Something like</p> <pre><...
[ { "answer_id": 371034, "author": "Bombe", "author_id": 43582, "author_profile": "https://Stackoverflow.com/users/43582", "pm_score": 3, "selected": true, "text": "List<Integer> ints = new ArrayList<Integer>();\nfor (int i = 0; i < count; i++) {\n ints.add(first + i);\n}\n" }, { ...
2008/12/16
[ "https://Stackoverflow.com/questions/371026", "https://Stackoverflow.com", "https://Stackoverflow.com/users/18722/" ]
371,032
<p>I am developing a program that continually sends a stream of data in the background and I want to allow the user to set a cap for both upload and download limit.</p> <p>I have read up on the <a href="http://en.wikipedia.org/wiki/Token_bucket" rel="noreferrer">token bucket</a> and <a href="http://en.wikipedia.org/wi...
[ { "answer_id": 29456717, "author": "0xDEADBEEF", "author_id": 909365, "author_profile": "https://Stackoverflow.com/users/909365", "pm_score": 2, "selected": false, "text": "public ThrottledStream(Stream parentStream, int maxBytesPerSecond=int.MaxValue) \n{\n MaxBytesPerSecond = maxByt...
2008/12/16
[ "https://Stackoverflow.com/questions/371032", "https://Stackoverflow.com", "https://Stackoverflow.com/users/9479/" ]
371,054
<p>I was working with the Action Delegates in C# in the hope of learning more about them and thinking where they might be useful.</p> <p>Has anybody used the Action Delegate, and if so why? or could you give some examples where it might be useful?</p>
[ { "answer_id": 371074, "author": "Sorskoot", "author_id": 31722, "author_profile": "https://Stackoverflow.com/users/31722", "pm_score": 2, "selected": false, "text": "SpecialRequest(this,\n new BalieEventArgs \n { \n Message = \"A Message\", \n Action = Update...
2008/12/16
[ "https://Stackoverflow.com/questions/371054", "https://Stackoverflow.com", "https://Stackoverflow.com/users/41968/" ]
371,055
<p>I am trying to modify the below program to ensure each msg is converted to utf-8 using Encode::decode(), but I am unsure of how and where to place this to make it work.</p> <pre><code>#!/usr/bin/perl use warnings; use strict; use Mail::Box::Manager; open (MYFILE, '&gt;&gt;data.txt'); binmode(MYFILE, ':encoding(UT...
[ { "answer_id": 371074, "author": "Sorskoot", "author_id": 31722, "author_profile": "https://Stackoverflow.com/users/31722", "pm_score": 2, "selected": false, "text": "SpecialRequest(this,\n new BalieEventArgs \n { \n Message = \"A Message\", \n Action = Update...
2008/12/16
[ "https://Stackoverflow.com/questions/371055", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1246613/" ]
371,059
<p>Here is my query:</p> <pre><code> Select Top 10 CS.CaseStudyID, CS.Title, CSI.ImageFileName From CaseStudy CS Left Join CaseStudyImage CSI On CS.CaseStudyID = CSI.CaseStudyID And CSI.CSImageID in( Select Min(CSImageID) -- &gt;not really satisfactory From CaseStudyImage Group By CaseStudyID ...
[ { "answer_id": 371061, "author": "Bombe", "author_id": 43582, "author_profile": "https://Stackoverflow.com/users/43582", "pm_score": 0, "selected": false, "text": "ORDER BY RAND() LIMIT 1" }, { "answer_id": 375418, "author": "Chaowlert Chaisrichalermpol", "author_id": 239...
2008/12/16
[ "https://Stackoverflow.com/questions/371059", "https://Stackoverflow.com", "https://Stackoverflow.com/users/11394/" ]
371,064
<p>I have unsorted map of key value pairs.</p> <pre><code>input = { "xa" =&gt; "xavalue", "ab" =&gt; "abvalue", "aa" =&gt; "aavalue", "ba" =&gt; "bavalue", } </code></pre> <p>Now I want to sort them by the key and cluster them into sections by the first character of the key. Similar to this:</p> <pre><code>o...
[ { "answer_id": 371234, "author": "ttepasse", "author_id": 46657, "author_profile": "https://Stackoverflow.com/users/46657", "pm_score": 1, "selected": false, "text": "class Hash\n def clustered\n clustered = Hash.new\n sort.each do | key, value |\n first = key[0,1]\n unl...
2008/12/16
[ "https://Stackoverflow.com/questions/371064", "https://Stackoverflow.com", "https://Stackoverflow.com/users/33165/" ]
371,072
<p>I have the code pasted below, which servers as the core of a small ajax application. This was working fine previously, with makewindows actually displaying a popup containing the rsult of artcile_desc. I seem to have an error before that function however, as now only the actual php code is outputted. This is not a p...
[ { "answer_id": 371284, "author": "Jay", "author_id": 41690, "author_profile": "https://Stackoverflow.com/users/41690", "pm_score": 2, "selected": true, "text": "child1.document.write(\"<?php echo htmlspecialchars(json_encode($row2['ARTICLE_DESC']), ENT_QUOTES); ?>\");\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371072", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1246613/" ]
371,079
<p>I have a problem with the jQuery-UI dialog in my ASP.NET form:</p> <pre><code>$("#pnlReceiverDialog").dialog({ autoOpen:false, modal: true, height:220, width:500, resizable :false, overlay: { opacity: 0.5,background: "black" }, buttons: { "Cancel": function() { $(this).dialog("close"); ...
[ { "answer_id": 4193284, "author": "Lars Thorén", "author_id": 372208, "author_profile": "https://Stackoverflow.com/users/372208", "pm_score": 0, "selected": false, "text": "$(\"#ModalId\").parent().appendTo(jQuery(\"form:first\"));\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371079", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,107
<p>Different iPhones have different published memory 4GB, 8GB and 16GB. The touch can have 32GB. My understanding is this is the off-line memory (disk alike). </p> <p>How much actual fast ram is there in the device available for my Cocoa Application? </p> <p>Is there a preconfigured virtual amount?</p>
[ { "answer_id": 3085744, "author": "AnthonyLambert", "author_id": 31762, "author_profile": "https://Stackoverflow.com/users/31762", "pm_score": 5, "selected": true, "text": "iPhone = 128 MB\niPhone 3G = 128 MB\niPhone 3GS = 256 MB\niPhone 4 = 512 MB\niPhone 4S =...
2008/12/16
[ "https://Stackoverflow.com/questions/371107", "https://Stackoverflow.com", "https://Stackoverflow.com/users/31762/" ]
371,109
<p><strong>UPDATE</strong> </p> <p>I have combined various answers from here into a 'definitive' answer on a <a href="https://stackoverflow.com/questions/1747235/weak-event-handler-model-for-use-with-lambdas/1747236#1747236">new question</a>.</p> <p><strong>Original question</strong></p> <p>In my code I have an even...
[ { "answer_id": 371150, "author": "Rory", "author_id": 8479, "author_profile": "https://Stackoverflow.com/users/8479", "pm_score": 3, "selected": false, "text": "public static class Linker\n{\n\n //(Non-lambda version, I'm not comfortable with lambdas:)\n public static EventHandler<...
2008/12/16
[ "https://Stackoverflow.com/questions/371109", "https://Stackoverflow.com", "https://Stackoverflow.com/users/11410/" ]
371,112
<p>Using the CRM views, is there a way to retrieve a list of all of the activities linked to a specific account?</p> <p>I want it to retrieve not only those associated with the account directly, but also those associated with the account's contacts, cases, etc. I am trying to replicate the list generated when you clic...
[ { "answer_id": 398242, "author": "brendan", "author_id": 225, "author_profile": "https://Stackoverflow.com/users/225", "pm_score": 1, "selected": true, "text": "Declare @account_guid varchar(200)\nSelect @account_guid = 'insert some guid here'\n\nDeclare @GUIDS as Table(id varchar(200), ...
2008/12/16
[ "https://Stackoverflow.com/questions/371112", "https://Stackoverflow.com", "https://Stackoverflow.com/users/44938/" ]
371,115
<p>I have a bunch of log files. I need to find out how many times a string occurs in all files.</p> <pre><code>grep -c string * </code></pre> <p>returns</p> <pre><code>... file1:1 file2:0 file3:0 ... </code></pre> <p>Using a pipe I was able to get only files that have one or more occurrences:</p> <pre><code>grep -...
[ { "answer_id": 371124, "author": "Michael Haren", "author_id": 29, "author_profile": "https://Stackoverflow.com/users/29", "pm_score": 5, "selected": false, "text": "grep string * | wc -l\n" }, { "answer_id": 371130, "author": "Bombe", "author_id": 43582, "author_prof...
2008/12/16
[ "https://Stackoverflow.com/questions/371115", "https://Stackoverflow.com", "https://Stackoverflow.com/users/17469/" ]
371,133
<p>I have a class that contains a list of objects. What's the best way to run some code in the class when the list is modified?</p> <pre><code>class MyManagerClass { ArrayList list = new ArrayList(); // will likely be a different collection class private OnItemAddedToList(object o) { // how to call...
[ { "answer_id": 371163, "author": "mookid8000", "author_id": 6560, "author_profile": "https://Stackoverflow.com/users/6560", "pm_score": 1, "selected": false, "text": "CollectionChanged" }, { "answer_id": 371167, "author": "Alex J", "author_id": 27667, "author_profile"...
2008/12/16
[ "https://Stackoverflow.com/questions/371133", "https://Stackoverflow.com", "https://Stackoverflow.com/users/27667/" ]
371,140
<p>I'm using WinRAR SFX module to create an installation, and use its presetup option to run some preliminary tests.</p> <p>Since wscript can only accept vbs file, and not the script itself, I first run "cmd /c echo {...script code...} > setup.vbs", and then I run "wscript setup.vbs". The run of the first cmd command ...
[ { "answer_id": 371198, "author": "Patrick Cuff", "author_id": 7903, "author_profile": "https://Stackoverflow.com/users/7903", "pm_score": 2, "selected": false, "text": "TYPE [script_file] > setup.vbs\n" }, { "answer_id": 393433, "author": "Patrick Cuff", "author_id": 7903...
2008/12/16
[ "https://Stackoverflow.com/questions/371140", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46635/" ]
371,147
<p>So I've got a form in my Rails app which uses a custom FormBuilder to give me some custom field tags</p> <pre><code>&lt;% form_for :staff_member, @staff_member, :builder =&gt; MyFormBuilder do |f| %&gt; [...] &lt;%= render :partial =&gt; "staff_members/forms/personal_details", :locals =&gt; {:f =&gt; f, :skill_...
[ { "answer_id": 405444, "author": "nakajima", "author_id": 39589, "author_profile": "https://Stackoverflow.com/users/39589", "pm_score": 1, "selected": false, "text": "# in the controller\nrender :partial => {\n :f => MyFormBuilder.new(:staff_member, @staff_member, template),\n :skill_g...
2008/12/16
[ "https://Stackoverflow.com/questions/371147", "https://Stackoverflow.com", "https://Stackoverflow.com/users/31582/" ]
371,153
<p>I am using the program below to sort and eventually print out email messages. Some messages may contain attachments or HTML code, which would not be good for printing. Is there an easy way to strip attachments and strip HTML but not the text formatted by HTML from the messages?</p> <pre><code>#!/usr/bin/perl use wa...
[ { "answer_id": 371179, "author": "Nietzche-jou", "author_id": 39892, "author_profile": "https://Stackoverflow.com/users/39892", "pm_score": 1, "selected": false, "text": "perldoc -q html" }, { "answer_id": 371192, "author": "innaM", "author_id": 7498, "author_profile"...
2008/12/16
[ "https://Stackoverflow.com/questions/371153", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1246613/" ]
371,155
<p>I'm using Python 2.5. The DLL I imported is created using the CLR. The DLL function is returning a string. I'm trying to apply "partition" attribute to it. I'm not able to do it. Even the partition is not working. I think "all strings returned from CLR are returned as Unicode".</p>
[ { "answer_id": 371200, "author": "sastanin", "author_id": 25450, "author_profile": "https://Stackoverflow.com/users/25450", "pm_score": 3, "selected": true, "text": "type(yourvar)" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371155", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46646/" ]
371,174
<p>I often find linq being problematic when working with custom collection object. They are often defened as</p> <p>The base collection</p> <pre><code>abstract class BaseCollection&lt;T&gt; : List&lt;T&gt; { ... } </code></pre> <p>the collections is defined as</p> <pre><code>class PruductCollection : BaseCollection...
[ { "answer_id": 371221, "author": "tvanfosson", "author_id": 12950, "author_profile": "https://Stackoverflow.com/users/12950", "pm_score": 4, "selected": true, "text": "IEnumerable<T>" }, { "answer_id": 371223, "author": "bruno conde", "author_id": 31136, "author_profi...
2008/12/16
[ "https://Stackoverflow.com/questions/371174", "https://Stackoverflow.com", "https://Stackoverflow.com/users/24821/" ]
371,181
<p>WSPBuilder</p> <p>Version: 0.9.8.0830 Created by Carsten Keutmann GPL License 2007</p> <p>Install and deploying [MYDLL] Unable to deploy solution Inner exception(1): This solution contains one or more assemblies targeted for the global assembly cache. You should use a strong name for any assembly that will be in t...
[ { "answer_id": 371215, "author": "alexandrul", "author_id": 19756, "author_profile": "https://Stackoverflow.com/users/19756", "pm_score": 1, "selected": false, "text": "Delay sign only" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371181", "https://Stackoverflow.com", "https://Stackoverflow.com/users/41291/" ]
371,183
<p>I'm developing an HTML newsletter system using PHP &amp; PEAR. It sends out the emails fine.</p> <p>However I cannot force Apple Mail to reload images from the server. I have tried:</p> <ul> <li>Restarting Mail</li> <li>Clear ~/Library/MailDownloads </li> <li>Clear ~/Library/Cache/Mail</li> <li>Empty Safari cache<...
[ { "answer_id": 485467, "author": "Ates Goral", "author_id": 23501, "author_profile": "https://Stackoverflow.com/users/23501", "pm_score": 2, "selected": false, "text": "<img src=\"http://example.com/images/hello.png?343882881923\"/>\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371183", "https://Stackoverflow.com", "https://Stackoverflow.com/users/2725/" ]
371,203
<p>Can you recommend any tool to migrate sources (with history) from TFS to SVN?</p>
[ { "answer_id": 7591528, "author": "Benjamin", "author_id": 186606, "author_profile": "https://Stackoverflow.com/users/186606", "pm_score": 1, "selected": false, "text": "public Tfs2SvnConverter(string tfsPath, string svnPath, bool createSvnFileRepository, int fromChangeset, string workin...
2008/12/16
[ "https://Stackoverflow.com/questions/371203", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,204
<p>I am writing a managed custom action. I am using the DTF Framework from Windows Installer Xml to wrap the managed dll into a usable CA dll. The CA does what it is supposed to, but I am still having trouble with error handling:</p> <pre><code>Dim record As New Record(1) ' Field 0 intentionally left blank ' Field 1 ...
[ { "answer_id": 654840, "author": "Community", "author_id": -1, "author_profile": "https://Stackoverflow.com/users/-1", "pm_score": -1, "selected": false, "text": " private void _handleSqlException(SqlException ex)\n {\n StringBuilder errorMessage = new StringBuilder();\n ...
2008/12/16
[ "https://Stackoverflow.com/questions/371204", "https://Stackoverflow.com", "https://Stackoverflow.com/users/23369/" ]
371,209
<p>How can I blur a whole page using CSS? Other elements such as images are allowed.</p>
[ { "answer_id": 371257, "author": "Aron Rotteveel", "author_id": 11568, "author_profile": "https://Stackoverflow.com/users/11568", "pm_score": 4, "selected": false, "text": "/* DIV-element with black background and 50% opacity set */\ndiv.overlay {\n position: absolute;\n width: 100...
2008/12/16
[ "https://Stackoverflow.com/questions/371209", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,227
<p>Is there anyway to change the ASPNETDB and also using SQLExpress (2005) user instance ?</p> <p>I have changed my web.config's connectin string to </p> <pre><code>&lt;remove name="LocalSqlServer"/&gt; &lt;add name="LocalSqlServer" connectionString="Data Source=.\SQLEXPRESS; AttachDbFilename=|DataDirectory...
[ { "answer_id": 371294, "author": "Zhaph - Ben Duguid", "author_id": 33051, "author_profile": "https://Stackoverflow.com/users/33051", "pm_score": 2, "selected": false, "text": "C:\\WINDOWS\\Microsoft.NET\\Framework\\v2.0.50727\\aspnet_regsql.exe\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371227", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,237
<p>In F#, you can generate a set of numbers, just by saying [1..100].</p> <p>I want to do something similar in C#. This is what I have come up with so far:</p> <pre><code>public static int[] To(this int start, int end) { var result = new List&lt;int&gt;(); for(int i = start; i &lt;= end; i++) result....
[ { "answer_id": 371251, "author": "lc.", "author_id": 44853, "author_profile": "https://Stackoverflow.com/users/44853", "pm_score": 0, "selected": false, "text": "Set(1,100)" }, { "answer_id": 371273, "author": "Christoffer Lette", "author_id": 11808, "author_profile":...
2008/12/16
[ "https://Stackoverflow.com/questions/371237", "https://Stackoverflow.com", "https://Stackoverflow.com/users/36687/" ]
371,246
<p>I have a very simple Update statement that will update mail server settings and network credentials info... Query works fine when I run it in Access but C# keeps giving me the error stating that my SQL Syntax is wrong ... I have a dataaccess layer (dal class) and Update instance method pasted belows ... But the prob...
[ { "answer_id": 371258, "author": "Marc Gravell", "author_id": 23354, "author_profile": "https://Stackoverflow.com/users/23354", "pm_score": 0, "selected": false, "text": "string.Format" }, { "answer_id": 371281, "author": "Tony Peterson", "author_id": 26140, "author_p...
2008/12/16
[ "https://Stackoverflow.com/questions/371246", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,266
<p>I've found this piece of code on <a href="http://www.koders.com/csharp/fidACD7502AA845419FF59B7DA804D3C8FCA0E40138.aspx?s=basecodegeneratorwithsite#L76" rel="nofollow noreferrer">Koders</a>:</p> <pre><code>private ServiceProvider SiteServiceProvider { get { if (serviceProvider == null) { ...
[ { "answer_id": 371310, "author": "Marc Gravell", "author_id": 23354, "author_profile": "https://Stackoverflow.com/users/23354", "pm_score": 3, "selected": false, "text": "SomeType provider = SomeFactory.CreateProvider();\nif(provider == null) // damn!! no factory implementation loaded......
2008/12/16
[ "https://Stackoverflow.com/questions/371266", "https://Stackoverflow.com", "https://Stackoverflow.com/users/4918/" ]
371,268
<p>using the Code Snippet for sending email in VB.Net I have successfully sent an email from my local machine, but when I Upload it to my server I get a message that the email failed. We have a national relay server that is running SMTP and I am pointed at that server in both instances. The only differance that jump ...
[ { "answer_id": 371309, "author": "J c", "author_id": 25837, "author_profile": "https://Stackoverflow.com/users/25837", "pm_score": 3, "selected": true, "text": "telnet RelayServerAddress 25\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371268", "https://Stackoverflow.com", "https://Stackoverflow.com/users/38349/" ]
371,272
<p>Rails introduced some core extensions to Ruby like <code>3.days.from_now</code> which returns, as you'd expect a date three days in the future. With extension methods in C# we can now do something similar:</p> <pre><code>static class Extensions { public static TimeSpan Days(this int i) { return new ...
[ { "answer_id": 371291, "author": "mackenir", "author_id": 25457, "author_profile": "https://Stackoverflow.com/users/25457", "pm_score": 3, "selected": false, "text": "TimeSpan.FromSeconds(4).FromNow()\n" }, { "answer_id": 371360, "author": "Andrew Hare", "author_id": 3421...
2008/12/16
[ "https://Stackoverflow.com/questions/371272", "https://Stackoverflow.com", "https://Stackoverflow.com/users/27782/" ]
371,279
<p>I've got the following Linq2Sql and it's doing more than one round trip for my 'SELECT' statement. I'm not sure why. First the code, then the explanation:-</p> <pre><code>from p in db.Questions select new Models.Question { Title = p.Title, TagList = (from t in p.QuestionTags select t.Tag.Name...
[ { "answer_id": 371297, "author": "Marc Gravell", "author_id": 23354, "author_profile": "https://Stackoverflow.com/users/23354", "pm_score": 2, "selected": false, "text": "DECLARE @foo varchar(max)\nSET @foo = ''\nSELECT @foo = @foo + [SomeColumn] + ',' -- CSV\nFROM [SomeTable]\nWHERE -- ...
2008/12/16
[ "https://Stackoverflow.com/questions/371279", "https://Stackoverflow.com", "https://Stackoverflow.com/users/30674/" ]
371,300
<p>In my domain model I have an abstract class CommunicationChannelSpecification, which has child classes like FTPChannelSpecification, EMailChannelSpecification and WebserviceChannelSpecification. Now I want to create an HQL query which contains a where clause that narrows down the result to certain types of channel s...
[ { "answer_id": 371343, "author": "bangroot", "author_id": 45693, "author_profile": "https://Stackoverflow.com/users/45693", "pm_score": 4, "selected": true, "text": "from CommunicationChannelSpecifications spec where spec.class in (?)\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371300", "https://Stackoverflow.com", "https://Stackoverflow.com/users/414376/" ]
371,302
<p>I would like to implement a post build event that performs the following actions</p> <ol> <li>A relative path copy of the DLL output (1 file, not all the debug jazz)</li> <li>A register the output DLL to GAC</li> </ol> <p>How is this done?</p>
[ { "answer_id": 371332, "author": "Dirk Vollmar", "author_id": 40347, "author_profile": "https://Stackoverflow.com/users/40347", "pm_score": 5, "selected": true, "text": "copy $(TargetPath) $(TargetDir)..\\..\\someFolder\\myoutput.dll\nregasm $(TargetPath) \n" }, { "answer_id": 37...
2008/12/16
[ "https://Stackoverflow.com/questions/371302", "https://Stackoverflow.com", "https://Stackoverflow.com/users/41291/" ]
371,320
<p>I have a YouTube's player in the webpage. I need to change the video played by this player dynamicaly.</p> <p>This is (relatively) easy using YouTube's chromeless player. It has method <a href="http://code.google.com/apis/youtube/chromeless_player_reference.html#loadVideoById" rel="noreferrer"><code>loadVideoById()...
[ { "answer_id": 5130725, "author": "asper", "author_id": 636047, "author_profile": "https://Stackoverflow.com/users/636047", "pm_score": 1, "selected": false, "text": " * The mediaContentUrl must be a fully qualified YouTube player URL in the format http://www.youtube.com/e/VIDEO_ID. I...
2008/12/16
[ "https://Stackoverflow.com/questions/371320", "https://Stackoverflow.com", "https://Stackoverflow.com/users/22920/" ]
371,322
<p>I have to read invoice ascii files that are structured in a really convoluted way, for example:</p> <pre><code>55651108 3090617.10.0806:46:32101639Example Company Construction Company Example Road. 9 9524 Example City </code></pre> <p>There's actually additional stuff in there, bu...
[ { "answer_id": 371344, "author": "mat", "author_id": 42083, "author_profile": "https://Stackoverflow.com/users/42083", "pm_score": 0, "selected": false, "text": "unpack" }, { "answer_id": 371383, "author": "S.Lott", "author_id": 10661, "author_profile": "https://Stack...
2008/12/16
[ "https://Stackoverflow.com/questions/371322", "https://Stackoverflow.com", "https://Stackoverflow.com/users/13466/" ]
371,328
<p>Given the following class</p> <pre><code>public class Foo { public int FooId { get; set; } public string FooName { get; set; } public override bool Equals(object obj) { Foo fooItem = obj as Foo; if (fooItem == null) { return false; } return fooI...
[ { "answer_id": 371348, "author": "Marc Gravell", "author_id": 23354, "author_profile": "https://Stackoverflow.com/users/23354", "pm_score": 12, "selected": true, "text": "HashSet<T>" }, { "answer_id": 371350, "author": "Trap", "author_id": 7839, "author_profile": "htt...
2008/12/16
[ "https://Stackoverflow.com/questions/371328", "https://Stackoverflow.com", "https://Stackoverflow.com/users/2469/" ]
371,329
<p>I've several textboxes. I would like to make the Enter button act as Tab. So that when I will be in one textbox, pressing Enter will move me to the next one. Could you please tell me how to implement this approach without adding any code inside textbox class (no override and so on if possible)?</p>
[ { "answer_id": 371351, "author": "arul", "author_id": 15409, "author_profile": "https://Stackoverflow.com/users/15409", "pm_score": -1, "selected": false, "text": "// on enter event handler\nparentForm.GetNextControl().Focus();\n" }, { "answer_id": 371362, "author": "JFV", ...
2008/12/16
[ "https://Stackoverflow.com/questions/371329", "https://Stackoverflow.com", "https://Stackoverflow.com/users/38940/" ]
371,333
<p>What is the Ruby idiomatic way for retrieving a single character from a string as a one-character string? There is the <code>str[n]</code> method of course, but (as of Ruby 1.8) it returns a character code as a fixnum, not a string. How do you get to a single-character string?</p>
[ { "answer_id": 371341, "author": "Thiago Arrais", "author_id": 17801, "author_profile": "https://Stackoverflow.com/users/17801", "pm_score": 0, "selected": false, "text": "'abc'[1].chr # => \"b\"\n" }, { "answer_id": 371342, "author": "Thiago Arrais", "author_id": 17801, ...
2008/12/16
[ "https://Stackoverflow.com/questions/371333", "https://Stackoverflow.com", "https://Stackoverflow.com/users/17801/" ]
371,337
<p>An image set as the background of a DIV is displayed in IE, but not in Firefox.</p> <p>CSS example:</p> <pre><code>div.something { background:transparent url(../images/table_column.jpg) repeat scroll 0 0; } </code></pre> <p>(The issue is described in many places but haven't seen any conclusive explanation or fix....
[ { "answer_id": 371367, "author": "Kablam", "author_id": 42389, "author_profile": "https://Stackoverflow.com/users/42389", "pm_score": 0, "selected": false, "text": "div.something {\nbackground: transparent url(../images/table_column.jpg);\n}\n" }, { "answer_id": 371368, "auth...
2008/12/16
[ "https://Stackoverflow.com/questions/371337", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46665/" ]
371,371
<p>I'd like a C library that can serialize my data structures to disk, and then load them again later. It should accept arbitrarily nested structures, possibly with circular references.</p> <p>I presume that this tool would need a configuration file describing my data structures. The library is allowed to use code gen...
[ { "answer_id": 372113, "author": "dmckee --- ex-moderator kitten", "author_id": 2509, "author_profile": "https://Stackoverflow.com/users/2509", "pm_score": 3, "selected": false, "text": "typedef" }, { "answer_id": 15064199, "author": "Amith Chinthaka", "author_id": 210680...
2008/12/16
[ "https://Stackoverflow.com/questions/371371", "https://Stackoverflow.com", "https://Stackoverflow.com/users/11951/" ]
371,372
<p>I am using ruby on rails with a MySQL backend. I have a table called notes and here is the migration I use to create it:</p> <pre><code>def self.up create_table(:notes, :options =&gt; 'ENGINE=MyISAM') do |t| t.string :title t.text :body t.timestamps end execute "alter table notes ADD FULLTEXT(t...
[ { "answer_id": 371408, "author": "Adam Bellaire", "author_id": 21632, "author_profile": "https://Stackoverflow.com/users/21632", "pm_score": 4, "selected": true, "text": "SELECT * FROM notes WHERE MATCH(title, body) AGAINST('test' IN BOOLEAN MODE)\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371372", "https://Stackoverflow.com", "https://Stackoverflow.com/users/5004/" ]
371,378
<p>Working with VS.NET 2008, output type Class Library, Target Framework .NET 2.0</p> <p>I've come up with a simplified scenario to ask this question.</p> <p>I have a <code>Button</code> user control, its a simple panel with a single big button on it.</p> <p>I want to create a <code>RedButton</code> control that ext...
[ { "answer_id": 371459, "author": "Jacob Adams", "author_id": 32518, "author_profile": "https://Stackoverflow.com/users/32518", "pm_score": 0, "selected": false, "text": "btnTheButton.BackGround=Color.Red; \n" }, { "answer_id": 6429536, "author": "AndyClaw", "author_id": 5...
2008/12/16
[ "https://Stackoverflow.com/questions/371378", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,384
<p>What is the best way to print stuff from c#/.net?</p> <p>The question is in regard to single pages as well as to reports containing lots of pages. </p> <p>It would be great to get a list of the most common printing libs containing the main features and gotchas of each of them.</p> <p>[Update] for standard windows...
[ { "answer_id": 371399, "author": "Stephen Wrighton", "author_id": 7516, "author_profile": "https://Stackoverflow.com/users/7516", "pm_score": 4, "selected": true, "text": "Sub MyMethod()\n Dim x as New PrintDocument\n AddHandler x.PrintPage, AddressOf printDoc_PrintPage\n x.P...
2008/12/16
[ "https://Stackoverflow.com/questions/371384", "https://Stackoverflow.com", "https://Stackoverflow.com/users/7021/" ]
371,386
<p>Having an odd problems with ASP MVC deployed on IIS6 (Windows 2003). I've simplified the controller code to the below;</p> <pre><code>&lt;AcceptVerbs(HttpVerbs.Get)&gt; _ Public Function CloseBatches() As ActionResult ViewData("Title") = "Close Batches" ViewData("Message") = Session("Message") Return Vi...
[ { "answer_id": 371433, "author": "Craig Stuntz", "author_id": 7714, "author_profile": "https://Stackoverflow.com/users/7714", "pm_score": 2, "selected": false, "text": "<AcceptVerbs(HttpVerbs.Get)> _\nPublic Function CloseBatches() As ActionResult\n ViewData(\"Title\") = \"Close Batch...
2008/12/16
[ "https://Stackoverflow.com/questions/371386", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,404
<p>I have an Access 2003 file that contains 200 queries, and I want to print out their representation in SQL. I can use Design View to look at each query and cut and paste it to a file, but that's tedious. Also, I may have to do this again on other Access files, so I definitely want to write a program to do it.</p> <p...
[ { "answer_id": 371811, "author": "Mark Bell", "author_id": 43140, "author_profile": "https://Stackoverflow.com/users/43140", "pm_score": 4, "selected": true, "text": "OleDbConnection conn = new OleDbConnection(connectionString);\nconn.Open();\n\nDataTable queries = conn.GetOleDbSchemaTab...
2008/12/16
[ "https://Stackoverflow.com/questions/371404", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1121861/" ]
371,417
<p>I'm working on mapping two objects in .NET. </p> <p>I would like to be able to print the items in the properties list from the Object Browser window in Visual Studio 2008. Is there a way to print that information out to the console?</p> <p>If that is not possible, what is a good method to print a general definit...
[ { "answer_id": 371494, "author": "R. Martinho Fernandes", "author_id": 46642, "author_profile": "https://Stackoverflow.com/users/46642", "pm_score": 2, "selected": true, "text": "System.Reflection" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371417", "https://Stackoverflow.com", "https://Stackoverflow.com/users/283/" ]
371,418
<p>I've recently found out about protocol buffers and was wondering if they could be applied to my specific problem.</p> <p>Basically I have some CSV data that I need to convert to a more compact format for storage as some of the files are several gig. </p> <p>Each field in the CSV has a header, and there are only tw...
[ { "answer_id": 371508, "author": "Jon Skeet", "author_id": 22656, "author_profile": "https://Stackoverflow.com/users/22656", "pm_score": 4, "selected": true, "text": "message CsvFile {\n repeated CsvHeader header = 1;\n repeated CsvRow row = 2;\n}\n\nmessage CsvHeader {\n requir...
2008/12/16
[ "https://Stackoverflow.com/questions/371418", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3820/" ]
371,419
<p>I have a function that expects real numbers (either integers or floats) as its input, and I'm trying to validate this input before doing mathematical operations on it.</p> <p>My first instinct is to cast inputs as floats from within a try-except block.</p> <pre><code>try: myinput = float(input) except: raise...
[ { "answer_id": 371436, "author": "Mapad", "author_id": 28165, "author_profile": "https://Stackoverflow.com/users/28165", "pm_score": 2, "selected": false, "text": "assert" }, { "answer_id": 371573, "author": "Brian", "author_id": 9493, "author_profile": "https://Stack...
2008/12/16
[ "https://Stackoverflow.com/questions/371419", "https://Stackoverflow.com", "https://Stackoverflow.com/users/8027/" ]
371,422
<p>I'm looking to build a query that will use the non-clustered indexing plan on a street address field that is built with a non-clustered index. The problem I'm having is that if I'm searching for a street address I will most likely be using the 'like' eval function. I'm thinking that using this function will cause ...
[ { "answer_id": 371447, "author": "Tomalak", "author_id": 18771, "author_profile": "https://Stackoverflow.com/users/18771", "pm_score": 1, "selected": false, "text": "Address LIKE 'Blah%'" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371422", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1491425/" ]
371,426
<p>When running a web application project, at seemingly random times a page may fail with a CS0433 error: type exists in multiple DLL's. The DLL's are all generated DLL's residing in the "Temporary ASP.NET Files" directory.</p>
[ { "answer_id": 714320, "author": "Mike Powell", "author_id": 205, "author_profile": "https://Stackoverflow.com/users/205", "pm_score": 2, "selected": false, "text": "compilation batch=\"false\"" }, { "answer_id": 10241054, "author": "Amrinder Singh", "author_id": 1345731,...
2008/12/16
[ "https://Stackoverflow.com/questions/371426", "https://Stackoverflow.com", "https://Stackoverflow.com/users/6902/" ]
371,439
<p>Normally when you update an object in linq2sql you get the object from a datacontext and use the same datacontext to save the object, right?</p> <p>What's the best way to update a object that hasn't been retreived by that datacontext that you use to perform the save operation, i.e. I'm using flourinefx to pass data...
[ { "answer_id": 371493, "author": "Marc Gravell", "author_id": 23354, "author_profile": "https://Stackoverflow.com/users/23354", "pm_score": 4, "selected": true, "text": "ctx.Customers.Attach(customer); // optional bool to treat as modified\n" }, { "answer_id": 725967, "author...
2008/12/16
[ "https://Stackoverflow.com/questions/371439", "https://Stackoverflow.com", "https://Stackoverflow.com/users/40939/" ]
371,445
<p>We have followed the approach below to get the data from multiple results using LINQ To SQL</p> <pre><code>CREATE PROCEDURE dbo.GetPostByID ( @PostID int ) AS SELECT * FROM Posts AS p WHERE p.PostID = @PostID SELECT c.* FROM Categories AS c JOIN PostCategories A...
[ { "answer_id": 460222, "author": "Pure.Krome", "author_id": 30674, "author_profile": "https://Stackoverflow.com/users/30674", "pm_score": 3, "selected": false, "text": "IEnumerable<Post> posts;\nIEnumerable<Category> categories;\n\nusing (BlogContext ctx = new BlogContext(...))\n{\n c...
2008/12/16
[ "https://Stackoverflow.com/questions/371445", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,455
<p>I have a c# class which uses the WindowsIdentity namespace to return details of the current Active Directory user. This is accessible through a web part on SPS and sure enough returns the desired record values specific to that user. </p> <p>I have a classic ASP application which I would like to have inherit this f...
[ { "answer_id": 460222, "author": "Pure.Krome", "author_id": 30674, "author_profile": "https://Stackoverflow.com/users/30674", "pm_score": 3, "selected": false, "text": "IEnumerable<Post> posts;\nIEnumerable<Category> categories;\n\nusing (BlogContext ctx = new BlogContext(...))\n{\n c...
2008/12/16
[ "https://Stackoverflow.com/questions/371455", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,464
<p>I have a non-visual component which manages other visual controls. </p> <p>I need to have a reference to the form that the component is operating on, but i don't know how to get it.</p> <p>I am unsure of adding a constructor with the parent specified as control, as i want the component to work by just being dropp...
[ { "answer_id": 371559, "author": "Rob Prouse", "author_id": 30827, "author_profile": "https://Stackoverflow.com/users/30827", "pm_score": 3, "selected": false, "text": "public Form ParentForm\n{\n get { return GetParentForm( this.Parent ); }\n}\n\nprivate Form GetParentForm( Control p...
2008/12/16
[ "https://Stackoverflow.com/questions/371464", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1500/" ]
371,468
<p>I'm using jQuery UI's draggable and droppable libraries in a simple ASP.NET proof of concept application. This page uses the ASP.NET AJAX UpdatePanel to do partial page updates. The page allows a user to drop an item into a trashcan div, which will invoke a postback that deletes a record from the database, then rebi...
[ { "answer_id": 516534, "author": "CodeChef", "author_id": 21786, "author_profile": "https://Stackoverflow.com/users/21786", "pm_score": 4, "selected": true, "text": "function IESafeOffsetParent(elem)\n{\n try\n {\n return elem.offsetParent;\n }\n catch(e)\n { ...
2008/12/16
[ "https://Stackoverflow.com/questions/371468", "https://Stackoverflow.com", "https://Stackoverflow.com/users/21786/" ]
371,471
<p>I am trying to get some <code>JavaScript</code> to programmatically adjust a HTML <code>img</code> tag's width to display various sized images correctly.</p> <p>I have a fixed width <code>img</code> tag at <code>800px</code> to display an image, this is the max width.</p> <p>If the image is wider then <code>800px<...
[ { "answer_id": 371504, "author": "bezmax", "author_id": 43677, "author_profile": "https://Stackoverflow.com/users/43677", "pm_score": 2, "selected": false, "text": ".dynamic_img {\n width: expression(document.body.clientWidth <= 800? \"auto\" : \"800px\");\n max-width: 800px; //For...
2008/12/16
[ "https://Stackoverflow.com/questions/371471", "https://Stackoverflow.com", "https://Stackoverflow.com/users/14260/" ]
371,490
<p>Does anyone know how to turn this string: "Smith, John R"<br> Into this string: "jsmith" ?</p> <p>I need to lowercase everything with lower()<br> Find where the comma is and track it's integer location value<br> Get the first character after that comma and put it in front of the string<br> Then get the entire last ...
[ { "answer_id": 386658, "author": "Gabe", "author_id": 48143, "author_profile": "https://Stackoverflow.com/users/48143", "pm_score": 1, "selected": false, "text": "with name_list as\n (select ' Parisi, Kenneth R' name from dual)\nselect name\n -- There may be a space after the com...
2008/12/16
[ "https://Stackoverflow.com/questions/371490", "https://Stackoverflow.com", "https://Stackoverflow.com/users/42229/" ]
371,497
<p>Is there any way (in Javascript) to download a remote website (i.e. like with Curl), read it into a string variable and further process it?</p>
[ { "answer_id": 371524, "author": "Vinko Vrsalovic", "author_id": 5190, "author_profile": "https://Stackoverflow.com/users/5190", "pm_score": 3, "selected": false, "text": " var xhReq = createXMLHttpRequest();\n xhReq.open(\"GET\", \"page.html\", true);\n xhReq.onreadystatechange = onResp...
2008/12/16
[ "https://Stackoverflow.com/questions/371497", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,503
<p>Why is ++i is l-value and i++ not?</p>
[ { "answer_id": 371533, "author": "Renaud Bompuis", "author_id": 3811, "author_profile": "https://Stackoverflow.com/users/3811", "pm_score": 2, "selected": false, "text": "C" }, { "answer_id": 371540, "author": "LeppyR64", "author_id": 16592, "author_profile": "https:/...
2008/12/16
[ "https://Stackoverflow.com/questions/371503", "https://Stackoverflow.com", "https://Stackoverflow.com/users/22076/" ]
371,513
<p>We have a database that persist our metadata and data.</p> <p>Our metadata is produced buy a dedicated team, using a Web application on the development server, and is a critical part of our application.</p> <p>Then the customer generates data according to this metadata.</p> <p>We already version the database schema,...
[ { "answer_id": 371533, "author": "Renaud Bompuis", "author_id": 3811, "author_profile": "https://Stackoverflow.com/users/3811", "pm_score": 2, "selected": false, "text": "C" }, { "answer_id": 371540, "author": "LeppyR64", "author_id": 16592, "author_profile": "https:/...
2008/12/16
[ "https://Stackoverflow.com/questions/371513", "https://Stackoverflow.com", "https://Stackoverflow.com/users/2797/" ]
371,534
<p>I'm running into an issue with an ASP.NET 2.0 application. Our network folks just upped our security, and now I get the floowing error whenever I try to access the app:</p> <blockquote> <p>"This implementation is not part of the Windows Platform FIPS validated cryptographic algorithms."</p> </blockquote> <p>I'v...
[ { "answer_id": 380866, "author": "kay.herzam", "author_id": 47093, "author_profile": "https://Stackoverflow.com/users/47093", "pm_score": 2, "selected": false, "text": "<machineKey \n validationKey=\"AutoGenerate,IsolateApps\"\n decryptionKey=\"AutoGenerate,IsolateApps\"\n validation=...
2008/12/16
[ "https://Stackoverflow.com/questions/371534", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46692/" ]
371,546
<pre><code>select Table1.colID, Table1.colName, (select * from Table2 where Table2.colID = Table1.colID) as NestedRows from Table1 </code></pre> <p>The above query gives you this error: Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, &lt;, &lt;= , >, >= or when the subquery...
[ { "answer_id": 371575, "author": "DCNYAM", "author_id": 30419, "author_profile": "https://Stackoverflow.com/users/30419", "pm_score": 0, "selected": false, "text": "SELECT tab1.colID, tab1.colName, tab2.Column1, tab2.column2\nFROM dbo.Table1 AS tab1\n INNER JOIN dbo.Table2 AS tab2\n ...
2008/12/16
[ "https://Stackoverflow.com/questions/371546", "https://Stackoverflow.com", "https://Stackoverflow.com/users/29519/" ]
371,551
<p>When I try to build my projects in Visual Studio 2008, web sites won't build anymore, they hang on this stage: </p> <pre><code>------ Build started: Project: C:\...\Web\, Configuration: Debug Any CPU ------ Validating Web Site Building directory '/Web/Admin/Secure/'. Building directory '/Web/Admin/'. Building direc...
[ { "answer_id": 371655, "author": "NikolaiDante", "author_id": 39643, "author_profile": "https://Stackoverflow.com/users/39643", "pm_score": 3, "selected": false, "text": "C:\\WINDOWS\\Microsoft.NET\\Framework\\<Framework Version>\\Temporary ASP.NET Files\n" }, { "answer_id": 1195...
2008/12/16
[ "https://Stackoverflow.com/questions/371551", "https://Stackoverflow.com", "https://Stackoverflow.com/users/33137/" ]
371,554
<p>I have the following code:</p> <pre><code>if ($_POST['submit'] == "Next") { foreach($_POST['info'] as $key =&gt; $value) { echo $value; } } </code></pre> <p>How do I get the foreach function to start from the 2nd key in the array?</p>
[ { "answer_id": 371560, "author": "Irmantas", "author_id": 43182, "author_profile": "https://Stackoverflow.com/users/43182", "pm_score": 2, "selected": false, "text": "if ($key == 0) //or whatever\n continue;\n" }, { "answer_id": 371563, "author": "Tom Haigh", "author_id...
2008/12/16
[ "https://Stackoverflow.com/questions/371554", "https://Stackoverflow.com", "https://Stackoverflow.com/users/37667/" ]
371,555
<p>My team is developing a large java application which extensively queries a MySQL database (in different classes and modules). I'd like to known if there is a pattern that allows me to be notified at compile time if there are queries that refer to a wrong table structure (for instance if I remove or add a field on a...
[ { "answer_id": 532425, "author": "Community", "author_id": -1, "author_profile": "https://Stackoverflow.com/users/-1", "pm_score": 1, "selected": false, "text": "select count(*) from test where name = null\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371555", "https://Stackoverflow.com", "https://Stackoverflow.com/users/17934/" ]
371,571
<p>I'm running a simple batch file which is generated by a vbscript to delete individual files, however when I execute it, it is deleting entire subdirectories. Anyone have any ideas on this? Below is the batch file. </p> <pre><code>rem 2008-12-15D:\DP-Production\Administrative\BUSINESS\FileLink del D:\DP-Production...
[ { "answer_id": 371594, "author": "Lasse V. Karlsen", "author_id": 267, "author_profile": "https://Stackoverflow.com/users/267", "pm_score": 3, "selected": false, "text": "del D:\\DP-Production\\Administrative\\BUSINESS\\FileLink\\Mail\\ BOBBSS LIST COUNT - DRIBOX 2008-06 ejs.msg /q/\...
2008/12/16
[ "https://Stackoverflow.com/questions/371571", "https://Stackoverflow.com", "https://Stackoverflow.com/users/18853/" ]
371,591
<p>I am trying to get simple jQuery to execute on my Content page with no luck below is what I am trying to do:</p> <pre><code>&lt;asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server"&gt; &lt;script src="../../Scripts/jquery-1.2.6.js" type="text/javascript"&gt;&lt;/script&gt; &lt;script t...
[ { "answer_id": 371603, "author": "Kieron", "author_id": 5791, "author_profile": "https://Stackoverflow.com/users/5791", "pm_score": 6, "selected": true, "text": "<script src=\"<%= Url.Content (\"~/Scripts/jquery-1.2.6.js\") %>\" type=\"text/javascript\"></script>\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371591", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3111/" ]
371,599
<p>In my app have a window splitted by a QSplitter, and I need to remove an widget. </p> <p>How can I do that? I can't find useful methods </p>
[ { "answer_id": 371649, "author": "Caleb Huitt - cjhuitt", "author_id": 9876, "author_profile": "https://Stackoverflow.com/users/9876", "pm_score": 2, "selected": false, "text": "setParent( NULL )" }, { "answer_id": 17196052, "author": "thrichard", "author_id": 1506390, ...
2008/12/16
[ "https://Stackoverflow.com/questions/371599", "https://Stackoverflow.com", "https://Stackoverflow.com/users/39339/" ]
371,604
<p>Following on from <a href="https://stackoverflow.com/questions/371418/can-you-represent-csv-data-in-googles-protocol-buffer-format">this</a> question, what would be the best way to represent a System.Decimal object in a Protocol Buffer?</p>
[ { "answer_id": 371690, "author": "Jon Skeet", "author_id": 22656, "author_profile": "https://Stackoverflow.com/users/22656", "pm_score": 3, "selected": false, "text": "message Decimal {\n\n // 96-bit mantissa broken into two chunks\n optional uint64 mantissa_msb = 1;\n optional ...
2008/12/16
[ "https://Stackoverflow.com/questions/371604", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3820/" ]
371,606
<p>i am trying to fix a site I am helping a friend with, and in IE it is displaying the navigation bar like it is stacking on top of each other.</p> <p>Is that a part of the double float bug, I tried adding display:inline, but I still have that problem.</p> <p>URL: <a href="http://www.flanels.com/RadiantecHOME.html" ...
[ { "answer_id": 371690, "author": "Jon Skeet", "author_id": 22656, "author_profile": "https://Stackoverflow.com/users/22656", "pm_score": 3, "selected": false, "text": "message Decimal {\n\n // 96-bit mantissa broken into two chunks\n optional uint64 mantissa_msb = 1;\n optional ...
2008/12/16
[ "https://Stackoverflow.com/questions/371606", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,608
<p>GCC 3.4.5 (MinGW version) produces a warning: parameter has incomplete type for line 2 of the following C code:</p> <pre><code>struct s; typedef void (* func_t)(struct s _this); struct s { func_t method; int dummy_member; }; </code></pre> <p>Is there a way to fix this (or at least hide the warning) without changin...
[ { "answer_id": 371870, "author": "HUAGHAGUAH", "author_id": 38809, "author_profile": "https://Stackoverflow.com/users/38809", "pm_score": -1, "selected": false, "text": "typedef void (*func_t)(void*);\n" }, { "answer_id": 371962, "author": "Adam Rosenfield", "author_id": ...
2008/12/16
[ "https://Stackoverflow.com/questions/371608", "https://Stackoverflow.com", "https://Stackoverflow.com/users/48015/" ]
371,637
<p>I am trying to use the following code, which I have not been able to test yet, because I get the following errors:</p> <pre><code>#!/usr/bin/perl use warnings; use strict; use Text::Wrap; use Mail::Box::Manager; use HTML::Obliterate qw(extirpate_html); open (MYFILE, '&gt;&gt;data.txt'); binmode(MYFILE, ':encoding...
[ { "answer_id": 371658, "author": "Tuminoid", "author_id": 40657, "author_profile": "https://Stackoverflow.com/users/40657", "pm_score": 3, "selected": true, "text": "print MYFILE wrap(\"\", \"\", <<\"\");\n" }, { "answer_id": 371772, "author": "Tuminoid", "author_id": 406...
2008/12/16
[ "https://Stackoverflow.com/questions/371637", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1246613/" ]
371,638
<p>I'm in the design stage for an app which will utilize a REST web service and sort of have a dilemma in as far as using asynchronous vs synchronous vs threading. Here's the scenario.</p> <p>Say you have three options to drill down into, each one having its own REST-based resource. I can either lazily load each one w...
[ { "answer_id": 373906, "author": "Kendall Helmstetter Gelner", "author_id": 6330, "author_profile": "https://Stackoverflow.com/users/6330", "pm_score": -1, "selected": false, "text": "- (NSArray *)users {\n if(users == nil && !didLaunchRequestAlready )\n users = do_async_reque...
2008/12/16
[ "https://Stackoverflow.com/questions/371638", "https://Stackoverflow.com", "https://Stackoverflow.com/users/40882/" ]
371,644
<p>In a mysqli prepared statement, a NULL gets turned into '' (in the case of a string) or 0 (in the case of an integer). I would like to store it as a true NULL. Is there any way of doing this?</p>
[ { "answer_id": 371782, "author": "Tomalak", "author_id": 18771, "author_profile": "https://Stackoverflow.com/users/18771", "pm_score": 2, "selected": false, "text": "mysqli_stmt::bind_param" }, { "answer_id": 1235102, "author": "Community", "author_id": -1, "author_pr...
2008/12/16
[ "https://Stackoverflow.com/questions/371644", "https://Stackoverflow.com", "https://Stackoverflow.com/users/1902010/" ]
371,656
<p>Are there any O/R mappers out there that will automatically create or modify the database schema when you update the business objects? After looking around it seems that most libraries work the other way by creating business object from the database schema.</p> <p>The reason I'd like to have that capability is that...
[ { "answer_id": 374028, "author": "faulty", "author_id": 20007, "author_profile": "https://Stackoverflow.com/users/20007", "pm_score": 2, "selected": true, "text": "namespace MyApps.Migrations\n{\n public class _001_Initial : Migration\n {\n public override void Up()\n ...
2008/12/16
[ "https://Stackoverflow.com/questions/371656", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46703/" ]
371,702
<p>I have made some code which exports some details of a journal article to a reference manager called <a href="http://www.endnote.com/enhome.asp" rel="nofollow noreferrer">Endnote</a></p> <p>The format of which is a list of items like below (an author):</p> <pre><code>%A Schortgen Frédérique </code></pre> <p>Unfort...
[ { "answer_id": 374287, "author": "Chris James", "author_id": 3193, "author_profile": "https://Stackoverflow.com/users/3193", "pm_score": 0, "selected": false, "text": "Response.Charset = \"ISO-8859-1\"; \nResponse.ContentEncoding = System.Text.Encoding.GetEncoding(28591);\nRes...
2008/12/16
[ "https://Stackoverflow.com/questions/371702", "https://Stackoverflow.com", "https://Stackoverflow.com/users/3193/" ]
371,708
<p>I have two classes that each need an instance of each other to function. Ordinarily if an object needs another object to run, I like to pass it in the constructor. But I can't do that in this case, because one object has to be instantiated before the other, and so therefore the second object does not exist to be p...
[ { "answer_id": 371768, "author": "James Curran", "author_id": 12725, "author_profile": "https://Stackoverflow.com/users/12725", "pm_score": 2, "selected": false, "text": "backend = new Backend();\npanel = new Panel(backend);\nbackend.setPanel(panel);\n" }, { "answer_id": 371779, ...
2008/12/16
[ "https://Stackoverflow.com/questions/371708", "https://Stackoverflow.com", "https://Stackoverflow.com/users/18103/" ]
371,716
<p>When we serialize an enum from C# to SQL Server we use a NCHAR(3) datatype with mnemonic values for each value of the enum. That way we can easily read a SELECT qry.</p> <p>How do you save enum to your database?</p> <p>What datatype do you use?</p>
[ { "answer_id": 371748, "author": "Kev", "author_id": 419, "author_profile": "https://Stackoverflow.com/users/419", "pm_score": 3, "selected": false, "text": "public enum ActionType\n{\n Insert = 1,\n Update = 2,\n Delete = 3\n}\n" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371716", "https://Stackoverflow.com", "https://Stackoverflow.com/users/28207/" ]
371,721
<p>I have a simple question and wish to hear others' experiences regarding which is the best way to replicate images across multiple hosts.</p> <p>I have determined that storing images in the database and then using database replication over multiple hosts would result in maximum availability.</p> <p>The worry I have...
[ { "answer_id": 371806, "author": "Tom Haigh", "author_id": 22224, "author_profile": "https://Stackoverflow.com/users/22224", "pm_score": 1, "selected": false, "text": "$_SERVER['PATH_INFO']" } ]
2008/12/16
[ "https://Stackoverflow.com/questions/371721", "https://Stackoverflow.com", "https://Stackoverflow.com/users/41690/" ]
371,725
<p>In Pseudo code</p> <pre><code>If Domain inList(GB,US,ES,FR Then Print This Html Else Print This HTML EndIf </code></pre>
[ { "answer_id": 371880, "author": "mtruesdell", "author_id": 6479, "author_profile": "https://Stackoverflow.com/users/6479", "pm_score": 1, "selected": false, "text": "<xsl:choose>\n <xsl:when test=\"domain = 'GB' or domain = 'US' or domain = 'ES' or domain = 'FR'\">\n print this html...
2008/12/16
[ "https://Stackoverflow.com/questions/371725", "https://Stackoverflow.com", "https://Stackoverflow.com/users/87783/" ]
371,728
<p>Every time I create a new excel sheet, I have to go in and change it's cell reference mode to the familiar A1, B1, etc. I can't seem to find a way to permanently set it to A1 style.</p> <p>Is there a macro I can write or a way to use templates or something, so that I don't have to keep changing the R1C1 setting?</p...
[ { "answer_id": 371757, "author": "Ian G", "author_id": 31765, "author_profile": "https://Stackoverflow.com/users/31765", "pm_score": 4, "selected": true, "text": "personal.xls" }, { "answer_id": 371765, "author": "Bill the Lizard", "author_id": 1288, "author_profile":...
2008/12/16
[ "https://Stackoverflow.com/questions/371728", "https://Stackoverflow.com", "https://Stackoverflow.com/users/26140/" ]
371,739
<p>I want to develop a plug-in that does this:</p> <p><em>A button, when clicked, opens the new mail window but has a certain phrase in the subject line, for e.g. when I click a button called 'PROJ123', the new mail window opens with the subject line "[PROJ123]"</em></p> <p>Other functionality it would need:</p> <ul...
[ { "answer_id": 371971, "author": "Fionnuala", "author_id": 2548, "author_profile": "https://Stackoverflow.com/users/2548", "pm_score": 2, "selected": false, "text": "Private Sub cmdCommand_Click()\n Dim eml As MailItem\n\n Set eml = Application.CreateItem(olMailItem)\n eml.Subje...
2008/12/16
[ "https://Stackoverflow.com/questions/371739", "https://Stackoverflow.com", "https://Stackoverflow.com/users/-1/" ]
371,753
<p>I want to override access to one variable in a class, but return all others normally. How do I accomplish this with <code>__getattribute__</code>?</p> <p>I tried the following (which should also illustrate what I'm trying to do) but I get a recursion error:</p> <pre><code>class D(object): def __init__(self): ...
[ { "answer_id": 371833, "author": "Egil", "author_id": 44606, "author_profile": "https://Stackoverflow.com/users/44606", "pm_score": 8, "selected": true, "text": "self.__dict__" }, { "answer_id": 371844, "author": "Singletoned", "author_id": 46715, "author_profile": "h...
2008/12/16
[ "https://Stackoverflow.com/questions/371753", "https://Stackoverflow.com", "https://Stackoverflow.com/users/13009/" ]
371,762
<p>What exactly is GUID? Why and where I should use it? <br/> I've seen references to GUID in a lot of places, and in wikipedia, but it is not very clear telling you where to use it. If someone could answer this, it would be nice. Thanks</p>
[ { "answer_id": 371868, "author": "Michael Burr", "author_id": 12711, "author_profile": "https://Stackoverflow.com/users/12711", "pm_score": 4, "selected": false, "text": "com.example.jpackage\n" }, { "answer_id": 67889504, "author": "N Djel Okoye", "author_id": 4170558, ...
2008/12/16
[ "https://Stackoverflow.com/questions/371762", "https://Stackoverflow.com", "https://Stackoverflow.com/users/37650/" ]
371,781
<p>There are 3 parts to the page. </p> <ol> <li><p>Header, which has unknown content at design time as it is populated with text at runtime. All the text must be displayed, no scroll bars.( I think <code>height: 100%</code> does this) </p></li> <li><p>Content, the content should fill the page below the bottom of the h...
[ { "answer_id": 371868, "author": "Michael Burr", "author_id": 12711, "author_profile": "https://Stackoverflow.com/users/12711", "pm_score": 4, "selected": false, "text": "com.example.jpackage\n" }, { "answer_id": 67889504, "author": "N Djel Okoye", "author_id": 4170558, ...
2008/12/16
[ "https://Stackoverflow.com/questions/371781", "https://Stackoverflow.com", "https://Stackoverflow.com/users/46716/" ]
371,796
<p>If I'm adding a column via MySQL, I can specify where in the table that column will be using the AFTER modifier. But if I do the add_column via a Rails migration, the column will be created at the end of the table.</p> <p>Is there any functionality for rails migrations to specify the position of an added column?</p...
[ { "answer_id": 371949, "author": "Bill Karwin", "author_id": 20860, "author_profile": "https://Stackoverflow.com/users/20860", "pm_score": 3, "selected": false, "text": "add_column" }, { "answer_id": 9946311, "author": "Tamik Soziev", "author_id": 429649, "author_prof...
2008/12/16
[ "https://Stackoverflow.com/questions/371796", "https://Stackoverflow.com", "https://Stackoverflow.com/users/2177/" ]
371,807
<p>I've been looking for a component that would allow me to pass an arbitrary C# object to an XSL transform.</p> <p>The naive way of doing this is to serialise the object graph using an XmlSerializer; however, if you have a large object graph, this could cause problems as far as performance is concerned. Issues such a...
[ { "answer_id": 431924, "author": "Bevan", "author_id": 30280, "author_profile": "https://Stackoverflow.com/users/30280", "pm_score": 2, "selected": false, "text": "XPathNavigator" }, { "answer_id": 466511, "author": "Adam Hawkes", "author_id": 6703, "author_profile": ...
2008/12/16
[ "https://Stackoverflow.com/questions/371807", "https://Stackoverflow.com", "https://Stackoverflow.com/users/886/" ]