text stringlengths 8 267k | meta dict |
|---|---|
Q: Recursive method will not move on and remains in an infinite loop (Java ) I'm learning about recursion as part of a Java tutorial and I am looking for a little help.
We need to make a recursive Java program which will work out how to get from one city to the other when there is no direct flight.
My problem is that I... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545689",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-3"
} |
Q: jQuery custom background through a cookie I'm making background changing script for my site. Everything works fine except the cookie which should store the required value. I'm using jQuery 1.3. IE 8 says: 'object doesn't support this property or method on line 47 char 118567432'!? Any help will be greatly appreciate... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545691",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to Identify if the process in User Interface Process? How can I get information from a process that it is UI(User Interface) process or non-ui?
With UI process I mean, Finder, Dock, System UI server, or any other mac application which has UI interface and it is used by Window Server.
I want to determine this in... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545695",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: I want the stage to react every time some changes are made to certain objects. Is there a way to write custom Event? I want the stage to react every time some changes are made to certain objects. Is there a way to write custom Event? I could of course modify this object, but I would like to know if there is any more... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545698",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: FB JavaScript SDK is giving wrong permissions dialog for my friend, but new one for me Currently, I'm using
<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js"></script>
<script>
FB.init({
appId: '214620658601362',
cookie: true,
status: true,
xfbml: true,
oauth: tr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545702",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-2"
} |
Q: specify which vim is called from a command like git I'm doing some rails dev on mac osx. I have an alias for vim that calls the version in homebrew
vim: aliased to /usr/local/Cellar/vim/7.3.266/bin/vim
But if I execute say git rebase -i [sha] then it will call a different vim from the one that's aliased. It's calli... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545705",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Clicking game - Operator '-' cannot be applied to operands of type 'string' and 'int' error Iam making a clicking game, but there is an error i can't get working correctly.
The error is:
Operator '-' cannot be applied to operands of type 'string' and 'int'
in the private void timer1.tick.
i have been looking on goo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545709",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: ASP.NET + C# HttpContext.Current.Session is null (Inside WebService) this is how I initiate the session
protected void Session_Start(object sender, EventArgs e)
{
HttpContext.Current.Session["CustomSessionId"] = Guid.NewGuid();
}
in my solution under a class library i am triyng to access it and get... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545711",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "14"
} |
Q: SSL, getting an upper bound on the length of a decoded message based on the encoded message Simply put, when given an encoded message of length n, is there anyway I can bound in advance the length of the decoded message (for memory allocation purposes)?
I thought that the length of the message added to the length of... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545712",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to use jquery method in asp.net Q:
I wanna to know how to use this jquery in asp.net.(steps)
$(...).scollTo( $('<%= txt_evaluateWeights.ClientID %>') )
My original question is How to prevent the Focus() method from scrolling the page to the top
My aspx:
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545716",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to create this custom edittext ? Please help In an application I wish to create an edit text control like shown here http://www.customeuropeanplates.com/images/UK-License-Plate.jpg can anybody please suggest how should this be done? I know this is something easy but I am new to android.
A: Create a 9-patch draw... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545721",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: C#: Calling method in another thread
Possible Duplicate:
How to update GUI from another thread in C#?
Following scenario:
I have a class with some GUI elements (winforms). This class has a update method which changes things on the controls.
I also have a FileSystemWatcher. This object gives me a callback whenever... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545724",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: USB Detection on MAC cocoa application using NSWorkspace notification I am trying to implement USB detection using NSworkspacenotification method, using this code
int main (int argc, const char * argv[])
{
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
[[[NSWorkspace sharedWorkspace] notificati... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545730",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Write a comma in a CSV File with PHP i am sending a csv file as a header and i want to use a comma (not to seperate, just to use). how would i do that?
i'm using PHP and i can not use fputcsv because i'm sending it as a header.
A: Either write the CSV to file first and then send it via readfile or write it to the o... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545733",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: Updating a ProgressDialog using an AsyncTask I need a AsyncTask to run my ProgressDialog while I'm fetching data from the network.
I understand the AsyncTask. But I have the network calls in more than a dozen places. How can I reuse a single AsynchTask class for all these calls as my call to the network is from dif... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545734",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: DataContractJsonSerializer leaving quotes in strings I am using the DataContractJsonSerializer on Windows Phone 7.1 (Mango RC) to pull data from a web service. The data from my web service looks like this:
[
{
"Color":"\"black\"",
"CurrentPlayerTurn":1,
"GameId":"\"3adbffa7b5744634aca0e4b743014247\"",
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545735",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Create and Write to Files with JavaScript/JQuery A few days ago I started to build a "Talk To Us Page" In c#.
So, I did a few buttons and text arena options..
And it was easy as C# should be. You just use a system IO or any thing and write to files..
I tried to do some thing very similarly with JS\jQuery and had no ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545736",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to format localized text in JSF I'd like to keep localized text in a formatted manner (Using the <resource-bundle> in JSF)
For example:
in english.txt:
welcome_msg = <p>Hello <b>Friend</b></p>
in spanish.txt:
welcome_msg = <p> Ola <b>Hombre</b> commo esta? </p>
(Just random examples)
If I just use <h:outputTex... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545746",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How can I create a DLNA server application in Android? I am looking to add DLNA server capabilities of one of my current applications (for movie management), and I've tried to do some searching for any documentation on it, but so far I've only found a project called Cling, which should support Android. I have yet to... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545748",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How and when are shared memory backing files removed in Linux? I am using the combination of shm_open() and mmap() to create a shared memory segment for IPC. What I'm wondering is how the backing files (in /dev/shm in my system, Linux kernel 2.6.31) are cleaned up.
My questions are threefold:
1) Is it the process's ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545750",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Mongoose: Suggested database schema Ok so I am coming from a mySQL background and am now trying to rebuild a site using nodeJS and Mongoose. My old mySQL schema looked something like this (simplified):
users
user_ID
user_name
user_email
user_password
groups
group_ID
group_name
group_description
group... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545754",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "7"
} |
Q: How to search text surrounded by double-quotes with RegEx? I have a string with some HTML code in, for example:
This is <strong id="c1-id-8">some</strong> <em id="c1-id-9">text</em>
I need to strip out the id attribute from every HTML tag, but I have zero experience with regular expressions, so I searched here and ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545756",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "7"
} |
Q: why does this query return a row with nulls compare
SELECT distinct u_id,timestamp as time
FROM my_table;
and
SELECT distinct u_id,max(timestamp) as time
FROM my_table;
When my table has no rows at all (or if I add a where clause that matches no rows):
The former returns an empty results set (which is what I exp... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545766",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: Text::MicroTemplate and Server side validation [Perl] I have a form, which I use Text::MicroTemplate to add some fields to it, such as:
User Name
Last Name
Email
the fields are added using a loop inside a <form> tag, the data for these is validated using a regex (sent as a parameter to the template and "hidden" in t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545768",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Applet works in IDE, but not in browser I have created a simple applet and HTML document, but when I open the HTML document, the applet will not show. Java is enabled, and the code should be correct. but I just get a blank page. The applet runs fine in eclipse. I tried removing the stop and destroy methods which did... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545772",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Socket.BeginReceive callback - message separator When the callback assigned by Socket.BeginReceive() gets some bytes, what is the best way to know I have the whole message? Should I have the first 4 bytes of each message I send hold the length of the message?
I am sending an XML file in each message so there is no u... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545773",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to loop through all controls in a Windows Forms form or how to find if a particular control is a container control? I will tell my requirement. I need to have a keydown event for each control in the Windows Forms form. It's better to do so rather than manually doing it for all controls if what I have to do for a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545775",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "12"
} |
Q: C++ error cleanup If I have a function I call when there is an error in my app, and I call ExitProcess in that function to exit. Do I need to find a way to have it call things like WSACleanup() and ReleaseMutex and RemoveFontMemResourceEx, and free other manually allocated variables?
I believe the system does this a... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545783",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Google map w/ circle that changes every second? How do I create a google map with a circle whose center changes every
second? I tried the below: (also at
http://test.barrycarter.info/sunstuff2.html)
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<style typ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545788",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: read xml in UTF-8 in scala I am trying to read a file to xml with the following code:
import scala.xml._
object HebrewToEnglishCityTranslator {
val data = XML.loadFile("cities_hebrew_utf.xml");
for(val entry <- data \\ "city") {
val hebrewName = (entry \\ "hebrew_name").text
val englishName = (entry \... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545792",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "10"
} |
Q: Get local time from UTC datetime in ActionScript 3 Does AS3 have a way of converting a datetime variable into local time?
A: //Some date string you got from somewhere
var dateStr:String = "Sun Sep 25 22:30:33 GMT+0600 2011";
var date:Date = new Date(dateStr);
//Use date.toLocaleString() to get a local time string ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545794",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to select multiple columns without duplicates in one column in Oracle The problem:
I need find top client for supplier.
Top client has max items sum on all orders.
If supplier has 2 top clients, then top client will be with min order id, which means - who first created order and get max items - it will be top.
I... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545795",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Modeless, parentless wxDialog still always above wxFrame window in z-order? My program opens a wxFrame-based window and multiple modeless and parentless wxDialog-based windows. It all works beautifully, except that the wxDialog-based windows insist on always being on top of the wxFrame-based one.
I know about wxDIAL... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545804",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: iPhone how to invoke a classes static function by string? I have a static function defined in a class called "Character" as:
+ (UIImage) getImage;
I have a set of other classes that extend the “Character” class called “Bob” and “Jim”, each of these classes define a different file to get the image from. I need to be... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545809",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: do you think http protocol mix character stream with byte stream is not a good design Firstly,when I say http protocol mix character stream with byte stream,I mean request head is character stream and request body is byte stream(specified by content-length ),they are seperated by an empty line.
This design make http... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545814",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Copying a file multiple times using loop; C/C++ I wanted to copy a file multiple times using different names.
The program is this:
#include<iostream>
#include<cstdio>
#include<cstdlib>
#include <sstream>
#include<cstring>
using namespace std;
main()
{
string text;
int i;
char ch;
ostringstream oss;... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545817",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: libdvm.so location I have a linker error when trying to build my JNI application:
undefined reference to `JNI_GetCreatedJavaVMs'
From this thread I figured out that I need to use libdvm.so to resolve the issue. But I can't figure out where the libdvm.so is located.
I'm using Android NDK r6 on MacOS.
A: libdvm.so is... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545819",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Total Number of Row Resultset getRow Method Read the Following Code:
public class selectTable {
public static ResultSet rSet;
public static int total=0;
public static ResultSet onLoad_Opetations(Connection Conn, int rownum,String sql)
{
int rowNum=rownum;
int totalrec=0;
try
{
Conn=ConnectionODBC.getConnection()... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545820",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "22"
} |
Q: Get child element in another child element of XML I have a XML file that goes like this... (the XML file was taken from web services [WCF] after passing some value into it.)
<Title>
<Questions>
<QuestionID> 1 </QuestionID>
<QuestionType> Quiz </QuestionType>
<Question> What is the shape? </Question>
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545821",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: bring page to foreground? multipage editor I'm develpping an RCP user interface. I have a multipage editor in which pages are editors (EditorPart). From a first page in my multipage editor I want to open a second one if a button is pressed. I've managed to do that but the problem that I'm facing is that the created ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545822",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Entity Error in GDataDB example Im getting the error "the type or namespace name 'Entity' could not be found" from the following code snippet.
So ive added the reference "System.Data.Entity" but its still not working...
Why is that?
Error 1 The type or namespace name 'Entity' could not be found (are you missing... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545825",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Xcode: Loading TabBarItem titles after ordering I'm using this [tutorial] to save user's customized TabBarItems order as my app has more than 5 tabs
The tutorial's concept is to save the TabBarItem titles in the NSUserDefault and load them next time app is opened.
It's working great for english language as my TabBar... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545830",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to create custom annotation and callout bubble in iphone? I want to create a customized annotation and callout bubble on MKMapView. I need to use a customized view rather than default annotation pin and annotaion view(which is limited to show only title and a single line description). When user tap on an annotat... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545839",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Wait for ajax to complete before method return I know I can set the call to synchronous, or wrap everything preceeding in the complete() callback, but it seems inelegant. Here's what i've got:
_loadShader: (url) ->
(@_loadResource url, false).complete (e) ->
vert = e.responseText.split '[Vertex shader... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545845",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Create a basic application that will act as a tutorial for how to use another app I have a very particular application I have developed. I want to create a second app, ideally in visual basic, that provides a tutorial/ guide on how to use my original app step by step.
I imagine PowerPoint slide style images embedde... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545846",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Password strength validator, how would you improve this? First of all, I am validating password length with StringLength validator so I want to keep that out of the PasswordStrength validator. Any ideas how to improve this?
I think my approach with arrays and array_diff is not very elegant but the only other way I c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545847",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: NSArrayController for polymorphic class I have the following (stripped down) class interfaces:
@interface ScriptEvent : NSObject {
...
}
@interface SingleLine : ScriptEvent {
NSString *line;
}
@interface MultiLine : ScriptEvent {
NSArray *lines;
}
Another parent class holds an NSArray containing a list of S... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545848",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Validation only in specific form Is there any way to trigger validation only in specific forms(controller's action), not globally at every save or update?
Something like User.create(:validate=>true) flag.
A: Yes, you can supply conditionals to the validations, eg:
validates_presence_of :something, :if => :special?
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545850",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: Simulate more than 2 touches on iPad/iPhone simulator Is it possible to simulate more than 2 touches on either the iPad or iPhone simulators?
Holding down the ALT key allows 2 touches but no more.
A: The default sim doesn't support more than 2 touches. But there is a 3rd party simulator called iSumulate which suppo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545851",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Problem using regex to remove number formatting in PHP I'm having this issue with a regular expression in PHP that I can't seem to crack. I've spent hours searching to find out how to get it to work, but nothing seems to have the desired effect.
I have a file that contains lines similar to the one below:
Total','"12... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545853",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Why are pointers not needed for structures and primitve types? On C and Objective-C, why aren't pointers needed for structures and primite types?
A: Primitive types can be on the stack (no pointer) or on the heap (pointer), Obj-C objects can only be on the heap (pointer).
In some languages such as C++ objects can b... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545855",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-2"
} |
Q: Rendering tabs (jquery ui) with Backbone.js & underscore.js I'm currently playing with strophe.js, backbone.js & wijmo (UI library based on jquery UI) and working on a chat interface. I have two dialog boxes, one is the contacts list, the other one will be the chat container. Chat will be organized in tabs with the ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545858",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: is there anyway to have just right or just left horizontal space using ckeditor I am using ckeditor and I have a number of pictures in my content. One issue i see is that you have the ability to add horizontal or vertical space around a picture but you can't just set a right or just a left horizontal picture. Norm... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545860",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: heapq.merge: after merge the result of merge, the original merge is empty First I created two results of a & b by using heapq.merge, but after mergeing a&b, I found the list of a is empty.
>>> a=merge([1,2],[3,4])
>>> b=merge([4,5],[6,7])
>>> list(a)
[1, 2, 3, 4]
>>> merge(a,b)
<generator object merge at 0x365c370>... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545862",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Canvas distorts drawing. How do I get the scale factor between the set size and the styled size? I have this canvas:
<canvas id="game" width="280" height="280"></canvas>
The css styles the canvas via:
canvas
{
width: inherit;
height: 280px;
}
As the width can change, the canvas distorts the drawing. I need... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545863",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: Why does this image not displaying (broken image icon)? I am trying to display an image that I saved to Datastore with DisplayImage handler below but I only see a broken image link. Do you know why? Thanks!
class HomePage(db.Model):
thumbnail = db.BlobProperty()
firm_name = db.StringProperty()
...
class Ima... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545865",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Cropping tool/script for PHP/Javascript I am looking for a decent image cropping solution, ideally a script that would do the following :
Allow to upload an image (ideally via ajax), crop the image using some jQuery like cropping tool and then save the 'new' cropped image while retaining the image untouched.
Is ther... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545869",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Is there a way to configure a JavaEE project to run with a default target runtime? I'm developing a JavaEE system with several applications which consists of many projects (EARs, EJBs, etc).
Whenever I change my runtime target of the Enterprise Server I have to reconfigure each project through Eclipse's wizards, and... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545873",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: AS3: Random Point on Irregular Shape I have a MovieClip holding an irregular shape such as this one:
I need to generate a random point on this shape.
I can use brute force by generating points within the bounding box and then hitTesting to see if they reside on the irregular shape. However, I'm sure there's a more... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545874",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Output an array I have created a shortlist feature which acts a bit like a shopping cart. I output the items in the shortlist by:
$i = 0;
while ($i < $countArray){
echo $_SESSION['shortlistArray'][$i]." <a href='shortlistRemoveItem.php?arrayID=$i'>[x]</a><br />";
$i++;
}
and delete an item by
$arrayID = $_GET["ar... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545876",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: C# generate a public and private keys for the DSA encryption algorithm How do I generate a public and a private key for the DSA algorithm in byte array format?
A: In DSA algorithm (from wiki):
*
*Public key is (p, q, g, y).
*Private key is x.
var dsa = new DSACryptoServiceProvider();
var pr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545877",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: String to a HH:mm:ss time and finding the difference between 2 times public static void stringToDate(String time, String time2) {
try {
DateFormat formatter = new SimpleDateFormat("HH:mm:ss");
Date t1 = formatter.parse(time);
System.out.println("Users first date: " + t1);
} catch (Pars... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545878",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Problem in update query in JSP all, i am writing an update query in jsp, but i am having a syntax error in it, can anybody help please. here is the query
<%
HttpSession ss=request.getSession();
String get_name=ss.getAttribute("key").toString().toUpperCase();
if(get_name == null)
{
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545880",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-2"
} |
Q: Safari 5.1 cookie format specs the way of storing cookie for SAFARI has changed whith SAFARI 5.1
and that they add a kind of integrity control code
in the last 8 bytes of the file :
The file is %APPDATA%\Apple Computer\Safari\Cookies\Cookies.binarycookies
Does anybody know what s the last 8 bytes corresponds to ?
CR... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545885",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "9"
} |
Q: C++ ofstream is changing output format randomly? I have a function that is writing to a .txt file.
ofstream fichier("C:\\users\\me\\Desktop\\test.txt", ios::app);
then :
fichier << "some text here";
The text i'm writing is a log file containing the history of my application changes.
As i'm french, i'm writing char... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545889",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Raphael asp.net - Microsoft JScript runtime error: Object expected I am new to Raphael, as well as asp.net. I am trying to test a simple raphael example with asp.net, but I keep geting the following error: Microsoft JScript runtime error: Object expected
this error occurs in this line:
var paper = Raphael("diii", 32... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545893",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: jQuery AJAX to call Java method Using jQuery AJAX, can we call a specific JAVA method (e.g. From an Action class)
The returned data from that Java method would be used to fill in some HTML code.
Please let me know if this can be done easily using jQuery (like it does in DWR)..Also for multiple data points in HTML, d... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545898",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How do add date and time stamp to an INSERT via PHP with mySQL? I have an insert script with mySQL. I need to place the date and time when the record is created in the 'add_time" column.
Can anyone show me how to modify my existing script to do this? Do I need a separate PHP script?
I would like the date to appea... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545912",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Importing frameworks on xcode 4 issue Lately any framework I attempt to add to my project fails with "No such file or directory".
Eg for GameKit:
<GameKit/GameKit.h>: No such file or directory
The strange thing is that the frameworks that I added some time ago are found, but if i try to add the same framework now,... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545914",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: GridView rows overlapping: how to make row height fit the tallest item? Like this previous person, I have unwanted overlap between GridView items:
Notice the text, in every column except the rightmost one.
Where I differ from that previous question is that I don't want a constant row height. I want the row height t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545915",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "44"
} |
Q: How can parents waits all child processes finish then exit when it receives SIGINT? I'm writing a multi process program in C.
I hope parents process can wait all child processes finish then exit when
it receives SIGINT.
I have two questions.
*
*How can parents record each pid of child process it forked.
Child... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545916",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Default parameters for methods of template class Is there a way to provide default parameter values for methods of a template class? For example I have the following:
template<class T>
class A
{
public:
A foo(T t);
};
How should I modify this to give foo a default parameter of type T? For example: T is int then... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545917",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: php regex [b] to "'\[b\](.*?)\[/b\]'is",
Is my current RegEx working. But I want to change the [] to be <> instead. But it doesn't work... What more then just the [] do I need to change.
A: Try ~ as a delimiter instead
preg_match("~<b>(.*?)</b>~is", $text, $b);
A: There are various BBCode parsers available fo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545920",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Working MDB example in JBoss 7.0.1? Here's an EJB3 MDB that used to work for me in JBoss 5.1:
@TransactionAttribute( TransactionAttributeType.NOT_SUPPORTED )
@org.jboss.ejb3.annotation.Depends("jboss.messaging.destination:service=Topic,name=IncomingArticleNotifications")
@MessageDriven(
activationConfig = {
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545921",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How can i replace characters AND numbers at the same time I have a string that looks like - /celebrity.html#portfolios/jennifer-aniston-2006#img10
I want to remove #img10 (which can also be #img6; any number really).
I have used this code
var docLoc = document.location.href.replace("#img", '');
var docLoc2= docLoc.r... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545923",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Android: Scale fixed Layout down i want to scale my android application, basically i developed it for 800x480 display with a AbsoluteLayout. This is necessary for my Application, i can't change it.
Now the Problem:
When i start my app in the Emulator the buttons disappear and the images are extremly large. I thought... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545926",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How can I add a scrollbar to my c# dockable forms when they are docked next to each other? I have some dockable forms that have a minimum size set so that when they are floating they always get the right size. But when I dock them next to each other some of the content is hidden. I want to add a scrollbar that shows... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545933",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to remove validation using instance_eval clause in Rails? I would like to enhance existing class using instance_eval. There original definition contains validation, which require presence of certain fields, ie:
class Dummy < ActiveRecord::Base
validates :field, :presence => true
end
Now I want to change that... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545938",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "39"
} |
Q: How to change authenticate method on IIS 7? I've got an error which tells me unauthorized. How and where to change that webserver allows anonymous (public) access?
HTTP Error 401.2 - Unauthorized
401.2 - Logon failed due to server configuration.
Something has happened on my local machine when I made the latest updat... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545951",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How to check the registers value of the network card on ARM Linux? On our device, we observed that the IPv6 NS packet with multicast address of Layer2 were droped. The tcpdump cannot capture these packet so I guess the packets were dropped by the network card driver(correct me if I am wrong).
To verify this, I want... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545952",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Push just one file to GitHub from a local repository I have a repo with multiple scripts. One of them is especially useful and I want to share it using GitHub.
How can I export one file (with commit history) to a GitHub repo without sharing all other scripts from the same repo?
Something like:
git remote add 'origin... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545953",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: AcceptButton doesn't work in case there are TabControl on the form In the following form, I want the AcceptButton to be OK button, but although I set the property to the Form that OK button is the accept button, the actual result is Test button.
How to fix it?
A: Earlier i got this kind of problem, but got solved ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545954",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: password reset url in asp.net I'm looking to send a user a link if they forget their password.
I have it that they enter their email address and an email is sent to them with a link to reset their password - although I want this link to expire in two days.
Looking at a password reset email I got sent from an online ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545958",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Looping with Conditions through a xml file using lxml etree I wonder if it's possible to make conditional statments connected with a tree.findall("...") statement in lxml library?
I have the following xml structure in a file
<sss version="1.2">
<date>2011-09-23</date>
<time>12:32:29</time>
<origin>OP... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545960",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Delete group containers in runtime in flex i am trying to make a some groups within a predefined group at run time. i can make groups, the code is working fine. Now i have added two buttons in each group which is created in run time. now the problem is one of the button is x . the property of button should be when i... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545961",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Data mining for significant variables (numerical): Where to start? I have a trading strategy on the foreign exchange market that I am attempting to improve upon.
I have a huge table (100k+ rows) that represent every possible trade in the market, the type of trade (buy or sell), the profit/loss after that trade close... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545962",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How to COUNT(*) from multi-table query? I have two tables, Snippets and Comments. Snippets has an Id column and Comments has a SnippetId column.
I want to count the number of comments for each snippet.
I tried this:
SELECT
S.Id,
S.Title,
COUNT(*) AS CommentCount
FROM
Snippets S,
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545968",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Converting byte number to grayscale and vica versa I got a number between 0-255 and need to convert it to a RGB grayscale color. And how do I convert a RGB-color to a grayscale value between 0-255?
A: The common formula is luminosity = 0.30 * red + 0.59 * green + 0.11 * blue. Matches the human eye's color percepti... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545969",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: Which HTML DOM parser works best on Android? I need to process some HTML pages in my Android App and I would prefer to use XPath for extracting the relevant information. For regular J2SE there are a lot of possible implementations for parsing regular HTML into a org.w3c.dom.Document:
*
*jTidy
*TagSoup
*Jericho... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545972",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: What should I use for guest identifier? I'm opening up a feature on my site that will not require a user to create a profile. I need to create and track user ids so I'm curious what others use as an indentifier for guest accounts. Here are some of my thoughts:
*
*Capture the client IP address and use that
*Assi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545975",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Move commits from one branch to another and then merge them back in I have a tree:
/--b1---b2 <-- topic b
/
a1---a2 <-- topic a
where 'b' depends on 'a'. Then I realize I need to do some changes related to topic 'a' in order to continue with 'b', but i'd like to do them on 'b' as a normal develop... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545982",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "8"
} |
Q: How to use BindingSource with not 1 to 1 set of columns between the list and the DataGridView I have the following situation working with winforms:
*
*I defined a DataGridView with X columns.
*Bind it to a list containing X-1 columns
dataGridViewMain.DataSource = _bindingSource;
_bindingSource.DataSource = _curr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545991",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Convert Decimal to int in Crystal Report Formula i have used formula to generate a RowNumber for each Record
formula is like this:
shared numbervar rownum;
rownum := rownum + 1;
rownum;
But it displays decimal numbers : 1.00, 2.00, 3.00, 4.00
i want to display only Int numbers in RowNumber : 1,2,3,4,5
how can i do ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545992",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Handle multiple db updates from c# in SQL Server 2008 I like to find a way to handle multiple updates to a sql db (with one singe db roundtrip). I read about table-valued parameters in SQL Server 2008 http://www.codeproject.com/KB/database/TableValueParameters.aspx which seems really useful. But it seems I need to c... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7545998",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How do I post adaptive payment information to paypal? I've managed to get an adaptive payments script to work in the apigee console, here is the request:
X-PAYPAL-REQUEST-DATA-FORMAT: JSON
X-PAYPAL-APPLICATION-ID: APP-80W284485P519543T
X-HostCommonName: svcs.sandbox.paypal.com
Host: svcs.sandbox.paypal.com
Content-L... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7546001",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: SQLiteDatabase select rows where column is equal something I have a SQLiteDatabase and I want to select the rows where one of the row's column is equal to a text. I know to do this with integer but I don't know how to do this with text. And I would like to have more options as WHERE theColumn is equal a or b or c.
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7546004",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Xamdatagrid howto get the current Cell on right click here is the scenario I want ta achieve on some XamDataGrid
*
*Some Cells may be selected in the grid - cells and not records
*User right clicks on a cell in the grid
I would like to add the right clicked cell to the SelectedItems.Cells collection of the XamD... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7546006",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Pointer to first element of C struct is the same as pointer to the struct. But not in C#: Interop problem Sorry for title, I have an interop problem.
The C dll that I'm using request, in a function, a pointer to the first element of a struct, however this in C can be cast to a pointer to that struct, while this is n... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7546007",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: JFileChooser inside JPanel; how to get users choice The default JFileChooser works, but what I don't like is the fact that it pops up. I'd rather have one GUI in which all the action takes place.
Now, I did manage to do that. The code below places the FileChooser menu nicely inside the GUI, instead of popping up abo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7546008",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: obtaining an AudioInputStream upto some x bytes from the original (Cutting an Audio File) How can i read an AudioInputStream upto a particular number of bytes/microsecond position ?
For example :
AudioInputStream ais = AudioSystem.getAudioInputStream( new File("file.wav") );
// let the file.wav be of y bytes
Now i ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7546010",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.