instruction_seed stringlengths 1 35.8k | _source stringclasses 1
value |
|---|---|
I regularly access Windows domains that have been set up to use a domain under the .local top level name. This conflicts with Bonjour/Zeroconf which reserves .local for it's own use. A number of platforms support Bonjour out of the box (including Mac OS, iPhone, and Ubuntu) and there's numerous name resolution issues w... | stackexchange/codereview |
Let's say I'm building a data access layer for an application. Typically I have a class definition for a each kind of object that is stored in the database. Of course, the actual data access retrieves data in the form of a datareader, typed or untyped dataset, or similar, usually with the data needed to create one ob... | stackexchange/codereview |
In Maven, dependencies are usually set up like this:
<dependency>
<groupId>wonderful-inc</groupId>
<artifactId>dream-library</artifactId>
<version>1.2.3</version>
</dependency>
Now, if you are working with libraries that have frequent releases, constantly updating the <version> tag can be somewhat annoying. Is t... | stackexchange/codereview |
Is anyone else having trouble running Swing applications from IntelliJ IDEA 8 Milestone 1? Even the simplest application of showing an empty JFrame seems to crash the JVM. I don't get a stack trace or anything, it looks like the JVM itself crashes and Windows shows me a pop-up that says the usual "This process is no ... | stackexchange/codereview |
I have a Delphi 7 application that has two views of a document (e.g. a WYSIWYG HTML edit might have a WYSIWYG view and a source view - not my real application). They can be opened in separate windows, or docked into tabs in the main window.
If I open a modal dialog from one of the separate forms, the main form is broug... | stackexchange/codereview |
How do you access a SQL Server 2005 Express Edition from a application in a network computer?
The access I need is both from application (Linq-to-SQL and ODBC) and from Management Studio
| stackexchange/codereview |
This is a self-explanatory question:
Why does this thing bubble into my try catch's even when nothing is wrong?
Why is it showing up in my log, hundreds of times?
I know its a newb question, but if this site is gonna get search ranking and draw in newbs we have to ask them
| stackexchange/codereview |
I have CruiseControl.NET Version 1.4 set up on my development server. Whenever a developer checks in code, it makes a compile.
Now we're at a place where we can start giving our application to the testers. We'd like to use ClickOnce to distribute the application, with the idea being that when a tester goes to test ... | stackexchange/codereview |
I've noticed a lot of sites, SO included, use XHTML as their mark-up language and then fail to adhere to the spec. Just browsing the source for SO there are missing closing tags for paragraphs, invalid elements, etc.
So should tools (and developers) use the XHTML doctype if they are going to produce invalid mark up? An... | stackexchange/codereview |
How can I connect to a remote SQL server using Mac OS X? I don't really need a GUI, but it would be nice to have for the color coding and resultset grid. I'd rather not have to use a VM.
Is there a SQL client for Mac OS X that works with MS SQL Server?
| stackexchange/codereview |
JavaScript needs access to cookies if AJAX is used on a site with access restrictions based on cookies. Will HttpOnly cookies work on an AJAX site?
Edit: Microsoft created a way to prevent XSS attacks by disallowing JavaScript access to cookies if HttpOnly is specified. FireFox later adopted this. So my question is: I... | stackexchange/codereview |
I have a datagrid getting bound to a dataset, and I want to display the average result in the footer for a column populated with integers.
The way I figure, there's 2 ways I can think of:
1."Use the Source, Luke"
In the code where I'm calling DataGrid.DataBind(), use the DataTable.Compute() method (or in my case DataSe... | stackexchange/codereview |
I want to create a function that performs a function passed by parameter on a set of data. How do you pass a function as a parameter in C?
| stackexchange/codereview |
What particular method/application are you using to communicate between your application and a database? Custom code with stored procedures? SubSonic? nHibernate? Entity Framework? LINQ?
| stackexchange/codereview |
Our group (corporate environment) needs to monitor a couple of faceless accounts' Outlook inbox for specific types of bounced e-mails.
WebDAV (using C# 2.0) is one of the paths we've traveled and we're almost there, except for one minor problem: we're getting the response below for the e-mail body element
<a:propstat... | stackexchange/codereview |
Given this HTML:
<ul id="topnav">
<li id="topnav_galleries"><a href="#">Galleries</a></li>
<li id="topnav_information"><a href="#">Information</a></li>
</ul>
And this CSS:
#topnav_galleries a, #topnav_information a {
background-repeat: no-repeat;
text-indent: -9000px;
padding: 0;
margin: 0 0;
... | stackexchange/codereview |
How do I create a new webpage in the Documentum front end Webtop?
| stackexchange/codereview |
I'm using LINQ to SQL classes in a project where the database design is still in a bit of flux.
Is there an easy way of synchronising the classes with the schema, or do I need to manually update the classes if a table design changes?
| stackexchange/codereview |
I forgot my password for Sql Server 2005. Windows Authentication is not enabled so I cannot login. How can I remove the current instance and create a new db instance? Or is there a better solution exists?
| stackexchange/codereview |
When you have a query or stored procedure that needs performance tuning, what are some of the first things you try?
| stackexchange/codereview |
When a controller renders a view based on a model you can get the properties from the ViewData collection using the indexer (ie. ViewData["Property"]). However, I have a shared user control that I tried to call using the following:
return View("Message", new { DisplayMessage = "This is a test" });
and on my Message c... | stackexchange/codereview |
Is it possible to create a trigger that will not be in a transaction?
I want to update data on a linked server with a trigger but due to firewall issues we can't create a distributed transaction between the two servers.
| stackexchange/codereview |
I'm trying to create a webapplication where I want to be able to plug-in separate assemblies. I'm using MVC preview 4 combined with Unity for dependency injection, which I use to create the controllers from my plugin assemblies. I'm using WebForms (default aspx) as my view engine.
If I want to use a view, I'm stuck on ... | stackexchange/codereview |
I'm trying to install a .NET service I wrote. As recommended by MSDN, I'm using InstallUtil. But I have missed how I can set the default service user on the command-line or even in the service itself. Now, when InstallUtil is run, it will display a dialog asking the user for the credentials for a user. I'm trying t... | stackexchange/codereview |
I am looking for any strategies people use when implementing server applications that service client TCP (or UDP) requests: design patterns, implementation techniques, best practices, etc.
Let's assume for the purposes of this question that the requests are relatively long-lived (several minutes) and that the traffic i... | stackexchange/codereview |
I'm going to start a new project - rewriting an existing system (PHP + SQL Server) from scratch because of some very serious limitations by design.
We have some quite good knowledge of SQL Server (currently we're using SQL Server 2000 in existing system) and we would like to employ its newer version (2008 I guess) in o... | stackexchange/codereview |
What would be the best way to have a list of items with a checkbox each in Java Swing?
I.e. a JList with items that have some text and a checkbox each?
| stackexchange/codereview |
Does anyone know of a good Command Prompt replacement? I've tried bash/Cygwin, but that does not really meet my needs at work because it's too heavy. I'd like a function-for-function identical wrapper on cmd.exe, but with highlighting, intellisense, and (critically) a tabbed interface. Powershell is okay, but the in... | stackexchange/codereview |
I have a huge web app that is having issues with memory leak in IE 6.
Fixing a memory leak in a 5 line code sample that demonstrates the problem is easy.
But if I have a very huge application, where should a start from?
| stackexchange/codereview |
Suppose that I have a form that contains three 10 fields: field1..field10. I store the form data in one or more database tables, probably using 10 database columns.
Now suppose a few months later that I want to add 3 more fields. And in the future I may add/delete fields from this form based on changing requiremen... | stackexchange/codereview |
Are there any rapid Database protoyping tools that don't require me to declare a database schema, but rather create it based on the way I'm using my entities.
For example, assuming an empty database (pseudo code):
user1 = new User() // Creates the user table with a single id column
user1.firstName = "Allain" // alters... | stackexchange/codereview |
We have a question with regards to XML-sig and need detail about the optional elements as well as some of the canonicalization and transform stuff. We're writing a spec for a very small XML-syntax payload that will go into the metadata of media files and it needs to by cryptographically signed. Rather than re-invent ... | stackexchange/codereview |
I'm writing a Telnet client of sorts in C# and part of what I have to parse are ANSI/VT100 escape sequences, specifically, just those used for colour and formatting (detailed here).
One method I have is one to find all the codes and remove them, so I can render the text without any formatting if needed:
public sta... | stackexchange/codereview |
Has anyone ever set up Cruise Control to build an OS X Cocoa/Objective-C project?
If so, is there a preferred flavor of CruiseControl (CruiseControl.rb or just regular CruiseControl) that would be easier to do this with.
I currently have a Ruby rake file that has steps for doing building and running tests, and wanted ... | stackexchange/codereview |
How do I compile, link and call different YACC grammars using yyparse() in one program?
| stackexchange/codereview |
In a recent project, I built my own MVC framework in PHP. One of the things I implemented was a routing system. I used Apache's mod_rewrite to send all requests to index.php, and then parsed the URI to extract information and route the request.
I'm dabbling in ASP.NET now, and I'm wondering if/how I might perform some... | stackexchange/codereview |
It wasn't that long ago that I was a beginning coder, trying to find good books/tutorials on languages I wanted to learn. Even still, there are times I need to pick up a language relatively quickly for a new project I am working on. The point of this post is to document some of the best tutorials and books for these ... | stackexchange/codereview |
I'm able to connect to and read an excel file no problem. But when importing data such as zipcodes that have leading zeros, how do you prevent excel from guessing the datatype and in the process stripping out leading zeros?
| stackexchange/codereview |
Specifically this is regarding when using a client session cookie to identify a session on the server.
Is the best answer to use SSL/HTTPS encryption for the entire web site, and you have the best guarantee that no man in the middle attacks will be able to sniff an existing client session cookie?
And perhaps second bes... | stackexchange/codereview |
In college I've had numerous design and UML oriented courses, and I recognize that UML can be used to benefit a software project, especially use-case mapping, but is it really practical? I've done a few co-op work terms, and it appears that UML is not used heavily in the industry. Is it worth the time during a projec... | stackexchange/codereview |
For years, I've been investigating how to create music streams from my computer. I've seen programs, but anything useful I've seen is Windows only (I use a Mac).
Eventually, I got interested in how streams work. Is there any way I could create my own stream, possibly using socket functions in PHP? Is there a PHP lib... | stackexchange/codereview |
I need to call into a Win32 API to get a series of strings, and I would like to return an array of those strings to JavaScript. This is for script that runs on local machine for administration scripts, not for the web browser.
My IDL file for the COM object has the interface that I am calling into as:
HRESULT GetArray... | stackexchange/codereview |
I have a rather complex page that dynamically builds user controls inside of a repeater. This repeater must be bound during the Init page event before ViewState is initialized or the dynamically created user controls will not retain their state.
This creates an interesting Catch-22 because the object I bind the repeate... | stackexchange/codereview |
Using this question as the base is there an alogrithm or coding example to change some text to Pascal or Camel casing.
For example:
mynameisfred
becomes
Camel: myNameIsFred
Pascal: MyNameIsFred
| stackexchange/codereview |
I have seen Solutions created in Visual Studio 2008 cannot be opened in Visual Studio 2005 and tried workaround 1. Yet to try the workaround 2.
But as that link was bit old and out of desperation asking here: Is there any convertor available?
I dont have VS2008 yet and i wanted to open an opensource solution which wa... | stackexchange/codereview |
I am building a public website using ASP.NET, as part of the deliverable I need to do an Admin Site for data entry of the stuff shown in the public site, I was wondering what techniques or procedures are people using to validate entries using ASP.NET MVC.
| stackexchange/codereview |
I have the need to copy the entire contents of a directory on a FTP location onto a shared networked location. FTP Task has you specify the exact file name (not a directory) and File System Task does not allow accessing a FTP location.
EDIT: I ended up writing a script task.
| stackexchange/codereview |
I'm trying to write a blog post which includes a code segment inside a <pre> tag. The code segment includes a generic type and uses <> to define that type. This is what the segment looks like:
<pre>
PrimeCalc calc = new PrimeCalc();
Func<int, int> del = calc.GetNextPrime;
</pre>
The resulting HTML removes the ... | stackexchange/codereview |
One of my co-workers checked in a some files in SVN and one of the files has a password in it. The password has been removed from the file and a new version checked in but the password is obviously still in the repository if we look at the revision history and go to that revision. (We're using TortoiseSVN as the client... | stackexchange/codereview |
Does anyone know of a powershell cmdlet out there for automating task scheduler in XP/2003? If you've ever tried to work w/ schtasks you know it's pretty painful.
| stackexchange/codereview |
I am maintaining an app for a client that is used in two locations. One in England and one in Poland.
The database is stored in England and uses the format £1000.00 for currency, but the information is being gathered locally in Poland where 1000,00 is the format.
My question is, in VB6 is there a function that takes a ... | stackexchange/codereview |
Is it possible to look back through the history of a Subversion repository for files of a certain name (even better would be for them to have a wildcard search)?
I want to see if a .bat file has been committed to the repository at some point in the past but has since been removed in later updates. Even a dump of the fi... | stackexchange/codereview |
By default each row of a Gridview maps to each row in a datatable or dataset attached to its datasource. But what if I want to display these rows in multiple columns. For example if it has 10 rows, 5 rows each should be displayed in 2 columns side by side. Also can I do this with the Infragistics grid. Is this possible... | stackexchange/codereview |
My organization has a form to allow users to update their email address with us.
It's suggested that we have two input boxes for email: the second as an email confirmation.
I always copy/paste my email address when faced with the confirmation.
I'm assuming most of our users are not so savvy.
Regardless, is this conside... | stackexchange/codereview |
I have a custom built ajax [div] based dynamic dropdown.
I have an [input] box which; onkeyup, runs an Ajax search which returns results in divs and are drawn back in using innerHTML. These divs all have highlights onmouseover so, a typical successful search yields the following structure (pardon the semi-code):
[inpu... | stackexchange/codereview |
How do you get the maximum number of bytes that can be passed to a sendto(..) call for a socket opened as a UDP port?
| stackexchange/codereview |
I know that MAC OS X 10.5 comes with Apache installed but I would like to install the latest Apache without touching the OS Defaults incase it causes problems in the future with other udpates. So I have used the details located at: http://diymacserver.com/installing-apache/compiling-apache-on-leopard/ But I'm unsure ho... | stackexchange/codereview |
I am trying to be a "good" programmer and have unit tests for my ColdFusion application but haven't been able to find a code coverage tool that can tie into the test that I'm using. For those of you who do unit tests on your ColdFusion code, how have you approached this problem?
| stackexchange/codereview |
The following PHP code snippet uses GD to resize a browser-uploaded PNG to 128x128. It works great, except that the transparent areas in the original image are being replaced with a solid color- black in my case.
Even though imagesavealpha is set, something isn't quite right.
What's the best way to preserve the transp... | stackexchange/codereview |
OK. This problem is doing my head in. And I don't know if there even IS a definitive answer.
We have a website, lets call it mycompany.com. It's a UK-based site, with UK based content. Google knows about it, and we have done a load of SEO on it. All is well.
Except, we are about to relaunch my company, the GLOBAL brand... | stackexchange/codereview |
I am currently using the following command to upload my site content:
scp -r web/* user@site.com:site.com/
This works great except that the .htaccess file is not sent. Presumably, this is because it's hidden.
I have tried adding a second line to send the file explicitely:
scp -r web/.htaccess user@site.com:site.com/.h... | stackexchange/codereview |
Having worked with Classic ASP for about 2 years now by creating a few 100 simple web forms I can't see a good reason for switching to .net; however, I'm not that versed in .net so I'm sure I could be missing a few things.
Some points that I often hear around work can be found here: http://www.packtpub.com/article/Clas... | stackexchange/codereview |
I ran into an issue with an IIS web app shutting down an idle worker process! The next request would then have to re-initialize the application, leading to delays.
I disabled the IIS shutdown of idle worker processes on the application pool to resolve this. Are there any issues associated with turning this off? If... | stackexchange/codereview |
I added a custom install action to my installer to add one of my installation directories to the System PATH environment variable. After I run the installer, the PATH variable reflects the changes (when I access it through the Control Panel::System applet), but when I start a new command shell, the PATH variable does n... | stackexchange/codereview |
I have an NFS-mounted directory on a Linux machine that has hung. I've tried to force an unmount, but it doesn't seem to work:
$ umount -f /mnt/data
$ umount2: Device or resource busy
$ umount: /mnt/data: device is busy
If I type "mount", it appears that the directory is no longer mounted, but it hangs if I do "ls /mn... | stackexchange/codereview |
My good friend, Wikipedia, didn't give me a very good response to that question. So:
What are language bindings?
How do they work?
Specifically accessing functions from code written in language X of a library written in language Y.
| stackexchange/codereview |
I am going to be using C/C++, and would like to know the best way to talk to a MySQL server. Should I use the library that comes with the server installation? Are they any good libraries I should consider other than the official one?
| stackexchange/codereview |
I know this isn't strictly a programming question but y'all must have experienced this.
So...you have four or five RDP sessions open over the corp VPN, you're bashing away inside your favourite IDE, your VPN to the data centre bounces briefly then recovers, all your RDP sessions start re-establishing their connections... | stackexchange/codereview |
Instead of relying on my host to send an email, I was thinking of sending the email messages using my Gmail account. The emails are personalized emails to the bands I play on my show.
Is it possible to do it?
| stackexchange/codereview |
When developing whether its Web or Desktop at which point should a developer switch from SQLite, MySQL, MS SQL, etc
| stackexchange/codereview |
So in my simple learning website, I use the built in ASP.NET authentication system.
I am adding now a user table to save stuff like his zip, DOB etc. My question is:
In the new table, should the key be the user name (the string) or the user ID which is that GUID looking number they use in the asp_ tables.
If the bes... | stackexchange/codereview |
I have a table of tags and want to get the highest count tags from the list.
Sample data looks like this
id (1) tag ('night')
id (2) tag ('awesome')
id (3) tag ('night')
using
SELECT COUNT(*), `Tag` from `images-tags`
GROUP BY `Tag`
gets me back the data I'm looking for perfectly. However, I would like to organize it... | stackexchange/codereview |
I read this PHP RegEx page, but either I'm missing something, misreading something, or it doesn't work the way they say. I'm guessing it's one of the first two.
$str = preg_replace("([|]\d*)", "\1;", $str);
| stackexchange/codereview |
I have a couple CSS files with overlapping CSS selectors that I'd like to programmatically merge (as in not just appending one file to the end of the other). Is there any tool to do this online? or a Firefox extension perhaps?
| stackexchange/codereview |
I absolutely need to use an IoC container for decoupling dependencies in an ever increasingly complex system of enterprise services. The issue I am facing is one related to configuration (a.k.a. registration). We currently have 4 different environments -- development to production and in between. These environments ... | stackexchange/codereview |
I am in the middle of reading the excellent Clean Code
One discussion is regarding passing nulls into a method.
public class MetricsCalculator {
public double xProjection(Point p1, Point p2) {
return (p2.x - p1.x) * 1.5;
}
}
...
calculator.xProjection(null, new Point(12,13));
It represents different wa... | stackexchange/codereview |
How can I test the same regex against different regular expression engines?
| stackexchange/codereview |
Most of my C/C++ development involves monolithic module files and absolutely no classes whatsoever, so usually when I need to make a DLL with accessible functions I just export them using the standard __declspec(dllexport) directive. Then access them either dynamically via LoadLibrary() or at compile time with a heade... | stackexchange/codereview |
I've been writing C and C++ code for almost twenty years, but there's one aspect of these languages that I've never really understood. I've obviously used regular casts i.e.
MyClass *m = (MyClass *)ptr;
all over the place, but there seem to be two other types of casts, and I don't know the difference. What's the diffe... | stackexchange/codereview |
I'm looking for the best method to parse various XML documents using a Java application. I'm currently doing this with SAX and a custom content handler and it works great - zippy and stable.
I've decided to explore the option having the same program, that currently recieves a single format XML document, receive two a... | stackexchange/codereview |
We created several custom web parts for SharePoint 2007. They work fine. However whenever they are loaded, we get an error in the event log saying:
error initializing safe control - Assembly: ...
The assembly actually loads fine. Additionally, it is correctly listed in the web.config and GAC.
Any ideas about how to s... | stackexchange/codereview |
I noticed that many people here use TextMate for coding on OS X. I've recently started using it, and although I like its minimalistic interface, it makes it harder to stumble upon cool features if you don't know what you're looking for.
So, what feature have you found most helpful for coding (mainly in Python)? Are the... | stackexchange/codereview |
Is there a way to always have LF line endings in Visual Studio? I can never seem to find it!
| stackexchange/codereview |
I have been searching everywhere for the following functionality in Lisp, and have gotten nowhere:
find the index of something in a list. example:
(index-of item InThisList)
replace something at a specific spot in a list. example:
(replace item InThisList AtThisIndex) ;i think this can be done with 'setf'?
return an... | stackexchange/codereview |
I have a large database and would like to select table names that have a certain column name. I have done something like this in MySQL, but can't find any info on SQL Server.
I want to do something like:
select [table]
from [db]
where table [has column 'classtypeid']
How can I do something like this?
| stackexchange/codereview |
How do you determine when to use table clusters? There are two types, index and hash, to use for different cases. In your experience, have the introduction and use of table clusters paid off?
If none of your tables are set up this way, modifying them to use table clusters would add to the complexity of the set up. But ... | stackexchange/codereview |
Working with dates in ruby and rails on windows, I'm having problems with pre-epoch dates (before 1970) throwing out of range exceptions. I tried using both Time and DateTime objects, but still have the same problems.
| stackexchange/codereview |
What is a data binding?
| stackexchange/codereview |
I'm writing a PHP script that involves scraping web pages. Currently, the script analyzes the page line by line, but it breaks if there is a tag that spans multiple lines, like
<img src="example.jpg"
alt="example">
If worse comes to worst, I could possibly preprocess the page by removing all line breaks, then re-inse... | stackexchange/codereview |
Using VS2008, C#, .Net 2 and Winforms how can I make a regular Button look "pressed"?
Imagine this button is an on/off switch.
ToolStripButton has the Checked property, but the regular Button does not.
| stackexchange/codereview |
I saw this in an answer to another question, in reference to shortcomings of the Java spec:
There are more shortcomings and this is a subtle topic. Check this out:
public class methodOverloading{
public static void hello(Integer x){
System.out.println("Integer");
}
public static void hello(lo... | stackexchange/codereview |
As the title says, is there a way to run the same Adobe AIR app more than once? I have a little widget I wrote that shows thumbnails from a couple of photo streams, and I'd like to fix it so I can look at more than one stream at a time. Thanks!
| stackexchange/codereview |
I think it can be done by applying the transformation matrix of the scenegraph to z-normal (0, 0, 1), but it doesn't work. My code goes like this:
Vector3f toScreenVector = new Vector3f(0, 0, 1);
Transform3D t3d = new Transform3D();
tg.getTransform(t3d); //tg is Transform Group of all objects in a scene
t3d.transform(t... | stackexchange/codereview |
I need to develop some programs for mobile devices but haven't decided the platform to build upon. I'm looking for Palm or Pocket PC devices that have Touch screen and Wi-Fi connection and are cheep because I'll need to buy several of them.
I don't really need camera, mp3 players, video players, pdf readers or anythin... | stackexchange/codereview |
I am a member of all the roles (Browser, Content Manager, My Reports, Publisher, Report Builder). If I login with a Local Administrator account, I can see and use it fine. Any ideas?
| stackexchange/codereview |
I've been unable to find a source for this information, short of looking through the Python source code myself to determine how the objects work. Does anyone know where I could find this online?
| stackexchange/codereview |
I have a small local network. Only one of the machines is available to the outside world (this is not easily changeable). I'd like to be able to set it up such that ssh requests that don't come in on the standard port go to another machine. Is this possible? If so, how?
Oh and all of these machines are running either U... | stackexchange/codereview |
Every time I turn on my company-owned development machine, I have to kill 10+ processes using the Task Manager or any other process management app just to get decent performance out of my IDE. Yes, these are processes from programs that my company installs on my machine for security and compliance. What I'd like to do... | stackexchange/codereview |
I have an application which really should be installed, but does work fine when deployed using JNLP.
However, it would seem that some Java functions such as Runtime.exec don't work using the default security options.
I would like to therefore disable UI functionality that relies upon such functions.
So my question is... | stackexchange/codereview |
What would be the easiest way to be able to send and receive raw network packets. Do I have to write my own JNI wrapping of some c API, and in that case what API am I looking for?
EDIT: I want to be able to do what wireshark does, i.e. record all incomming packets on an interface, and in addition be able to send back m... | stackexchange/codereview |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.