instruction_seed stringlengths 1 35.8k | _source stringclasses 1
value |
|---|---|
I have a table which contains the following fields
Supervisorid
Empid
This is just like a referral program. A guy can refer 3 guys under him i.e, 3 is referring three guys namely 4 5 8 similarly 4 is referring 9 10 and 11 likewise 8 is referring 12, 13 it goes like this..
I want a query to get all EmpId under Super... | stackexchange/codereview |
I've found this excellent question / answer on how localize a string with the users current currency settings... localize-currency-for-iphone
This is the code used...
NSDecimalNumber *someAmount = [NSDecimalNumber decimalNumberWithString:@"5.00"];
NSNumberFormatter *currencyFormatter = [[NSNumberFormatter alloc] init];... | stackexchange/codereview |
I have the following possible lines in my code
addEventListener(PropertyChangeEvent.PROPERTY_CHANGE, propertyChangeHandler)
addEventListener("click", propertyChangeHandler)
addEventListener(PropertyChangeEvent.PROPERTY_CHANGE, _propertyChangeHandler)
addEventListener(PROPERTY_CHANGE, _propertyChangeHandler)
They all h... | stackexchange/codereview |
I am trying to set the selected item in my silverlight combobox from a string.
In this example lets say I have a combobox named "MyComboBox" as follows:
<ComboBox Height="23" x:Name="MyComboBox" Width="200" HorizontalAlignment="Left">
<ComboBoxItem Tag="0" Content="Pizza" IsSelected="True"/>
<ComboBoxItem Tag="... | stackexchange/codereview |
Converting an object .tostring() removes the leading zeros. The object is not a fixed length, so I can't do object.tostring("0000000") where the number of zeros represents the fixed length.
An example object value is "0357" when I convert that object .tostring it becomes "357".
Is there a method for keeping the leadin... | stackexchange/codereview |
My application pops up a custom dialog whenever new items are found in an RSS feed, the custom dialog starts off the bottom of the screen, raises up, pauses, and then drops back down.
I want the dialog to be on top of other windows (because the notices are important to me), so I set the TopMost property on the form t... | stackexchange/codereview |
I have an external JavaScript in an asp.net 3.5 project.
While writing different functions, sometimes the JavaScript is loaded into FF and sometimes it is not (based on FireBug) and the JavaScript does not run.
Even if there is an error in the JS it should still load or be visible to the browser, right?
What is the l... | stackexchange/codereview |
I have a generic list declared as so:
List<Dictionary<string, int>> sales;
The string will be a product name and the int the number of units sold. I want to group by productname and sum the total sales. So i can see the number of units sold for each product.
How would i do this using linq?
Thanks!
| stackexchange/codereview |
I'm in the process of converting a system from sql server to mongodb. I believe the project is a good candidate for mongodb, but that's not my question.
In the sql database, i have a stored procedure that I use to return a set of records that need processing. So, I have Processed BIT and LastProcessingRequestDate DAT... | stackexchange/codereview |
I've got the task of making a car rental program, which uses linked lists to control what cars are available for rent, are rented, or are in repair. The 'car' is a structure, and so is the rented list, available list, and repair list.
Heres my current issue. If the user wants to make a new car available, we must add i... | stackexchange/codereview |
When I try to use WebOperationContext.Current in a WCF project, the Current is null. Below is the example. Could anyone please shed a light on it?
WebForm - default.aspx:
ServiceClient sc = new ServiceClient();
Response.Write(sc.DoWork(1) + "<br />");
WebOperationContext c = WebOperationContext.Current; ... | stackexchange/codereview |
For some unknown reason I cannot push a view, I will try to explain the best I can but i have alot of complicated views going on, And it would be a nightmare to explain but say I have the following method.
-(void)showDetailView{
DetailViewController *detailView = [[DetailViewController alloc] initWithNibName:@"Detail... | stackexchange/codereview |
How do i set the DateTime format centrally so that at any time if I use a DateTime.ToString() in my code I get string in the ISO format(eg:2008-2-19 01:00:00) or (2008-2-19)
| stackexchange/codereview |
When working with stored procedures in linq, I can go to my SP and select what type of entity it should be returning. This works fine in most cases, except the time's I'm not sure of what will be returned. If I don't select what type of entity to return i get the standard
return ISingleResult<SP-Name>
I thought I wou... | stackexchange/codereview |
This question is more logic than programming at the moment.. once I understand what algorithm(s) I need to use I'll be looking into how to implement it.
I've got a list of items in a database that need to be voted up or down by users to determine if they are correct or not. The aim is to provide a % for each item to sh... | stackexchange/codereview |
I'm working on my first ever AIR application with flashbuilder - just so you know.
I've bound a mx:DataGrid component to a DataProvider which is a mx:HTTPService fetching an xml file with items. To keep the data up to data I'm polling the webservice on a given interval.
My problem is that I loose the currently selected... | stackexchange/codereview |
I found this article on Context Variables in an earlier version of Ninject. My question is two-fold. First, how can I get this behavior with Ninject 2? Secondly, do context variables carry through down the request chain? For example, let's say I wanted to replace these calls:
var a = new A(new B(new C())));
var specia... | stackexchange/codereview |
Is there anyway to make the OOB version of my Silverlight app open(if installed) when i go to
http://mydomain.com/silverlightapp <--- where the Xap is loaded.
Just like a irc client opens when i go to irc://servername
but instead of prefix can my app open the OOB version if
App.Current.InstallState == InstallState.Ins... | stackexchange/codereview |
I have developed an asp.net website in VS2010. The defaultDocument is set to default.aspx in the root directory, as I have dome many times before.
For reasons unknown an asp:button in default.aspx is not firing correctly when the url is typed in without the file extension.
For example, if I type the url www.mywebsite.... | stackexchange/codereview |
Some coworkers who have been struggling with Stata 11 are asking for my help to try to automate their laborious work. They mainly use 3 commands in Stata:
tsset (sets a time series analysis)
as in: tsset year_column, yearly
varsoc (Obtain lag-order selection statistics for VARs)
as in: varsoc column_a column_b
ve... | stackexchange/codereview |
I have an relatively image in local storage, I want to show it to the user without disturbing UI thread.
I'm currently using
[[UIImage alloc] initWithContentsOfFile:path];
to load image.
Any suggestions/help please....
| stackexchange/codereview |
We are planning to rebuild our intranet on SP 2010 and are planning to have department sites (among others) where one or more people will be able to edit the page, add/remove web parts, etc. I'm concerned about managing this configuration between environments such as production/test. I'd like to know how people go abou... | stackexchange/codereview |
My android application is consists of 20+ activities. I want to perform some task when application is in background (not an specific activity) and want to perform some other task when application is resumed. How to do this? I couldn't find onPause() and onResume() methods in Application class.
| stackexchange/codereview |
In all tutorials about MVVM, I see code behind file is of no great use as we are trying to shift all the logic in view model. Is there any specific reason why we dont use Code Behind file itself as View Model?
I understand benefits of MVVM over typical code behind codes with events and book keeping, but I am trying to ... | stackexchange/codereview |
Explaining jQuery dialogs in the Nemikor Blog, Scott González uses the .each() method on an id selector:
$('#page-help').each(function() {
var dialog = $('<div></div>')
.load($(this).attr('href'))
.dialog( ... );
$(this).click(function() { ... });
});
Since an id selector can only return a single element, ... | stackexchange/codereview |
We have a Silverlight 4 client connecting to RIA services. It's based on the standard "Business Application" Silverlight application in VS 2010. The objects we send to the client over RIA services are EF 4 entities that are POCO objects generated from our edmx by T4. Our RIA service is a LinqToEntitiesDomainService<> o... | stackexchange/codereview |
I am trying to use hook_nodeapi in my template.php file to alter the breadcrumb. I have tried altering the 'if' statement, but it seems as if Drupal is not even using this hook in my template.php.
function gh_nodeapi(&$node, $op, $a3 = NULL, $a4 = NULL) {
$productNodeType = 'product';
$tid = preg_replace('#[^\d+]#i... | stackexchange/codereview |
I am trying to implement a UIpicker with numeric values in a Actionsheet on a text box event. When the user touches the text box, i want the UIpicker to pop up and allow a user to select a value. Do i have to declare the values in a array or is there some other way to do that?
| stackexchange/codereview |
Goal
Find a perfect, flexible schema for storing many different types of objects with a wide variety of links between them in a relational database.
Problem
EAV is a workaround to the normal confinements of a RDBMS.
If you were to normalize an EAV schema, it would be ugly.
Idea
If EAV was normalized, it would be ugl... | stackexchange/codereview |
I have a website which creates a cookie and I want to use this cookie in my application on Facebook. is it possible? if not, any idea how to recieve information from my website and pass it to Facebook?
| stackexchange/codereview |
I want to get the following working, please could someone advise...
Dim rpt As ReportDocument
If (Exists(rpt.ReportDefinition.ReportObjects("crlTitle"))) Then
txtTitle = CType(rpt.ReportDefinition.ReportObjects("crlTitle"), TextObject)
txtTitle.Color = mainColour
txttitle.Text = "Report Title"
End If
Any hel... | stackexchange/codereview |
I want to develop a eclipse plugin for a launguage with auto completion features.
But i don't know where to start. Is there any tutorial on this kind of subject?
Do i need to develop a parser which parses the code first and/or other things?
best regards
| stackexchange/codereview |
I have the following table:
I am trying to create an SQL query that returns a table that returns three fields:
Year (ActionDate), Count of Built (actiontype = 12), Count of Lost (actiontype = a few different ones)
Bascially, ActionType is a lookup code. So, I'd get back something like:
YEAR CountofBuilt Cou... | stackexchange/codereview |
org.eclipse.swt.events.Progresslistner{
public void completed(ProgressEvent e){}
}
the method completed(ProgressEvent) only means the browser has loaded the html, but still not ready to render.
What I needed is a callback when render completed. Is there any way could do this?
thx
| stackexchange/codereview |
I'm using delta indexing for my Thinking Sphinx indexes in my Rails project. In my machine (Mac OS X) it's working fine. I change a record and it immediately finds it. On the servers (Debian) it doesn't.
I did run a sql query for delta = true and the I've got the expected recently changed records, so that part is worki... | stackexchange/codereview |
How's the text(like below "Temporary ASP.NET") hovers directly over the tree node called? Any difference from tooltip?
Can it be controlled on visibility? e.g. do not display even when the node is partially visible.
pic: Windows Explorer
Thanks,
| stackexchange/codereview |
In my application, there are possibilities to format a string using the string.Format() function. I want to add the possibility to return blank when the result is zero.
As far as I can see, it is possible to do this using the code: 0.toString("0;; ");, but as i already mentioned, I need to use the string.Format() funct... | stackexchange/codereview |
Does (or will) a tool exist to convert WebForm view engine markup (aspx) to Razor view engine markup (cshtml)?
| stackexchange/codereview |
Update: in
http://php.net/manual/en/language.oop5.references.php
it says:
One of the key-points of PHP5 OOP that
is often mentioned is that "objects
are passed by references by default".
This is not completely true.
Why is that? The following is a reason which I don't know is completely true or not:
I thin... | stackexchange/codereview |
I'm looking to implement OpenID the same way that StackOverFlow uses it. I've looked through a few APIs and I've scouted out JanRain but I'm not sure these do what I'm looking for. Has anyone duplicated the login functionality available here?
| stackexchange/codereview |
At my work, we are developing different applications using .net framework 4. All the applications use common assemblies that we developed, for example the data layer in data.dll. These applications reside on a network drive and are launched directly from there.
Most big applications take a while, like maybe 4-5 seconds... | stackexchange/codereview |
Is there a way to have my console app open my PDF file (in my default application for PDFs) given a byte array?
| stackexchange/codereview |
I would like to give our intranet users and create, edit, colaborate documents via a browser. What is the best way to go about this?
Requirements: The user should be able to:
1. create content,
2. edit content (content created by anyone)
3. records should be kept on who edited what and when
4. should easily be able to... | stackexchange/codereview |
i am doing a project on SOFWARE PLAGIARISM DETECTION..i am intended to do it with language C..for that i am supposed to create a token generator, and a parser..but i dont know where to start..any one can help me out with this..
i created a database of tokens and i separated the tokens from my program.Next thing i wanna... | stackexchange/codereview |
I have just started using Yard to generate my docs and whilst it works great for my models and controllers, I can't seem to get it to generate anything for the views
I've tried a variety of different ways to get it to work. Currently I've set up a rake task to generate the docs that looks something like this
YARD::Rak... | stackexchange/codereview |
I've not found the dataChange handler for spark label, as it was for mx:Label.
Is there ability to catch changing the text of spark label?
Any help will be appreciated.
| stackexchange/codereview |
E/ddms IllegalArgumentException 'Bad version' with both 32 and 64 bit Java JRE installed
Hello. Working on a Windows 7 Pro 64-bit system, that has the 64-bit Java JDK (and via the JDK the JRE) installed, and using Eclipse 3.5.2 and the latest Android SDK (rev 7). Everything works fine.
If I then install the 32-bit Ja... | stackexchange/codereview |
Recently, I figured out that Xcode could be used to write normal C++ programs.
My problem is with the following code :
#include <iostream>
#include <fstream>
using namespace std;
int main (int argc, char *argv[]) {
char operation='0';
int operand=0;
//open file for reading
ifstream ifile;
ifile.op... | stackexchange/codereview |
I'm building a django application that will be operated via desktop application. Key feature for now is sending/storing files. Basically I need a django view with URL on which I can send files with POST and this view will store the files. Currently I have something like this :
def upload(request):
for key, file in ... | stackexchange/codereview |
I have a Controller/View for a generic list of items, that can be extended for displaying a custom list.. Listing and navigation works fine.. but I can't change the title of UINavigationController.
In the generic Controller:
- (void)viewDidLoad
{
[super viewDidLoad];
[self.view addSubview: navigationController.... | stackexchange/codereview |
taken a string example as 550e8400-e29b-41d4-a716-446655440000 how can one count how many - chars are in such string?
I'm currently using:
int total = "550e8400-e29b-41d4-a716-446655440000".Split('-').Length + 1;
Is there any method that we don't need to add 1... like using the Count maybe?
All other methods such as
C... | stackexchange/codereview |
I have an iPhone program using Core Location.
When I run it on the simulator - the simulator seems to run very slowly. By this - I mean mouse movements are very slow and jerky.
I can see no noticable difference however in CPU utilization, network or disk activity, etc (on the simulator or the Mac itself). This proble... | stackexchange/codereview |
I've got some old legacy code that I'm maintaining (please forgive the naming, this was written by a non programmer and the application is not important enough to be rewritten):
Dim Path3 As String
Path3 = "C:\Inetpub\wwwroot\uscgcrc\rsa\RSADocuments\IRBCorrespondenceToPI\"
Dim dirInfo3 As New DirectoryInfo(Path3)
Di... | stackexchange/codereview |
I'm trying to make a function which drops the first n items of a list:
let rec drop n h =
if n == 0 then h
else (drop n-1 (match h with a::b -> b));;
This is giving:
Characters 43-49:
if n == 0 then h else (drop n-1 (match h with a::b -> b));;
^^^^^^
Error: This expression has type ... | stackexchange/codereview |
Ii have a database (sql server 2008) and I am working with c# in visual studio 2010.
I want to establish a connection with my db. I have written a code for that as follows:
SqlConnection mySqlConnection = new SqlConnection
("Data Source=servername\\SQL2008; Initial Catalog=MyData;UID=MyID;PWD=mypassword;");
... | stackexchange/codereview |
I can not find any documentation for this - is it possible?
| stackexchange/codereview |
I'm new to this whole thing, and am making a web app that relies heavily on dynamically loaded html pages into a div on the main page.
The main page links to various js files including jquery and some of my own.
As well as this, each of the loaded html files links to its own js file to control user interaction. And s... | stackexchange/codereview |
I would like to know which way is the best to resolve my question :
I have a form in order to select people via a select field. If the name is missing in the select field, a text field is available to add directly the person's name.
- The form in new.html.erb is the format of the new action of the Team controller.
- T... | stackexchange/codereview |
I have an entity relationship setup in my mvc2 application such that each user has one role and each role can have many users. Like so:
Roles Users
-------- ---------
RoleID-- UserID
\
Name --> RoleID
So a pretty basic many to one relationship enforced in the database and reflected in... | stackexchange/codereview |
How to add a new TextView to a layout in run time? is it possible?
| stackexchange/codereview |
I need tree file at my asp.net site.
For getting icons I try use SHGetFileInfo api function.
At non asp.net application it works well, returns corrects Icon. When I conusme it at asp.net context I got:
Attempted to read or write protected memory.
What's wrong? Can I get fiel icon at asp.net context?
Code:
public cla... | stackexchange/codereview |
hii
I am using devexpress xtrascheduler.in that am having a scheduler which is having the default look(having time in the left side verticaly)but i have to get some labels on the left side ie,in addition to the existing scheduler control look...
In simple i want to add some label on the existing scheduler control vert... | stackexchange/codereview |
I've got an issue when installing Django.
The official guide says open cmd with administrator privileges and run "setup.py install"
I did this but then the system default python editor came out, I don't know how to do anymore, please help me~
| stackexchange/codereview |
By default, Django uploads images to the MEDIA_ROOT setting, which is assumed to be a publicly accessible directory.
I don't want users to be able to upload images and to have those images immediately accessible. Instead, I want the images to be uploaded to a non-public tmp directory. Later on, a site moderator will ... | stackexchange/codereview |
I've got a "search" box that is supposed to be able to search data "live". Right now if I attach the "keypress" event to it and update the results, it works pretty good. However, if they press backspace it doesn't account for that (refresh the results).
I understand I can probably account for the "backspace" key.
But a... | stackexchange/codereview |
a lot of command-line .exe applications i use allow you flag optional inputs
e.g. program.exe -o outputfile.txt -f F
where "-o" indicates an optional output file name different to the default, and where "-F' indicates another option about the script.
so far i've been using the sys.arg[] variables to input file names a... | stackexchange/codereview |
I work in a branch 'develop', and when ready to merge with master, use interactive rebase to squash all my little commits into one feature-encompassing commit which I gets applied on top of master.
Works well, only issue I have is the time the commit is labelled is of the first small commit. It makes sense as that is t... | stackexchange/codereview |
I have two app.config's in my application where i have written two connectionstrings in one config file and another two in other config file .Now in .cs file i have written this
string Connect = ConfigurationManager.ConnectionStrings["con1"].ConnectionString.ToString();
string Connect = ConfigurationManager.Connection... | stackexchange/codereview |
Good programmers keep simple things easy right?
And it's not like the boost documentation makes your life less uneasy...
All I want is an implementation for:
// fulfils the function of a regex matching where the pattern may match a
// substring instead of the entire string
bool search( std::string, std::string, SomeRes... | stackexchange/codereview |
I need to get the line number of a phrase in a text file. The phrase could be:
the dog barked
I need to open the file, search it for that phrase and print the line number.
I'm using Python 2.6 on Windows XP
This Is What I Have:
o = open("C:/file.txt")
j = o.read()
if "the dog barked" in j:
print "Found It"
else:... | stackexchange/codereview |
I used the SQL Server Maintenance wizard (along with a book) to generate both Full and Differentail backups. The Full backup runs on Monday morning and the Differentials run Tuesday through Saturday. The Full backup runs fine and generates the following email report...
Microsoft(R) Server Maintenance Utility (Unicode) ... | stackexchange/codereview |
I'm profiling JavaScript using dynaTrace AJAX edition.
According to the tool's "Hot Spots", the following jQuery method is using the majority of execution time:
CLASS(*, *, undefined, *, undefined, false): false
...it has over 700 invocations on my page.
What is this call and how can I optimize it?
I'm using jQuery ve... | stackexchange/codereview |
This is in regards to PHP, Mysql and Html's textarea.
I want to dump a user's input from html's textarea into my mysql database. The situation is that if the user has semi-colons within the text itself, mysql will reject the insert command for obvious reasons. What I want to know is that are there any ways to force mys... | stackexchange/codereview |
I currently have a method that checks to see if I go out of bounds either from either the top/bottom/sides. The object itself is a ball, and I have a question about getting the ball bouncing off the edges correctly? How do I go about this?
// The behavior is not quite what I want.
if ( InsideOfBounds )
{
Vector3... | stackexchange/codereview |
So i'm trying to make a login box with 2 fields and a submit button. The submit button position itself differently in EVERY browser. In Firefox it works as expected but in IE8 and Safari the vertical alignment gets screwed up. Any ideas to resolve this problem?
Here's a screendump of the issue: http://gefuhlkunder.dk/b... | stackexchange/codereview |
HI all,
First of all i want to know that what are the index of list view items??? is something like the index of array (a[0],a[1]....).
Actually i want to get the index of list item. it always showing me -1
here is the code.
protected void onListItemClick(ListView l, View v, int position, long id) {
super.onLi... | stackexchange/codereview |
I'm n00b in IL language. In my task i have to create dynamic types inherited from System.ServiceModel.DomainServices.Client.Entity. When i am adding additional code to set method of property, i receive "operation could destabilize the runtime". Help me, please, resolve that problem.
Code from Reflector:
L_0000: nop
L_... | stackexchange/codereview |
when iPhone connects to a wireless router, and that router is not connected to the internet? i need to display an error message saying "check you internet connection" i tried the Reachability sample code. but no luck,
http://developer.apple.com/library/ios/#samplecode/Reachability/Listings/ReadMe_txt.html
when i disabl... | stackexchange/codereview |
Hey all. I'm writing a simple client/server application (just for the experience, networking is fairly new to me) where the client sends the server data and the server outputs it to a textbox. It all works fine, except for one small detail... It seems sometimes a connection is made, but the data isn't being sent or rea... | stackexchange/codereview |
i have some records in a table. some of them have duplicated value in a field.
i want to extract these duplicated values with mysql commands.
how can i do that?
| stackexchange/codereview |
HI ,
1.create Base usercontrol which contains a label and sets text of it to be "test1" this is set in the ascx page.
2.Create a user control which inherits from the base user control.
3. Now on the page load of the child control i try to do:
protected override void Page_Load(object sender, EventArgs e)
{
... | stackexchange/codereview |
Background:
I have a MainTest class that has many buttons, each of which instantiate a class that I am coding/testing. I want the code/test cycle for these classes to be quick, and see the effect of my changes quickly, a few times a minute. MainTest which is stable takes about 20 seconds to load, which would not be a p... | stackexchange/codereview |
I have a script that is trying to load some data into MySQL with LOAD DATA INFILE. For some reason, it works if the file is in the /tmp directory, but not if the file is in another directory with identical permissions. I can't find any way to get MySQL to import data from outside the /tmp directory, or the database dir... | stackexchange/codereview |
I have some html code as follows:
<div id="wrapper">
<div id="items">
<div class="item">Item 1</div>
<div class="item">Item 2</div>
<div class="item">Item 3</div>
<div class="item">Item 4</div>
<div class="item">Item 5</div>
</div>
</div>
and css as such:
#wrapper {
overflow:hidden;
width:5... | stackexchange/codereview |
I have following python code:
def scrapeSite(urlToCheck):
html = urllib2.urlopen(urlToCheck).read()
from BeautifulSoup import BeautifulSoup
soup = BeautifulSoup(html)
tdtags = soup.findAll('td', { "class" : "c" })
for t in tdtags:
print t.encode('latin1')
This will return me following h... | stackexchange/codereview |
After reading google, I still don't quite understand what this does/means? Could someone explain this? Possibly a simple example? Thank you very much.
| stackexchange/codereview |
I'm using parameterized queries with PHP I have the following two queries:
SELECT username,question_text
FROM questions,users
WHERE questions.question_id = 4 AND questions.user_id = users.user_id
and
SELECT username, post_text
FROM posts,users WHERE posts.question_id = 4
AND posts.user_id = users.user_id ORDER BY ... | stackexchange/codereview |
How can I expose a WCF service so that one client using wsHttp bindings and another client using netTcp bindings can both use the service?
| stackexchange/codereview |
I am trying to word wrap a string into multiple lines. Every line will have a defined width.
For example, I would get this result if I word wrap it to an area of 120 pixels in width:
Lorem ipsum dolor sit amet,
consectetur adipiscing elit. Sed augue
velit, tempor non vulputate sit amet,
dictum vitae lacus. In... | stackexchange/codereview |
I want to embed a like button either using image tag or fb social plugins to let it work same as like button does in my static fbml page. I read somewhere that it can be done with the help of iframe and javascript, can anybody tell me how to implement this on my landing page? I tried with fb:iframe tag also but it didn... | stackexchange/codereview |
Using Oracle 9.2i I need to get the offset of various dates from one timezones in relation to another timezone, previously I did this as such
select
(TO_DATE('10-Oct-2010 09:00:00','DD-Mon-YYYY HH24:Mi:SS') -
TO_DATE(TO_CHAR(FROM_TZ(to_timestamp( '10-Oct-2010 09:00:00','DD-Mon-YYYY HH24:Mi:SS'), 'Austral... | stackexchange/codereview |
I am writing a web service similar to below. But Java is not recognizing the URL, URLConnection. I am unable to solve this issue.
URL yahoo = new URL("http://www.yahoo.com/");
URLConnection yc = yahoo.openConnection();
int dataLen = yc.getContentLength() ;
| stackexchange/codereview |
I have an .aifc file of about 2 minutes that I'm playing using AVAudioPlayer. When I send stop I hear a short 'tick'. When I send play after that I hear the tick again.
I tried setting volume to 0 before sending the play and stop methods, but that didn't work.
The tick is somewhat comparable to the sound you hear when ... | stackexchange/codereview |
I've got some data that is coming in through a byte stream. I want to determine its file type so I know how to parse it. At present, I'm only concerned about HTML or Images, everything else can be discarded.
What's an efficient method of differentiating between the two? And what if I want to expand this to include othe... | stackexchange/codereview |
I'm trying to do what I thought was a very simple operation to set a property on an ASP.Net LinkButton control but for some reason ASP.Net is ignoring the tags and just passing through the value as a string.
<asp:LinkButton id="viewDetails" runat="server" Text="Details" OnClick="btnDetails_Click" CommandName="ItemID" C... | stackexchange/codereview |
If installing a gem using
gem install ______
actually install 6 gems, because of the dependencies, then if the gem is installed as plugin by
script/plugin install git://github.com/author/____.git
or
script/plugin install _____
then we to manually install the gem it depends on?
Does it matter if it is the later form... | stackexchange/codereview |
The code below is part of an rss feed parser using WordPress's simplepie fetch_feed()...
Code is:
if ($enclosure = $item->get_enclosure(0))
{
$image_thumb = $item->get_enclosure()->get_link().'screenshot.jpg';
$image = $item->get_enclosure()->get_link().'screenshot-full.jpg';
}
$link = esc_url( ... | stackexchange/codereview |
I have a public transport app for one country and I want to create a separate app for another country. Most of the code will be shared, but I need some classes to have different implementations for example TransitProvider.
Is it possible to share code using Android Library Project? Can I do the following?
Have Transit... | stackexchange/codereview |
I"m new to xslt, and now I'm stuck a little with it.
I have an XML:
<map>
<node TEXT="test" TYPE="node" >
<element/>
<node TYPE="normal" >
<dummy>
<FONT>
mindmap_node1_l1
</FONT>
</dummy>
<node LINK="url.com" TYPE="node" >
<dummy>
<FONT>
... | stackexchange/codereview |
Which functions and techniques should a good programmer not use?
Probably ereg is one of them.
Is it a good practice to use the global keyword, or should I avoid it as much as possible?
| stackexchange/codereview |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.