text stringlengths 8 267k | meta dict |
|---|---|
Q: Clojure NullPointerException error I'm new in clojure and try to write simple function which get list of numbers and filter only even numbers.
I want to do it witout filter or even?, only pure clojure
(defn my-even [ilist]
(if
(= (mod (first ilist) 2) 0)
(concat (list (first ilist)) (my-even (rest ilist)... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584337",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Ajax load issue with MVC Pager control We have an MVC pager control on a view, when moving to a new page with the next, previous, or page number, the page loses all of its CSS. The pager ajax loads the view into the div it's sitting in. Here's the view, moving page to page fires the controller action correctly but w... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584338",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: on click/completion of select drop down list, show more select drop downs Using JQuery I want the user to select an item from a drop down list and when he completes it, another one appears. There should be a total of 4 drop down lists.
JQuery
<script>
$("select: nth-child(1)").click(function () {
$("select... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584339",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Will throwing a WCF Fault in a IsTerminating=true method still close the channel I have a WCF service that is using SessionMode.Required for state. I have a method that will terminal the channel if called (IsTerminating=true). However I only want to terminate if certain conditions are met. If I throw a fault will... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584340",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: how to make single function here used two time In this code :
if (!parms.script) { // no script... load filename
execscript(parms, function (data){
var text={'result':'success', 'response':data };
if(typeof(data)!='object') {
try {
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584343",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Using JQuery to get VH1's "Pop Up Video" effect? I am hoping someone can help me recreate the "VH1 Pop Up video" effect, where the entire bubble scales, and has the Easing effect at the end.
I have a list with some display:none DIVs hidden in each item of a list.
I was hoping that when user clicks on each list item... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584344",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How to detect in a running C++/Qt application if underlying Windows is a 32 or 64 bit version?
Possible Duplicate:
Detect whether current Windows version is 32 bit or 64 bit
Correct way to check if Windows is 64 bit or not, on runtime? (C++)
I found some questions on the topic, but not exactly what I need.
I'm de... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584346",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: To extract all the files to a folder before starting installation
*
*We are creating a setup. In that we want to extract all files to a folder and then we want to install it one after the other. Is there any way to carry this out?
*During Installation we want to list the steps to be executed, to the end users, li... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584351",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: C# Duplicate Data Problem I am having problems with duplicate data being inserted in to the database, am I passing a wrong parameter in the IEnumerable<Location>?
It doesn't bring up any errors when I debug the app.
IEnumerable<Location> locations = context.Locations.Where(l => l.FacebookID == facebookID);
if (loc... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584352",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Omniauth not updating OAuth token secret on log in I'm using Omniauth to authenticate users with Twitter and Facebook, going by the "standard" tutorial on the topic (Ryan Bates' screencast, although I'm using Authlogic, not Devise).
I can log in using Twitter, but can't handle authenticated requests back because my ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584354",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: SQL ANSI joins and the order of tables in it The following query is automatically translated from the "old" syntax to ANSI syntax and gives an error:
select *
from ods_trf_pnb_stuf_lijst_adrsrt2 lst
join ods_stg_pnb_stuf_pers_adr pas
on (pas.soort_adres = lst.soort_adres)
right outer join od... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584355",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: jQuery UI Modal Dialog should be fixed on scroll Is there any possibility to fix the modal window for jQuery UI, so when the user is using the scroller on the right side, the side behind scrolls, but the modal window is staying fix?
A: Create a css class with the fixed position:
.fixed-dialog{
position: fixed;
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584362",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "22"
} |
Q: Loading any persistent workflow containing delay activity when it is a runnable instance in the store We are trying to load and resume workflows which have a delay. I have seen the Microsoft sample of Absolute Delay for this using store.WaitForEvents and LoadRunnableInstance to load the workflow. However here the wo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584367",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Awk - unterminated regex I am writing a shell script which needs to pull values out of a text file which looks like this:
app.full.name /warfilelocation/ warfilename
My shell script will be iterating over a list of application names and pulling out either the location or name using AWK. I have tested doing this on... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584371",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to create a mesh object in ITK using Python bindings? I am trying to create a Mesh object in Python. I am using the python bindings which are being installed from the following web page. As far as the c++ code is concerned we can do it as follows
MeshType::Pointer mesh = MeshType::New();
I am very new to... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584373",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: placement of facebook like and google + buttons inline? Does anyone have any tricks to aligning these two buttons on a page? By default the iframe version of the facebook like button appears below the google plus button or vice versa. Are there any css tricks to keep them inline?
This is my current attempt
<div sty... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584374",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "9"
} |
Q: Struts Validation Framework not working I am trying to validate a form using struts validation framework, but the validation seems to be getting bypassed. I have all the validations setup in validation.xml.
I also have some custom form validations in the form's validate() method which are running fine.
I have set th... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584381",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Android + AM PM in a Time Object? I'm setting a Time Object in Android. How do I set the AM and PM value at creation without relying on 24 hour time? For instance:
int hour = 7; // this returns 7am
//int hour = 19; this returns 7pm
myTime.set(second, minute, hour, day, month, year);
Log.i("TIME", "My time is: "... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584384",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: onerorr callback method does not fire. is an event listener needed? I dynamically create DOM elements based upon the user input using this code (Example 1). I also use php/xhtml to create the same elements on a reload (Example 2).
Problem I'm seeing is that my image onerror event only works for the reloaded versio... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584388",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Proper Way to Float Elements I have the following HTML:
<fieldset>
<legend>Details</legend>
<div class="form-section first">
<div class="abc">
<div class="editor-label">
<label for .../>
</div>
<div class="editor-field">
<input type... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584396",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How should I implement this credit system? I am creating a website where members of the family can book a vacation in the family's sea cottage.
Each member is assigned 40 credits each year. A member must have enough credit points to book a vacation. (this credit system makes sure every member has equal opportunity t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584398",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: List Box enable/disable one column Access 2007: Is it possible to enable/disable one column in a List Box on a form. For example: Say you have 2 columns A,B - If Me.A = title Then Me.B.Enabled = True Else Me.B.Enabled = False.
If so, where would it go? On Got Focus, On Click??
Thanks
A: I'm not sure what you mea... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584399",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Overriding a method with an object Why is it possible to override an empty-parentheses method with an object?
trait A {
def meth = {}
def meth_p() = {}
}
class B extends A {
object meth_p
} // compiles
Overriding the method without parentheses does not compile:
class B1 extends A {
object meth
} // does no... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584400",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "14"
} |
Q: Need some changes to the below code This was the code suggested by Reafidy a programmer on stackoverflow. it was working as intended. Need a better optimized code?
Now I have to Re-use the same code for a large file.
Sub Delete_Duplicate_Codes()
ThisWorkbook.Worksheets("Data").Activate
Dim vData As Variant, vArr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584407",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How can you conditionally display links in jqgrid? I have a jqgrid and I have a custom formatter for it which formats and displays links as per my needs. This does work fine but I have a problem. I want to display links conditionally. How can I do that?
For Eg. If the person is Admin then show him all links like edi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584410",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Find overlapping time ranges I'm surprised this hasn't come up yet.
In T-SQL, I need to find the intervals (defined by startDateTime and endDateTime) that overlap with daily interval (say 9am-5pm).
For example, with table:
CREATE TABLE [dbo].[Interval](
[startDateTime] [datetime] NOT NULL,
[endDateTime] [dat... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584414",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Convert ODT to single XML file I know that standards define two versions of ODT file:
- one is a archive of different files, i.e. meta.xml, content.xml etc,
- second is one big XML file with all the data.
(I know above from http://en.wikipedia.org/wiki/OpenDocument_technical_specification#Document_Representation)
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584416",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Do Arrays take up space even without values in them in .net? I have a program in VB.net that uses a 3D array:
Private gridList(10, 900, 900) As GridElement
Now, I just used a Memory Profiler on it (because my application is having some major leak issues or something) and apparently, this array (containing at the mo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584417",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Iterate the classes defined in a module imported dynamically I have a module from a child package that is imported dynamically; how can I iterate over the classes that it contains?
I have been importing the module and listing the names like this:
package = current_module.__name__
package = package[:package.rindex(".... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584418",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "25"
} |
Q: Pausing/resuming an upload request using Webdav on Android I'm planing to build a Webdav client for Android and I'm not sure what's the best library to use. Basically I would like to allow the user to pause and resume an upload request to a Webdav server. Is there any way to do that?
I' ve looked around and apparent... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584421",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Running BAT/CMD file with accented characters in it I have a Windows batch file which has an instruction to execute an EXE file in a location whose path contains accented characters. Following are the contents of the batch file.
@echo off
C:\español\jre\bin\java.exe -version
C:\español\jre\bin\java.exe - This path ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584423",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "23"
} |
Q: Retrieving Family information from Facebook using FQL? Hi I am trying to pull information from Facebook using FQL. I was able to gather info on my friends and the profile users likes however I cant seem to get a list of family information, the code I currently have is below. I was wondering if anyone could help and ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584430",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Traceback for regular expression Lets say i have a regular expression:
match = re.search(pattern, content)
if not match:
raise Exception, 'regex traceback' # i want to throw here the regex matching process.
If regular expression fails to match then i want to throw in exception Its working and where it fails to ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584435",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: jquery hover function not working after showing img i have the code below:
the first function shows an alternative image on mouse over using the rel atribute
the second function takes a hidden div and shows the content in another place on the same page but when i hover the image the image doesn't change, the hover o... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584439",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Facebook SEO with image not loading
Possible Duplicate:
How does Facebook Sharer select Images?
I've got an app recently put online. On my Facebook wall, when I type in the URL to my app. Facebook displays available thumbnails. At the moment it's displaying GoDaddy's thumbnails. I'm guessing its because Facebook ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584440",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Using ruby/nokogiri to transform xml to another xml I've never encountered task of transforming XML from one form to another. I hear that XSLT is just for that, but I don't want to go there. So, using only ruby and nokogiri, how can I:
remove all item elements but time from initial XML and also rename element time t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584443",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Django: how to properly use UserProfile? (Django auth extra information) i finally can make my Django+Auth app works. I add the extra information to the user as the docs say. Now, i've a simple question. When i'm building a model that is related to the user, which user should i relate to? To auth.models.User or to m... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584450",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: My Play app is very slow I'm a begginer with PlayFramework and I have a few questions about how to put the server to work properly.
I have been reading a few tutorials on how to deploy a Play! app and I decided to use the server that comes with it and lighttpd as reverse proxy. (I want to deploy 2 or 3 apps in the s... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584451",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Unix: assign variable to command I am trying to assign the path of a file to a variable so I am doing something like:
PATH = dirname script.sh
However I am getting an error. Can someone assist? Thanks.
Sincerely,
Eric Anderson
A: There can be no spaces between the variable name and the equals sign. Also, I think ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584453",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Problems installing: mysql2 on Mac OS X Lion + Ruby 3 when i'm under my app over rails. and i do:
$ bundle install
I retrieve this error:
Installing mysql2 (0.2.7) with native extensions /Users/workdreamer/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:533:in `rescue in block in build_ex... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584456",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: iPhone trying to use a block animation to simulate a card flip, but nothing happens no animation I'm trying to do a card flip animation...but nothing happens.
this is what I do
1. create a container view, to hold the two views to animate from.
2. Create the first view.
3. add it to the container.
4. create the secon... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584458",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Nested singular resource, not showing up in rake routes I created a search and replace controller, with just an index action. Since it's meant to go under one of my restful controllers created by a scaffold, i setup the following in the routes file:
resources :sites do
resource :search_and_replace, only: [:index]
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584460",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Hibernate union-subclass (table per concrete class) mapping generator of "increment" very slow? My Hibernate hbm file looks something like this with a mysql DB:
<hibernate-mapping>
<class name="com.company.common.bo.position.Parent" table="Parents"
abstract="true">
<id name="id">
<generator class="in... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584465",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Java array declaration without hard coding the size How can I initialize an array of objects of a class in another class without hardcoding its size?
A: Arrays are fixed in length. I would recommend using a Collection.
Here is an article on collections:
http://en.wikipedia.org/wiki/Java_collections_framework
With t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584467",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: CakePHP 2.0 - Cake was unable to write to File cache I'm using CakePHP 2.0 RC-1. After checking out the project from SVN, the application is starting to complain that it can't write cache files to the tmp/cache directory. Since this is local, I know the directory is writeable and I can CLEARLY see that the directori... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584472",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "18"
} |
Q: Field values gets reset to blank on seam file upload exception I have jsf-seam application in which I am uploading a file using seam:fileUpload using the code below. Also, I have made a entry of multipart-filter to restrict file size to 1 MB.
<s:fileUpload id="offerImage" data="#{myBean.data}" contentType="#myBean.c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584482",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Is there a way to get the IP address of the client/caller in a Shiro Filter in Grails sorry if this is a dumb question. I have some web service calls that are implemented in Grails controllers and we use the Shiro plugin for security. I want to be able to create a whitelist of IP addresses for certain operations tha... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584484",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: User relationships are corrupting my sessions in Symfony2 My users have a number of relationships setup in Doctrine but one in particular seems to be causing me a lot of problems, each user can have a number of memberships and each membership has a membership type.
For some reason however when I load those membersh... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584485",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Python print statement “Syntax Error: invalid syntax” Why is Python giving me a syntax error at the simple print statement on line 9?
import hashlib, sys
m = hashlib.md5()
hash = ""
hash_file = raw_input("What is the file name in which the hash resides? ")
wordlist = raw_input("What is your wordlist? (Enter the fi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584489",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "57"
} |
Q: Trigger iScroll 4 on all elements with a certain Class The script iScroll4 is triggered in this manner
$(document).ready(function() {
var myScroll;
myScroll = new iScroll('wrapper');
});
That however assumes there is an element with ID 'wrapper'. I would lik... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584491",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to get a set of values as a list when grouped by a pair of columns I have a datatable with below values
id Name date
1 a 5/3/2011
1 a 6/4/2011
I want to retrieve the values with a list of associated dates for each id/name pair.
A: I would suggest you create a class which encaps... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584498",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How can I write HTML in a Word document? How can I write HTML in a Word document using C#?
I made a class to help writing a document
using System;
using System.IO;
using Microsoft.Office.Interop.Word;
namespace WordExporter
{
public class WordApplication : IDisposable
{
private Application applicati... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584503",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: RequestThrottling issue in Amazon MWS API I am testing API Sample of Amazon MWS API in C# for submit feeds however after setting AWS Secret key , access key etc. in code i am getting error of RequestThrottled , so there is details what is that but could not find any code sample how to resolved that.
I would like to ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584507",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "14"
} |
Q: How do you do autopostback feature of webforms in asp.net mvc? I have a simple webgrid which displays list. I also have a combobox which contains few items. I want that when user changes the selection, the changed value should be posted to the server. How can I do this?
Any code snippets would be helpful.
A: Auto-... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584515",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Flex 3: how can I simulate the clicking of a certain image (button) Long story short - In order to make something work correctly, I need to simulate the user clicking on an image which doubles as a button and calls yet another function. I've tried simply calling the function, but it didn't work... for some reason, ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584516",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Issue Using Mockito's When Method I'm struggling trying to teach myself Mockito.
Consider the following method, hasInventory(), which should not really run in my way of thinking, but get set up to return true or false as I squirrel-cage my test. Class Warehouse is my "mocked-dependency".
public class Warehouse imple... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584518",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "9"
} |
Q: SQL Azure Backup & Restore strategy We have a web based (ASP.NET MVC) application that uses SQL Server 2008 for its database.
Because the data is important to us (and our clients), we have a Backup & Restore strategy in place which, in a nutshell, looks like this:
-Weekly: Full database backup
-Nightly: Differentia... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584521",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: UIColor colorWithRed:green:blue:alpha: always returns white unless one argument is 0 I am using
[UIColor colorWithRed:136 green:155 blue:218 alpha:1.0];
to change the background color of my table view cells.
But for some reason the background just stays white. If I try
[UIColor colorWithRed:0 green:155 blue:218 ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584531",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: static initialization in case of dependencies Is the following code safe (given no guarantees of static initialization order?).
In some library:
class A {
A() : x_ = 0 {
}
int add() {
return ++x_;
}
};
namespace S {
static A a_;
}
#define ADD(varname) \
namespace S { \
stat... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584532",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: 2 Image views in Android? I have a relative layout with 2 image views in them, I try and set the xpos of image view 2 and it seems to appear inside image view 1, as if image view 1 is masking it, whats happening?
xylophoneHolder = new HorizontalScrollView(context);
xylophoneLayout = new RelativeLayout(context);
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584535",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: How do you port bash aliases to ipython > 0.10? How do you port your bash aliases to IPython version >= 0.11?
This question has already been answered for IPython < 0.11, and link for that is
here:
http://ipython.scipy.org/Wiki/tips
A: Here is my solution. Improvements welcome!
In your ipython config, add the follo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584536",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Convert HTML into PDF using Python I am trying to convert HTML into a PDF document in Django and haven't been successful.
I have tried using wkhtmltopdf 0.9.9, however Apache throws an error that wkhtmltopdf cannot connect to server. When I use wkhtmltopdf directly, it runs perfectly fine and converts the HTML into ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584546",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How to update 3 records using only one update? I want to change seqid :
*
*2 instead of 1
*3 instead of 2
*4 instead of 3
using one update statement.
UserID seqid
1 1
1 2
1 3
1 4
A: Make sure you make a backup before running any update in case you get it wrong.
Assuming (as ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584550",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to change libav decoding framerate? Is there any way to change libav decoding frame rate? There are several variables in libav structures responsible for getting frame rate but as I know these all are for reading purposes only (in decoding mode). Among them are:
AVStream.duration
AVStream.nb_frames
AVStream.r_fr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584555",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: javax.servlet.ServletException: null Recieved the following error whilst testing a small apache strut based web application ive been working on, the crux of the matter is that somehow a null httpservletrequest request parameter was passed to an Actionforward Execute function within an extened Action class??
My knowl... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584558",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Initialise a counter before the first loop This line
$.each(data[0].hotel_id, function (index, value) {
Loops through hotel_id array executing the inner JS code for each entry in the dictionary setting index to the key in the dictionary and value to the contents.
My dictionary:
"hotel_id": [{
"hotel_id": ["1"]
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584559",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: Crystal Reports for VS 2010 Redistributable installed - and not working I have a .net project using a crystal report. I am using VS2010 and targeting the .net 3.5 framework. Everything works on my development machine, but not on the production web server. I have installed the SAP Crystal Reports 32 bit redistribu... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584564",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Triggering a SUBMIT in an asp.net application I need to trigger a submit when saving my image file in SQL 2005 database.
A user will upload their image file.
My application will then check to see if the image file size is within specific requirements.
If so, then save the image into a table where the field is imag... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584565",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: How do I create a URL to link between apps in Padrino? I have a separate app called "api" that I'd like to link to from my admin app. But if I do a link like:
%td=button_to "API", url("/api/users", :attributes, :id => user.id),
:method => :get, :class => :button_to
It takes me to /admin/api/users, I want to go ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584572",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: utility to dump memory representation of float? I'm looking for a utility that'll dump how a various number types are stored in RAM. It's easy to write but if there is a ready tool for achieving this, it'll be great.
Hopefully it'll take of endianess as well.
Syntax could be something like this:
hex uint32 big
E.g... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584574",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Setting A URL Alias is changing the look of the Page OK I a page that is assigned to node/4 and it looks fine:
The client wants the URL to read Pictorial Availability or something like that. I change the URL Alias and this is what happens:
I know in the content box they have the following:
<?php require_once "cus... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584577",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Convert dates in JSF for "title" attribute in a table Is it possible in JSF to convert a date value and put it in "title" attribute? In a similar question, JSF Convert dates for title attribute, there was an answer, that it can be done with JSTL's fmt:formatDate, but not in repeating components, such as UIData. I ne... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584583",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: c++: class declaration and definition separated inside header causes Duplicate Symbol I usually only have the definitions of my classes inside a header if they are template classes.- If this is the case, i still like to split declaration and definition inside the header like that:
template<class T>
class Foo
{
publi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584589",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How to get Joomla's breadcrumb to display correct path to K2 item? I'm almost done with developing a quite complex Joomla website and I have a very irritating bug with the breadcrumb. I'll try to explain it the simplest way possible.
I mix Joomla Articles and K2 items in order for my website to work as it should.
I ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584591",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Adding extra run-time attribs to an activerecord object I have an Agent model which gets its attributes from the underlying database table. However for one particular controller action I would like to add some 'temporary' attributes to the Agent records before passing them on to the view.
Is this possible?
A: Yes... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584592",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "15"
} |
Q: Regex for login page URL? Right now, I have this code:
string strURL = "aLogin.aspx?test=hello";
string strPattern = "(.*/)?Login.aspx(?.*)?";
bool bIsLoginPage = System.Text.RegularExpressions.Regex.IsMatch(strURL , strPattern, System.Text.RegularExpressions.RegexOptions.IgnoreCase);
I'm searching for the proper r... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584595",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: how to implement dynamic intercept url pattern i.e from database in spring security 3.0.5 I am new to spring security so not getting how to proceed for making the Url's to be authenticated should come from database.
What things to be added in applicationContext-security.xml and what custom java classes will be neede... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584596",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to intercept POST data in an android webview I have an android app that consists of a webview. It needs to allow users to fill in a form on a webpage and then change the data of the form after the user has clicked submit on the form. The form will use the POST request method.
So my question is, how can I interc... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584597",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "31"
} |
Q: what the alternative to native libmedia in Android 2.3 i am using native code that uses libmedia.so and it was running fine in android 2.2 but when i tried it in 2.3.3 it got this error :
09-28 16:06:28.206: ERROR/AndroidRuntime(3307): Caused by: java.lang.UnsatisfiedLinkError: Cannot load library: reloc_library[131... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584599",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to draw a circle by following MVC architecture I am new to iOS platform and i heard about MVC archtecture.
To draw a circle i just create a separate UIView class and override the drawRect: and able to do this.
But now i want to rebuild the same project using MVC architecture.The main aim is to separate my Model ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584601",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to set PATH environment variable in CMake script? I want to build my sources by Mingw compiler which in not placed on my system PATH.
I tried this in the beginning of my script:
set(Env{PATH} "c:/MyProject/Tools/mingw/bin/" "c:/MyProject/Tools/mingw/msys/1.0/bin/")
And this:
set(CMAKE_PROGRAM_PATH "c:/MyProject... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584602",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "17"
} |
Q: git-svn dcommit fails because the repository name contains a space When attemping to git svn dcommit to a repository that has spaces in it's name, I get the following error:
Committing to http://svn.kuluvalley.com/Meet the Expert/trunk ...
http://svn.kuluvalley.com/Meet the Expert/trunk
Filesystem has no item: '/!sv... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584605",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Disable Hibernate lazy fetching many-to-one associations A topic of many previous questions I see - but not quite as this one however. I understand Hibernates lazy fetching strategies, open-session-in-view etc., but I cant seem to find the solution to this simple little thing, where my association is fetched lazily ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584607",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Join all files in a directory, with a separator I have a directory containing hundreds of files (each having several chars). I want to join them into a single file with a separator, "|".
I tried
find . -type f | (while read line; do; cat $line; echo "|"; done;) > output.txt
But that created an infinite loop.
A: ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584609",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: Return a typedef in C In a .h file I defined:
#define PAIR_TYPE(type1, type2)\
typedef struct { \ // added \ after edit
type1 first; \ // added \ after edit
type2 second; \ // added \ after edit
}; // added ; after edit
#define MAKE_PAIR(val1, val2) {v... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584610",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Dont hide if it hasClass in jQuery Okay, start out saying this is hard to explain with words only.
So i have setup a example here: http://jsfiddle.net/AFhvS/2/
I have a code in PHP, that show() the span element with X .sletindtastningfelt if it's filled.
In the jsfiddle, it's placed at the bottom in the js field.
j... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584612",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Why do I get many repeated compiling messages during a grails build in intelliJ Here's the build console trace when I launch a grails 2.0 app in intellij in debug mode. It didn't used to be so verbose in grails 1.3.4
"C:\Program Files\Java\jdk1.6.0_22\bin\java" -agentlib:jdwp=transport=dt_socket,address=127.0.0.1:5... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584615",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: JGit: Count objects How can I retrieve the total number of git objects in a repository? (I search something like the git count-objects in JGit.)
I made a Java program that calculates statistic values and has to read every object (blob, tree, commit, tag) of a git repository. Something like a progress bar should show... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584616",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How to monitor a directory for changes in Python?
Possible Duplicate:
Monitoring files/directories with python
I am making an API server that allows hot-deploying of code. And yes, there are dozens of questions about re-importing modules. I just want to monitor a directory, and when a change is detected, perform ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584626",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to get a list of physical storage devices? I want to get a list of physical storage devices.
I've seen some code but that actually loops and does something like brute force.
I want to know what is the general way of getting the list of physical storage disks.
I've found CreateFile(). But I cannot understand how... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584627",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: compiler-optimization for numerical stability do GCC or similar compilers perform optimizations that are aimed at improving the numerical stability of floating-point operations.
It is known that seemingly simply operations like addition or computing the norm of a vector are numerically unstable if implemented in the... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584632",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: What language or framework commonly uses tags like "" You will see it in the source code of many web sites as follows:
<!--ls:begin[stylesheet]-->
<!--ls:end[stylesheet]-->
It appears to be some method of moving pieces defined in the body of some templating engine to the <head> of the the document (or wherever make... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584637",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: How can I dim the backround view when a custom View is displayed How can I dim my background when custom View is showing? In my Activity I have Relative Layout with some photo in background. When user do some action - FrameLayout appears in center of screen - and then I want make it to act like dialog - dim everythi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584641",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: SQL Stored Proc eats memory over time I've been trying to diagnosis this 30 MB memory leak in this webservice. It has some bulk gets from SQL using standard stored procs. Each "bulk" returns around 10,000-50,000 rows. The webservice generates its report and sends it to the caller.
It seems everytime you call fo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584644",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to stop a thread in my unmanaged DLL made in C# I have a C# DLL that starts a thread for polling an USB device. My problem is that the workerObject and workerThread in the StopListenUSB function are null.
public class USBDevice
{
private Worker workerObject;
private Thread workerThread;
public void Sta... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584645",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to hide JDialog from JApplet when user switch browser tab? Problem: user starts long operation from applet; JDialog with progress bar is displayed. User open/switch to another browser tab - JDialog is still displayed (and annoys user).
JDialog should be hidden when user switch to another tab; and displayed again... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584646",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Asking ffmpeg to extract frames at the original frame rate On the FFmpeg documentation (here, and here) I read that, by default, FFmpeg chooses to extract frames at 25 frames per second (otherwise you can specify a framerate with the -r option)
My problem is that I have a folder with dozens of videos, each of them r... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584647",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "7"
} |
Q: jQuery Ajax request in Sharepoint 2007 (SOAP) I have the following web service:
SOAP 1.1
The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.
POST /_vti_bin/QuickLinks.asmx HTTP/1.1
Host: myintracomm-design.ec.europa.eu
Content-Type: text/xml; char... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584649",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: java data types to byte array I have a Java class
public class MsgLayout{
int field1;
String field2;
long field3;
}
I have to write this object as a byte array in a Socket output stream. The three fields (instance variables) have a layout. i.e. field1 must occupy 1 byte, field2 must occupy 4 bytes and field3 must o... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584652",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Return an item in a nested list (python) I'm doing a lab for a basic programming class in Python, and I can't figure out how to return a number in a list, in another list.
I'm supposed to return 4 with "one expression and no parenthesis"
[1,[2,[3,4]]]
Any ideas?
All I've gotten so far is returning [2,[3,4]] and I h... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7584653",
"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.