text stringlengths 8 267k | meta dict |
|---|---|
Q: robots.txt in ASP.NET MVC app returning 404 I've deployed an ASP.NET MVC site with a robots.txt file in the root but when I try and access this url it's returning 404. I have an .xml and a .html file in the root as well and they return valid content.
I'm running this on IIS 6. I've tried adding .txt as "text/plain" ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434515",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Anyone knows how to fix compile error: LNK2005? (Source Code inside) I have the below code in stdafx.h.
using namespace std;
typedef struct {
DWORD address;
DWORD size;
char file[64];
DWORD line;
} ALLOC_INFO;
typedef list<ALLOC_INFO*> AllocList;
//AllocList *allocList;
Without the commen... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434522",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How can I inspect form data being Posted? I am reverse engineering an app and I need to see what is in the post data without viewing the form source. Is a there a decent app/plugin to see what is being posted?
I'm looking for something other then packet sniffing.
A: Fiddler for Internet explorer.
A: Charles - web ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434528",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How slow is DISTINCT? I have the option of writing two different formats for a database structure:
Article
-------
ArticleID int FK
Article_Tags
------------
ArticleTagID int FK
ArticleID int FK
TagText varchar(50)
or
Article
-------
ArticleID int PK
Article_Tags
------------
ArticleTagID int PK
ArticleID int FK
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434546",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: AlmostEqual2sComplement or BigDecimal Scaling What would be a better approach to compare two floating point values - using Epsilon or a Big Decimal comparison with scaling?
For instance, your data would range from 0.00 - 49,999.99?
A: For a data range of 0 through 50000 with 2 decimal digits, I would use the built-... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434548",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Is there a way to detect all user generated events (click, keypress, ...) in Windows Mobile? I'll be developing something for a Windows Mobile device using CompactFramework/C#.
I wonder if there is some event available that can capture any user driven event (click, keypress, ...) in context of the device. Sure, I co... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434557",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: What strategy do you use to sync your code when working from home At my work I currently have my development environment inside a Virtual Machine. When I need to do work from home I copy my VM and any databases I need onto a laptop drive sized external USB drive. After about 10 minutes of copying I put the drive in ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434569",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "11"
} |
Q: MySQL Query - getting missing records when using group-by I have a query :
select score, count(1) as 'NumStudents' from testresults where testid = 'mytestid'
group by score order by score
where testresults table contains the performances of students in a test. A sample result looks like the following, assuming ma... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434571",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Streaming video library for C# I'm looking at options for adding streaming video to a social web site written in ASP.NET/C#. I have a great deal of experience with Flash too, so I'm comfortable using FLV players, but I'd definitely go Silverlight if the right library is available.
*
*The library would need to be ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434575",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How can I limit DataSet.WriteXML output to typed columns? I'm trying to store a lightly filtered copy of a database for offline reference, using ADO.NET DataSets. There are some columns I need not to take with me. So far, it looks like my options are:
*
*Put up with the columns
*Get unmaintainably clever about t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434576",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: For Python support, what company would be best to get hosting from? I want to be able to run WSGI apps but my current hosting restricts it. Does anybody know a company that can accommodate my requirements?
A: I am a big fan of Slicehost -- you get root access to a virtual server that takes about 2 minutes to instal... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434580",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "14"
} |
Q: exit batch file using java code I am having the sample code like this.
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
/**
*
* @author padmaja
*/
import java.io.*;
class Test{
public static void main(String arg[]){
try{
String command = "cmd /C sta... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434581",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: What is the fastest way to draw an image from discrete pixel values in Python? I wish to draw an image based on computed pixel values, as a means to visualize some data. Essentially, I wish to take a 2-dimensional matrix of color triplets and render it.
Do note that this is not image processing, since I'm not trans... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434583",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "50"
} |
Q: Getting the content of XHTML tags: p, ul and/or ol from string I have a CMS with a WYSIWYG editor which produces pretty good xhtml. Based on this fact, I think a HTML parser might be slightly overkill for this small job.
I am intending to use regular expressions but so far have been unable to get mine to match what ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434585",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Create user exception derived from std::exception? How a user exception class is created from standard exception?
Addressing below cases
Say i have a class with some enum that indicates type of object
so based on type, member functions are available.Calling member function that is not available should throw an exce... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434592",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Open document with default OS application in Python, both in Windows and Mac OS I need to be able to open a document using its default application in Windows and Mac OS. Basically, I want to do the same thing that happens when you double-click on the document icon in Explorer or Finder. What is the best way to do th... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434597",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "170"
} |
Q: How does one jump to a particular offset more than once? Imagine this function:
void SoundManager::playSource(ALuint sourceID, float offset)
{
alSourceStop(sourceID);
ALint iTotal = 0;
ALint iCurrent = 0;
ALint uiBuffer = 0;
alGetSourcei(sourceID, AL_BUFFER, &uiBuffer);
alGetBufferi(uiBuffer... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434599",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Waveform Audio buffer i look at this article in msdn Recording and Playing Sound with the Waveform Audio Interface and download the P/Invoke Library Sample that record using wave in and wave out .
how do i get the data from buffer (Waveform Audio Interface) (wave in) while recording and play it using c# or vb (wav... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434601",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How do I find the absolute url of an action in ASP.NET MVC? I need to do something like this:
<script type="text/javascript">
token_url = "http://example.com/your_token_url";
</script>
I'm using the Beta version of MVC, but I can't figure out how to get the absolute url of an action. I'd like to do something li... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434604",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "252"
} |
Q: Setting up passive FTP (IIS6) on Windows Server 2003 I am having trouble setting up passive FTP on IIS 6. I used this instruction: http://www.velikan.net/iis-passive-ftp/
When I tried to upload a file through the FTP, I got the error:
425 Can't open data connection. : /index.html
The interesting thing is that from... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434608",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: asp.net mvc - How i convert local file path string to http url After saved upload file, i got local url of this file, how i convert it to http url?
A: public static string PathMap(string path)
{
string approot = HttpContext.Current.Request.PhysicalApplicationPath.TrimEnd('\\');
return path.Replace(approot, ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434609",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: What do you recommend using for graphically visualizing a WSDL? I'm looking for a good solution for graphically viewing a SOAP-based web service and possibly interacting with it (for testing purposes). Online (browser-based) solutions would be interesting too.
A: I have used SOAP UI with success in the past:
http:/... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434617",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "27"
} |
Q: Should I create a interface and mock this class I have this class called Table:
class Table
{
public string Name
{
get
{
return this.wrapper.Eval(//some command);
//wrapper is pass in by the ctor and is a COM object.
}
}
}
which is used in this class:
cla... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434620",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Thread stops doing its job We have a C# application that connects to a FTP server, downloads some files, disconnects, and after a certain amount of time (selected by the user through the UI) reconnects and repeats the process. We implemented this using BackgroundWorker, but we noticed that after running for a longer... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434626",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: File Upload in Javascript? Does any one know how to make a file upload control in javascript. For example, one using a texbox and a button.
Dupe of Javascript file uploads
A: Plain HTML:
<input type="file" />
To programmatically create one using javascript:
var el = document.createElement('input');
el.type = 'fil... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434631",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Global variables in Delphi I have a console application written in Delphi.
I saw that I can have global variables by assigning them to unit scopes, but in a console application I don't use units (from what I've understood it's forms-only).
A: Nope, a unit is not equivalent to a form.
A unit is a module which contai... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434636",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How do I set permissions (attributes) on a file in a ZIP file using Python's zipfile module? When I extract files from a ZIP file created with the Python zipfile module, all the files are not writable, read only etc.
The file is being created and extracted under Linux and Python 2.5.2.
As best I can tell, I need to ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434641",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "48"
} |
Q: Java: Double Value Comparison Do we need to be careful when comparing a double value against zero?
if ( someAmount <= 0){
.....
}
A: For equality: (i.e. == or !=) yes.
For the other comparative operators (<, >, <=, >=), it depends whether you are about the edge cases, e.g. whether < is equivalent to <=, which is a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434657",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "23"
} |
Q: TextBox Undo/Redo commands The WinForms TextBox has an 'Undo' command but has not a 'Redo' command - Why?
A: Because the native Windows Edit control, the base for TextBox, has WM_UNDO but not WM_REDO. It has lots of quirks, dating back from Windows 1.0 and a gazillion app compat patches.
| {
"language": "en",
"url": "https://stackoverflow.com/questions/434658",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: accessing command-line arguments from OSGi bundle I have an application that runs as a collection of OSGi bundles. I start it using a very small wrapper that embeds the Felix framework. The necessity of that wrapper irks me a little, as does the fact that it depends on Felix (whereas the application itself could run... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434664",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "7"
} |
Q: IEnumerable interface I don't understand why IList implements IEnumerable taking in consideration that IList implements ICollection that implements IEnumerable also.
A: IList only implements IEnumerable by associaton; i.e. it implements IEnumerable precisely because it inherits ICollection which is IEnumerable. You... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434666",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Access sharepoint list data in SQL I am new to SharePoint development. I have a list, this list has a column that is called Todaysdate. This column needs to be updated daily to today's actual date and since it contains ~20,000 rows I am NOT going to update it manually everyday. Because it's used in a calculation r... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434680",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Receiving email notification from smartd (smartmontools) To get information about my HDD drive condition, I configured smartmontools daemon (through smartd.conf) like this:
dev/sdb -I 194 -a -o on -S on -s (S/../.././03|L/../../6/04) \
-m sys@example.com -M exec /usr/share/smartmontools/smartd-runner
Also, by a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434683",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How can i remove a USB flash disk programmatically using delphi? How can I detect and remove a USB flash disk programatically using delphi?
I have seen some of the examples in this website, but they lack clear explanation on how to go about it!
Please examples will really help!
A: This is a quick and dirty translat... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434688",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "12"
} |
Q: How to hide new elements in jQuery? I have this code:
var $msg = jQuery('<div></div>')
.hide()
.appendTo(document.body)
;
if ($msg.is(":hidden")) {
console.log("hidden");
} else {
console.log("visible");
}
When run, it logs "hidden" on Firefox, but "visible" on Google Chrome. Is this a bug, or am I ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434694",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Cleaning up a database in django before every test method By default when Django runs against sqlite backend it creates a new in memory database for a test. That means for every class that derives from unittest.TestCase, I get a new database. Can this be changed so that it is cleared before every test method is run?... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434700",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "27"
} |
Q: Normal main to WinCE main I'm porting an existing (mostly) cross-platform application to WinCE 4.2. The current entry point for the function is
int main(int argc, char *argv[]){}
I would like to keep this part as-is, and have the WinCE entry point simply call it. I believe something like the following should wor... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434702",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Extended css sprites not working with :hover? I just encountered this article of an extention of css sprites that enables the spriting trick with foreground images . I tried to use the technique on :hover but it doesn't appear to work in IE and Opera. See my attempt to use this technique for a menu here: http://www... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434703",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How does one submit a potential patch to the Linux kernel? We have some software which relied on certain behavior from another (very commonly used) application that has now changed, rendering our current implementation workable, but less than optimal.
We believe that this change may have affected a number of other a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434711",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "17"
} |
Q: Read Csv file encoding error I am using the following method for reading Csv file content:
/// <summary>
/// Reads data from a CSV file to a datatable
/// </summary>
/// <param name="filePath">Path to the CSV file</param>
/// <returns>Datatable filled with data read from the CSV file</returns>
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434715",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: Sockets: Discover port availability using Java How do I programmatically determine the availability of a port in a given machine using Java?
i.e given a port number, determine whether it is already being used or not?.
A: This is the implementation coming from the Apache camel project:
/**
* Checks to see if a spec... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434718",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "142"
} |
Q: Organizing files of a website powered by PHP, Smarty, JavaScript, MySQL I am writing an web application powered by
PHP, Smarty, JavaScript, CSS, MySQL.
There will be some classes, which will be used through out the application.
There will be some scripts which will use those classes.
Any good article, tutorial, arc... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434724",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: ungetc equivalent of c# Is there any function in c# equivalent to C's stdio function ungetc() ?
A: Not that I know of; for some scenarios, you could use something like a StreamReader and use Peek?
using(StreamReader reader = new StreamReader(stream))
{
/// ... lots of reading
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434734",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How do I add a new record to an IQueryable variable? The IQueryable results is queried from my db using LINQ, How do I add a new record to the IQueryable result.
A: The simple answer is that unless you add the record to the underlying datastore that the Iqueryable is querying, you can't add a new record into an IQu... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434737",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "37"
} |
Q: How often would you tolerate your IDE crashing? I was experimentally trying to switch from coding in vim to coding in an IDE (in this case, Anjuta on Linux), but I found that every time I crashed the IDE, my trust in it went down, until around a crash rate of once a day I trusted it so little that using it was consi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434741",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Is there a way to collapse functions and sub-routines for Classic ASP in Visual Studio 2008? Is there a way to enabling collapsing of functions and sub-routines for Classic ASP in Visual Studio 2008? I'm able to manually go through and specify blocks of code as collapsable, but it would save me a lot of time if the... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434750",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Cached crystal reports controls on Toolbox in VS 2005 and VS 2008 I have a couple duplicate custom crystal reports controls in my Toolbox in VS2005 and VS2008. One of each of the duplicates is preceded with the word Cached. These controls are all part of other projects in the same solution. I have removed some of th... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434758",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Array versus List: When to use which? MyClass[] array;
List<MyClass> list;
What are the scenarios when one is preferable over the other? And why?
A: It is rare, in reality, that you would want to use an array. Definitely use a List<T> any time you want to add/remove data, since resizing arrays is expensive. If you... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434761",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "732"
} |
Q: Why does the x.designer.cs part of the LinqToSql dbml triad disappear after an edit in the visual editor? I ran into a particularly annoying issue. I have a LinqToSql project up and running..
A X.dbml file has three dependent files an X.cs, X.dbml.layout and X.designer.cs
Now when I drop an additional table into the... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434762",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Are prototypes required for all functions in C89, C90 or C99? To be truly standards-compliant, must all functions in C (except for main) have a prototype, even if they are only used after their definition in the same translation unit?
A: It depends on what you mean by 'truly standards compliant'. However, the shor... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434763",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "52"
} |
Q: how can I diff two sections of the same file? I have a source file with two similar yet subtly different sections. I'd like to merge the two sections into one subroutine with a parameter that handles the subtle differences, but I need to be sure I'm aware of them all so I don't miss any.
What I usually do in such c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434766",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "13"
} |
Q: How do I add first user (root) in ASP.NET MVC app? I'm using ASP.NET MVC Framwork and trying to grok the ASP Membership 3.5 stuff.
What is the best way to add the first administrator user without having to log in? I've been staring at the membership starter kit's source without finding it.
A: A simple solution (es... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434776",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Reasonable Downtime I run about 5 different hosted servers, through a variety of hosting providers. In the past two months, one of the servers I work on has been down twice. Both times were unexpected and fairly long (36 hours and 4 hours). The server in question is a VPS not a shared server. Given my experience... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434781",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How to sample multi-channel sound input in Java I realised this might be relatively niche, but maybe that's why this is good to ask anyway. I'm looking at a hardware multiple input recording console (such as the Alesis IO 26) to take in an Adat lightpipe 8 channel input to do signal processing. As I have yet to acqu... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434803",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: How do I make a field in MySql auto-incrementing in PHPMyAdmin? I created a field in my table and set it as the index but I can't get it to increase on it s own when a new item is added. How do I do make it do this through PHPMyAdmin?
A: Select the A_I check box when creating/editing a column.
A: The Answer of Bri... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434810",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "18"
} |
Q: Modifying the Data Source for the Strongly Typed Dataset connection string Here are two questions related to modifying the data source for strongly typed dataset connection string.
When my app is deployed, a light weight database ( in the form of Microsoft Access) is deployed to the Application Data folder. I have a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434815",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: RCP + JNLP\WebStart App will not start I've followed this example: RCP+JavaWS but the app just briefly comes up and goes away. I've turned the console on and it quickly goes away too. I've tried adding: -console, -consoleLog, and -noExit to my application-desc args and I have searched my Application Data dir to no a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434818",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Unit testing drawing control Based on my previous question here my new concern is how do I unit test my drawing code?
A: This is not the ultimate answer but basically, you can test you drawing code by splitting it into small chunk functions, some of which probably have a testable results (not an image).
For the fu... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434828",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: SQL Join maybe? $query = mysql_query("SELECT * FROM news WHERE id = '{$_GET['id']}'");
$news = mysql_fetch_assoc($query);
$sql84 = mysql_query("SELECT username FROM users WHERE id = '".$news['user_id']."'") or exit(mysql_error());
$author = mysql_fetch_array($sql84);
is there i better way of doing this? a join maybe... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434829",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How do I check if my workstation is locked? Can anyone help with code snippet for checking if the workstation is locked? I tried with getting the document.title, so that when the workstation is locked it returns blank for document.title. This is not working.
I am encoding wscript in vbscript which is residing in HT... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434830",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: WPF Shape Rectangle Binding I'm trying to make some kind of shape in wpf, which does resize itself to the content (which should be text). Unfortunately, the stretch property isn't the right thing, since I want only the width of the Shape resized and without the borders (pls copy bottom example in xamlpad to see for ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434832",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Where do you like to catch exceptions and why? Where do you like to catch exceptions and why?
I'm interested in seeing where people find it useful to put their try/catch blocks in the hope that some general patterns might emerge. I'll post my two example answers in C++ but any language is fine.
One location and rea... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434839",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "9"
} |
Q: How to pass a flexible number of ids into a controller in Rails? I'd like to display a comparison page so user can compare the properties of several objects in my database. Any number of objects can be compared. I'd also like it to be bookmarkable (so a 'get').
How should I structure my URL / route for the controlle... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434840",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: sql to detect fields modified in update trigger ( sql server 2005 )? In sql server 2005 , inside an update trigger is there a way to find the list of fields\columns those are modified by the original update query.
I have a table with 150 columns and inside the trigger need to konw if ONLY one particular field was up... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434842",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Is there any trivial way to 'delete by date' using ´rm'- in bash? I noticed today (after ~8 years of happily hacking away at bash) that there is no trivial way to 'delete by date' using ´rm'. The solution is therefore to pipe stuff around a combination of commands like rm, ls, find, awk and sed.
Say for example I wa... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434851",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: OS recommendation to run Java Swing App on very basic hardware We have a Client/Server POS application.
For the Java Swing Client, we are evaluating a system with very basic hardware
*
*Celeron 300 CPU expandable to PIII 1.2 Ghz.
*810 E motherboard.
*64 MB SD RAM, DIMM's, expandable to 256 MB.
*4.3 GB HDD expa... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434855",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: handling Application_Error in ASP.NET app's global.asax I wish to send mail to an administrator when the application crashes.
So I simply do this in global.asax:
void Application_error(object sender, EventArgs e)
{
SendMessageToAdministarator(Server.GetLastError().ToString());
}
But actually many times Applicat... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434859",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "27"
} |
Q: How to check if connection string is valid? I'm writing an application where a user provides a connection string manually and I'm wondering if there is any way that I could validate the connection string - I mean check if it's correct and if the database exists.
A: If the goal is validity and not existence, the fol... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434864",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "91"
} |
Q: How to rename a file name without change its type? I have doubt in renaming java files... My application has to rename the incoming file which is mdb,dbf,xls,xml,etc. format. I used the following source code.
eg:
String filename = "D:/sample.mdb";
File filediriden = new File(filename);
String[] filetype = filename.s... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434865",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How do I stop exceptions trashing my delegate chain? I have come across what must be a common problem. When I have an event which may be subscribed to by several different classes, an exception thrown by one of these classes will kill the callback chain; as I do not know a priori in what order the callback is carrie... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434873",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: How should I teach my friend C#? My comfort level with java is good , I wanted to teach my friend C# (where I would not consider myself expert in anyway). From the perspective of interviews what should I be studying/implementing myself in C# before i can teach her from an interview perspective. I am not a big fan o... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434888",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Is a string property itself threadsafe? String's in C# are immutable and threadsafe. But what when you have a public getter property? Like this:
public String SampleProperty{
get;
private set;
}
If we have two threads and the first is calling 'get' and the second is calling 'set' at the "same" time, what wi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434890",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "32"
} |
Q: Reporting using NUnit I want to have a managerial report after executing tests from NUnit. By looking into NUnit, It seems as it generates the output in XML format. Plz any one can give suggesttion of how to accomplish this.
A: You could use XSLT to transform your xml in to something more pretty.
A: You could use... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434895",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: ReSharper syntax suggestion The if keyword in the following statement is underlined in green by ReSharper:
if (readOnlyFields.Contains(propertyName)) return false;
return base.CanWriteProperty(propertyName);
ReSharper suggests the following change:
return !readOnlyFields.Contains(propertyName)
&& base.CanWri... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434897",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: VS 2008 Service Pack 1 problem My OPS is XP and service pack 3 installed.I cant install vs2008 service pack1,In log file i see 'Visual C++ 2008 SP1 Design-Time Components for x86 - KB947888' cant be installed. Error code is 1603.Last part of Installation file is here.
Returning IDOK. INSTALLMESSAGE_ERROR
[Error ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434899",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: JavaScript function parameter I am trying to pass a number to my JavaScript function, but actually a wrong value is getting passed. I am giving the entire code here:
<html>
<head>
<script type="text/javascript">
function test(num)
{
/*It should alert as 01004 or 1004 but to my surprise it's alerting as 516!*/
alert(... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434904",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: WebOrb to record from my webcam Can WebOrb record a video (flv) streaming using the webcam as a source? How?
A: Here they talk about this.
On the weborb site i found this entry, so it can be done, but apperently they haven't updated their site yet with an example...
A: As of WebORB 4.2 this is a definite yes if y... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434907",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Handling svn locks / cleanup when using CruiseControl .NET and Subversion I am using CruiseControl .NET with the Subversion source control plugin to automatically build our project.
Some of the projects are automatically checking for modifications, but occasionally the check fails and CruiseControl .NET marks the pr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434923",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: ASP.NET: FileUpload control failing with long filenames One of our clients is breaking the software in every way imaginable, and he's just discovered this one.
If the user tries to upload a file with a very long filename (I think the user is trying with a 180 character filename), the FileUpload control refuses to re... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434926",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: CSV access via ADO.NET in 64-bit? In a 32-bit .NET app, I can use this OLEDB connection string to connect to a CSV file via ADO.NET:
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\foo;"
or this ODBC one:
"Driver={{Microsoft Text Driver (*.txt; *.csv)}};Dbq=c:\foo"
However there apparently arent 64-bit versions o... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434933",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Using Ruby Gem DBI I want to access MySQL through ruby on a shared linux server. I figure I need to use the DBI module, but I can't seem to access it. I installed it as follows:
gem install -r dbi
It couldn't install it in the normal location, since I'm on a shared server and don't have permission:
WARNING: Instal... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434935",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How does one use SBCL's SB-SPROF allocation profiling? Update: Upgrading to SBCL 1.0.24 fixed my problem. (Though I also needed to upgrade SLIME to the 11-23-2008 revision. The stable 2006-04-20 revision, as well as the head of CVS don't seem to work with SBCL 1.0.24.)
The documentation for the SBCL statistical pr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434937",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Printing from web applications How do you generate paper-prints from a web application?
Specifically I am thinking about more complex paper documents like diplomas, invoices and contracts. Variable number of pages with frames, tables, logos and headers/footers.
Today I use custom forms and CSS for certain things and... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434940",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: Why LoadLibrary Fail only when EXE is launched from the IDE? On Delphi 2009, on a new VCL project:
procedure TForm1.FormCreate(Sender: TObject);
var
Handle: THandle;
begin
Handle := loadlibrary('oci.dll');
if Handle <> 0 then
begin
try
ShowMessage('Success');
finally
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434948",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Transaction rollback and web services Given an example of calling two web services methods from a session bean, what if an exception is thrown between the calls to two methods? In the case of not calling the web services the transaction will rollback and no harm done. However, the web service will not rollback. Of c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434950",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "14"
} |
Q: ASP.NET AJAX WebForms custom error handling question I've made a web application that has the following architecture: Every form is a UserControl, there is just one actual page (Default.aspx), and a parameter in the URL specifies which UserControl to load. The UserControl is loaded in an UpdatePanel so that it can e... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434959",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Silverlight: How to ignore (the absence of) crossdomain.xml with System.Net.WebClient? I get security exception when using System.Net.WebClient to do HTTP requests, which is due to the fact that crossdomain.xml or clientaccesspolicy.xml on the target server are either missing or are too restrictive. I know there is ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434962",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Global Variable identification in C code base I have a C code base and need to programmatically identify all of the global variables used. I think that gcc can be made to produce a memory map file but don't know how and this might let me see which variables are global? Any help would be appreciated.
Cheers
A: You c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434968",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How do I profile and optimize an XSLT? I have an XSLT for viewing XML files in the browser. The XSLT is naively written and currently takes a long time to execute (several minutes).
My XML file is of modest size (~1 MiB), and other XSLTs for the same document that do different processing execute much more quickly. ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434976",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "31"
} |
Q: Mirroring vs Replication How to decide whether to choose a Replication or Mirroring in SQL Server 2005 to provide data availabilty and performance at the same time.
To be more specific about my SQL server architecture, I have an active/active cluster of 2 nodes which are used for load balancing, and I have another ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434982",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "14"
} |
Q: Memory management when using sqlite database in iphone My application makes use of a SQLite database to store the user's inputs. The number of records in the input would go to around 100 records and I have a lot of SQL operations going on in the application.
When I run the application with Object Allocations, it sho... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434988",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: HashMap initialization parameters (load / initialcapacity) What values should I pass to create an efficient HashMap / HashMap based structures for N items?
In an ArrayList, the efficient number is N (N already assumes future grow). What should be the parameters for a HashMap? ((int)(N * 0.75d), 0.75d)? More? Less? W... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434989",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "38"
} |
Q: How to design this method if it returns multi-dimensional arrays? I am now designing an SNMP library. The problem is caused by a special function like this,
*** GetTable(string id)
This function may return Variable[,] which is a two dimensional array sometimes, but also Variable[,,] and arrays with more dimensions. ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434996",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: When making-up new XML tags, do they need to be in a namespace? I'm not sure if namespaces are required for valid/correct XML. Can I add arbitrary tags to an XML document without having to define/declare a namespace for them?
I think namespaces are a good idea and are probably best practice but I just want to know i... | {
"language": "en",
"url": "https://stackoverflow.com/questions/434997",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: ListBox ItemsSource dynamic filter WPF I want to make a UI virtualization via the datasource.
The idea is to "Filter" what i send to the UI (a listbox in my case).
I noticed that the ItemsSource (an observable collection) is read once and that changing the Filter does not trigger refreshing...
I don't understand why... | {
"language": "en",
"url": "https://stackoverflow.com/questions/435003",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: xslt, javascript and unescaped html entities i have a tiny little problem with xslt, js and html entities, eg. within a template:
<script type="text/javascript">
<xsl:value-of select="/some/node"/>
for (var i = 0; i < 5; i++) {
// ^^^ js error
}
</script>
<script type="text/javascr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/435005",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How to use the site's masterpage from a _layout SharePoint page? I want to use a masterpagefile (the site's one if this makes sense) in my SharePoint 12 hive/template/layouts/TelephoneBookList/test.aspx file. However, whenever I add MasterPageFile="~/_layouts/simple.master" or something like that to my test.aspx pag... | {
"language": "en",
"url": "https://stackoverflow.com/questions/435019",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Spring context.xml and Set.contains() Spring: In my context.xml, I have:
<util:set id="someIDs"
set-class="java.util.HashSet"
value-type="java.lang.String">
<value>"W000000001"</value>
<value>"W000000003"</value>
<value>"W000000009"</value>
</util:set>
In my Java bea... | {
"language": "en",
"url": "https://stackoverflow.com/questions/435023",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Building a WPF UI on a workerthread? I have to buil a rather complex WPF UI (a hughe Grid) in code (no xaml invloved). Is there a way to stop the main UI thread from blocking while beeing in the process of building the Grid? Are there some portions of building the UI that can be outsourced to a workerthread? What pa... | {
"language": "en",
"url": "https://stackoverflow.com/questions/435025",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How can I access the name of a current library in a CL program? I need to use the current library name explicitly in a CL program.
CHGVAR &LIB *CURLIB
doesn't work (after this line &lib = '*curlib'). This should be simple - any ideas?
A: Found it:
RTVJOBA CURLIB(&LIB)
A: Be aware that a given job may not have a c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/435028",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.