instruction_seed stringlengths 1 35.8k | _source stringclasses 1
value |
|---|---|
I am relatively new to ASP.NET MVC, but I have developed a couple of simple applications using it, so I am not completely new. I have gone through the majority of tutorials on http://www.asp.net/mvc and I have read the "Professional ASP.NET MVC2 (Wrox)" book by the guys over at Microsoft. I have also done some extensiv... | stackexchange/codereview |
T BlockingQueue<T>::pop( ) {
pthread_mutex_lock(&lock);
if (list.empty( )) {
pthread_cond_wait(&cond) ;
}
T temp = list.front( );
list.pop_front( );
pthread_mutex_unlock(&lock);
return temp;
}
The above is the pop operation as defined for a templatized conc... | stackexchange/codereview |
I have created an iPhone test application. Also I have integrated SoundCloud with the test application.
Also I got consumer key and consumer secret. When I tried to run my application, I am getting following messages.
2010-11-03 15:49:11.420 iPhoneTestApp[883:207] No CallbackURL supplied
2010-11-03 15:49:11.510 iPhone... | stackexchange/codereview |
I have scrollView with pagingScrollView.pagingEnabled = YES;.
After flicking to next page the
scrollView bounces a little after decelerating, here is my log origin.x change with comments:
2010-11-03 12:53:09.187 app[84864:207] scrollview.bound.origin.x: 713.000000 << deccelerating..
2010-11-03 12:53:09.199 app[84864:20... | stackexchange/codereview |
I've been stuck on this for quite a while and would appreciate some help if possible.
Basically I receive a date from an API in the format yyyy-mm-dd. Amongst other things, I wish to display the weekday. Here is the relevant code:
// jsonDate is in the format yyyy-mm-dd
var splitDate = jsonDate.split("-");
var joined... | stackexchange/codereview |
Need to display folder listings from 2 different network shares. What is the best way to merge them? This is a legacy c# code...
The merged list is displayed in a list view control
| stackexchange/codereview |
I am working on one of the project which requires
class MyObj;
map<string, MyObj*> myMap;
Here logic is here to map file name to MyObj class.
If I try to insert following
string strFilename = "MyFile";
MyObj* pObj = new MyObj();
myMap.insert(strFileName, pObj); // This line throwing following error.
no matching... | stackexchange/codereview |
I have a Service which tracks the location of the user. Currently, the Service boots when the application starts and stops when the application terminates. Unfortunately, if users keep the application in the background, the Service never stops and drains battery.
I would like the Service to stop when my application i... | stackexchange/codereview |
I've read about a bajillion Q&A's on this very topic, and followed all the instructions to the letter. But I'm still getting headaches trying to set up Git to diff and merge using WinMerge.
I've taken the following steps using the Git terminal:
git config --global diff.tool winmerge
git config --global difftool.winmerg... | stackexchange/codereview |
I'm trying to add a check in my installer, so that if a specific registry key is not present it has to fail. That's roughly what I'm doing:
<Property Id="REGVALUE">
<RegistrySearch Id="regval" Root="HKLM" Key="SOFTWARE\Foo" Type="raw"/>
</Property>
<Condition Message="Valid Foo value not present. Found [REGVALUE]">
... | stackexchange/codereview |
Sorry I know the question isnt as specific as it could be. I am currently working on a replenishment forecasting system for a clothing company (dont ask why it's in VBA). The module I am currently working on is distribution forecasts down to a size level. The idea is that the planners can forecast the number to sell, t... | stackexchange/codereview |
I dont want to rely on all those ORM/Querybuilder etc. tools in Kohana 3.x. I just want do use plain old SQL to Insert a new row in my table of my MySQL Database.
How can I do that?
| stackexchange/codereview |
I have a .Net 4.0 windows service application that uses log4net.
Here's my log4net config.
<log4net>
<appender name="ConsoleAppender" type="log4net.Appender.ConsoleAppender">
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="%date [%thread] %-5level %logger [%property{Context}] - %mess... | stackexchange/codereview |
I have a jQuery toggler that I am fighting with. I can get it to toggle the visibility of multiple divs at once, but as soon as I implement the next() function, the only thing that toggles is the plus/minus portion of the script, not the visibility of the div. Anything stand out in this code?
This works, but toggles al... | stackexchange/codereview |
I have a dev Ruby on Rails database full of data. I want to delete everything and rebuild the database. I'm thinking of using something like:
rake db:recreate
Is this possible?
| stackexchange/codereview |
What is the "correct" construct in Common Lisp to apply elementwise operations to multidimensional arrays?
The following examples should help illustrate what I'm trying to do:
A) Suppose I want to increase every element of an array by one:
0 1 2 1 2 3
3 4 5 -> 4 5 6
6 7 8 7 8 9
B) Suppose I want to add 2 arrays... | stackexchange/codereview |
So far I can only get session info of the current one out of $_SESSION,
how can I investigate the session info of arbitary session_id() ?
| stackexchange/codereview |
I don't understand why this is happening. I've been working with this same command for a long time and now, suddenly, it's started locking up.
mkfifo ./pipe
echo "test" >./pipe
What can I do to stop this from locking up?
| stackexchange/codereview |
I'm in need of floating point calculations for C# that can correctly store up to maybe 500 digits/decimals. Is there any built-in-type for this, do I have to create it myself, any library available or what is the best way to go?
Thanks
| stackexchange/codereview |
I'm trying to build the code that will generate a single PDF from a bunch of images in Objective-C. Most of examples I've seen so far don't really allow me to build the PDF, but only generating Cocoa views and turning them into PDFs.
What I'm looking for is some toolkit (like Java's iText) that would allow me to genera... | stackexchange/codereview |
I have recently deployed a Symfony 1.3.6 website. I have chosen to keep frontend_dev.php on the server, so I can debug on the local machine when absolutely required.
I modified frontend_dev.php like this:
<?php
require_once(dirname(__FILE__).'/../config/ProjectConfiguration.class.php');
$configuration = ProjectConfig... | stackexchange/codereview |
I need to setup Maven to:
a) compile the GWT module
b) copy the *.java files in the jar (so it can be imported in another GWT module)
c) copy the result of the compilation step in the jar (so it can be used on a server as is)
Does any one know how this can be done ?
The basic idea is that I want to decouple my GWT pr... | stackexchange/codereview |
i want to write a simple proxy. I don't know what a proxy is. Someone please explain and give a simple http proxy code ?
| stackexchange/codereview |
I'm facing an organizational problem and thought maybe someone could enlighten me :)
I'm working on a classifieds website using drupal and i just can't figure out how to seperate the posts published for each place.
Imagine the website can be used by people from three cities. Chicago, Boston, Seattle
The cities have the... | stackexchange/codereview |
I have the following HTML:
<div id="root">
<div id="left_side">LEFT</div>
<div id="center_s">CENTER</div>
<div id="right_side">RIGHT</div>
</div>
...and CSS:
#root {
background-color: #eee;
}
#left_side {
float: left;
}
#center_s {
margin-left: auto;
margin-right: auto;
width: 65px;
... | stackexchange/codereview |
I need to put small icon inside button in HTML (for example I need to have facebook button on my site, inside button first F icon and then "facebook"). How to do that ?
| stackexchange/codereview |
currently with devise & rails 3 there is a one page user edit page: /users/edit
I would like to split that out into sections for a better UI, something like:
/account/settings
/account/password
/account/notices
/account/disable
Also, I'd like to require the user to enter their current password when a user wants to ch... | stackexchange/codereview |
I want my c++ application to watch for changes in a file called "aaa". I want to do it by QSocketNotifier. I didn't understand from the documentation how to do it. Can you please send me a sample?
10!
| stackexchange/codereview |
I have in my Xaml a pivot control :
<controls:Pivot ItemsSource="{Binding ObjectList}">
<controls:Pivot.HeaderTemplate>
<DataTemplate>
<TextBlock />
</DataTemplate>
</controls:Pivot.HeaderTemplate>
<controls:Pivot.ItemTemplate>
<DataTemplat... | stackexchange/codereview |
Is there a way to add a shortcut to the Markup/Tidy/Reflow Document submenu in BBEdit?
| stackexchange/codereview |
I have two scenarios for using Paperclip, but I'm unsure of how to tweak the settings or if it's possible or even necessary. Need the advice of more seasoned professionals on this one.
First up, I have a Document model for uploads such as PDFs, which would be defined:
has_attached_file :document...
This would give me ... | stackexchange/codereview |
I'm using Kwicks jQuery plugin for my portfolio. I want to show a child container within the list item after the kwicks click event. I can't seem to find a hook for this, at least within the parameters of the kwicks plugin.
After doing some research I couldn't find anything. Anybody know how to achieve this?
I'm using ... | stackexchange/codereview |
I use a finanical planning program http://www.visionsystemscorp.com/ProductOverview.aspx?pid=1 that is based on Dalphi programing, 32 bit system. It worked fine on a XP system but when I got a new system with windows 7, 64 bit and a larger screen I am having trouble with the display. In some cases the font is over si... | stackexchange/codereview |
According to the Flash docs:
http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/events/Event.html#
The Event.EXIT_FRAME constant defines
the value of the type property of an
exitFrame event object.
Note: This event has neither a
"capture phase" nor a "bubble phase",
which means that event... | stackexchange/codereview |
Does it exists ? There is http://github.com/heynemann/pynq , but only for 2.5
| stackexchange/codereview |
Using VS 2008 Crystal Reports, I would like to do a running total on a formula that is calculated on a group change. When I click on add a running total, this formula does not appear in the Available Tables and Fields list.
This is the logic:
On Change Group of group
if CalculatedValue > 0 then
ReportRunningTotal1... | stackexchange/codereview |
When you do your first clone using the syntax
git clone username@server:gitRepo.git
Is it possible using your local repository to find the name of that initial clone?
(So in the above example, find gitRepo.git.)
| stackexchange/codereview |
I have a NSString i.e. 'Hello Mr <>. How are you?' and I want to have the <> as an UITextField to enter something or an UIButton to call a select list.
What is the best way to do this?
My idea is to count the letters from 0 to '<'-1, this is the start position of the UITextfield. Place the UITextfield via CGRect there... | stackexchange/codereview |
I'm looking for an implementation of s-t cut algorithm for flow network (directed graph) in Python.
Is there vertex cut version of the algorithm?
| stackexchange/codereview |
http://gcc.gnu.org/onlinedocs/gcc-2.95.3/objc-features_1.html#SEC2
The GNU Objective-C runtime provides a way that allows you to execute code before the execution of the program enters the main function. The code is executed on a per-class and a per-category basis, through a special class method +load.
Update: the answ... | stackexchange/codereview |
I am new to jquery and javascript so I haven't been able to figure this problem out; nor have my google-fu skills helping me today.
I developed a page with HTML and Javascript/Jquery, placing all the jquery between script tags and all was well. When I was done the page I realized that I wanted the same javascript on a... | stackexchange/codereview |
I have executed AudioPlayer.java example posted by open source community link
Audio Player Tutorial
I got the following exception
Exception in thread "main" java.lang.IllegalArgumentException: No such Gstreamer factory: playbin
at org.gstreamer.ElementFactory.makeRawElement(ElementFactory.java:180)
at org.gstreamer.... | stackexchange/codereview |
I would like to insert a image for a description for my site because of the font quality. I am wondering if I put in description in the title or alt attribute inside of the img element will it be the same for search engines if it was just text?
| stackexchange/codereview |
I have an array of files, but the problem is the root path isn't attached to the file, so using the data below, how would I go about appending the linq item to the static string?
string rootPath = "C:\\Users\\MyUserName";
List<string> files = new List<string>();
files.Add("\\My Documents\\File1.txt");
files.Add("\\My ... | stackexchange/codereview |
I have code that I want to make the following changes:
How do I override ToString()? It says: A static member ...ToString(System.Collections.Generic.List)' cannot be marked as override, virtual, or abstract.
How do I make it generic?
public static override string ToString(this List<int> list) {
string output = "";... | stackexchange/codereview |
how can we clean the stack...
return statement is used to go out from the function. now
if (m1.high_[0] < m2.low_[0]) return FALSE;
here it have m1 and m2 two points with high[0],low[0], low[1] and high[1] values..
now if we use return with statement than is this clean the stack.. i mean return statement with if c... | stackexchange/codereview |
Which annotation, @Resource (jsr250) or @Autowired (Spring-specific) should I use in DI?
I have successfully used both in the past, @Resource(name="blah") and @Autowired @Qualifier("blah")
My instinct is to stick with the @Resource tag since it's been ratified by the jsr people.
Anyone has strong thoughts on this?
| stackexchange/codereview |
I've got my self sort of familiar with pygtk. I find it to be a lot of work to build GUI from code. So I turned to Glade. I'm trying to follow tutorials for Glade and PyGTK, and how they work together, however, I can't seems to find any tutorial for the GTKBuilder format.
I found a couple tutorials, like http://www.wm... | stackexchange/codereview |
I have created a brand new heroku app, beforehand i deleted the old .git file from my app's directory and created a new one with the usual steps:
git init, git add ., git commit -m "new git"
all of which worked fine. I then created a new app like so and got the following error:
$ heroku create
Creating glowing-summer... | stackexchange/codereview |
I've set up proguard according to this link: http://android-developers.blogspot.com/2010/09/proguard-android-and-licensing-server.html
When I build with Ant I get no errors or warnings, but I also don't get any verbose output telling me that ProGuard is doing anything. By other means I'm able to tell that the apk is no... | stackexchange/codereview |
I'm trying to write a program that will put lower case letters entered from the console into alphabetical order. It must discard upper case letters and any non-alphanumeric. This is what I have so far. It works OK but I still need to implement the code to remove uppercase and non-alphanumeric. Any ideas on how I ca... | stackexchange/codereview |
I have this python file that I'm working on:
class Range:
""" An object that has a non-negative start position and a non-negative length"""
def __init__(self, start, end):
"""
Function: generates a new Range
Returns : a new range
Args : start - ... | stackexchange/codereview |
I notice that there are two methods by which an event handler can be hooked up to a GWT widget: addHandler and addDomHandler. The JavaDoc for addDomHandler says, "Adds a native event handler to the widget and sinks the corresponding native event. If you do not want to sink the native event, use the generic addHandler m... | stackexchange/codereview |
I'm having some problems working with my development environment. Specifically, after I invoke the screen utility from within Cygwin I lose the ability to do tab completion. Before I invoke screen however tab completion works just fine.
I messed around with setting different values for the TERM env variable (VT100, xte... | stackexchange/codereview |
I'm interested in starting my own JIT project in C++. I'm not that unfamiliar with assembly, or compiler design etc etc. But, I am very unfamiliar with the resulting machine code format - like, what does a mov instruction actually look like when all is said and done and it's time to call that function pointer. So, what... | stackexchange/codereview |
I want to define a custom file format that my application can recognize. The file will be effectively an archive but I want the file extension to be different and also with a different mimetype. The content of the archive will be in a specific structure so I can easily find the entries.
Also, when a user is uploading,... | stackexchange/codereview |
I've set up a WCF service to provide table data in JSON:
{
"d":{
"__type":"ExtJsDataResults:#MyProject.WebServices",
"rows":[
["TitleA","1.98","English"],
["TitleB","1.98","Spanish"],
["TitleC","1.98","Korean"]
],
"totalcount":10
}
}
How to re... | stackexchange/codereview |
I have an object with a few items in it:
public class ObjectT{
public int ValueA{
get
set;
}
public string ValueB{
get;set;
}
public int Description{
get{
XDocument doc = XDocument.Load(@"xmldocument.xml");
return (string)doc.Elements("test").Single(t => t.Element(ValueB).Value);... | stackexchange/codereview |
I'm building a telnet app in C# (for scripting door games on oldschool BBS systems e.g. Wildcat) and can't seem to build a working parser for ANSI escape codes (e.g. cursor movement, colorizing, etc) - almost all systems I've tested send undefined sequences which defy any "standards". There also seem to be very few res... | stackexchange/codereview |
Well the question says it all.I am trying to create a file transfer application using python, and pygtk for UI.Most of the code is complete,the only problem being the UI for listing remote host's file list.
I really like the Gtk Dialog Chooser widget,and already use it to list the local machine file list.I really would... | stackexchange/codereview |
My app project contains several helper classes that serve all kind
of different purposes (eg time/date/calculation, db access, ..).
Initiating these classes is quit expensive since they contain some
properties that need to be filled up from the database or need to be
recalculated each time an new instance is created. ... | stackexchange/codereview |
I made a simple Android application which gives the latitude and longitude of the place where I am via GPS and I want to send the coordinates to a Webpage and represent them on google maps.
Which is the simpliest possibility to send the data to the server ?
| stackexchange/codereview |
Iamtrying to have a button at the bottom of the list, so when u scroll down and the list has ended than there will be a button "Get more", which will populate the list with more items.
But the button is not visible. this is how my xml file looks like.
Maybee this occurs because of the scroller,, maybe the scroller onl... | stackexchange/codereview |
I'm wondering of it's possible to create a module structure in a module (or something that appears like that)
Currently I use an admin module, using urls like this:
public/admin/index/index
with a folder structure like this:
applications
-- modules
---- admin
------ controllers
------ views [and so on]
I would like t... | stackexchange/codereview |
Does anyone know of any event or sequence of events to be able to handle when a user clicks an item in a ComboBox? Currently the only events that I see being fire from ComboBox within WinForms is SelectedIndexChanged or SelectedValueChanged. The problem with these events is that they are also fired under many other s... | stackexchange/codereview |
I have a window with a background image. The image may change at runtime which really should not matter for this.
I want the image to be fixed to the top left (which it is) and not scale (which is also correct. But I need the image to repeat (tile) when the window is made larger than the image. I am doing ...
What... | stackexchange/codereview |
I'm trying to create a macruby app that calls a rsync script with the --progress argument, but the way rsync displays its progress is by changing the same line, not adding new lines to its output, so how can I grab this data?
| stackexchange/codereview |
I want to read the approved actual work via the Project Server Interface (PSI) on a Project Server 2007
I stumbled upon the ReadStatusTimephasedData function on the PSIStatusing namespace. This does exactly what I want, EXCEPT: It gives me the actual work as entered by the project member in the pwa. It is not the appro... | stackexchange/codereview |
how to display the html page in flexpopup without using iframe any idea?
Thanks,
aravindakumarThangaraju
| stackexchange/codereview |
We are using a dynamic attributes plugin similar to this:
http://codaset.com/joelmoss/dynamic-attributes
Which allows us to store dynamic attributes in our rails model. Those dynamic attributes are in a single database column. We are facing performance issues because of this and I am wondering if MongoId, MongoMapper... | stackexchange/codereview |
I have been working with the DevExpress Filter TreeList code and am curious about why it throws a DevExpress.Utils.HideException.
My understanding is that exceptions are expensive and should be used sparingly and only in certain situations, but the code snippit below shows that we are always throwing the HideException ... | stackexchange/codereview |
I need to be able to copy shapes (chart, table, etc.) programmatically from one slide to another in PowerPoint 2007 keeping their original colors. The source and destination slides are in different presentations which have different themes.
These shapes might be complex and include a lot of colors, e.g., charts, tables... | stackexchange/codereview |
i don't want to add it as below cause i needed them only once in certain action method
(so do not useless load the memory)
class UsersController extends AppController {
var $name = 'Users';
var $helpers = array('Html', 'Session');
var $components = array('Session', 'Email');
| stackexchange/codereview |
For a single producer-consumer arrangement the producer places a 'done signal' as the last item on the queue.
The consumer checks each object taken from the queue and shuts down when the done signal is dequeued.
while(true) {
MyQueueableObject o = queue.take() ;
if ( o.type==PRODUCER_DONE_SIGNAL ) {
re... | stackexchange/codereview |
I'm using Java 6.
Suppose I had a bunch of cats to feed, and suppose myCats is sorted.
for (Cat cat : myCats) {
feedDryFood(cat);
//if this is the last cat (my favorite), give her a tuna
if (...)
alsoFeedTuna(cat);
}
and I wanted to treat my last cat specially.
Is there a way to do this elegantl... | stackexchange/codereview |
Is it better to extend my users controller to include administrative task on other nested controllers?
Or create a 'profile' controller where I could create different actions and views that summarize admin actions.
Scenario A:
"/users/current/" : would show a link to edit products user own.
"/users/current/products"... | stackexchange/codereview |
I'm currently repeating a task in a for loop inside a callback using Twisted, but would like the reactor to break the loop in the callback (one) if the user issues a KeyboardInterrupt via Ctrl-C. From what I have tested, the reactor only stops or processes interrupts at the end of the callback.
Is there any way of send... | stackexchange/codereview |
Is there a way to specify an alternative background image/color for a Button in the XML file that is going to be applied onClick, or do I have to do a Button.setBackground() in the onClickListener?
| stackexchange/codereview |
I'm trying to implement some performance instrumentation for our Windows Forms app and I'd like to detect when a new thread is spawned (specifically from the UI thread) and watch for when it exits. I know I can catch the thread exit event on
System.Windows.Forms.Application.ThreadExit
But I need to find out when a n... | stackexchange/codereview |
i'm using vbscript to extract data from db2 and write to file.
Writing to file like:
Set objTextFile = objFSO.CreateTextFile(sFilePath, True, True)
that creates file in unicode. But that is xml file and it uses UTF-8.
So when i open xml file with MS XML Notepad it throws error:
'hexadecimal value 0x00 is an invalid ... | stackexchange/codereview |
Question
Is there a way to reliably ensure that both the python source paths and compiled java class paths are added to the Jython PythonPath when running unit tests under eclipse?
If not, is there a better workaround than adding absolute paths to the PyDev PythonPath, External Libraries list?
Background
I have been ha... | stackexchange/codereview |
I am trying to set a MinWidth for my columns.
MinWidth works correctly for Column 0 but not Column 2. The splitter just keeps dragging and I can get the Column to be less than the declared MinWidth
The MinWidth seems to only take effect if the Column Width has a numeric value rather than Auto.... Is there a way to get ... | stackexchange/codereview |
var.split('/').delete_at(0)
upon inspection returns
""
no matter what the string, however....
var.split('/')
var.delete_at(0)
gives me no trouble. this is probably a stupid question, but are there some sort of restrictions/limitations regarding method chaining like this?
thanks,
brandon
| stackexchange/codereview |
Am I allowed to have two or more ob_start(); in my php files if so what is the proper way to end one ob_start(); and start another?
| stackexchange/codereview |
I've already configured the necessary things to work the extends template function in django. here's my codes:
in settings.py
def my_dir():
import os.path
return os.path.abspath(os.path.dirname(__file__))
TEMPLATE_DIRS = ( my_dir() + '/app/templates', ) #dynamic template directory
in base.html - located in app... | stackexchange/codereview |
How can I add a Oauth provider to a web application using Zend Framework? Zend Framework has support for oauth consumers, but I don't see a provider support. What do you use to implement a Oauth provider in php (with Zend Framework)?
| stackexchange/codereview |
I have a vector that I fill with pointers to objects. I am trying to learn good memory management, and have a few general questions:
Is it true that when I am done with the vector, I must loop through it and call delete on each pointer?
Why don't I have to call delete on the vector or any other variable I declare with... | stackexchange/codereview |
Question for you guys.
If I am capturing a 404 error through an isapi filter in IIS and calling a handler with code to redirect the user by taking in their url request as a parameter and running a query on the database. Can I run into issues making that dynamic server side redirect if multiple users are being caught b... | stackexchange/codereview |
I cannot make TagSoup work. I'm using the code that follows, but when I print the Node returned by the parser (the line with System.err.println(doc);) , I always get "[#document: null]".
I don't know how to find the bug in this code or, whichever it is, the origin of the problem. Please help!
public final Document par... | stackexchange/codereview |
I have been searching the internet trying to understand in its simplist form why this behavior happens.
Dim mysingle As Single = 456.11
Dim mybool As Boolean = mysingle = 456.11
In the lines above mybool becomes false. I found this behavior when putting the single into a double I found extra digits showing. The .net d... | stackexchange/codereview |
Is there an easy way, using a subroutine maybe, to print a string in Perl without escaping every special character?
This is what I want to do:
print DELIMITER <I don't care what is here> DELIMITER
So obviously it will great if I can put a string as a delimiter instead of special characters.
| stackexchange/codereview |
I have:
String[] time = {"22:22:22","22:22:23"};
Array asd = null; // This should have the same strings as time
How can I create an java.sql.Array containing the given time values, i.e. something like asd = time?
| stackexchange/codereview |
how to track the path of ball flowing motion in cocos 2d
For example in angry bird game video the bird flowing motion. they display the path. likewise i want
| stackexchange/codereview |
Hey,
I'm using Spring MVC and I got used to "sending" DTO to a view without populating servlet request directly, which is very flexible and effective. I'm trying to figure out how to do something similar in Struts, because as far as I can see, the only way how to "send" DTO to view is via request dispatcher where servl... | stackexchange/codereview |
I'm trying to send a message and we sometime get this error :
Service not available, closing transmission channel. The server response was: 4.4.2 Timeout while waiting for command.
Anyone know what to do with this? Because it only happens "sometime" and apperently, for no specific reason.
I saw many article saying :
... | stackexchange/codereview |
I'm using a div as a "dialog box" on a web page. I've defined it as follows:
#ha2game {
position:absolute;
top:0px;left:50%;
width:258px; height:258px;
margin-top:110px;
margin-left:-155px;
padding:21px;
background-color:#900;
border:1px #444 solid;
color:#000;
font-weight:bold;
... | stackexchange/codereview |
How can I convert "Sat Nov 06 05:48:16 +0000 2010" to '11-06-2010' in Ruby? I've tried
Date.strptime("Sat Nov 06 05:48:16 +0000 2010", '%m-%d-%Y')
but I get this error:
ArgumentError (invalid date):
/Users/ben/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/date.rb:1688:in `new_by_frags'
/Users/ben/.rvm/rubies/ruby-1.9.2... | stackexchange/codereview |
Can I attach an event to an SqlCommand.Disposed event that will dispose of the SqlCommand's connection? Here is the code I am testing:
public static SqlCommand GetCommand(string query, SqlParameter[] paramCollection, bool isStoredProcedure)
{
return new DBSettings().CreateCommand(query, paramCollection,... | stackexchange/codereview |
What I am thinking of is something like the "this" keyword but at a class level i.e.
class Example {
public static void main(String[] args) {
assert Example.class == thisclass.class
}
}
where "thisclass" is a keyword that returns the current class, just like "this" returns the current instance.
I can ... | stackexchange/codereview |
I want to be able to click a table cell, have it switch to color1, and then on the next click have it switch to color2, then back to color1... and so on.
function cSwap(cell){
if (cell.style.backgroundColor = "#00000F")
{
cell.style.backgroundColor = "#F00000";
}
else if (cell.style.backgroundColor = "#F00000")
... | stackexchange/codereview |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.