instruction_seed stringlengths 1 35.8k | _source stringclasses 1
value |
|---|---|
I'm doing a app which allow user to search on the server. how can i get the text from the Quick Search Box and send to server?
if (Intent.ACTION_SEARCH.equals(intent.getAction())) {
String search= intent.getStringExtra(SearchManager.QUERY);
}
the string "search" is it the text which typing by user?
P/S: sorry a... | stackexchange/codereview |
I am trying to integratae my Grails application with extJS.
Below is the code in my edit.gsp file.
<%@ page import="tune.Music"%>
<script type="text/javascript">
var ds = new Ext.data.Store({
autoLoad: true,
proxy: new Ext.data... | stackexchange/codereview |
let's way that one of my controller's action gets - as a parameter - an encrypted string. A problem is, that when the URL looks
MyAccount/Activate/?code=DbXQ2SQiwYYiDhC+ahAppa23P95YifE2z6uyvnhWCFE=
the 'code' parameter in that action looks like:
DbXQ2SQiwYYiDhC ahAppa23P95YifE2z6uyvnhWCFE=
(the "+" char is missing)... | stackexchange/codereview |
I am attempting to use a single Document Library to store and display multiple Xml documents based on a handful of different schemas. Each schema will have an InfoPath form associated with it.
Can I associate the same file type (.xml) with multiple Content Types, given this will require Sharepoint to inspect the conte... | stackexchange/codereview |
I need to know which interrupt in Linux checks if any key was pressed?
| stackexchange/codereview |
I'm having a very strange CSS issue with my slider and IE. As you can see, the pagination is being displayed above the slider. However, in all other browsers it is being displayed at the bottom of the slider correctly. I cannot figure out why this is, and I have tried everything, hence why I am here. See for yourself:
... | stackexchange/codereview |
I have used an XSL to convert a docbook document into dita. The conversion was successful, bu there are unwanted artifacts which remain. I've gotten rid of a few of them, but I have saved these changes in another XSL which is run after the conversion. My question is: Is it possible to combine this into a single XSL... | stackexchange/codereview |
I'm writing a simple snippet of code for an assignment and I need to convert a decimal number to binary, octal, and hexadecimal. I have it working, but I realized afterwards that because of the algorithm I'm using, I print the binary number backwards. The strategy I was using was to print one digit at a time. I'm st... | stackexchange/codereview |
I have a bash script that is being used in a CGI. The CGI sets the $QUERY_STRING environment variable by reading everything after the ? in the URL. For example, http://example.com?a=123&b=456&c=ok sets QUERY_STRING=a=123&b=456&c=ok.
Somewhere I found the following ugliness:
b=$(echo "$QUERY_STRING" | sed -n 's/^.*b=\(... | stackexchange/codereview |
it's possible to return, from a method, an anonymous type list?
I build my list of anonymous type like this
var l = (new[] { new { Name = "thename", Age = 30 } }).ToList();
Thanks
| stackexchange/codereview |
How do I loop a dictionarys values that has a certain key?
foreach(somedictionary<"thiskey", x>...?
/M
| stackexchange/codereview |
I'm working on a existing embedded system (memory is limited, Flash is limited,
...) with an RT OS. All data structures have a fixed size and are allocated
at "compile time" and are therefore suited for RT. There is no dynamic memory
allocation. The programming language is C++, but there is no STL available. I
like to ... | stackexchange/codereview |
I've recently set up a new system and wanted to install Padre to check it out. The Padre install instructions specifically said to install local::lib, so I did so (although I've never had need of it before). I then went on my way installing several other modules, running CPAN from my normal user account with sudo to ... | stackexchange/codereview |
I'd like my users to be able to use Google Translate with my Rails apps. I have forms and login for the app. I keep getting the Rails InvalidAuthenticityToken when using the app through Google Translate.
Any insights on how i can get both to work? I am using Rails 2.5.x.
Thank you!
PS: To clarify, this the authenticity... | stackexchange/codereview |
I have this code to do some ugly inline text style color formatting on html content.
But this breaks anything inside tags as links, and emails.
I've figured out halfways how to prevent it from formatting links, but it still doesn't prevent the replace when the text is info@mytext.com
$text = preg_replace('/(?<!\.)myte... | stackexchange/codereview |
<script language="javascript">
function switchScreen(v)
{
if(v=='d')
{
mf.rows="0,*";
window.frames.topFrame.location='blank.htm';
}
else
{
mf.rows="*,0";
window.frames.topFrame.location='http://sample.htm';
}
}
</script>
<frameset name="mf" id="mainFrame" rows="*,0" frameborder=no framespa... | stackexchange/codereview |
How do you call a function defined in a Groovy script file from Java?
Example groovy script:
def hello_world() {
println "Hello, world!"
}
I've looked at the GroovyShell, GroovyClassLoader, and GroovyScriptEngine.
| stackexchange/codereview |
I have create object lik
e this
testObj.prototype = {
cVar: 15,
init: function(c){
/*initialization code*/
this.cVar = c;
}
};
var a = new testObj(10);
var b = new testObj(20);
Now both object's cVar values is 20. Are they sharing the variable? How i can get seperate variable for each obje... | stackexchange/codereview |
I have dynamic strings, for example
hello bold italic {0} xxx {0}yyy {0} etc...,
abcd {0} how to xyz {0} newline {0}..etc...,
and more.
How to insert <% Html.RenderAction("CartSummary", "ShoppingCart"); %> to the dynamic string at the {0} position?
| stackexchange/codereview |
I'm porting my code to use the new OpenCV C++ interface. I like the possibility to strictly type everything, so derive all my images and matrices from the template class:
Mat_<type> var;
Now I have problems using the distanceTransform function. My code does something like this:
Mat_<float> imgGray;
Mat_<unsigned char>... | stackexchange/codereview |
Whenever I navigate to the PayPal sandbox for a transaction, I see the new PayPal sandbox interface because of which I am unable to make transactions. Because the new interface does not return the post parameters after the transaction.
The PayPal new interface is visible on production as well, and the same problem is h... | stackexchange/codereview |
Nearly every table in our database has a FK to the Auditing table which logs created, updated and deleted status (date and username).
We mapped the auditing table to the Auditing class and use it like this:
@MappedSuperclass
public class BusinessObject extends DataObject {
private static final long serialVersionUI... | stackexchange/codereview |
I am wondering if this is possible and within the realms of Access?
I currently have a database system where the user can open up directories/folders related to the record; such as images, docs etc...
This avoids bloat by attaching the images to the records and what not, and works fine.
A user enhancement would be to a... | stackexchange/codereview |
I get a customer name from dropdown and use that value to query an excel spreadsheet, however, the name can contain a single quote (example: Adam's Meat). This breaks my application and how do I make a query with a variable that contains a single quote?
Private Sub cboCompany_Change()
Dim customerName As St... | stackexchange/codereview |
I'm trying to prove the following by induction:
sum(k*2^(H-k), k = 0 .. H) = N-H-1
it's a problem for an algorithms class. I was thinking I could do what I normally do for summations, which is to assume that it works for some P(m) and then increment the sum for P(m+1) and work backwards by adding to the right side wha... | stackexchange/codereview |
I actually don't even know how to call this :P, but...
I have one table, let's call it "uploads"
id owner date
-----------------------------
0 foo 20100101120000
1 bar 20100101120300
2 foo 20100101120400
3 bar 20100101120600
.. .. ..
6 foo 20100101120800
Now,... | stackexchange/codereview |
I am running a Dynamic SOQL query in my apex test code, and the LIMIT clause is not working. It does however seem to work when using it in the production code.
The Query is similar to below. I dynamically build up the where clause using some terms from a form.
string query = 'SELECT name, billingstreet, billingpostal... | stackexchange/codereview |
First off, I am not using Rails. I am using Sinatra for this project with Active Record.
I want to be able to override either to_json or as_json on my Model class and have it define some 'default' options. For example I have the following:
class Vendor < ActiveRecord::Base
def to_json(options = {})
if options.em... | stackexchange/codereview |
I read some documents that share library comiled with -fPIC argument,
the .text seqment of the .so will be shared at process fork's dynamic linking stage
(eq. the process will map the .so to the same physical address)
i am interested in who (the kernel or ld.so ) and how to accomplish this?
maybe i should trace the co... | stackexchange/codereview |
We're working on a site that will make use of the OFX standard to provide access to customer financial data. However, for security we make use of secret question/secret answer, machine tagging, etc. Does the OFX standard provide any mechanisms for security beyond just the simple username/password? I've taken a look ... | stackexchange/codereview |
Possible Duplicate:
Why should I learn algorithms?
Hello, I'm a curious beginner and I don't understand how algorithms and data structures are useful in programming. Are they crucial for being a good programmer? Why should I learn them and how they actually help me when writing code?
Thanks so much!
| stackexchange/codereview |
We are trying to use the ListFieldIterator control to display the edit form of a list item including the content type. When viewing the list item in edit mode in the UI, the content type shows up as a dropdown with the list of content types but when going through the listfielditerator, the "content type" field shows up... | stackexchange/codereview |
How to create an array of label??
| stackexchange/codereview |
I am loading the following javascript files from a CDN. Is there any way I can check if these have been loaded correctly and if not, load them from a local folder?
http://ajax.microsoft.com/ajax/jQuery/jquery-1.4.2.min.js
http://ajax.microsoft.com/ajax/jquery.ui/1.8.5/jquery-ui.min.js
http://ajax.microsoft.com/ajax/jqu... | stackexchange/codereview |
I'm making an App that needs to be able to draw new graphics on top of the last set.
This is my current onDraw() method -
protected void onDraw(Canvas canvas) {
canvas.drawColor(Color.WHITE);
if(points.size() > 0) {
//do some stuff here - this is all working ok
canvas.drawLine(p1.x, p1.y, p2.... | stackexchange/codereview |
I'm new to programming & i found this code when i was going through a book. I believe it gives an example of how to use a defined assert() macro. It doesn't compile on code::blocks 10.05. I get errors such as
'#' is not followed by a macro parameter
unterminated #else
in function 'int main()' 'ASSERT' was not declared... | stackexchange/codereview |
Anyone knows what is the initialTomcat5.5 heap size?
| stackexchange/codereview |
What should be a fairly simple regex extraction is confounding me. Couldn't find a similar question on SO, so happy to be pointed to one if it exists. Given the following HTML:
<h1 class="title">Title One</h1><p><a href="#">40.5</a><a href="#">31.3</a></p>
<h1 class="title alternate">Title Two</h1><p><a href="#">12.1... | stackexchange/codereview |
I have the following tables structure:
Item:
Id,
Description
Tags:
Id,
TagName
ItemXrefTag
Id,
TagId,
ItemId
What is the best way to read all the items related to some tag and all other tags, related to the items, to be able to display list of items and all the tags related to the item?
If it's n... | stackexchange/codereview |
An array arrives with some or all of the following values, in any order. What's the best way to order them in ascending size order? So starting with small and ending with XXL. I can usort but am a bit lost as to how the elements should be ordered in my user defined function
Small
XXL
Medium
Large
XL
EDIT: left out so... | stackexchange/codereview |
I have this page called profile. The time is wrong when I run the application. Can someone help me correct the time to the right format?
<asp:LoginView ID="LoginView1" runat="server">
<AnonymousTemplate>
<strong>To View Profiles You Have to Register Or </strong> <asp:HyperLink ID="HyperLink1" runat=... | stackexchange/codereview |
While it's not good practise to find out and use this information in your application, is there a way to find what model of iPhone / iPod / iPad you have. For example: 2G/3GS/4G etc
| stackexchange/codereview |
I need to create a WPF application which is maximized and which rotates amongst about 10 different screens. Each screen will take the entire area and show different content.
I already know how to maximize the window with
My question is what is best to put inside that window to achieve what I want?
Ideally I'd be abl... | stackexchange/codereview |
I am currently have two seperate applications, both perform seperate tasks, but there is on limited occasion times when I need one application to use the other if its there.
So I use a function to check the required application exists:
public static boolean isIntentAvailable(Context context, String action)
{
final... | stackexchange/codereview |
I have been looking around for a website that can automatically provide me we content relative to either a city/state combo, or a zip code. Essentially I want to have a bit of content pertinent to where my user actually is. Does anybody know of any online services that provide something like this? I also wouldn't be op... | stackexchange/codereview |
int BUFFER_SIZE = 4096;
byte[] buffer = new byte[BUFFER_SIZE];
InputStream input = new GZIPInputStream(new FileInputStream("a_gunzipped_file.gz"));
OutputStream output = new FileOutputStream("current_output_name");
int n = input.read(buffer, 0, BUFFER_SIZE);
while (n >= 0) {
output.write(buf... | stackexchange/codereview |
In principle, can I create a class library to store my Extension methods for System namespace for example, and add it to the GAC to be usable from any project in my development machine and able to deployment on the GAC of other machines by the setup project ?
If yes, Do you think it useful?
Thanks in advance.
| stackexchange/codereview |
I'd like to pass some user supplied arguments to an application (using C# on Windows).
The arguments are in a NameValueCollection and I wish to pass them as a string so that the application can be invoked using the supplied arguments and invoked using ProcessStartInfo:
ProcessStartInfo startInfo = new ProcessStartInfo(... | stackexchange/codereview |
In code below (please see comment):
#include "stdafx.h"
#include <iostream>
using std::cout;
struct Base
{
void fnc()
{
cout << "Base::fnc()";
}
};
struct Impl
{
void* data_;
Impl(void (Base::*fp)())
{
fp();//HERE I'M INVOKING IT - I'M DOING SOMETHING WRONG!
}
};
int _tmain(int argc, _TCHAR* argv[])
... | stackexchange/codereview |
I'm obviously pretty new to Android. Does better documentation exist for the set of android.R.* classes somewhere? The API reference is pretty bare bones, many times only containing the resource literal IDs and not explaining how/where they are used. Similarly, it would be nice if additional information (or pictorial e... | stackexchange/codereview |
I am very much confused whether i should use spring
Reason - I want to develop a loosely coupled code which i think can be developed using Factory pattern and interfaces... and dependency injection can be implemented without using spring too...(by passing parameters).. why should i use spring then ?? Which are the... | stackexchange/codereview |
Is this possible? (Assuming Java 6)
A contrived/simplistic example to illustrate my point is:
I have a well-defined RMI interface that will never change (a single JAR file, no template parameters)
an RMIRegistry running on host X;
RMI Services which registry.rebind() to it (RMIRegistry on host X) from host Y; and
RMI ... | stackexchange/codereview |
I am working in the .NET 2.0 framework. I have some code working, just want it working a little more elegantly.
I have a need to effectively "mirror" a Dictionary object such that if we start with an object like this
Dictionary<TKey,TValue> StartDictionary;
We can Mirror it like this
Dictionary<TValue,TKey> MirroredDi... | stackexchange/codereview |
I really like how selenium 2 by convention pushes you towards using PageObjects as POJOs, and then simply using the PageFactory to instantiate the fields in this class.
What I am finding limiting is that we reuse a lot of elements on many different pages. The big problem is that these reused components do not have the... | stackexchange/codereview |
i have 4 annotation with same lat/long as they are pointing some location in 1 building , since they share common lat/long so i can show only one of them on map?? so is there any way to use some error correction so that i can show them Lil side by side??
here is my annotation code
MKCoordinateRegion SecondRegiona;
Se... | stackexchange/codereview |
Given a set of points, what's the fastest way to fit a parabola to them? Is it doing the least squares calculation or is there an iterative way?
Thanks
Edit:
I think gradient descent is the way to go. The least squares calculation would have been a little bit more taxing (having to do qr decomposition or something to ... | stackexchange/codereview |
Webkit allows the use of an external SVG file as a mask for any HTML element. Ie:
<img src="kate.png" style="-webkit-mask-image: url(circle.svg)">
Resulting in:
(More information here: http://webkit.org/blog/181/css-masks/)
Does anyone know if there's a way to do it without an external SVG file? More specifically, ca... | stackexchange/codereview |
How to get that div id="left" has height equal like divs right_up and right_down together ?
<div style="width: 1050px;">
<div id="left" style="width: 80%;height:80%;min-height: 80%;float: left; background-color: blueviolet;">a</div>
<div id="right_up" style="width: 20%;height:40%;min-height: 40%; float: l... | stackexchange/codereview |
IE only bug... go figure...
I get Object doesn't support this property or method when I do this...
$('#the-content').showAsModal({
'leftPosition': 100,
'topPosition': 200,
'centerX': true
});
I extended jQuery like this...
(function ($) {
$.fn.showAsModal = function (options) {
var settings ... | stackexchange/codereview |
I have different screen to work in an android application.
I'm using ViewFlipper for this.
I decided to used different class for different view children
public main extends Activity{
{
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.sign_in);
ViewFlippe... | stackexchange/codereview |
ASP.NET 4 & C# and
I would like to know which CODE, Classes could be useful for creating a WEB APPLICATION that could:
01 - Connect to an HTML file on the web.
02 - Parse its content (text content).
03 - Find out specific content in a page (for example looking for specific keywords).
Also how to implement:
04 - How t... | stackexchange/codereview |
As of now I have no errors in my program, but I need the primary key for one of the tables for a relation for the following Query. but instead of getting a actual number the value the query is sending back is Resource id #4
Here is my Code: (The query that I'm having issues with is the $sql_branch, is there a function ... | stackexchange/codereview |
I have the following SQL query:
select bank.*
from bank
join branch on branch.bank_id = bank.id
join account a on a.branch_id = branch.id
join import i on a.import_id = i.id
It returns exactly what I expect.
Now consider the following two DQL queries:
$q = Doctrine_Query::create()
->select('Bank.*')
... | stackexchange/codereview |
I'm writing a java gui application that has to display dates.
Since this application is primarily going to run on Windows systems, I would like to be able to use date & time formats that correspond to the Windows localization settings.
I found DateFormatProvider class, in Java 6, which gave me high hopes ... but I have... | stackexchange/codereview |
This is probably not possible with CSS, but maybe I'm wrong:
I have a document structure like this:
BODY
DIV[A]
DIV[B]
DIV[A] is position:absolute with fixed with and centered on screen. It has no height setting.
DIV[B] is position:absolute with top:300px. This is the actual content DIV. Inside that, I position... | stackexchange/codereview |
If I start a Java app, it initiates and does some work then goes to thread sleep for an hour, then wake up after an hour and does some more work ...
But my PC is running Win7 and after 15 minutes of inactivity, it will go into sleep mode, so my question is : an hour from I started the Java app, if I don't touch the PC,... | stackexchange/codereview |
i wrote a quick little application that takes a base file of code with some keywords, a file of replacements for the keywords, and outputs a new file with the keywords replaced.
When i was using Ruby 1.8, my outputs would look fine. Now when using Ruby 1.9, my replaced code has the newline characters in it instead of l... | stackexchange/codereview |
I'm pushing a simple view onto a NavigationController. The view loads fine, and when I use the built-in back button, it is properly popped.
However, when I try and pop the view with my own UIButton within the view, I get a crash.
This is the action run by my UIButton:
-(IBAction)iAgreePressed {
[[self navigationContr... | stackexchange/codereview |
I have a script that works in Firefox, Safari, and Chrome. It just doesn't work in Internet Explorer for whatever reason. The code is fairly simple:
<script type="text/javascript">
(function( $ ){
$.fn.tabSwap = function() {
return this.each(function() {
$('.current').removeClass('current');
... | stackexchange/codereview |
I'm work on a tool for learning purposes, it perform a search with google apis. Using HTTPSocket I get the results of the search in json format and then parse it to dictionary with the json.parser written by CharcoalDesign.co.uk
This is how looks json results:
{"responseData": {
"results": [
{
"GsearchResultClas... | stackexchange/codereview |
I'm trying to set up a skeleton Spring 3 MVC project but i'm having difficulties getting the views to render. I have followed the structure as described in the mvc-basic sample project and at http://blog.springsource.com/2009/12/21/mvc-simplifications-in-spring-3-0/?utm_source=feedburner&utm_medium=feed&utm_campaign=Fe... | stackexchange/codereview |
I have some knowledge of C/C++ programming and want to learn CUDA. I'm also on a mac. So what is the best way to learn CUDA?
| stackexchange/codereview |
I was going through http://web2py.com/book/default/chapter/02 and found this:
>>> print 'number is ' + str(3)
number is 3
>>> print 'number is %s' % (3)
number is 3
>>> print 'number is %(number)s' % dict(number=3)
number is 3
It has been given that The last notation is more explicit and less error prone, and is to be... | stackexchange/codereview |
Hii , I am new to C++ programming and need some help regarding the code i wrote below....
Its a basic exception handling program
#include<iostream>
class range_error
{
public:
int i;
range_error(int x){i=x;}
}
int compare(int x)
{
if(x<100)
throw range_error(x);
... | stackexchange/codereview |
How to check the integer value in XSL? I'm using version 1.0
This is what I've tried, but it's not working:
<xsl:variable name="ShowEmailEventId"
select="com.zoniac.emailevent.NewEmailEventBean/emailEventIdString"/>
<xsl:if test="$ShowEmailEventId !=48">
<table align="center"
width="96%"
... | stackexchange/codereview |
Hai friends I am trying to display thumbnail videos in my media player and it's not working. Log cat error is
10-25 19:50:35.577: ERROR/MediaPlayerService(33): error: -2
10-25 19:50:35.577: ERROR/MediaPlayer(65): Unable to to create media player
10-25 19:50:35.916: ERROR/AndroidRuntime(1175): FATAL EXCEPTION: main
... | stackexchange/codereview |
i am trying to make a pdf file with wkhtmltopdf when i pass url www.example.com pdf is generating or www.example.com?id=1
but when i try to put another parameter command execution is not working
www.example.com?id=1&type=u
shell_exec("c:\pdf\wkhtmltopdf.exe
http://localhost/test/index.php?id=1&typee=abc
test.pdf... | stackexchange/codereview |
i have eclipse
Eclipse IDE for Java EE Developers
Eclipse IDE for C/C++ Developers
Eclipse for PHP Developers
Pulsar for Mobile Java Developers
but how can i merge them and have a single interface just by changing perspective rather as if i have installed them from the update site as a plug-in can i just move a... | stackexchange/codereview |
Does anyone know in which situations initializing a NSURLConnection returns nil instead of the created connection. The documentation says it's possible but fails to specify when this happens.
The method/message in question:
[[NSURLConnection alloc] initWithRequest:request delegate:self];
-
According to the NSURLConnect... | stackexchange/codereview |
Just curious, did anybody use WS-AT protocol to propagate transactions in WCF over the Internet in production(wsHttpBinding)?
Is it hard to deploy/support?
Is it a good approach to keep a WS-AT port open?
Or maybe it is better to have a custom solution to support transactions? What do u think?
| stackexchange/codereview |
I am creating a program that listens to video streams over multicast. Listening to one feed with Mono on Linux works fine but listening to 15 feeds drops packets. Running the code on Windows .NET does not drop packets and listening to the feeds with a C program on Linux does not drop packets. Is there something I could... | stackexchange/codereview |
By referring to the answer at Multi Columns Combo Box for Swing, I manage to implement a 3 multi columns JComboBox as follow.
However, this is not perfect. My intention is to have something without the horizontal scroll bar, as follow.
My question is, how can I have a JComboBox drop down list, which is wider than the... | stackexchange/codereview |
Is there something like IIS 6.0 Resource Kit Tools for IIS 7, specially the metabase explorer tool to be able to edit the IIS configurations without editing the .xml and .config files directly?
| stackexchange/codereview |
I'm trying to do a hidden file upload to iframe and i'm stuck.
What seems to be not working is choosing a file.
When I unhide form controls and use them everything works fine.
If I use form controls to pick a file and then submit form via "send" link - it works fine.
When i use choose file link, I can see that file con... | stackexchange/codereview |
Having just spent ages debugging this, I'm keen to understand what exactly is going on!
In a very contrived example, let's say we have two objects, Object1 has this method:
- (void) testMethod:(NSString *)testString
Object 2 has this method:
- (void) testMethod:(NSArray *)testArray
Then, back in Object1, there's the ... | stackexchange/codereview |
When I change the layout_height of an EditText field in Android, the nice looking gradient becomes a hard gray line as you can see here:
Is there a way to either fix or disable this gradient?
thx
Ben
| stackexchange/codereview |
Im trying to check a file line by line for any_string=any_string. It must be that format, no spaces or anything else. The line must contain a string then a "=" and then another string and nothing else. Could someone help me with the syntax in python to find this please? =]
pattern='*\S\=\S*'
I have this, but im pretty... | stackexchange/codereview |
This guys says yes:
http://web.tiscalinet.it/giordy/midi-tech/lowmidi.htm
Same with a really old book from 1998 (Maximum MIDI).
MSDN doesn't mention it.
I'm not getting any sound.
I fill a char buffer with status|note|velocity|status|note|velocity...
Set lpData, dwBufferLength, and dwFlags of a MIDIHDR struct
call mid... | stackexchange/codereview |
I want to get redundant records from the database. Is my query correct for this?
select (fields)
from DB
group by name, city
having count(*) > 1
If wrong please let me know how can I correct this.
Also if I want to delete duplicate record will it work?
delete from tbl_name
where row_id in
(select row_id from tb... | stackexchange/codereview |
Does rails provide solution to get website user time and timezone configured on his local machine, which is used in his web browser?
| stackexchange/codereview |
I'm wanting to do an ANDing or ORing in my MySQL query, but the LIMIT needs to be the same regardless.
eg. SELECTION * FROM table WHERE text LIKE %word1 OR word2 OR word3% LIMIT 10
I'd like this to work the same way it does on Twitter.
| stackexchange/codereview |
Given:
class TestA {
public void start() { System.out.println(”TestA”); }
}
public class TestB extends TestA {
public void start() { System.out.println(”TestB”); }
public static void main(String[] args) {
((TestA)new TestB()).start();
}
}
What is the result?
A. TestA
B. TestB
C. Compilation fa... | stackexchange/codereview |
I'm developing an application in which a Course belongs to a user. I would like to predefine a number of courses, such that a Course's template details are then copied into the users course details. From this initial point each user has a one-to-one mapping with a course.
I'd like to know the best place for the static... | stackexchange/codereview |
I have a static variable in source file test_1.c declared as:
static char var1 = 0;
I need to access the current value of this variable from source file test_2.c. So, I did something like:
In test_1.c
static char var1 = 0;
volatile char var_another = var1;
and in test_2.c, I declare the variable var_another as extern... | stackexchange/codereview |
I am trying to add a button to a page to tweet a message, but I don't want it to link back to the referring page.
For example: tweet adds a t.co link to the end of the tweet that points at the referring page.
Does anyone know of a way to keep that from happening?
| stackexchange/codereview |
say I create someObj like this
var someObj = function(){
var self = this;
//use this normally
document.body.addEventListener('click',function(){
//use self because this is unavailable
},false)
}
new someObj();
In the event this is not the someObj which id like to use but in this case the body element. Is ... | stackexchange/codereview |
I am trying to parse a XML file, it works perfectly in FF but dont in IE. Pls help debug this. The code is as follows.
if (window.XMLHttpRequest)
{// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else
{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xml... | stackexchange/codereview |
In a project on which I am performing maintenance, I am referencing a database stored on another server. This reference was previously pointing at a database on the same server, but my testbed server isn't large enough to store both databases, so I'm having to refer back to the live database.
Anyway, whoever created th... | stackexchange/codereview |
Possible Duplicate:
Delegates, can't get my head around them
I am new to iPhone development, just started learning on my own.
While proceding i came up with a word Delegate. Can any one please explain them to me with an example.
| stackexchange/codereview |
I have the following seems to work in Internet Explorer but not Chrome. Can anyone please explain why, and what I should do to correct it.
<iframe id="confirmed_list" src="./meets/confirmed.php?meet_id=$1" scrolling="no" width="80%" onload="document.getElementById('confirmed_list').height = confirmed_list.document.body... | stackexchange/codereview |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.