Id
int64 1.68k
75.6M
| PostTypeId
int64 1
2
| AcceptedAnswerId
int64 1.7k
75.6M
⌀ | ParentId
int64 1.68k
75.6M
⌀ | Score
int64 -60
3.16k
| ViewCount
int64 8
2.68M
⌀ | Body
stringlengths 1
41.1k
| Title
stringlengths 14
150
⌀ | ContentLicense
stringclasses 3
values | FavoriteCount
int64 0
1
⌀ | CreationDate
stringlengths 23
23
| LastActivityDate
stringlengths 23
23
| LastEditDate
stringlengths 23
23
⌀ | LastEditorUserId
int64 -1
21.3M
⌀ | OwnerUserId
int64 1
21.3M
⌀ | Tags
list |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
5,070,326 | 1 | null | null | 1 | 264 | I would like to open an activity which in turns uses startActivityForResult window and opens, let us assume, 5 activities. So in the UI I would like it to display using the format present in the attached screen shot format.
See the attached honeycomb picture, I would like the 5 square to represent each activity that is linked to the main activity.
Is it possible in HoneyComb? What is the view name that I should be using?

| HoneyComb activity preview showing 5 activities in one screen | CC BY-SA 2.5 | null | 2011-02-21T19:29:05.580 | 2011-05-29T06:44:16.160 | 2011-05-29T06:44:16.160 | 750,987 | 402,637 | [
"android",
"android-3.0-honeycomb"
]
|
5,070,355 | 1 | 5,070,559 | null | 7 | 13,647 | I am just doing a research on a project and came across a problem. I would be very grateful if anybody could help me out with this. Consider the figure below:

Two dots joined by a line results in only one diagram, three dots joined by single lines also results in one figure no matter how you join the dots, the result is the same. But as we increase the dots there are different possibilities, as seen with four dots.
Is there a formula for counting the number of unlabeled trees that can be formed from a set of nodes?
| What is the formula to find the different unlabeled trees that can be formed from a given set of nodes? | CC BY-SA 3.0 | 0 | 2011-02-21T19:32:10.787 | 2016-03-10T15:02:55.660 | 2011-12-15T03:48:55.123 | null | 70,774 | [
"math",
"discrete-mathematics"
]
|
5,070,796 | 1 | 5,071,939 | null | 1 | 754 | I am to implement the following formula in Delphi:

Y_k is a floating point number which we'll call just Y.
w[i][j] is an array containing floating point numbers as well (1<=i<=43 and 1<=j<=30).
According to [my source paper](http://www.cs.bris.ac.uk/Publications/Papers/2000100.pdf) (p. 12) is the of (column) vector w with respect to the value Y". Is this correct?
So how do I implement this in Delphi?
Thanks a lot in advance!
| Gradient (nabla) of vector/array in Delphi | CC BY-SA 2.5 | 0 | 2011-02-21T20:15:31.857 | 2011-02-21T22:22:07.027 | null | null | 89,818 | [
"arrays",
"delphi",
"vector",
"gradient"
]
|
5,070,941 | 1 | 5,071,056 | null | 4 | 3,731 | I'm working on a software solution to for a group of applications running on the same server.
The applications are loosely related, and share an event log. The problem that we are running into is performance, with each application making calls to the database every time they need to log an event.
What I'm trying to do is decouple the entire process by removing the applications direct calls to the database, and routing them through a service running on the machine whos sole purpose is processing events from the multiple applications on the machine.

Ultimately my goal is to implement some sort of system in the "Event" Helper Object that would allow those objects to communicate directly with the "Event" Service.
My first instinct was to use your typical "event", but it would appear from the research that I've done that it is not possible to invoke an event in one process to be handled in another process.
As a part of my research I came across [Listen for events in another application](https://stackoverflow.com/questions/17878/listen-for-events-in-another-application) and [C# Win32 messaging with SendMessage](http://boycook.wordpress.com/2008/07/29/c-win32-messaging-with-sendmessage-and-wm_copydata/).
Sendmessage looks like a promising solution, but I wanted to be sure so I spoke with one of my colleagues who was close to the project (the original developer who was moved on to a new project before the completion of this one) and he imparted some additional information as to the situation. They had apparently attmped to use WCF and build it as a web service. This probably would have worked except for the location and security level of the server itself.
He believes it MAY be possible to implement a WCF system at the OS level without having to use it in a web service environment.
My question is... "Is using WCF possible at the OS level?" and "Which of the options listed would be the most efficent under the scenario?" Keeping in mind that this MUST be decoupled and the applications cannot have any interaction with the event log in the database itself.
So I started putting something together and this is what I came up with..
```
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;
using System.ServiceModel.Description;
namespace SelfHost
{
[ServiceContract]
public interface ISelfHostingService
{
[OperationContract]
string SelfHost(string name);
}
public class SelfHostingService : ISelfHostingService
{
public string SelfHost(string name)
{
return string.Format("Hello, {0}", name);
}
}
class Program
{
static void Main(string[] args)
{
Uri baseAddress = new Uri("http://localhost:8080/SelfHost");
ServiceHost host = new ServiceHost(typeof(SelfHostingService), baseAddress);
host.AddServiceEndpoint(typeof(SelfHost.ISelfHostingService), new BasicHttpBinding(), baseAddress);
host.Open();
Console.WriteLine("The service is ready at {0}", baseAddress);
Console.WriteLine("Press <Enter> to stop the service.");
Console.ReadLine();
}
}
}
```
But there is a problem. This line:
```
Uri baseAddress = new Uri("http://localhost:8080/SelfHost");
```
I guarantee that the server will not allow the service to register that local address (its been tried already and it was a flop).
So my new question is... "Is there a way around that that does not involve changing configuration settings on the server itself?"
This is deffinately an option but... [pregnant pause] We do use the message queue for other pieces of functionality. My only hesitation is the overhead. I'd rather that it was completely decoupled I'm looking for an application to application solution. I'd rather that the service was "listening" instead of going to get.
I did a lot more research and I've decided that using WCF is in my best interest.
As a part of the windows service I plan on adding an app.config for the event logging service and then configuring the service to use named pipes over localhost.
thanks for all the help
For anyone who might be interested. This works beautifuly. The net.pipe is active and I am able to create events and send them to the service from multiple apps with little or no processing time.
The wcf service is encased in a very simple windows service that simply opens the service pipe. on the client side i was able to discover and implement the service easily. All i have to do is make a call to the client class and it shows my events in real time in the database.
Thanks again.
| Cross Application Communication (C#) | CC BY-SA 2.5 | null | 2011-02-21T20:31:47.997 | 2011-02-28T17:34:21.463 | 2017-05-23T12:30:36.930 | -1 | 112,550 | [
"c#",
"wcf",
"ipc",
"msmq"
]
|
5,070,968 | 1 | 5,216,089 | null | 11 | 9,738 | So I inherited an IIS website and I am not familiar with the tools. When I run project it wants to start up at localhost/myApp/. If I do not have IIS configured to start up in this location then debugger fails to attach. However, I have code that assumes my site is on the root directory. I am on IIS 7 and Win 7 x64.
when I debug the website from inside VS2010 how do I tell it that my website is located at localhost/? My project is the one highlighted in red.



| Debug VS2010 website at root instead of subdirectory | CC BY-SA 2.5 | 0 | 2011-02-21T20:34:42.950 | 2013-10-02T16:49:47.523 | 2011-12-20T03:45:06.670 | 3,043 | 510,314 | [
"visual-studio-2010",
"iis-7"
]
|
5,071,063 | 1 | null | null | 11 | 26,585 | You'd take images and mark specific points (for example, mark the region around the eyes, nose, mouth etc of people) and then transform them into the points marked into another image. Something like:
```
transform(original_image, marked_points_in_the_original, marked_points_in_the_reference)
```
I can't seem to find an algorithm describing it, nor can I find any libraries with it. I'm willing to do it myself too, as long as I can find good/easy to follow material on it. I know it's possible though since I've seen some incomplete (don't really explain how to do it) .pdfs on google with it.
Here's an example of the marked points and the transformation, since you asked for clarification. Though this one isn't using 2 people as I said earlier.


Edit: I managed to get the `im.transform` method working, but the argument is a list of `((box_x, box_y, box_width, box_height), (x0, y0, x1, y1, x2, y2, x3, y3))`, with the first point being NW, the second SW, the third NE and the fourth SE. (0, 0) is the leftmost upper part of the screen as far as I could tell. If I did everything right, then this method doesn't really do what I need.
| Is there a library for image warping / image morphing for python with controlled points? | CC BY-SA 3.0 | 0 | 2011-02-21T20:45:12.140 | 2021-01-02T15:48:48.280 | 2017-08-09T05:03:42.727 | 1,714,410 | 627,274 | [
"python",
"image-processing",
"image-manipulation"
]
|
5,071,112 | 1 | 5,073,041 | null | 0 | 123 | Could anyone comment on what IOS components for navigation/layout etc were used for the iPhone application "Pocket Weather AU"? It looks quite good the way it's set out. I'm guessing:
Navigation Controller
- - -


PS. Also when the "+" symbol is pressed it goes to:

| what layout components were used for Pocket Weather AU? | CC BY-SA 2.5 | null | 2011-02-21T20:49:32.703 | 2011-02-22T05:22:51.510 | 2011-02-22T04:08:25.313 | 173,520 | 173,520 | [
"iphone",
"layout",
"uinavigationcontroller"
]
|
5,071,223 | 1 | 5,071,274 | null | 0 | 1,152 | Hi Stackoverflow users...
I have this website I'm trying to style really cool.
[http://kebax.dk/blog](http://kebax.dk/blog)
Here's the structure of the Div's:
```
<div id="blog">
<div id="bloghead">
#Blog headline
</div>
<div id="blogbody">
<p>Test tekst!!</p>
<p>Test tekst!!</p>
<p>Test tekst!!</p>
<p>Test tekst!!</p>
<p>Test tekst!!</p>
<p>Test tekst!!</p>
</div>
<div id="blogcreditsleft">
Written by: Kristian
</div>
<div id="blogcreditsright"><?php echo date("Y-m-d") ?></div>
</div>
```
And here's the CSS behind it (you can also just check out my stylesheet too):
```
#blog {
.rounded();
left:65px;
position:relative;
width:520px;
margin-left:auto;
margin-right:auto;
padding:5px;
background:#052507;
}
#bloghead {
color:#000000;
background:#2BAC2B;
padding:5px;
border-bottom:1px solid #052507;
font-size:14pt;
}
#blogbody {
color:#000000;
background:#42E64F;
padding:5px;
height:auto;
overflow:auto;
min-height:300px;
}
#blogcreditsleft, #blogcreditsright {
color:#000000;
padding:5px;
width:250px;
.gradientVBottomCenter();
}
#blogcreditsleft {
float:left;
}
#blogcreditsright {
float:right;
text-align:right;
}
```
Only way I can make it work is by setting the `position:absolute` and adding `left:65px` to push it into center of my "center" :)
But then my problem is that when more blog elements are added they won't just be under each other, because of the absolute position.
it's something about a missing `clear:both`, but I have no idea how to fix it though...
Can anyone help?
Edit: 
| Div height becomes smaller with position:relative than absolute | CC BY-SA 2.5 | null | 2011-02-21T21:01:24.120 | 2011-02-21T21:10:17.910 | 2011-02-21T21:10:17.910 | 515,772 | 515,772 | [
"html",
"css",
"less"
]
|
5,071,335 | 1 | 5,073,048 | null | 4 | 917 | For those who have seen my other questions: I am making progress but I haven't yet wrapped my head around this aspect. I've been pouring over stackoverflow answers and sites like Cocoa With Love but I haven't found an app layout that fits (why such a lack of scientific or business app examples? recipe and book examples are too simplistic).
I have a data analysis app that is laid out like this:

Communication Manager (singleton, manages the hardware)
DataController (tells Comm.mgr what to do, and checks raw data it receives)
Model (receives data from datacontroller, cleans, analyzes and stores it)
MainViewController (skeleton right now, listens to comm.mgr to present views and alerts)
Now, never will my data be directly shown on a view (like a simple table of entities and attributes), I'll probably use core plot to plot the analyzed results (once I figure that out). The raw data saved will be huge (10,000's of points), and I am using a c++ vector wrapped in an ObjC++ class to access it. The vector class also has the encodeWithCoder and initWithCoder functions which use NSData as a transport for the vector. I'm trying to follow proper design practices, but I'm lost on how to get persistent storage into my app (which will be needed to store and review old data sets).
I've read several sources that say the "business logic" should go into the model class. This is how I have it right now, I send it the raw data, and it parses, cleans and analyzes the results and then saves those into ivar arrays (of the vector class). However, I haven't seen a Core Data example yet that has a Managed Object that is anything but a simple storage of very basic attributes (strings, dates) and they never have any business logic. So I wonder, how can I meld these two aspects? Should all of my analysis go into the data controller and have it manage the object context? If so, where is my model? (seems to break the MVC architecture if my data is stored in my controller - read: since these are vector arrays, I can't be constantly encoding and decoding them into NSData streams, they need a place to exist before I save them to disk with Core Data, and they need a place to exist after I retrieve them from storage and decode them for review).
Any suggestions would be helpful (even on the layout I've already started). I just drew some of the communication between objects to give you an idea. Also, I don't have any of the connections between the model and view/view controllers yet (using NSLog for now).
| Cocoa app layout with Core Data and lots of business logic | CC BY-SA 2.5 | null | 2011-02-21T21:12:24.857 | 2011-02-23T20:43:30.087 | 2011-02-21T22:14:40.490 | null | 589,451 | [
"iphone",
"arrays",
"cocoa-touch",
"model-view-controller",
"core-data"
]
|
5,071,387 | 1 | 5,072,424 | null | 0 | 140 | I have a Windows service that isn't writing to the Application Event log under UserAccount. When the service is set to use AdminAccount, the Security log reports the following attributes:

Under UserAccount, the only privilege reported is SeImpersonatePrivilege.
Is there a security impersonation that I can implement to give the UserAccount the ability to write to the Application Event log?
I would prefer to use the UserAccount for this service rather than the AdminAccount.
| What privileges do I need? | CC BY-SA 2.5 | null | 2011-02-21T21:18:04.623 | 2011-02-21T23:21:16.930 | null | null | 210,709 | [
".net",
"windows-services",
"event-log"
]
|
5,071,861 | 1 | 5,071,911 | null | 7 | 4,243 | I have a gridview with `AutoGenerateDeleteButton`

And i export this gridview simple this code..
```
Response.Clear();
Response.AddHeader("content-disposition", "attachment;filename=Avukat.xls");
Response.Charset = "";
Response.ContentType = "application/vnd.xls";
System.IO.StringWriter stringWrite = new System.IO.StringWriter();
System.Web.UI.HtmlTextWriter htmlWrite = new HtmlTextWriter(stringWrite);
GridView1.RenderControl(htmlWrite);
Response.Write("<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />");
Response.Write(stringWrite.ToString());
Response.End();
```
There is no problem with that.
But in the excel there is a delete column :))

How can i delete the delete column in excel?
| Gridview to Excel | CC BY-SA 2.5 | 0 | 2011-02-21T22:14:39.217 | 2013-10-16T06:14:52.450 | null | null | 447,156 | [
"c#",
".net",
"asp.net",
"excel",
"gridview"
]
|
5,071,974 | 1 | 5,071,988 | null | 8 | 1,120 | 
I come from Eclipse world and there we have this kind of outline view.
Is there something like this in VS2010? Maybe some plugin? I do have ReSharper.
| Is there anything like outline view in VS? | CC BY-SA 2.5 | 0 | 2011-02-21T22:25:57.603 | 2011-02-21T22:27:31.603 | null | null | 30,453 | [
"c#",
".net",
"visual-studio",
"visual-studio-2010",
"resharper"
]
|
5,072,467 | 1 | 5,072,549 | null | 33 | 10,158 | Consider this example:
[http://jsfiddle.net/treeface/P8JbW/](http://jsfiddle.net/treeface/P8JbW/)
:
```
<div id="test">
<img src="http://ycombinator.com/images/y18.gif" />
</div>
```
:
```
#test {
position:relative;
margin-left:50px;
margin-top:50px;
border:1px solid black;
height:50px;
width:50px;
overflow-x:visible;
overflow-y:hidden;
}
img {
position:absolute;
left:-11px;
}
```
I'm expecting to see this:

But I'm getting this:

It seems that the overflow-x property is being overridden here. Is that what's actually happening? Assuming that I have to keep the overflow-y set to hidden, is there a way around this behavior?
| Why does "overflow-y:hidden" affect the visibility of items overflowing on the x axis? | CC BY-SA 2.5 | 0 | 2011-02-21T23:27:51.297 | 2011-02-22T00:01:57.573 | null | null | 385,950 | [
"html",
"css"
]
|
5,072,587 | 1 | null | null | 0 | 389 | Well, after taking into consideration all the helpful comments I got on v1 and v2 of my class diagram for the space invader game, I updated my class diagram once again to implement all the changes.
With no further ado, I present v3:

The Move and Update methods in the abstract class are doing nothing, the implementations of the methods are in the concrete classes that inherit from bullet. Each of these concrete classes will also inherit the Speed property from the interface, and each will have their own speed set. The whole abstract class and their concrete class derivatives is the strategy pattern.
Some things I want to ask: The and class can only have one bullet at a time - but the class can also have no bullets. This is e.g. when all the rows of aliens are still intact, then only the first row of aliens can fire bullets. The rows above them are not able to shoot. But how would I implement this in the class? Should the bullet variable in the class of the invaders who are not able to shoot be set or left to null? Or is there a better option?
I hope I am getting closer and closer to getting the right design, all your comments are welcome!
| Comments on my design v3 | CC BY-SA 2.5 | 0 | 2011-02-21T23:48:52.283 | 2013-02-14T14:40:09.723 | 2012-07-28T17:51:47.143 | 50,776 | 543,269 | [
"design-patterns",
"architecture",
"class-diagram"
]
|
5,072,688 | 1 | 5,087,116 | null | 3 | 1,036 | I'm going to ask a question regarding an issue I'm having and try to figure this out based on input from your guys. I'll post source code if I REALLY can't get it, but here I go ...
So, I have a form, which displays fields vertically. Everything is a drop down menu, and at the very end is a submit button. There's a sprinkle of javascript that allows me to add a new row without a page refresh. So, there's never the same amount of $_POST arrays for each key. The key I'm worried about (well all of them, but once I get it working, it will work for all of them) is the `$_POST['monworkhours']` drop down. This is a drop down that has a listing of different work hours. I believe the problem lies in the fact I need to loop through all the `$_POST['monworkhours']` array based on the submission. .
Additionally, the "problem" is causing the same results for each row of output. So whatever I set for the first field ends up being the result for every additional row I have "added" via the javascript function.
Any help is appreciated.
The Form:
```
<select name="monshifthours[]" id="monshifthours">
<option value="OFF">OFF</option>
<optgroup label="Front/Back Half">
<option value="7am7pm">7AM-7PM</option>
<option value="7pm7am">7PM-7AM</option>
<option value="7am7pmalt">7AM-7PM (Alt)</option>
<option value="7pm7amalt">7PM-7AM (Alt)</option>
</optgroup>
<optgroup label="Monday - Friday">
<option value="630am330pm">630AM-330PM</option>
<option value="7am4pm">7AM-4PM</option>
<option value="8am5pm">8AM-5PM</option>
<option value="10am7pm">10AM-7PM</option>
</optgroup>
</select>
```
The $_POST output (2 form rows):
```
["monshifthours"]=>
array(2) {
[0]=>
string(6) "7am7pm"
[1]=>
string(6) "7pm7am"
}
```
Screenshot:

getCellColor() Function:
```
function getCellColor($dow) {
foreach($_POST[$dow . 'shifthours'] as $key=> $hour) {
echo $count;
if ($hour == "7am7pmalt") {
return "style=\"background: yellow; color:#000;\"";
}
elseif ($hour == "OFF") {
return "style=\"background: red; color:#fff;\"";
}
else {
return "style=\"background: green; color:#fff;\"";
}
}
}
```
For Submission Output:
```
if (isset($_POST['submit'])) {
echo preTableFrmt();
foreach($engineer as $a => $b) {
echo "| [[$engineer[$a]]] || ".getCellColor('mon')." | $monday[$a] || ".getCellColor('tues')." | $tuesday[$a] || ".getCellColor('wed')." | $wednesday[$a] || ".getCellColor('thur')." | $thursday[$a] || ".getCellColor('fri')." | $friday[$a] || ".getCellColor('sat')." | $saturday[$a] || ".getCellColor('sun')." | $sunday[$a] <br />|-<br />";
}
echo postTableFrmt();
}
else { echo "Waiting for data..."; }
```
Note: When submitting one row of the form, everything is fine; it's when I have more than one; then I get duplicate information.
The following example should show you what happens when I "add an engineer" (making it now two form rows). I'll post the output after the image:
Application Image:

Note: Don't pay attention to the output of the times, as they are being formatted on the fly through some regex, and some of them work and some do not as I have to finish writing those functions. Pay attention to the fact that the following output I send is correct on the first section, but the second section is a duplicate of the first line of output:
```
|-
| [[Drew Decker]] || style="background: yellow; color:#000;" | 7am7pmalt || style="background: red; color:#fff;" | OFF || style="background: red; color:#fff;" | OFF || style="background: red; color:#fff;" | OFF || | || style="background: red; color:#fff;" | OFF || style="background: red; color:#fff;" | OFF
|-
| [[Drew Decker]] || style="background: yellow; color:#000;" | 7pm-7am || style="background: red; color:#fff;" | OFF || style="background: red; color:#fff;" | OFF || style="background: red; color:#fff;" | OFF || | || style="background: red; color:#fff;" | OFF || style="background: red; color:#fff;" | OFF
```
Note: The duplicates are here the `style="background: yellow; color:#000;"`.
So, I ended up figuring out a solution that didn't require me to change my form code. I don't believe I needed to change my form code since it is dynamic. Normally, if I was writing this to a database and submitting multiple rows of form data to the database, I can see where this is important, however, in this situation, I do not believe that it was the proper solution. However, I do thank and appreciate all the thoughtful and informational answers I received.
I ended up changing the `getCellColor()` function to the following:
```
function getCellColor($index,$dow) {
if ( isset($_POST[$dow . 'shifthours'][$index]) && ($_POST[$dow . 'shifthours'][$index] == "7am7pmalt" || $_POST[$dow . 'shifthours'][$index] == "7pm7amalt")) {
return "style=\"background: yellow; color:#000;\"";
}
elseif ($_POST[$dow . 'shifthours'][$index] == "OFF") {
return "style=\"background: red; color:#fff;\"";
}
else {
return "style=\"background: green; color:#fff;\"";
}
}
```
My `foreach` now looks like:
```
foreach($engineer as $a => $b) {
echo "|-<br />| [[$engineer[$a]]] || ".getCellColor($a,"mon")." | ".format_date($monday[$a])." || ".getCellColor($a,"tues")." | ".format_date($tuesday[$a])." || ".getCellColor($a,"wed")." | ".format_date($wednesday[$a])." || ".getCellColor($a,"thur")." | ".format_date($thursday[$a])." || ".getCellColor($a,"fri")." | ".format_date($friday[$a])." || ".getCellColor($a,"sat")." | ".format_date($saturday[$a])." || ".getCellColor($a,"sun")." | ".format_date($sunday[$a])."<br />";
}
```
Doing it this way ensures that I just tell it to select the correct array index, and proceed accordingly.
| PHP: Array $_POST loop issues | CC BY-SA 2.5 | null | 2011-02-22T00:05:48.787 | 2011-02-23T04:48:36.170 | 2011-02-23T00:36:51.727 | 259,717 | 259,717 | [
"php",
"arrays",
"post",
"loops",
"for-loop"
]
|
5,073,215 | 1 | null | null | 0 | 842 | I'm trying to install the Flash Builder 4 plugin for eclipse on my Mac.
The installation completes but when i launch eclipse i get the following pop-up message, after which eclipse quits unexpectedly.

I'm using the eclipse-jee-galileo-SR2-macosx-carbon version of eclipse.
| Unable to install Flash Builder 4 plugin - Configuration Error 6 | CC BY-SA 2.5 | null | 2011-02-22T01:43:34.707 | 2011-03-10T15:25:02.350 | null | null | 379,524 | [
"eclipse-plugin",
"flash-builder"
]
|
5,073,724 | 1 | 5,115,849 | null | 2 | 932 | I have an UITableView in my application, which is in an UIView that has it's background colour to the Scroll View Texture thing. This is all in an UIViewController. It works all nicely and stuff, but I get these fugly black corners around my table view edges:

The Background colour of the table view is set to the clear colour, and those squares even appear in Interface Builder. Any ideas on how to eradicate these evil UI blemishes? They make my UI look like something that was thrown together in 3 minutes, even when I spent more than a week designing my entire UI. It makes me want to punch UITableView in the face, too.
| Weird black corners at edge of Grouped UITableView | CC BY-SA 2.5 | null | 2011-02-22T03:35:48.950 | 2011-02-25T09:58:52.320 | null | null | 219,515 | [
"cocoa-touch",
"uitableview",
"artifacts"
]
|
5,073,766 | 1 | 6,111,378 | null | 34 | 56,924 | I am having problems styling form fields with CSS. As you can see below I am trying to get an input field and then to its right the submit button. However for some reason I can't get them to align correctly on any browser, nor can I get them to at least look the same in them and finally everything goes bad when I zoom as well!
I have tried the "line-height:normal !important;" solution, but that doesn't seem to work either...
What am I doing wrong?



CSS (nothing for subscribe_form):
```
#form_box {
position: relative;
height: 35px;
top: 7px;
left: 20px;
}
#subscribe_email {
border: solid 1px #CCC;
height: 24px;
width: 250px;
font-size: 15px;
color: #999;
padding-left: 5px;
}
#subscribe_submit {
position: relative;
border: solid 1px #CCC;
height: 25px;
width: 115px;
color: white;
}
```
HTML:
```
<div id="box2" class="tbox">
<div id="form_box">
<form id="subscribe_form" action="subscribe" method="post">
Sign Up:
<input class="tbox" id="subscribe_email" type="text" name="email" value="email address" />
<input class="tbox" id="subscribe_submit" type="submit" value="Subscribe" />
</form>
</div>
</div>
```
| How do I align input field and submit button (also differences between: IE, FFox, Chrome)? | CC BY-SA 3.0 | 0 | 2011-02-22T03:42:32.607 | 2012-09-15T15:05:36.537 | 2012-09-15T15:05:36.537 | 106,762 | 577,145 | [
"css"
]
|
5,073,773 | 1 | 5,123,481 | null | 3 | 3,362 | I am having a problem with tkinter.ttk on mac. I am using macports and python3.1. When I try to use tkinter.ttk I get very old looking gui elements.
eg: I get this

Instead of this:

The code I used is:
```
from tkinter import *
from tkinter import ttk
root = Tk()
button = ttk.Button(root, text="Hello World").grid()
root.mainloop()
```
I would be happy to provide any information from my computer needed to answer this question. As I am a novice programer please tell me where to find said information.
I have a Macbook 5,2 with Snow Leopard installed. Any help would be appreciated.
Thanks, Marlen
Question Update:
I installed as suggested only to get this error:
```
TclMacOSXNotifierAddRunLoopMode: Tcl not built with CoreFoundation support Abort trap
```
I fixed this error with the patch from [https://trac.macports.org/ticket/22954](https://trac.macports.org/ticket/22954). I followed the instructions to the letter(they are):
```
$ cd /opt/local/var/macports/sources/rsync.macports.org/release/ports/lang/tcl
$ sudo patch < ~/Downloads/tcl.2.patch
$ sudo port install tcl
```
This created a new error which is:
```
Traceback (most recent call last):
File "hello.py", line 5, in <module>
root = Tk()
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.1/lib/python3.1/tkinter/__init__.py", line 1632, in __init__
self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: Can't find a usable tk.tcl in the following directories:
/opt/local/lib/tcl8.5/tk8.5 /opt/local/lib/tcl8.5/tk8.5/Resources/Scripts /opt/local/lib/tk8.5 /opt/local/lib/tk8.5/Resources/Scripts /opt/local/Library/Frameworks/Python.framework/Versions/3.1/Resources/Python.app/Contents/lib/tk8.5 /opt/local/Library/Frameworks/Python.framework/Versions/3.1/Resources/Python.app/Contents/lib/tk8.5/Resources/Scripts /opt/local/Library/Frameworks/Python.framework/Versions/3.1/Resources/Python.app/lib/tk8.5 /opt/local/Library/Frameworks/Python.framework/Versions/3.1/Resources/Python.app/Contents/library
/opt/local/lib/tk8.5/tk.tcl: version conflict for package "Tk": have 8.5.7, need exactly 8.5.9
version conflict for package "Tk": have 8.5.7, need exactly 8.5.9
while executing
"package require -exact Tk 8.5.9"
(file "/opt/local/lib/tk8.5/tk.tcl" line 20)
invoked from within
"source /opt/local/lib/tk8.5/tk.tcl"
("uplevel" body line 1)
invoked from within
"uplevel #0 [list source $file]"
This probably means that tk wasn't installed properly.
```
| How do I make my ttk widgets look modern? | CC BY-SA 2.5 | null | 2011-02-22T03:43:39.903 | 2012-05-03T01:19:01.533 | 2011-02-26T19:11:13.240 | 488,331 | 488,331 | [
"user-interface",
"python-3.x",
"tkinter",
"macports",
"ttk"
]
|
5,073,831 | 1 | null | null | -1 | 350 | There are a strange set of arrows on my Bookmarks Toolbar.

The underlying bookmark has nothing to do with it. Even if I delete the bookmark, the arrows still remain.
I am using Firefox 3.6.13 on Ubuntu 10.10. I haven't installed any new extensions or themes.
How can I get rid of these arrows?
| Strange arrows in Firefox Bookmarks Toolbar | CC BY-SA 2.5 | null | 2011-02-22T03:59:08.590 | 2011-02-23T21:18:11.943 | 2011-02-22T04:00:55.327 | 23,199 | 620,361 | [
"firefox",
"toolbar"
]
|
5,073,865 | 1 | 5,074,203 | null | 6 | 4,034 | In Matlab, I am trying to plot a function on 2-dim Euclidean space with following code
```
s=.05;
x=[-2:s:2+s];
y=[-1:s:3+s];
[X,Y]=meshgrid(x,y);
Z=(1.-X).^2 + 100.*(Y-X.*X).^2;
surf(X,Y,Z)
colormap jet
```
Here is what my plot look like:

I hope to color the surface with stronger contrast, just as [Wikipedia](http://en.wikipedia.org/wiki/File:Rosenbrock_function.svg) shows

The plot in Wikipedia is drawn with Python code:
```
from mpl_toolkits.mplot3d import Axes3D
from matplotlib import cm
from matplotlib.colors import LogNorm
import matplotlib.pyplot as plt
import numpy as np
fig = plt.figure()
ax = Axes3D(fig, azim = -128, elev = 43)
s = .05
X = np.arange(-2, 2.+s, s)
Y = np.arange(-1, 3.+s, s)
X, Y = np.meshgrid(X, Y)
Z = (1.-X)**2 + 100.*(Y-X*X)**2
ax.plot_surface(X, Y, Z, rstride = 1, cstride = 1, norm = LogNorm(), cmap = cm.jet)
plt.xlabel("x")
plt.ylabel("y")
plt.show()
```
My Matlab code and the Wikipedia Python code seem to both use "jet" as colormap, but their actual mappings of height value to color are different. So I was wondering how I can get similar coloring in Matlab?
Thanks and regards!
| How to color surface with stronger contrast | CC BY-SA 2.5 | null | 2011-02-22T04:06:02.663 | 2017-11-29T17:43:31.433 | 2011-02-22T22:40:16.360 | 156,458 | 156,458 | [
"python",
"matlab",
"plot"
]
|
5,074,065 | 1 | 5,100,332 | null | 2 | 1,398 | I'm looking to implement something like the famous "letterpress" effect in my application. Here's what I'm talking about: (just a quick example made in PShop)

As you can see, it looks like it's pressed into the background. I wonder if it's possible to do something like this on the Mac . Is there a way? Thanks!
| How to create letterpress effect? | CC BY-SA 2.5 | 0 | 2011-02-22T04:39:51.707 | 2011-02-24T04:24:59.203 | null | null | 456,851 | [
"objective-c",
"cocoa",
"macos"
]
|
5,074,100 | 1 | 5,102,316 | null | 0 | 1,863 | I'm a newbie to jQuery.
I've been experimenting and working on a method of using a dropdown menu to dynamically create tabs and paginate them (no need for the tabs to create a new line as seen on the default jQuery tabs plugin) but have run into a few problems which i'm not sure how to resolve. for each difficulty I have included screen shot as a visual aid.
Here is the interface its rather simple but in the future the data used within it will be dynamic.

Now here are the problems I am currently facing due to a lack of skill.
1) the title of the tab is selected from a dropdown but I'm not sure how to set individual content for each tab created. Right now each tab created is empty as seen below.

2) I would also like to prevent the duplication of tabs. Each option on the dropdown can be selected an infinite number of times.

3) lastly I hope to move the remove button alongside each tab (floated to the right) as seen on Google Chrome/Firefox tabs.

4) I am also trying to create an option to disable the default tab from being closed
Here is the code below. It can be copied and pasted as is for viewing as all dependencies are currently stored in remote web locations!
```
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<title></title>
<link rel="stylesheet" type="text/css" media="screen" href="http://www.seyfertdesign.com/jquery/css/reset-fonts.css" />
<link rel="stylesheet" type="text/css" media="screen" href="http://www.seyfertdesign.com/jquery/css/base/ui.all.css" />
<style type="text/css">
h1 {
font-size: 1.1em;
font-weight: bold;
padding-left: 10px;
}
p {
padding: 5px 0 5px 1em;
}
em {
font-style: italic;
}
.example {
margin: 0 1em;
padding: 5px 0 0 0;
margin: 5px 10px 20px 10px;
}
.ui-tabs-paging-next {
float: right !important;
}
.ui-tabs-paging-prev, .ui-tabs-paging-next {
background: transparent !important;
border: 0 !important;
margin-bottom: 1px !important;
}
#example2 .ui-tabs-paging-prev, #example2 .ui-tabs-paging-next {
font-weight: bold;
}
.ui-tabs-paging-prev a, .ui-tabs-paging-next a {
display: block;
position: relative;
top: 1px;
border: 0;
z-index: 2;
padding: 0;
/* color: #444; */
text-decoration: none;
background: transparent !important;
cursor: pointer;
}
.ui-tabs-paging-next a:hover, .ui-tabs-paging-next a:focus, .ui-tabs-paging-next a:active, .ui-tabs-paging-prev a:hover, .ui-tabs-paging-prev a:focus, .ui-tabs-paging-prev a:active {
background: transparent;
}
.ui-tabs-paging-disabled {
visibility: hidden;
}
</style>
<script type="text/javascript" src="http://www.seyfertdesign.com/jquery/js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="http://www.seyfertdesign.com/jquery/js/ui/ui.core.js"></script>
<script type="text/javascript" src="http://www.seyfertdesign.com/jquery/js/ui/ui.tabs.js"></script>
<script type="text/javascript" src="http://www.seyfertdesign.com/jquery/js/ui/extensions/ui.tabs.paging.js"></script>
<script type="text/javascript">
jQuery(document).ready(function() {
// initialize tabs with default behaviors
jQuery('#example1').tabs();
jQuery('#example2').tabs({ cache: true });
jQuery('#example3').tabs({ cache: true });
jQuery('#example4').tabs({ cache: true, selectOnAdd: true });
jQuery('#example4').tabs('select', 21);
// initialize paging
function init() {
jQuery('#example1').tabs('paging');
jQuery('#example2').tabs('paging', { cycle: true, nextButton: 'next >', prevButton: '< prev' });
jQuery('#example3').tabs('paging', { follow: true, followOnSelect: true, tabsPerPage: 5 });
jQuery('#example4').tabs('paging', { cycle: true, follow: true, followOnSelect: true, selectOnAdd: true });
}
init();
});
</script>
</head>
<body style="font-size: 75%;">
<script type="text/javascript" src="http://jqueryui.com/themeroller/themeswitchertool/"></script><script type="text/javascript">
function addTab(selector, index) {
var myTabs = jQuery(selector);
if (index == undefined)
index = myTabs.tabs('length');
tabId = '#tab' + (new Date).getTime();
myTabs.tabs('add', tabId, $('#TAB_NAME').val());
$(tabId).load('new_tab_data.txt');
}
function removeTab(selector, index) {
var myTabs = jQuery(selector);
if (index == undefined || index.length == 0)
index = myTabs.tabs('length') - 1;
else
index = parseInt(index);
myTabs.tabs('remove', index)
}
</script>
<div class="example">
<div>
<br>
<table>
<tr>
<td style="padding-left: 30px"><select id="TAB_NAME">
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
</select>
<button onclick="addTab('#example4');">Add</button>
</p></td>
<td style="padding-left: 30px" valign="top"><button onclick="removeTab('#example4', jQuery('#TAB_INDEX').val());">Remove</button></td>
</tr>
<tr></tr>
</table>
</div>
<div id="example4">
<ul class="tabs">
<li><a href="#example4-1">Tab 1</a></li>
</ul>
<div id="example4-1">Tab 1</div>
</div>
</div>
</body>
</html>
```
| jQuery tab pagination questions | CC BY-SA 3.0 | null | 2011-02-22T04:45:28.877 | 2017-02-19T11:15:00.053 | 2017-02-19T11:15:00.053 | 472,495 | 436,493 | [
"jquery",
"html",
"css",
"pagination"
]
|
5,074,178 | 1 | 5,076,514 | null | 2 | 514 | friends. I want draw MapOverlay like as PopUp Menu same as in this image. How I can do this.
| MapOverlay like as PopUp | CC BY-SA 2.5 | null | 2011-02-22T04:58:39.653 | 2011-02-22T09:46:38.723 | null | null | 624,069 | [
"android"
]
|
5,074,232 | 1 | 5,099,780 | null | 1 | 515 | The Firebug console window shows the source file name and line number on the right of each entry, but it's too narrow to display file names longer than about 10 chars.
Is it possible to adjust the width of the column?

| Set Firebug's file, Source link, column width | CC BY-SA 2.5 | null | 2011-02-22T05:05:55.540 | 2011-02-24T02:43:39.870 | 2011-02-24T02:43:39.870 | 331,508 | 494,373 | [
"firebug",
"preferences"
]
|
5,074,375 | 1 | 5,075,856 | null | 0 | 422 | I am wondering If I can use stack panel to get the following layout

| Can i use stack panel to design the following layout | CC BY-SA 2.5 | null | 2011-02-22T05:28:51.590 | 2011-02-22T08:43:05.593 | null | null | 496,949 | [
"wpf",
"wpf-controls"
]
|
5,074,592 | 1 | null | null | 0 | 53 | i want to get the lastest info in the databse using sql ,
this is my datbase's table

what can i do ,
i want to get the last
the table's name is 'location'
thanks
| how to return the lastest info using sql | CC BY-SA 2.5 | null | 2011-02-22T05:59:37.237 | 2011-02-22T06:20:47.133 | 2011-02-22T06:20:14.940 | 420,840 | 420,840 | [
"sql",
"mysql"
]
|
5,074,619 | 1 | 7,497,851 | null | 4 | 5,631 | I want to send an email in HTML format like as below image.
How can I do this?
Please help me.
Thanks in advance...!

| Send E-mail in HTML format | CC BY-SA 3.0 | 0 | 2011-02-22T06:03:21.850 | 2014-08-12T09:08:53.527 | 2013-09-23T11:00:04.473 | 624,069 | 624,069 | [
"android",
"html",
"android-intent"
]
|
5,074,678 | 1 | null | null | 0 | 819 | how can i achieve font like this as shown in image.
| UILabel Font Problem | CC BY-SA 2.5 | null | 2011-02-22T06:10:24.867 | 2011-02-23T00:52:49.253 | null | null | 517,047 | [
"iphone",
"uilabel",
"uifont"
]
|
5,074,684 | 1 | 5,652,318 | null | 3 | 616 | I'm using this code to display the contacts in an app.
```
- (IBAction) selectContact:(id)sender {
ABPeoplePickerNavigationController *picker = [[ABPeoplePickerNavigationController alloc] init];
picker.peoplePickerDelegate = self;
NSArray *displayedItems = [NSArray arrayWithObjects:[NSNumber numberWithInt:kABPersonAddressProperty], nil];
picker.displayedProperties = displayedItems;
[self presentModalViewController:picker animated:YES];
[picker release];
}
```
and there is a memory leak, according to instruments. Even if I cancel the person picker like this:
```
- (void) peoplePickerNavigationControllerDidCancel:(ABPeoplePickerNavigationController *)peoplePicker {
NSLog(@"peoplePickerNavigationControllerDidCancel");
[self dismissModalViewControllerAnimated:YES];
}
```
... I got a leak:

I have found some posts of developers claiming that this is a bug in the SDK and that a bug has already been filed. Can someone confirm that? or point me in the right direction.
| Memory leak with ABPeoplePickerNavigationController? | CC BY-SA 2.5 | null | 2011-02-22T06:11:30.853 | 2011-12-27T15:44:40.763 | null | null | 440,243 | [
"iphone",
"objective-c",
"memory-leaks",
"abpeoplepickerview"
]
|
5,074,921 | 1 | 5,078,666 | null | 10 | 12,104 | Inspired by [this question](http://ask.sagemath.org/question/396/plotting-arrows-at-the-edges-of-a-curve) at ask.sagemath, what is the way of adding arrows to the end of curves produced by `Plot`, `ContourPlot`, etc...? These are the types of plots seen in high school, indicating the curve continues off the end of the page.
After some searching, I could not find a built-in way or up-to-date package to do this. (There is [ArrowExtended](http://www.scientificarts.com/arrowextended.html), but it's quite old).
The solution given in the ask.sagemath question relies on the knowledge of the function and its endpoints and (maybe) the ability to take derivatives. Its translation into Mathematica is
```
f[x_] := Cos[12 x^2]; xmin = -1; xmax = 1; small = .01;
Plot[f[x],{x,xmin,xmax}, PlotLabel -> y==f[x], AxesLabel->{x,y},
Epilog->{Blue,
Arrow[{{xmin,f[xmin]},{xmin-small,f[xmin-small]}}],
Arrow[{{xmax,f[xmax]},{xmax+small,f[xmax+small]}}]
}]
```

An alternative method is to simply replace the `Line[]` objects generate by `Plot[]` with `Arrow[]`. For example
```
Plot[{x^2, Sin[10 x], UnitStep[x]}, {x, -1, 1},
PlotStyle -> {Red, Green, {Thick, Blue}},
(*AxesStyle -> Arrowheads[.03],*) PlotRange -> All] /.
Line[x__] :> Sequence[Arrowheads[{-.04, .04}], Arrow[x]]
```

But this has the problem that any discontinuities in the lines generate arrow heads where you don't want them (this can often be fixed by the option `Exclusions -> None`). More importantly, this approach is hopeless with `CountourPlot`s. Eg try
```
ContourPlot[x^2 + y^3 == 1, {x, -2, 2}, {y, -2, 1}] /.
Line[x__] :> Sequence[Arrowheads[{-.04, .04}], Arrow[x]]
```
(the problems in the above case can be fixed by the rule, e.g., `{a___, l1_Line, l2_Line, b___} :> {a, Line[Join[l2[[1]], l1[[1]]]], b}` or by using appropriate single headed arrows.).
As you can see, neither of the above (quick hacks) are particularly robust or flexible. Does anyone know an approach that is?
| Plotting arrows at the edges of a curve | CC BY-SA 2.5 | 0 | 2011-02-22T06:42:12.973 | 2011-03-06T23:03:52.140 | null | null | 421,225 | [
"wolfram-mathematica",
"plot"
]
|
5,075,243 | 1 | 5,075,751 | null | 6 | 13,235 | How do I create a window which looks like this in Java:

I want that window layout, instead of the standard Windows-borders, and I don't know how this is called.
Edit: look and feel doesn't work for me:

| How to make a window look like this in Java? | CC BY-SA 3.0 | 0 | 2011-02-22T07:24:46.797 | 2013-08-27T12:47:14.083 | 2013-08-27T12:47:14.083 | 40,342 | 254,850 | [
"java",
"swing",
"look-and-feel"
]
|
5,075,271 | 1 | 5,075,472 | null | 1 | 152 | We have a SVN set up across many developers. i am trying to import the project into Eclipse and i am getting the following error
[http://variable3.com/files/screenshots/2011-02-22_1255.png](http://variable3.com/files/screenshots/2011-02-22_1255.png)

| Importing Android Project | CC BY-SA 2.5 | null | 2011-02-22T07:27:23.423 | 2011-02-22T08:14:12.087 | null | null | 155,196 | [
"android",
"import",
"project"
]
|
5,075,305 | 1 | 5,282,429 | null | 17 | 13,928 | There are some applications which shows icon disabled which stops me from running the application.It does not happen to all applications but on a few . It mainly occurs to me in facebook applications and a few more applications.Can anybody have an idea what could be the problem ? I have tried everything from changing the build settings etc. but it does not work.

| Build and run Disabled in xcode | CC BY-SA 2.5 | 0 | 2011-02-22T07:32:03.200 | 2017-06-12T09:37:12.030 | 2011-02-28T04:05:02.950 | 401,198 | 401,198 | [
"iphone",
"objective-c",
"xcode",
"debugging"
]
|
5,075,361 | 1 | null | null | 0 | 156 | I want to add a Imgae plz help me to do this i want to know which property is used to set image i am using UltraToolBarManager

| How To add a Image on ToolBarManager | CC BY-SA 2.5 | null | 2011-02-22T07:39:05.813 | 2011-04-29T20:08:11.250 | null | null | 409,732 | [
"c#"
]
|
5,075,409 | 1 | 5,075,486 | null | 0 | 2,916 | I want to generate pdf file as attached in the picture. i want to harcode the contents shown in the picture into a pdf file on button click.
How do i proceed, using table structure will work?I am unable to form the table stucture here.
Please help me to sort out my problem.i want the output as shown in below image.

| Generating pdf using itextsharp in asp.net c# | CC BY-SA 2.5 | 0 | 2011-02-22T07:44:50.887 | 2011-02-22T07:55:16.980 | null | null | 243,680 | [
"c#",
"asp.net",
"pdf-generation",
"itext"
]
|
5,075,602 | 1 | 5,075,661 | null | 9 | 13,532 | Almost every time I commit to SVN I keep getting a checksum mismatch error. I already know how to fix it (by checking out the folder and copying over the .svn folder after deleting the old one). What I want to know is what causes this as its starting to drive me insane.
OS: Windows 7
SVN Client: VisualSVN, TortoiseSVN

| What is the underlying cause of an SVN checksum mismatch? | CC BY-SA 3.0 | 0 | 2011-02-22T08:12:07.043 | 2018-01-17T10:26:40.157 | 2014-12-09T21:12:51.880 | 643,826 | 23,339 | [
"windows",
"svn",
"tortoisesvn",
"visualsvn",
"corrupt-data"
]
|
5,075,563 | 1 | null | null | 1 | 16,650 | I'am using Developer Express `XtraGrid` Component to show some data. I have 2 `XtraGrid` on my Windows Application Form. Both grids have more than 200k+ lines, and 8 columns of data, and I have export to excel button. There are two ways (as I know) for exporting grid data to excel.
1- `grid.ExportToXls();` or `grid.ExportToXlsx();`
2- Using Office Interop, and `OpenXML Utilities`
If I use `grid.ExportToXls();` or `grid.ExportToXlsx();`, the process time is faster than Office Interop Codes (for arround 2k lines of data). But, this method can be used for just 1 grid. So result appears on 2 different `Excel` files. So, I'am using Office Interop to merge workbooks after process completed. Here is the problem occurs. With both these ways, I am always getting `System.OutOfMemory` Exception. (See the memory graph below)

I'am stuck here, because the ways I know to export excel are throwing `System.OutOfMemory` Exception. Do you have any suggestion, how can I export more than 200k - 300k+ lines of data to `Excel`? I'am using `.Net Framework 3.5` on `Visual Studio 2010`.
And you can find my Interop, and `Document.Format OpenXML Utility` codes below.
```
try
{
SaveFileDialog saveDialog = new SaveFileDialog();
saveDialog.Title = SaveAsTitle;
saveDialog.Filter = G.Instance.MessageManager.GetResourceMessage("EXCEL_FILES_FILTER");
saveDialog.ShowDialog();
if (string.IsNullOrEmpty(saveDialog.FileName))
{
// Showing Warning
return;
}
List<GridControl> exportToExcel = new List<GridControl>();
exportToExcel.Add(dataGrid);
exportToExcel.Add(summaryGrid);
ExportXtraGridToExcel2007(saveDialog.FileName, exportToExcel);
}
catch (Exception ex)
{
// Showing Error
}
```
And this is my `ExportXtraGridToExcel2007();` function codes
```
public void ExportXtraGridToExcel2007(string path, List<GridControl> grids)
{
try
{
DisableMdiParent();
string tmpPath = Path.GetTempPath();
List<string> exportedFiles = new List<string>();
for (int i = 0; i < grids.Count; i++)
{
string currentPath = string.Format(@"{0}\document{1}.xlsx", tmpPath, i);
GridControl grid = grids[i];
grid.MainView.ExportToXlsx(currentPath);
exportedFiles.Add(currentPath);
}
if (exportedFiles.Count > 0)
{
OpenXmlUtilities.MergeWorkbooks(path, exportedFiles.ToArray());
foreach (string excel in exportedFiles)
{
if (File.Exists(excel))
{
try
{
File.Delete(excel);
}
catch (Exception ex)
{
EventLog.WriteEntry("Application", ex.Message);
}
}
}
}
}
catch (Exception ex)
{
// showing error
}
finally
{
EnableMdiParent();
}
}
```
and this is the OpenXML Merge Work Books Codes
```
public static void MergeWorkbooks(string path, string[] sourceWorkbookNames)
{
WorkbookPart mergedWorkbookPart = null;
WorksheetPart mergedWorksheetPart = null;
WorksheetPart childWorksheetPart = null;
Sheets mergedWorkbookSheets = null;
Sheets childWorkbookSheets = null;
Sheet newMergedSheet = null;
SheetData mergedSheetData = null;
SharedStringTablePart mergedSharedStringTablePart = null;
SharedStringTablePart childSharedStringTablePart = null;
// Create the merged workbook package.
using (SpreadsheetDocument mergedWorkbook =
SpreadsheetDocument.Create(path,
SpreadsheetDocumentType.Workbook))
{
// Add the merged workbook part to the new package.
mergedWorkbookPart = mergedWorkbook.AddWorkbookPart();
GenerateMergedWorkbook().Save(mergedWorkbookPart);
// Get the Sheets element in the merged workbook for use later.
mergedWorkbookSheets = mergedWorkbookPart.Workbook.GetFirstChild<Sheets>();
// Create the Shared String Table part in the merged workbook.
mergedSharedStringTablePart = mergedWorkbookPart.AddNewPart<SharedStringTablePart>();
GenerateSharedStringTablePart().Save(mergedSharedStringTablePart);
// For each source workbook to merge...
foreach (string workbookName in sourceWorkbookNames)
{
// Open the source workbook. The following will throw an exception if
// the source workbook does not exist.
using (SpreadsheetDocument childWorkbook =
SpreadsheetDocument.Open(workbookName, false))
{
// Get the Sheets element in the source workbook.
childWorkbookSheets = childWorkbook.WorkbookPart.Workbook.GetFirstChild<Sheets>();
// Get the Shared String Table part of the source workbook.
childSharedStringTablePart = childWorkbook.WorkbookPart.SharedStringTablePart;
// For each worksheet in the source workbook...
foreach (Sheet childSheet in childWorkbookSheets)
{
// Get a worksheet part for the source worksheet using it's relationship Id.
childWorksheetPart = (WorksheetPart)childWorkbook.WorkbookPart.GetPartById(childSheet.Id);
// Add a worksheet part to the merged workbook based on the source worksheet.
mergedWorksheetPart = mergedWorkbookPart.AddPart<WorksheetPart>(childWorksheetPart);
// There should be only one worksheet that is set as the main view.
CleanView(mergedWorksheetPart);
// Create a Sheet element for the new sheet in the merged workbook.
newMergedSheet = new Sheet();
// Set the Name, Id, and SheetId attributes of the new Sheet element.
newMergedSheet.Name = GenerateWorksheetName(mergedWorkbookSheets, childSheet.Name.Value);
newMergedSheet.Id = mergedWorkbookPart.GetIdOfPart(mergedWorksheetPart);
newMergedSheet.SheetId = (uint)mergedWorkbookSheets.ChildElements.Count + 1;
// Add the new Sheet element to the Sheets element in the merged workbook.
mergedWorkbookSheets.Append(newMergedSheet);
// Get the SheetData element of the new worksheet part in the merged workbook.
mergedSheetData = mergedWorksheetPart.Worksheet.GetFirstChild<SheetData>();
// For each row of data...
foreach (Row row in mergedSheetData.Elements<Row>())
{
// For each cell in the row...
foreach (Cell cell in row.Elements<Cell>())
{
// If the cell is using a shared string then merge the string
// from the source workbook into the merged workbook.
if (cell.DataType != null &&
cell.DataType.Value == CellValues.SharedString)
{
ProcessCellSharedString(mergedWorksheetPart, cell,
mergedSharedStringTablePart, childSharedStringTablePart);
}
}
}
}
}
}
//Save the changes to the merged workbook.
mergedWorkbookPart.Workbook.Save();
}
}
```
| XtraGrid - Export To Excel | CC BY-SA 3.0 | 0 | 2011-02-22T08:04:23.033 | 2015-03-12T17:22:07.743 | 2011-12-12T08:34:11.853 | 169,195 | 378,765 | [
"c#",
"winforms",
"devexpress",
"xtragrid"
]
|
5,075,745 | 1 | 5,075,862 | null | 0 | 757 | I'm currently working on a groupable datagridview. All works fine, but now I want to add a padding to the left. In the picture below I'm using the rowheader and paint over it, but isn't there any other way?

| How to add a RowPadding to DataGridView? | CC BY-SA 2.5 | null | 2011-02-22T08:29:01.147 | 2011-02-22T08:43:38.620 | 2020-06-20T09:12:55.060 | -1 | 533,413 | [
"c#",
"datagridview",
"custom-controls"
]
|
5,075,878 | 1 | 5,075,897 | null | 3 | 9,290 | I have a simple Gridview with `AutogenerateDeleteButton`.

I want to put a an recycle bin instead of Delete Hyperlink Button.
For example like this: 
Every row has to have this image instead of Delete Hyperlink Button.
How can I do that?
This is a perfect example:

| Putting an Image Gridview Delete Button | CC BY-SA 3.0 | null | 2011-02-22T08:46:32.310 | 2015-07-20T19:39:22.873 | 2015-07-20T19:39:22.873 | 4,370,109 | 447,156 | [
"c#",
"asp.net",
"image",
"gridview"
]
|
5,076,335 | 1 | 5,076,379 | null | 0 | 327 | this is my code :
```
public static List populate(ResultSet rs, Class clazz) throws Exception {
ResultSetMetaData metaData = rs.getMetaData();
int colCount = metaData.getColumnCount();
List ret = new ArrayList();
Field[] fields = clazz.getDeclaredFields();
while (rs.next()) {
Object newInstance = clazz.newInstance();
for (int i = 1; i <= colCount; i++) {
try {
Object value = rs.getObject(i);
for (int j = 0; j < fields.length; j++) {
Field f = fields[j];
if (f.getName().replaceAll("_", "").equalsIgnoreCase(
metaData.getColumnName(i).replaceAll("_", ""))) {
BeanUtils.copyProperty(newInstance, f.getName(),
value);
}
}
} catch (Exception e) {
e.printStackTrace();
}
}
ret.add(newInstance);
}
rs.close();
return ret;
}
```
and this is the method to call it :
```
public List getLastAddress(String terminal_id, String last_2) throws Exception {
String sql ="SELECT a.adress_reality from accounts_location_"+last_2+" AS a WHERE a.terminal_id = '"
+terminal_id+"' ORDER BY a.time_stamp DESC limit 1";
System.out.println(sql);
ResultSet rs = getDr().getSt().executeQuery(sql);
return populate(rs, Class.forName("hdt.ChineseAddressBean"));
```
and then :
```
List cn_address=sd.getLastAddress(toNomber,last_2);
System.out.println(cn_address.get(0));
```
but it show :
```
hdt.ChineseAddressBean@f0eed6
```
so How to get the current string from `cn_address.get(0)`,
thanks
this is my ChineseAddressBean.java:
```
package hdt;
public class ChineseAddressBean {
String adress_reality = "";
public String getAdress_reality() {
return adress_reality;
}
public void setAdress_reality(String adress_reality) {
this.adress_reality = adress_reality;
}
}
```
when i use this , it show error :


this is the error :

| How to get the current string from "Class.forName(name).newInstance()" using java | CC BY-SA 2.5 | 0 | 2011-02-22T09:29:27.493 | 2012-08-14T15:41:41.037 | 2011-02-22T10:11:10.903 | 420,840 | 420,840 | [
"java",
"sql",
"mysql"
]
|
5,076,622 | 1 | 5,095,340 | null | 64 | 41,434 | I am working on a sketching app on the iPhone.
I got it working but not pretty as seen here

And I am looking for any suggestion to smooth the drawing
Basically, what I did is when user places a finger on the screen I called
```
- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
```
then I collect a single touch in an array with
```
- (void) touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event
```
and when the user lefts a finger from the screen, I called
```
- (void) touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event
```
then I draw all the points in the array using
```
NSMutableArray *points = [collectedArray points];
CGPoint firstPoint;
[[points objectAtIndex:0] getValue:&firstPoint];
CGContextMoveToPoint(context, firstPoint.x, firstPoint.y);
CGContextSetLineCap(context, kCGLineCapRound);
CGContextSetLineJoin(context, kCGLineJoinRound);
for (int i=1; i < [points count]; i++) {
NSValue *value = [points objectAtIndex:i];
CGPoint point;
[value getValue:&point];
CGContextAddLineToPoint(context, point.x, point.y);
}
CGContextStrokePath(context);
UIGraphicsPushContext(context);
```
And now I want to improve the drawing tobe more like "Sketch Book" App

I think there is something to do with signal processing algorithm to rearrange all the points in the array but I am not sure. Any Help would be much appreciated.
Thankz in advance :)
| iPhone smooth sketch drawing algorithm | CC BY-SA 2.5 | 0 | 2011-02-22T09:56:31.857 | 2018-04-06T13:44:08.263 | 2017-12-04T06:51:18.870 | 543,875 | 408,721 | [
"ios",
"iphone",
"drawing",
"quartz-graphics"
]
|
5,076,871 | 1 | null | null | 6 | 7,113 | OneToMany + MapKeyJoinColumn doesn't work for me, please suggest what I'm doing wrong.
I'm using JPA 2.0 + Hibernate 3.6.1
And want to map following tables:
---

---
To Classes:
---
```
@Entity
public class Question {
// id and other fields
@OneToMany(mappedBy="question", cascade = CascadeType.ALL)
@MapKeyJoinColumn(name="language_id")
private Map<Language, Statement> statements =
new HashMap<Language, Statement>();
}
@Entity
public class Statement {
@Id
private Long id;
@ManyToOne
@JoinColumn(name = "language_id", nullable = true)
private Language language;
@ManyToOne
@JoinColumn(name = "question_id", nullable = false)
private Question question;
@Column(name = "message")
private String message;
}
@Entity
public class Language {
@Id
private Long id;
@Column(name = "name")
private String name;
}
```
But it doesn't work. EntityManager persists it correctly, but when I retrieve Question, in it's statements map there is only one language-to-null entry.
Please, help
---
: Strange, but when I preload all Languages, like this:
```
String sql = "select l from Language l";
List languages = entityManager.createQuery(sql, Language.class).getResultList();
```
then it works!
| JPA 2.0 Hibernate @OneToMany + @MapKeyJoinColumn | CC BY-SA 2.5 | 0 | 2011-02-22T10:21:21.527 | 2011-08-29T22:39:10.393 | 2011-02-22T13:14:46.877 | 485,180 | 485,180 | [
"java",
"hibernate",
"jpa",
"one-to-many"
]
|
5,076,934 | 1 | 5,076,994 | null | 0 | 279 | I have a UITableView which I use to display images in a grid form. 4 images per row.
The problem I have now is that the overlay which I have to display when an image is selected. (see image). The overlay is removed, or the image is hidden when the tableview scrolls down. The images are still selected, but the overlay is hidden.
How can the tableview be stopped from removing the overlay image when the image is scrolled out of bounds.

after scrolling the images out of view and back in the image overlays are gone, but images are still selected.

| Overlay image is hidden when tableview scrolls | CC BY-SA 2.5 | null | 2011-02-22T10:29:19.367 | 2011-02-22T10:35:04.453 | null | null | 356,387 | [
"iphone",
"uitableview"
]
|
5,077,067 | 1 | 5,077,139 | null | 0 | 581 | Im looking for an html slider that will look like this :

that give me the ability to assign the range , and if the range is larger than the slider size ,i should have these arrows to go to the right and left.
Im sure there is someone has done that.
| Looking for an html Slider (HTMl, JQuery, Javascript) | CC BY-SA 2.5 | null | 2011-02-22T10:43:07.723 | 2011-02-22T11:16:39.430 | null | null | 233,085 | [
"javascript",
"jquery",
"html",
"slider"
]
|
5,077,169 | 1 | 5,988,371 | null | 5 | 368 | I have developed a face book iframe application in .net c#.First time when user access iframe application 
it shows this window but it should ask for permission & allow user to access my app.
When i click go to face book.com it shows permission window.after that when i choose allow its redirecting me to my canvas URL out side the face book.when i try to access 2nd time its working fine.The issue is that for every first time user who want to access the app ist shows the existing window.Please help me to solve this issue.
Thanks
| Facebook iframe application issue | CC BY-SA 2.5 | null | 2011-02-22T10:54:17.513 | 2011-05-13T06:59:13.500 | null | null | 307,989 | [
"c#-4.0",
"facebook"
]
|
5,077,191 | 1 | 9,275,154 | null | 1 | 249 | I have a table like this. Columns --> (MUSTERI, AVUKAT, HESAP (Unique))
My page design like this.

Simply, first dropdown is MUSTERI, second dropdown is AVUKAT, when i click EKLE (it means ADD) button, automaticyly getting HESAP (unique) and showing on gridview.
What i want is, if any user try to add a data which they are the same HESAP, geting an error.
For example;There is a data "`2M LOJİSTİJ`" "`ALİ ORAL`" "`889`" in my gridview.
Someone try to add a data like "2M LOJİSTİK" "EMRA SARINÇ" "889" showing an error and don't add to table.
My Add_Click button code is
```
protected void Add_Click(object sender, EventArgs e)
{
string strConnectionString = ConfigurationManager.ConnectionStrings["SqlServerCstr"].ConnectionString;
SqlConnection myConnection = new SqlConnection(strConnectionString);
myConnection.Open();
string hesap = Label1.Text;
string musteriadi = DropDownList1.SelectedItem.Value;
string avukat = DropDownList2.SelectedItem.Value;
SqlCommand cmd = new SqlCommand("INSERT INTO AVUKAT VALUES (@MUSTERI, @AVUKAT, @HESAP)", myConnection);
cmd.Parameters.AddWithValue("@HESAP", hesap);
cmd.Parameters.AddWithValue("@MUSTERI", musteriadi);
cmd.Parameters.AddWithValue("@AVUKAT", avukat);
cmd.Connection = myConnection;
SqlDataReader dr = cmd.ExecuteReader(System.Data.CommandBehavior.CloseConnection);
Response.Redirect(Request.Url.ToString());
myConnection.Close();
}
```
And my first dropdown MUSTERI (getting HESAP auto by this field)
```
protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e)
{
string strConnectionString = ConfigurationManager.ConnectionStrings["SqlServerCstr"].ConnectionString;
SqlConnection myConnection = new SqlConnection(strConnectionString);
myConnection.Open();
string hesapNo = DropDownList1.SelectedItem.Value;
string query = "select A.HESAP_NO from YAZ..MARDATA.S_TEKLIF A where A.MUS_K_ISIM = '" + hesapNo + "'";
SqlCommand cmd = new SqlCommand(query, myConnection);
if (DropDownList1.SelectedValue != "0")
{
Add.Enabled = true;
Label1.Text = cmd.ExecuteScalar().ToString();
}
else
{
Add.Enabled = false;
}
Label1.Visible = false;
myConnection.Close();
}
```
How can i blocking insert data which already have the same HESAP?
| Adding just Unique Data to Gridview | CC BY-SA 2.5 | null | 2011-02-22T10:56:31.133 | 2012-02-14T10:17:09.897 | null | null | 447,156 | [
"c#",
"asp.net",
"database",
"gridview",
"sqldatasource"
]
|
5,077,357 | 1 | 5,077,684 | null | 4 | 3,808 | I want to try and design a reward system on a new website I am building. For example (for illustrative purposes only):



Stack overflow's [medals system](https://stackoverflow.com/badges) is another example.
My question is, you can store the description and name of each badge easily in a database table.
```
**tbl_Badges**
ID | Badge Name | canHaveMultiple | hasProgress | progressScale
----------------------------------------------------------------------------
1 Copy Editor Yes No null
2 The Mob Yes No null
3 Jquery No Yes 100
```
And then to associate users with these badges:
```
**tbl_UsersBadges**
ID | Badge ID | User ID
---------------------------
1 1 5
2 1 5
3 2 5
4 2 12
```
(And perhaps another one to store user progress through scale badges etc etc)
But the difficulty comes in programming the triggers that award these badges.
Are systems like this built with hard coded triggers in the website? This is about the only way I can think of doing it due to the broadness and flexibility of these badges. However if the triggers are hard coded to a badge ID, you are going to have to be extremely careful when changing anything.
So is this how such a system works? It goes against what I have learnt. Or am I approaching the problem wrongly?
| How to design a rewards system on my website | CC BY-SA 2.5 | 0 | 2011-02-22T11:14:49.240 | 2011-02-22T11:51:16.540 | 2017-05-23T12:34:04.650 | -1 | 356,635 | [
"database-design",
"badge",
"reward-system"
]
|
5,077,390 | 1 | 5,077,687 | null | 13 | 11,482 | I'm building a website that has videos embedded within them. This website needs to cater for iPad users as well but I'm having trouble with the ol' `video` tag at the moment. I have a video that plays fine in browsers but not on an iPad unfortunately.
I'm just getting a black screen with the iPad, and no error message to speak of.
Here is my code for the video:
```
<video id="movie" width="790" height="250" controls >
<source src="anim/intro.ipad.mp4" type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"'>
<source src="anim/intro.webm" type='video/webm; codecs="vp8, vorbis"'>
<source src="anim/intro.theora.ogv" type='video/ogg; codecs="theora, vorbis"'>
</video>
<script>
var v = document.getElementById("movie");
v.onclick = function() {
if (v.paused) {
v.play();
} else {
v.pause();
}
};
</script>
```
The videos were all created following tutorials about HTML5 video. They were all encoded using preferred iPad settings on Miro Video converter.
Just incase this matters (I'm not sure it will) I'm testing the video on an iPad simulator.
No matter what I do, I just can't get the video to play:

| HTML5 Video "Black Screen" on iPad | CC BY-SA 2.5 | null | 2011-02-22T11:17:31.653 | 2011-02-22T16:11:17.763 | 2011-02-22T11:42:04.730 | 418,146 | 418,146 | [
"javascript",
"ipad",
"html",
"html5-video"
]
|
5,077,498 | 1 | 5,077,521 | null | 0 | 687 | I am facing some unusual problem every now and then to solve I even formatted my system but all in vain, problem is when ever I open any xml file its says and no graphical layout is rendered as in below image

| Android eclipse problem | CC BY-SA 2.5 | null | 2011-02-22T11:29:44.723 | 2011-02-22T11:40:50.990 | null | null | 517,247 | [
"android",
"eclipse"
]
|
5,077,815 | 1 | 5,077,931 | null | 1 | 540 | I embed a .swf file in HTML and then embed this HTML itself in another HTML.
In the .swf file I call
```
ExternalInterface.call(" function(){ return window.location.toString();}";
```
The problem is sometimes I seem to get window location of the embedded HTML and sometimes I get address of the main HTML (see picture).

All I am after is reliability. I want to get the same address everytime. I haven't even been able to understand when it get which location. I wonder if it is some sort of browser related mystery!
Thanks for any help
Cheers!
Ali
| Getting window.location in embedded Flash | CC BY-SA 2.5 | 0 | 2011-02-22T11:58:14.827 | 2011-02-22T12:10:45.270 | 2011-02-22T12:05:42.517 | 315,725 | 315,725 | [
"javascript",
"html",
"flex4"
]
|
5,077,891 | 1 | 5,078,185 | null | 10 | 29,640 | How can I change the border size/style/color of my `TabControl` to make it blend in with my form's background color?
I am unable to find any property for this in Visual Studio. Is this possible?

| How can I change the border color and size of a TabControl? | CC BY-SA 2.5 | null | 2011-02-22T12:05:12.373 | 2020-07-07T11:02:10.110 | 2011-02-22T12:52:16.653 | 366,904 | 590,666 | [
".net",
"vb.net",
"winforms",
"tabcontrol"
]
|
5,077,926 | 1 | 5,077,948 | null | 0 | 1,694 | I have `Gridview` but some daha is two or three line. (more than one)

How can i show all daha is one line?
| Gridview All Data is one line | CC BY-SA 2.5 | null | 2011-02-22T12:10:02.040 | 2011-02-22T12:12:34.733 | null | null | 447,156 | [
"asp.net",
"gridview",
"line",
"row"
]
|
5,077,996 | 1 | 5,078,052 | null | 0 | 585 | I run a Rails 3 application on Windows XP and it fails sometimes with the following error:

This causes the WEBrick server to shutdown.
When I start the server again, sometimes the page loads as expected and sometimes it fails again with the same error.
I noticed that the error appears when I change one of the JavaScript files that belong to the loaded page.
What could be the reason for this ?
How could I debug this ?
My Ruby version is: `ruby 1.9.2p0 (2010-08-18) [i386-mingw32]`.
| Why Rails fails with: ruby.exe has encountered a problem and needs to close. We are sorry for the inconvenience | CC BY-SA 2.5 | 0 | 2011-02-22T12:17:54.493 | 2011-02-22T12:23:38.123 | null | null | 247,243 | [
"ruby-on-rails",
"ruby",
"ruby-on-rails-3",
"windows-xp"
]
|
5,078,026 | 1 | 5,078,642 | null | 2 | 7,297 | Are there any good (if possible scientific) resources available (web or books) about overlap processing. I am not that interested in the effects of using overlap processing and windows when analyzing a signal, since the requirements are different. It is more about the following Real Time situation: (I am currently dealing with audio signals)
- - - - - -
I am especially interested in the influence of the window used on the resulting error as well as the effect of the overlap length. However I couldn't find any good resources that deal with the subject in detail. Any suggestions?
After some discussions if using a window function is appropriate, I found a decent handout explaining the overlap and add/save method. [http://www.ece.tamu.edu/~deepa/ecen448/handouts/08c/10_Overlap_Save_Add_handouts.pdf](http://www.ece.tamu.edu/~deepa/ecen448/handouts/08c/10_Overlap_Save_Add_handouts.pdf)
However, after doing some tests, I noticed that the windowed version would perform more accurate in most cases than the overlap & add/save method. Could anybody confirm this?
I don't want to jump to any conclusions regarding computation time though....
Here are some graphs from my tests:
I created a signal, which consists of three cosine waves

I used this filter function in the time domain for filtering. (It's symmetric, as it is applied to the whole output of the FFT, which also is symmetric for real input signals)

The output of the IFFT looks like this: It can be seen that low frequencies are attenuated more than frequency in the mid range.

For the overlap add/save and the windowed processing I divided the input signal into 8 chunks of 256 samples. After reassembling them they look like that. (sample 490 - 540)



It can be seen that the overlap add/save processes differ from the windowed version at the point where chunks are put together (sample 511). This is the error which leads to different results when comparing windowed process and overlap add/save. The windowed process is closer to the one processed in one big junk.
However, I have no idea why they are there or if they shouldn't be there at all.
| Signal processing: FFT overlap processing resources | CC BY-SA 2.5 | 0 | 2011-02-22T12:20:32.200 | 2011-12-23T19:13:03.960 | 2011-02-23T14:17:37.497 | 473,950 | 473,950 | [
"audio",
"signal-processing",
"fft",
"overlap"
]
|
5,078,080 | 1 | 5,078,258 | null | 0 | 423 | I have 3 projects that I use svn for them. My folder system is that: There is a folder `projects`, within projects folder there are 3 projects `projectA`, `projectB` and `projectC`.
I have a Windows batch script code like that:
```
d:
cd projectA
svn update
cd ../projectB
svn update
cd ../projectC
svn update
```
The purpose of it with one .bat file I want to update all of my projects. That code seems like can be improved. Is it possible to change it like:
```
set folder=projects
set directories=(projectA projectB projectC)
set command=svn update
d:
for %%i in %directories% do cd.. && cd %folder%/%%i && %command%
```
That code fails on somewhere. It should be change to do while loop or something like that because it tries to make `cd projects\projectB` while it is under projects folder (It should be at upper folder of projects to execute cd projects\etc.)
@Andriy M There is a screenshot from my computer. Red is projectA, blue is projectB and purple is projectC.
Here it:

| Windows Batch File Iterator Problem | CC BY-SA 2.5 | null | 2011-02-22T12:26:47.503 | 2011-02-22T13:25:57.313 | 2011-02-22T13:25:57.313 | 453,596 | 453,596 | [
"windows-7",
"batch-file"
]
|
5,078,129 | 1 | 5,078,199 | null | 2 | 1,761 | I want to create a following kind of layout in android , rite now i have created with fixed height of listview which is causing a problem with different dimension of screens of mobiles.

Initially when this screen appears a button will be at the bottom side only with empty listview and as an when the items will get added in a list view , it grows but button will remain steady at the bottom.
so far i have written following code
```
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
<ImageView
android:id="@+id/cText"
android:src="@drawable/c_text"
android:visibility="visible"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="50dip"
/>
<ListView
android:id="@android:id/list"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:drawSelectorOnTop="false"
/>
<ImageButton
android:id="@+id/cBtn"
android:layout_width="150dip"
android:layout_height="52dip"
android:src="@drawable/preview"
android:layout_alignParentTop="@+id/list"
android:layout_gravity="center_horizontal"/>
</RelativeLayout>
```
| Flexible relativelayout with list and image button | CC BY-SA 2.5 | null | 2011-02-22T12:32:34.310 | 2011-02-22T12:59:35.800 | null | null | 405,383 | [
"android",
"android-layout",
"android-relativelayout"
]
|
5,078,186 | 1 | 7,057,273 | null | 35 | 54,079 | Using `-webkit-transform: rotate(-5deg);` on a container div, Chrome renders the grid of images with really jagged edges. Whereas in FF (`-moz-transform:`) and IE (`-ms-filter:`) everything looks OK - see the difference below.
Is there any thing I can do about this?


| -webkit-transform rotate - Pixelated images in Chrome | CC BY-SA 3.0 | 0 | 2011-02-22T12:36:44.923 | 2014-04-05T13:33:43.203 | 2012-08-15T19:25:40.090 | 352,765 | 219,609 | [
"html",
"css",
"google-chrome",
"transform"
]
|
5,078,771 | 1 | null | null | 1 | 315 | I execute "SHOW PROCESSLIST" on the client App.
it gives the Output:

When I look at Host column it displays in one of the row as "WIN-R2VUKMIS1PR:54822"
How do I get to know what the host IP is "WIN-R2VUKMIS1PR:54822"...
I am writing a c program that executes "SHOW PROCESSLIST"
and displays the output of all connected hosts.
So how do I resolve the Host name to IP? I tried using
Here is the demo app I used to convert "WIN-R2VUKMIS1PR:54822" to IP:
```
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <netdb.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
int main(int argc, char *argv[ ]) {
struct hostent *h;
/* error check the command line */
if(argc != 2) {
fprintf(stderr, "Usage: %s hostname\n", argv[0]);
exit(1);
}
/* get the host info */
if((h=gethostbyname(argv[1])) == NULL) {
herror("gethostbyname(): ");
exit(1);
}
else {
printf("Hostname: %s\n", h->h_name);
printf("IP Address: %s\n", inet_ntoa(*((struct in_addr *)h->h_addr)));}
return 0;
}
```
Am I missing something? :-)
| Why does not "SHOW PROCESSLIST" give Host IP? | CC BY-SA 2.5 | 0 | 2011-02-22T13:30:59.813 | 2011-02-22T13:51:55.297 | 2011-02-22T13:51:55.297 | null | null | [
"c++",
"mysql",
"c",
"network-programming"
]
|
5,078,831 | 1 | 5,079,099 | null | 4 | 16,607 | I have unordered list inside a div. I use it to create buttons in menu.
```
#tagscontainer
{
width: 700px;
height: 50px;
margin: auto;
}
#tagscontainer li
{
margin-right: 1em;
float: left;
background: none repeat scroll 0 0 #EEEEEE;
}
<div id="tagscontainer">
<ul>
<li><a href="menu1"> Link 1</a></li>
<li><a href="menu2"> Link 2</a></li>
<li><a href="menu3"> Link 3</a></li>
</ul>
</div>
```
I want items to be centered vertically in hosting DIV. Also what is best practice to set height for ul or for li in menus like that. Basically I want my button to be larger than text with some IDENTICAL indent from parent div ceiling and floor.

| how to align UL inside DIV | CC BY-SA 2.5 | null | 2011-02-22T13:36:44.053 | 2011-02-22T14:12:32.917 | 2011-02-22T13:57:14.653 | 207,047 | 207,047 | [
"html",
"css"
]
|
5,079,011 | 1 | null | null | 0 | 133 | When I open:
Next select tab
I get samtimes empty list scriprs.
I write a simply extension manifest.json (my minimum)
```
{
"name": "TEST",
"version": "1.0",
"browser_action": {
"popup": "popup.html"
}
}
```
Popup.html
```
<!DOCTYPE html>
<html>
<head>
<script src="popup.js"></script>
</head>
<body>
<h1>TEST1</h1>
<div id="content">
TEST
</div>
</body>
</html>
```
popup.js
```
console.log('test OK');
```
Sometimes I get list but not with all my js files.
This file is only short example. I send to console message, and I see this message and I see this file in resource, but i not see in the tab.
My chrome version is 9.0.597.98.
I try with other version and I have the same problem.

| Debugging popup extensions | CC BY-SA 2.5 | 0 | 2011-02-22T13:53:34.520 | 2011-02-23T20:59:01.440 | 2011-02-23T10:36:34.923 | 266,202 | 266,202 | [
"google-chrome",
"google-chrome-extension"
]
|
5,079,385 | 1 | 5,081,133 | null | 1 | 1,664 | I am using HighCharts to produce some graphs.
For some reason the graph axis do not start at 00:00 (which is the earliest data point in this case) but instead start from 23:00, which seems odd.
I have tried setting the `pointStart` option to the earliest data point but this doesn't help either. I set the property like so:
```
options.plotOptions.series.pointStart = time;
```
Here is an image showing the issue:

| HighCharts - Graph axis starting BEFORE first data point | CC BY-SA 2.5 | 0 | 2011-02-22T14:28:34.000 | 2011-02-22T16:46:29.647 | 2011-02-22T14:39:36.607 | 94,278 | 94,278 | [
"javascript",
"jquery",
"highcharts"
]
|
5,079,420 | 1 | 5,080,450 | null | 1 | 565 | i try to get some data via WCF. İ created below app.config. But i face to face below

Large png:
[http://i54.tinypic.com/mjb9j4.png](http://i54.tinypic.com/mjb9j4.png)
```
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.web>
<compilation debug="true" />
</system.web>
<!-- When deploying the service library project, the content of the config file must be added to the host's
app.config file. System.Configuration does not support config files for libraries. -->
<system.serviceModel>
<services>
<service name="WcfServiceLibrary.OnDomainModels.Message">
<endpoint address="http://127.0.0.1:8731/MessageSrv" binding="wsHttpBinding" contract="WcfServiceLibrary.OnDomainModels.IData">
<identity>
<dns value="127.0.0.1" />
</identity>
</endpoint>
<!--<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />-->
<host>
<baseAddresses>
<add baseAddress="http://127.0.0.1:8731/Design_Time_Addresses/WcfServiceLibrary.OnDomainModels/Message/" />
</baseAddresses>
</host>
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior name="WcfServiceLibrary.OnDomainModels.MessageBehavior">
<!-- To avoid disclosing metadata information,
set the value below to false and remove the metadata endpoint above before deployment -->
<serviceMetadata httpGetEnabled="True" />
<!-- To receive exception details in faults for debugging purposes,
set the value below to true. Set to false before deployment
to avoid disclosing exception information -->
<serviceDebug includeExceptionDetailInFaults="False" />
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
```
### Error:
URL could not record. Do not have permission to access this namespace for your action C#
My WCf code:
```
namespace WcfServiceLibrary.OnDomainModels
{
[ServiceContract]
public interface IData
{
[OperationContract]
int GetData();
}
}
public class Message : IData
{
public int GetData()
{
using (entity MaintCtx = new entity ())
{
return MaintCtx.NonRoutineCard.Count();
}
}
```
| How to access Wcf? | CC BY-SA 2.5 | null | 2011-02-22T14:31:42.613 | 2011-02-22T19:59:17.753 | null | null | 52,420 | [
"c#",
".net",
"wcf",
"visual-studio-2008",
"wcf-binding"
]
|
5,079,746 | 1 | 5,145,653 | null | 2 | 5,410 | Yesterday I installed . Created some repository () and tried to import my project into it. But when I looked at repository folder structure it was like this:

In examples I saw import command is shown without pointing trunk subfolder in the repository URL. Later I tried to make a checkout but there was no folder and there was the same folder structure as in my repository.
What do I do wrong?
| Visual SVN server project import | CC BY-SA 2.5 | null | 2011-02-22T14:57:57.007 | 2013-05-17T09:54:37.417 | 2013-05-17T09:54:37.417 | 761,095 | 532,675 | [
"svn",
"import",
"project",
"visualsvn-server"
]
|
5,079,890 | 1 | 5,102,600 | null | 7 | 8,745 |
# Short Description
I am using charts for a specific application where i need to change the view angle of the rendered 3D Pie chart and value of automatic labels from pie label names to corresponding pie values.
This how the chart looks:

---
# Initialization
This is how i initialize it:
```
Dictionary<string, decimal> secondPersonsWithValues = HistoryModel.getSecondPersonWithValues();
decimal[] yValues = new decimal[secondPersonsWithValues.Values.Count]; //VALUES
string[] xValues = new string[secondPersonsWithValues.Keys.Count]; //LABELS
secondPersonsWithValues.Keys.CopyTo(xValues, 0);
secondPersonsWithValues.Values.CopyTo(yValues, 0);
incomeExpenseChart.Series["Default"].ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Pie;
incomeExpenseChart.Series["Default"].Points.DataBindXY(xValues, yValues);
incomeExpenseChart.ChartAreas["Default"].Area3DStyle.Enable3D = true;
incomeExpenseChart.Series["Default"].CustomProperties = "PieLabelStyle=Outside";
incomeExpenseChart.Legends["Default"].Enabled = true;
incomeExpenseChart.ChartAreas["Default"].Area3DStyle.LightStyle = System.Windows.Forms.DataVisualization.Charting.LightStyle.Realistic;
incomeExpenseChart.Series["Default"]["PieDrawingStyle"] = "SoftEdge";
```
Basically i am querying data from database using the `HistoryModel.getSecondPersonWithValues();` to get pairs as `Dictionary<string, decimal>` where is the and is .
---
# Problem #1
What i need is to be able to change the marked labels from to the or add another label of ammounts with the same colors (See Image).

---
# Problem #2
Another problem is that i need to change the view angle of 3D Pie chart. Maybe it's very simple and I just don't know the needed or maybe i need to override some paint event. Either ways any kind of ways would be appriciated.
Thanks in advance George.
| How to change the view angle and label value of a chart .NET C# | CC BY-SA 2.5 | 0 | 2011-02-22T15:09:42.327 | 2012-10-20T12:12:59.580 | 2012-03-13T15:43:29.107 | 50,776 | 151,907 | [
"c#",
"3d",
"angle",
"pie-chart"
]
|
5,080,012 | 1 | 5,080,381 | null | 1 | 2,336 | I took a clone of the [Selenium iOS Driver](http://code.google.com/p/selenium/wiki/IPhoneDriver) however xcode isn't allowing me to build for a device.
Here is the menu:

When I select 'device' from the list, it pauses for a second then appears to do nothing.
NB: Im using, xcode Version 3.2.5
| Selenium iOS Driver | CC BY-SA 2.5 | null | 2011-02-22T15:19:12.317 | 2011-02-22T15:48:26.490 | 2017-02-08T14:31:35.437 | -1 | 293,008 | [
"iphone",
"xcode",
"ipad",
"ios",
"selenium"
]
|
5,080,037 | 1 | 5,080,695 | null | 6 | 7,719 | I have this snippet of code (AJAX) in jQuery.
```
$.get('someScript.php?lat=' + clickedLatLng.lat() + '&lon=' + clickedLatLng.lng() + '&value=5', doSomething);
```
And this is a function (shows an icon on Google Maps and changes some values in input fields).
```
function doSomething(data) {
data = data.trim();
data = data.split(",");
var stopName = data[0];
var stopLat = data[1];
var stopLon = data[2];
$("#start").val(stopName);
if (startMarker == null) {
startMarker = new google.maps.Marker({
position: new google.maps.LatLng(stopLat,stopLon),
map: map,
zIndex: 2,
title: stopName,
icon: startImage
});
} else {
startMarker.setPosition(new google.maps.LatLng(stopLat,stopLon));
}
}
```
But it works in all browsers except IE, in my case IE 8. I didn't test it in IE 6/7. It pops out this error...

I looked into and this is the function where it breaks...
```
// resolve with given context and args
resolveWith: function( context, args ) {
if ( !cancelled && !fired && !firing ) {
firing = 1;
try {
while( callbacks[ 0 ] ) {
callbacks.shift().apply( context, args );
}
}
finally {
fired = [ context, args ];
firing = 0;
}
}
return this;
},
```
actually
```
callbacks.shift().apply( context, args );
```
Can someone help? Where is the problem? The same thing with
This is my larger code...
```
// Set some events on the context menu links
contextMenu.find('a').click( function()
{
// fade out the menu
contextMenu.fadeOut(75);
// The link's href minus the #
var action = $(this).attr('href').substr(1);
switch (action) {
case 'startMenu':
$.get('someScript.php?lat=' + clickedLatLng.lat() + '&lon=' + clickedLatLng.lng() + '&radijus=5', doSomethingWithData1);
break;
case 'stopMenu':
$.get('someScript.php?lat=' + clickedLatLng.lat() + '&lon=' + clickedLatLng.lng() + '&radijus=5', doSomethingWithData2);
break;
}
return false;
});
```
When user clicks on an item within on Google Maps then do "" and "". This is also some code for context menu
```
// Hover events for effect
contextMenu.find('a').hover( function() {
$(this).parent().addClass('hover');
}, function() {
$(this).parent().removeClass('hover');
});
```
and this for
```
$.ajaxSetup ({
cache: false
});
```
This is how I included my scripts.
```
<!-- Google Maps -->
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
<!-- Load Javascript / jQuery -->
<script type="text/javascript" src="js/jquery-1.5.js"></script>
<script type="text/javascript" src="js/jquery.ui.core.js"></script>
<script type="text/javascript" src="js/jquery.ui.position.js"></script>
<script type="text/javascript" src="js/jquery.ui.widget.js"></script>
<script type="text/javascript" src="js/jquery.ui.autocomplete.js"></script>
<link rel="stylesheet" href="js/jquery.ptTimeSelect.css" type="text/css" media="all" />
<script type="text/javascript" src="js/jqtransformplugin/jquery.jqtransform.js"></script>
<link rel="stylesheet" href="js/jqtransformplugin/jqtransform.css" type="text/css" media="all" />
<script type="text/javascript" src="js/jquery.ui.datepicker.js"></script>
```
| jQuery error only in IE (8) - "Object doesn't support..." | CC BY-SA 2.5 | 0 | 2011-02-22T15:21:17.993 | 2011-02-22T16:11:52.410 | 2011-02-22T15:50:38.347 | 455,268 | 455,268 | [
"jquery",
"ajax",
"google-maps",
"internet-explorer-8"
]
|
5,080,212 | 1 | null | null | 0 | 948 | I made a similar question few hours ago, but I think I asked a wrong question there. This is more exact one.
im using cURL on PHP and i want to use a site, but everytime i change my site, the browser posts a value to server, and if you dont, you can't go to the site.
you can see that the x value changes all the time from the picture, its a FireFox Live HTTP headers addon, it shows what pages i visit with browser

i looked the source code and found out what is the x value, and it comes from javascript. can i get the value with cURL or some other way from the server?
```
date = new Date();
ms = (date.getHours() * 24 * 60 * 1000) + (date.getMinutes() * 60 * 1000) + (date.getSeconds() * 1000) + date.getMilliseconds();
```
| Advanced cURL and PHP | CC BY-SA 2.5 | null | 2011-02-22T15:34:47.800 | 2015-08-23T22:05:23.137 | 2015-08-23T22:05:23.137 | 1,768,232 | 625,189 | [
"javascript",
"php",
"html",
"curl"
]
|
5,080,332 | 1 | 5,187,073 | null | 1 | 277 | I have a problem with UIViews to which I really don't know how to proceed.
It will be futile to describe my problem so here are the screenshots of before and after.
Somehow the UIView gets the layout that was defined in interfacebuilder AFTER an image is chosen. Before an image is chosen it doesn't obey to its defined layout for some reason.
Before using imagePicker for picking an image:..........................After Picking image:
 | 
So yeah that is basically the problem. The black squares are other images and you can tell by that how it should and how it shouldn't, one of the images is being cut (normally behind the "No SIM" label.) I just put them to hide the real images on the screenshots.
So maybe is something in relation to two things I do here.
1. I resize the image chosen to 320-480 and put it on a smaller UIImageView before uploading it to a server.
2. If the user is writing on a textField the entire view is animated up, so the keyboard won't hide the textFields.
UPDATE:
I noticed this happens on a UIView that does nothing related to resizing images or textFields. This is happening too on a UIView I have where there are only 3 buttons and 2 labels. Only 5 elements. The 3 buttons are in custom mode with images. So 3 image~Buttons and 2 labels....
Thank you for your help and suggestions fellow Stackoverflowers!!! (Stackoverflowerers?)
I really have no idea on how to proceed here, though I've been playing around transforming the UIView at the viewDidLoad to no avail.
UPDATE 2:
I started to think that maybe there is something wrong with the code I use to make the transition from view to view and has nothing to do with the elements that are contained in it. Since it is happening in all my views EXCEPT the first view. So here is the code I use for the transition of views:
```
- (void) flipToUploadView {
UploadViewController *aUploadView = [[UploadViewController alloc] initWithNibName:@"UploadView" bundle:nil];
[self setUploadViewController:aUploadView];
[aUploadView release];
[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:1.0];
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromLeft forView:window cache:YES];
[uploadViewController viewWillAppear:YES];
[viewController viewWillDisappear:YES];
[viewController.view removeFromSuperview];
[self.window addSubview:[uploadViewController view]];
[viewController viewDidDisappear:YES];
[uploadViewController viewDidAppear:YES];
[UIView commitAnimations];
}
```
| UIView being pushed up (apparently)inexplicably | CC BY-SA 2.5 | 0 | 2011-02-22T15:43:41.480 | 2011-03-03T21:55:06.877 | 2011-02-23T13:28:52.500 | 582,829 | 582,829 | [
"iphone",
"objective-c",
"uiview",
"uikeyboard"
]
|
5,080,407 | 1 | 5,080,673 | null | 0 | 222 | I am using a wordpress plugin called shopp sell products, and one aspect of shopp is it's image rendering. I am trying to basically tell shopp to return two images of the same product: one thumbnail and one large image. Both of those images are returned to the page right next to each other. Perfect!
What i need to do is to use jquery to hide the large image, and to set the thumbnail as a link to the large image (lightbox style).
See example below!!

The reason I cant do this in pure HTML and css is because the images are dynamically generated, and shopp has no "image-link" functionality. SO again, I need to take these two images, and set the large image as a link of the small image using the markup below the (above) image using jquery.
Any idea how I can accomplish this?
| Turn two dynamic images into a link with Jquery | CC BY-SA 2.5 | null | 2011-02-22T15:50:39.957 | 2015-05-26T11:36:33.933 | 2015-05-26T11:36:33.933 | 2,332,721 | 121,630 | [
"jquery",
"image",
"dynamic",
"wordpress",
"shopp"
]
|
5,080,380 | 1 | 5,108,249 | null | 18 | 11,511 | I have a problem where an application (written in Delphi) is behaving properly at default 96 DPI settings on all systems, but is behaving inconsistently at the "150% text size" (internally 144 dpi) setting, on different systems. It seems that on some systems, that certain text/font parts of my application are being stretched and on other systems, they aren't. I would have thought that my application, on a certain version of Windows (Win7), at a certain DPI, should behave the same way.
Either my application will make it known to Windows that it doesn't need the DPI Virtualization feature, or it will not. That much I understand. What I don't understand is how DPI changes can cause different appearance on two machines, both running Windows 7, both at 144 dpi, displaying the same fonts and forms at the same fixed sizes.
Is there some configuration-dependant elements involved in DPI Virtualization that I need to inspect in windows (registry etc)? Otherwise, how do you troubleshoot and know whether DPI virtualization is being done on your client window?
In Delphi, one has to set the TForm.Scaled property to false, if one doesn't want scaling. But what I don't understand is that when the main form's Scaled property is true, I cannot always predict the outcome.
What is most perplexing to me in my application, is that I have a control that only misbehaves in my large real application, but which does not misbehave in a standalone app where I am trying to debug just the control. To understand the control behaviour in a standalone app I was forced to make a demo app where I force the DPI awareness in via the manifest file. Then I can reproduce the control drawing glitch, although in a different form.
Here is the manifest file I use in my demo app, which exposes the problems that my controls have with dealing with high-dpi settings in windows. However, one strange thing I have found is that it is possible for an application
```
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<asmv3:application xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
<asmv3:windowsSettings
xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
<dpiAware>true</dpiAware>
</asmv3:windowsSettings>
</asmv3:application>
<assemblyIdentity version="14.0.3615.26342" processorArchitecture="*"
name="TestProject" type="win32"></assemblyIdentity>
<description>High DPI Controls Test App</description>
</assembly>
```
here's an example of one of about 30 places where the controls in my application are messed up when I disable DPI virtualization in my app. This particular glitch was solved by turning off the Scaled property in my form. But in other places, having TForm.Scaled=false causes the problem, whereas in some forms, it fixes it:

Update: It turns out that some of my controls use GDI+ and that font behaviour in GDI+ contexts is different than font behaviour in normal GDI contexts, at least for certain third-party controls that use GDI+. That's a major source of headaches. Secondly, there is the spotty test coverage and poorly-defined requirements, for DPI awareness, in the VCL. Some VCL controls are based on MS Common Controls, and while it's fair to say that the underlying common controls probably work fine in high-DPI situations, not all the VCL control wrappers can be guaranteed to work correctly. So, reviewing an application for high-DPI-awareness in all its controls, as well as correct behaviour in all available windows 7 themes:
1. aero glass on, at 96dpi (Default Win7 appearance on most modern hardware)
2. basic theme (aero glass off) but xp themes enabled
3. classic win2000 look where glass is off, as well as xp level themes,
4. high contrast white
5. high contrast black
6. Various Other-than-96-DPI settings
..and the list goes on., and you have a pretty heavy burden, as an application developer. Whether you are a delphi user and use the VCL, or you are an MFC/ATL C++ developer, it seems to me, that supporting all of the various quirky windows modes is a burden almost too heavy to bear. So most people don't bother. Am I right?
| Troubleshooting DPI Virtualization and DPI-aware applications, in Windows Vista and Windows 7 | CC BY-SA 2.5 | 0 | 2011-02-22T15:48:26.083 | 2013-08-06T10:19:32.000 | 2011-02-24T17:19:02.490 | 84,704 | 84,704 | [
"delphi",
"windows-7",
"windows-vista",
"dpi",
"highdpi"
]
|
5,080,567 | 1 | 5,080,741 | null | 0 | 3,148 | how can i tighten things up and make the fields not so wide so it can fit on a page without horizontal scrolling? i added css to a div but the field is still very long while the link text does wrap (in some browsers)
i am hopping for a .net way to get it to work in all browsers.
here is my terrible UI of my data grid

here is my defined asp.net code:
```
<asp:GridView ID="gv" runat="server" CellPadding="4" Font-Names="Verdana" Font-Size="8pt"
EnableModelValidation="True" ForeColor="#333333" GridLines="None" OnRowCommand="gv_RowCommand"
OnRowEditing="gv_RowEditing" OnRowCancelingEdit="gv_RowCancelingEdit" OnRowDataBound="gv_RowDataBound"
OnRowDeleting="gv_RowDeleting" OnRowUpdating="gv_RowUpdating" ShowFooter="true"
DataKeyNames="ProjectLinkId,LastUpdate" AutoGenerateColumns="False">
<AlternatingRowStyle BackColor="White" />
<RowStyle BackColor="#EFF3FB" />
<Columns>
<asp:TemplateField>
<ItemTemplate>
<table>
<tr>
<td>
<asp:Button runat="server" ID="cbEdit" Text="Edit" Width="75px" Font-Size="8pt" CommandName="Edit" />
</td>
</tr>
<tr>
<td>
<asp:Button runat="server" ID="cbDelete" Text="Delete" Width="75px" Font-Size="8pt"
CommandName="Delete" />
</td>
</tr>
</table>
</ItemTemplate>
<EditItemTemplate>
<table>
<tr>
<td>
<asp:Button runat="server" ID="cbUpdate" Text="Update" Width="75px" Font-Size="8pt"
CommandName="Update" />
</td>
</tr>
<tr>
<td>
<asp:Button runat="server" ID="cbCancel" Text="Cancel" Width="75px" Font-Size="8pt"
CommandName="Cancel" />
</td>
</tr>
</table>
</EditItemTemplate>
<FooterTemplate>
<asp:Button runat="server" ID="cbSave" Text="Insert" Width="75px" Font-Size="8pt"
CommandName="Save" />
</FooterTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Type">
<ItemTemplate>
<asp:Label runat="server" ID="lblLinkTypeText" Text='<%# Bind("LinkTypeText") %>'
CssClass="DefaultFont" />
</ItemTemplate>
<EditItemTemplate>
<asp:DropDownList runat="server" ID="ddlLinkTypeCID" CssClass="DefaultFont" />
</EditItemTemplate>
<FooterTemplate>
<asp:DropDownList runat="server" ID="ftrLinkTypeCID" CssClass="DefaultFont" />
</FooterTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="URL">
<ItemTemplate>
<div style="width:316px; word-wrap: break-word">
<asp:HyperLink runat="server" ID="lbURL" NavigateUrl='<%# Bind("URL") %>' Text='<%# Bind("URL") %>' Width="300" />
</div>
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox runat="server" ID="txtURL" TextMode="MultiLine" Text='<%# Bind("URL") %>'
CssClass="DefaultTextBox" />
</EditItemTemplate>
<FooterTemplate>
<asp:TextBox runat="server" ID="ftrURL" TextMode="MultiLine" Text='<%# Bind("URL") %>'
CssClass="DefaultTextBox" />
</FooterTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Description">
<ItemTemplate>
<div style="width:316px; word-wrap: break-word">
<asp:Label runat="server" ID="lblDescription" Text='<%# Bind("Description") %>' CssClass="DefaultFont"/>
</div>
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox runat="server" ID="txtDescription" TextMode="MultiLine" Text='<%# Bind("Description") %>'
CssClass="DefaultTextBox" />
</EditItemTemplate>
<FooterTemplate>
<asp:TextBox runat="server" ID="ftrDescription" TextMode="MultiLine" Text='<%# Bind("Description") %>'
CssClass="DefaultTextBox" />
</FooterTemplate>
</asp:TemplateField>
</Columns>
<FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
<SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#2461BF" />
<AlternatingRowStyle BackColor="White" />
</asp:GridView>
```
| can i set the width of fields in my datagrid? | CC BY-SA 2.5 | null | 2011-02-22T16:01:51.487 | 2012-02-09T01:40:37.987 | 2011-02-22T16:05:39.313 | 352,157 | 352,157 | [
"asp.net",
"gridview"
]
|
5,080,672 | 1 | 5,080,745 | null | 2 | 369 | 
I want to change the settings so that i should get rid of these symbols..
So how can i do that in eclipse
| Unknown symbols allover in eclipse | CC BY-SA 2.5 | null | 2011-02-22T16:09:42.623 | 2011-02-22T16:21:26.537 | null | null | 410,693 | [
"eclipse",
"format"
]
|
5,080,842 | 1 | 5,080,957 | null | 0 | 223 | Hay, not sure how many of you have come across this, but i was in a meeting with a client who has a small monitor and when i viewed the WordPress admin area, panels with overlapping.
This problem appears when the window gets resized. I've attached a screenshot of the issue

Does anyone know a solution, or perhaps a CSS hack for this?
| WordPress admin area has overlapping panels when resized | CC BY-SA 2.5 | null | 2011-02-22T16:23:34.143 | 2011-02-23T10:13:20.507 | null | null | 164,230 | [
"css",
"wordpress",
"browser",
"admin"
]
|
5,080,828 | 1 | 5,081,418 | null | 22 | 18,897 | Is it possible to created in a Django select (dropdown) widget, when that widget is on a form that is from a data Model? Can I create the widget on the left-side picture below?

My first experiment in creating a form with named groups, was done , like this:
```
class GroupMenuOrderForm(forms.Form):
food_list = [(1, 'burger'), (2, 'pizza'), (3, 'taco'),]
drink_list = [(4, 'coke'), (5, 'pepsi'), (6, 'root beer'),]
item_list = ( ('food', tuple(food_list)), ('drinks', tuple(drink_list)),)
itemsField = forms.ChoiceField(choices = tuple(item_list))
def GroupMenuOrder(request):
theForm = GroupMenuOrderForm()
return render_to_response(menu_template, {'form': theForm,})
# generates the widget in left-side picture
```
And it worked nicely, creating the dropdown widget on the left, with named groups.
I then created a data Model that had basically the same structure, and used Django's ability to auto-generate forms from Models. It worked - in the sense that it showed all of the options. But the options were not in named groups, and so far, I haven't figured out how to do so - if it's even possible.
I have found several questions, where the answer was, “create a form constructor and do any special processing there”. But It seems like the forms.ChoiceField requires a for named groups, and I’m not sure how to convert a tuple to a QuerySet (which is probably impossible anyway, if I understand QuerySets correctly as being pointer to the data, not the actual data).
The code I used for the data Model is:
```
class ItemDesc(models.Model):
''' one of "food", "drink", where ID of “food” = 1, “drink” = 2 '''
desc = models.CharField(max_length=10, unique=True)
def __unicode__(self):
return self.desc
class MenuItem(models.Model):
''' one of ("burger", 1), ("pizza", 1), ("taco", 1),
("coke", 2), ("pepsi", 2), ("root beer", 2) '''
name = models.CharField(max_length=50, unique=True)
itemDesc = models.ForeignKey(ItemDesc)
def __unicode__(self):
return self.name
class PatronOrder(models.Model):
itemWanted = models.ForeignKey(MenuItem)
class ListMenuOrderForm(forms.ModelForm):
class Meta:
model = PatronOrder
def ListMenuOrder(request):
theForm = ListMenuOrderForm()
return render_to_response(menu_template, {'form': theForm,})
# generates the widget in right-side picture
```
I'll change the data model, if need be, but this seemed like a straightforward structure. Maybe too many ForeignKeys? Collapse the data and accept denormalization? :) Or is there some way to convert a tuple to a QuerySet, or acceptable to a ModelChoiceField?
final code, based on [meshantz](https://stackoverflow.com/users/341480/meshantz)' [answer](https://stackoverflow.com/questions/5080828/how-to-group-the-choices-in-a-django-select-widget/5081418#5081418):
```
class FooIterator(forms.models.ModelChoiceIterator):
def __init__(self, *args, **kwargs):
super(forms.models.ModelChoiceIterator, self).__init__(*args, **kwargs)
def __iter__(self):
yield ('food', [(1L, u'burger'), (2L, u'pizza')])
yield ('drinks', [(3L, u'coke'), (4L, u'pepsi')])
class ListMenuOrderForm(forms.ModelForm):
def __init__(self, *args, **kwargs):
super(ListMenuOrderForm, self).__init__(*args, **kwargs)
self.fields['itemWanted'].choices = FooIterator()
class Meta:
model = PatronOrder
```
(Of course the actual code, I'll have something pull the item data from the .)
The biggest change from the djangosnippet he linked, appears to be that Django has incorporated some of the code, making it possible to directly assign an Iterator to , rather than having to override the entire class. Which is very nice.
| How to group the choices in a Django Select widget? | CC BY-SA 2.5 | 0 | 2011-02-22T16:22:37.377 | 2018-10-11T09:30:57.013 | 2017-05-23T12:08:53.243 | -1 | 78,409 | [
"python",
"django",
"widget"
]
|
5,080,903 | 1 | 5,081,031 | null | 0 | 222 | I am trying to make a multi-table query that I am not quite sure how to do properly. I have User, Message, Thread, and Project.
A User is associated with Message/Thread/Project as either the Creator or as it being 'shared' with them.
A Message is contained within a Thread (associated by message.thread_id and thread.id), and a Thread is contained within a Project (associated by thread.project_id and project_id).
I would like to create a query where given a User.id value, it will return all messages that the user has access to, as well as the Thread and Project name that that message is under, both as Creator or 'Shared'. I use a table to handle the 'shares'. The rough diagram is: [http://min.us/mvpqbAU](http://min.us/mvpqbAU)

There are more columns in each, but I left them out for simplicity.
| multi-table mysql query | CC BY-SA 2.5 | null | 2011-02-22T16:27:57.943 | 2011-02-22T16:37:46.990 | 2011-02-22T16:31:38.967 | 341,251 | 628,670 | [
"mysql"
]
|
5,080,998 | 1 | 5,081,060 | null | 1 | 1,446 | 
Hi. I want to make a dynamic combo box with the example above, which when pressing "+", new combo box appears below and when pressing "-", the combo box disappears.
How do I do this in Java? Thank you very much.
| How do I create dynamic combo box in Java which adds and removes when clicking the button? | CC BY-SA 2.5 | null | 2011-02-22T16:34:51.433 | 2011-02-22T17:00:15.590 | 2011-02-22T17:00:15.590 | 343,955 | 461,025 | [
"java",
"swing",
"combobox"
]
|
5,081,304 | 1 | 5,083,476 | null | 1 | 1,498 | I have a simple Silverlight project that is just getting a set of entities (EF 4) on an IIS 7.5 system. Here is my web config:
```
<configuration>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true">
<add name="DomainServiceModule" preCondition="managedHandler" type="System.ServiceModel.DomainServices.Hosting.DomainServiceHttpModule, System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</modules>
<validation validateIntegratedModeConfiguration="false" />
</system.webServer>
<system.web>
<httpModules>
<add name="DomainServiceModule" type="System.ServiceModel.DomainServices.Hosting.DomainServiceHttpModule, System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</httpModules>
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
</assemblies>
</compilation>
</system.web>
<connectionStrings>
<add name="BusinessProcessEntities" connectionString="metadata=res://*/ForecastModel.csdl|res://*/ForecastModel.ssdl|res://*/ForecastModel.msl;provider=System.Data.SqlClient;provider connection string="Data Source=usd-ctct-app-01.mydomain.net;Initial Catalog=BusinessProcess;Integrated Security=True;MultipleActiveResultSets=True"" providerName="System.Data.EntityClient" />
</connectionStrings>
<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
</system.serviceModel>
</configuration>
```
When I browse to [http://forecasting.mydomain.net/ClientBin/ForecastTool_2-Web-ForecastDomainSvc.svc?wsdl](http://forecasting.mydomain.net/ClientBin/ForecastTool_2-Web-ForecastDomainSvc.svc?wsdl) I see the service web page. Fiddler has given me nothing to really go on. SQL Profiler does not show the query hitting the DB server. As you would expect, everything works briliantly with Cassini. Here is a show of the popup message I get for the error. Just not sure what I have done wrong here. I feel this should be simpler than it is right now...

| DomainOperationException when loading entities via Domain Service (WCF RIA) | CC BY-SA 2.5 | null | 2011-02-22T17:02:10.353 | 2012-06-09T20:26:30.803 | 2012-06-09T20:26:30.803 | 41,956 | 330,430 | [
".net",
"entity-framework-4",
"silverlight-4.0",
"ria",
"domainservices"
]
|
5,081,409 | 1 | 5,081,440 | null | 4 | 1,033 | I am trying to create a custom shaped listBox in WPF which I will use to display some stuff. I need it to look something like a cloud shape (see attachment). What is the simplest way to achieve this (preffably in Blend). Many thanks.

| WPF Custom Shaped Listbox | CC BY-SA 2.5 | 0 | 2011-02-22T17:11:11.170 | 2011-02-22T17:46:55.077 | null | null | 546,564 | [
"c#",
"wpf"
]
|
5,081,454 | 1 | null | null | 4 | 3,123 | I have built a FB4 application which accesses a .NET web service of a partner company. The app runs just fine in FB4 development environment, but won't work when published to my server. I can not figure out how to get past the following error:
> Security error accessing url Destination: DefaultHTTP
It is unlikely that I will get a crossdomain.xml file on their server, so I'm trying to get it to work using a proxy. The proxy.php is located in the same directory as the swf, and it works just fine if I use it directly in the browser.
The following is what I currently have setup:
proxy.php:
```
<?php
$session = curl_init(trim(urldecode($_GET['url']))); // Open the Curl session
curl_setopt($session, CURLOPT_HEADER, false); // Don't return HTTP headers
curl_setopt($session, CURLOPT_RETURNTRANSFER, true); // Do return the contents of the call
$xml = curl_exec($session); // Make the call
header("Content-Type: text/xml"); // Set the content type appropriately
echo $xml; // Spit out the xml
curl_close($session); ?>
```
The code in Flash Builder 4 (I'm using a Webservice object in FB4):
```
wsdl = http://example.com/autoben/proxy2.php?url=http://staging.partnerCompany.net/api/v01_00/theservice.asmx?wsdl
```
The flash player is version 10.x
I'm obviously not understanding the new security rules built into the latest Flash player.
A of the error can be seen here:

| Flash Builder 4 Security error accessing url Destination: DefaultHTTP | CC BY-SA 4.0 | 0 | 2011-02-22T17:15:10.393 | 2020-12-10T16:03:25.770 | 2020-12-10T16:03:25.770 | 2,756,409 | 628,711 | [
"flash",
"security",
"adobe",
"flexbuilder"
]
|
5,081,526 | 1 | 5,081,735 | null | 2 | 248 | I need some suggestions in the database design schema I've created below... I am not sure that it's correct.. in terms of relationship. Especially the USER - USER_RESERVATION - RESERVATION.
What I am trying to say is that a USER can have many RESERVATION, but then the same RESERVATION can belong to many different USERS... am I representing it correctly?

| database schema question | CC BY-SA 2.5 | null | 2011-02-22T17:21:23.197 | 2011-02-22T17:40:50.313 | null | null | 95,265 | [
"database",
"database-design",
"schema"
]
|
5,081,611 | 1 | null | null | 2 | 2,592 | In some websites (example: [http://www.dubizzle.com/](http://www.dubizzle.com/)) I have seen an excellent Google Map feature which allows the user to select a neighborhood/region from a dropdown and the Google map shown just below the drop downwill zoom to that area and highlighted the region using a polygon.. Can anyone please tell me how to achieve this functionality.. The screen shot of this is given below

Thanks
Anz
| Google map area/neighbourhood selection | CC BY-SA 2.5 | null | 2011-02-22T17:29:04.313 | 2011-02-22T17:36:26.010 | 2011-02-22T17:33:36.667 | 139,010 | 146,329 | [
"google-maps"
]
|
5,081,830 | 1 | 5,094,004 | null | 0 | 473 | i need to display values of the type "Integer" in a table.
now, what i thought to do, is to simply check for the type "Integer" in the "getDataFields()"
method of DataTemplate and to set this DataTemplate as the datatemplate of my TableView.
The screenshot below shows you my "getDataFields" method. After running this code on a simulator i just get a NoClassDefFoundError.
Do any of you guys have any ideas how to do this?

| How to display Integer values in a BlackBerry Table | CC BY-SA 2.5 | null | 2011-02-22T17:50:41.657 | 2011-02-24T15:50:35.597 | null | null | 579,071 | [
"java",
"user-interface",
"blackberry",
"components"
]
|
5,081,842 | 1 | 5,084,569 | null | 3 | 12,750 | I'm trying to rotate a vector in 3 dimensions by creating a rotation matrix from the world to the new rotation. I do the rotation by first rotating around the Z axis, then the Y axis and lastly the X axis using right hand notation.
The matrix I use can be found on wikipedia ([http://en.wikipedia.org/wiki/Euler_angles](http://en.wikipedia.org/wiki/Euler_angles)). It's located slightly below the middle of the page in the list of transformation matrices. I'm using the ZYX one:

I now create it with a Z rotation of +45 degrees, a Y rotation of +45 degrees and no X rotation. This gives me the following matrix:
```
[ 0.5 -0.707 0.5 ]
[ 0.5 0.707 0.5 ]
[ -0.707 0.0 0.707 ]
```
Now I multiply it by the following vector:
```
[ 10 ]
[ 0 ]
[ 0 ]
```
As can be seen it's a 10 unit long vector along the x-axis. I expect the rotated result to be around 6 in the x, y, and z field (with z being negative) as that gives a vector of roughly length 10. Ie the vector is rotated first exactly between the world x and y axis (the first z rotation) and then angled down from there another 45 degrees ending up exactly between the x-y plane and the negative z axis (the second y rotation). In my mind this means three equally long unit vectors representing this vector.
However, both my matrix class and all other programs give me this vector as result:
```
[ 5 ]
[ 5 ]
[ -7.07 ]
```
It seems correct as the length of it is 10 as expected. So the question is where am I wrong? I'm sure I'm making some stupid thought error somewhere obvious, because it sure doesn't have three equally long arms :p
| 3D Z-Y-X rotation of vector | CC BY-SA 2.5 | 0 | 2011-02-22T17:51:42.327 | 2011-02-22T22:13:53.713 | 2011-02-22T18:09:02.183 | 498,519 | 498,519 | [
"3d",
"matrix",
"rotation"
]
|
5,082,067 | 1 | 5,082,277 | null | 9 | 34,626 | I need to create a horizontal navigation menu with a changing number of items (this is important - I can't hard-code widths into the CSS and I don't want to calculate them with JS) that fill up to a certain width, let's say 800px.
With tables, 
```
<table width="800" cellspacing="0" cellpadding="0">
<tr>
<td>One</td>
<td>Two</td>
<td>Three</td>
<td>Four</td>
<td>Five Seven</td>
</tr>
</table>
<style>
table td {
padding: 5px 0;
margin: 0;
background: #fdd;
border: 1px solid #f00;
text-align: center;
}
</style>
```
Note that longer items take up more space and I can add items into the HTML without changing anything in CSS and the menu items shrink to accommodate additional items - the whole menu never being shorter or longer than 800px.
As a menu isn't a semantically correct use of a table, can this be done with say a list and pure CSS?
| CSS dynamic horizontal navigation menu to fill up specific width (table behavior) | CC BY-SA 3.0 | 0 | 2011-02-22T18:10:16.603 | 2017-11-02T15:31:44.327 | 2017-11-02T15:31:44.327 | 4,370,109 | 242,317 | [
"html",
"css",
"menu",
"html-table",
"navigation"
]
|
5,082,295 | 1 | 5,087,555 | null | 0 | 348 | i need to implement a list as shown in the screenshot below!
now, my question is, what BB component do you suggest to use?
i thought of a RichList, but there are not many possibilities to customize this component afaik.
the alternative would be a Table.
are there other ways to implement this? is it possible to customize a RichList in a way to make it look like the screenshot below?

| How to implement a certain List design? | CC BY-SA 2.5 | null | 2011-02-22T18:33:52.137 | 2011-02-23T06:05:21.110 | null | null | 579,071 | [
"java",
"user-interface",
"blackberry",
"components"
]
|
5,082,632 | 1 | 5,082,824 | null | 64 | 128,057 | The text is correctly displayed in Chrome. I want it to display this way in all browsers. How can I do this?
I was able to fix this in Safari with `-webkit-font-smoothing: antialiased;`
Chrome:

Firefox:

```
h1 {
font-family: Georgia;
font-weight: normal;
font-size: 16pt;
color: #444444;
-webkit-font-smoothing: antialiased;
}
```
```
<h1>Hi, my name</h1>
```
And a JSFiddle: [http://jsfiddle.net/jnxQ8/1/](http://jsfiddle.net/jnxQ8/1/)
| Same font except its weight seems different on different browsers | CC BY-SA 4.0 | 0 | 2011-02-22T19:02:54.773 | 2018-12-13T16:02:10.597 | 2018-12-13T16:02:10.597 | 2,756,409 | 502,236 | [
"css",
"fonts",
"cross-browser"
]
|
5,082,833 | 1 | 5,083,215 | null | 3 | 14,223 | I am currently developing a PUBLIC and OPEN SOURCE ecommerce software and want to embed a chat plugin into it using PHP/MySQL (similar to Facebook). But much simpler. You can see the draft preview below.

- -
Security is important issue, because this chat plugin would be embedded into software and that software will be published as OPEN SOURCE.
My question is that where should I to writing it and how to get ?
| Chat Script with PHP/MySQL like Facebook | CC BY-SA 3.0 | 0 | 2011-02-22T19:23:01.347 | 2012-10-21T20:55:05.290 | 2011-06-02T08:26:20.367 | 272,478 | 272,478 | [
"php",
"mysql",
"facebook",
"chat"
]
|
5,082,905 | 1 | 5,082,938 | null | 0 | 1,270 | I'm accessing a Subversion repository with Subclipse. Some of the folders in the Package Explorer window of MyEclipse show up with the uncommitted changes decorator: 
Usually, this means that one or more files in the directory on my machine have local, uncommitted changes. Right now, though, some of the folders appear to contain no files or subfolders with uncommitted changes. (I.e. I don't see any of these: )
This inconsistency is supported by Team Synchronization mode. When I tell Subclipse to synchronize with the repository for one of the affected directories, I see the following screen:

Under normal conditions, there would be a list under the folder of every file that didn't match its repository counterpart. However, as you can see, there's nothing there but a "will be committed" decorator on the folder itself. The "SVN update" and "replace with repository version" commands do nothing, and "compare with repository version" brings up a "no changes found" dialog.
[this answer](https://stackoverflow.com/questions/3917925/what-do-the-arrow-icons-in-subclipse-mean/3920248#3920248)
| Why do I see SVN's uncommitted changes decorator on fully synced directories? | CC BY-SA 2.5 | null | 2011-02-22T19:28:06.657 | 2011-02-23T22:59:43.027 | 2017-05-23T11:48:25.477 | -1 | 122,607 | [
"svn",
"decorator",
"subclipse"
]
|
5,082,982 | 1 | 5,083,090 | null | 0 | 527 | i'm looking to make divs flip around like in this short animation i made with flash. [this flip](http://lab.smashup.it/flip) plugin looks pretty close to what i need, but the developer said it can't flip along the left axis like in my video. it only flips along the center.
also in flash i might've used a 3d tool to make it happen.

| jquery flip plugin on an axis | CC BY-SA 2.5 | null | 2011-02-22T19:35:15.630 | 2011-02-22T19:46:12.987 | null | null | 42,589 | [
"jquery",
"flip"
]
|
5,082,991 | 1 | 5,099,056 | null | 15 | 12,937 | I have a POCO class that has two one-way unary relationships with another class, both classes share an ancestor. The names of the foreign keys in the generated schema do not reflect the property names. (Properties MainContact and FinancialContact give PersonId and PersonId1 field names).
How can I influence schema generation to generate database column names that match the property names?
The model looks like this:

The code looks like this:
```
public class CustomerContext: DbContext
{
public DbSet<Organisation> Organisations { get; set; }
public DbSet<Person> Persons { get; set; }
protected override void OnModelCreating(ModelBuilder builder)
{
DbDatabase.SetInitializer(new DropCreateDatabaseAlways<CustomerContext>());
}
}
public abstract class Customer
{
public int Id { get; set; }
public string Name { get; set; }
}
public class Person : Customer
{
public string Email { get; set; }
}
public class Organisation : Customer
{
public Person FinancialContact { get; set; }
public Person MainContact { get; set; }
}
```
The schema looks like this:

# Answer from druttka
---
druttka's answer below did the job and it's nice to know that it's a CTP5 bug that's behind this. EF also needs the cascade behaviour to be specified and I've used the fluent API to do this following the example in the link given by druttka. Some more good reading from Morteza Manavi [here](http://weblogs.asp.net/manavi/archive/2011/01/23/associations-in-ef-code-first-ctp5-part-3-one-to-one-foreign-key-associations.aspx).
The code now is this:
```
public class CustomerContext : DbContext
{
public DbSet<Organisation> Organisations { get; set; }
public DbSet<Person> Persons { get; set; }
protected override void OnModelCreating(ModelBuilder builder)
{
DbDatabase.SetInitializer(new DropCreateDatabaseAlways<CustomerContext>());
builder.Entity<Organisation>()
.HasRequired(p => p.MainContact)
.WithMany()
.HasForeignKey(p => p.MainContactId)
.WillCascadeOnDelete(false);
builder.Entity<Organisation>()
.Property(p => p.MainContactId)
.HasColumnName("MainContact");
builder.Entity<Organisation>()
.HasRequired(p => p.FinancialContact)
.WithMany()
.HasForeignKey(p => p.FinancialContactId)
.WillCascadeOnDelete(false);
builder.Entity<Organisation>()
.Property(p => p.FinancialContactId)
.HasColumnName("FinancialContact");
}
}
public abstract class Customer
{
public int Id { get; set; }
public string Name { get; set; }
}
public class Person : Customer
{
public string Email { get; set; }
}
public class Organisation : Customer
{
public Person FinancialContact { get; set; }
public int FinancialContactId { get; set; }
public Person MainContact { get; set; }
public int MainContactId { get; set; }
}
```
Which now gives the far more suitable database:

| Influencing foreign key column naming in EF code first (CTP5) | CC BY-SA 2.5 | 0 | 2011-02-22T19:36:52.227 | 2011-02-24T08:45:51.223 | 2011-02-24T08:45:51.223 | 2,608 | 2,608 | [
"c#",
"entity-framework",
"code-first"
]
|
5,083,136 | 1 | null | null | 0 | 270 | Here's is a part of my database schema:

So I'm using the tables pages,points and items to generate the layout of my page. To each item is also tied an itemData. All my tables models are created and their relationship defined. I can generate a page by looping through the result of the following query:
```
<cfset variables.page = EntityLoad("Page", {id=arguments.id}, true)>
```
Now the problem comes when I try to do the same thing, but which is an idea in french. I can't think of a way to do this with entityLoad so I tried using HQL:
```
<cfset variables.page = ORMExecuteQuery("
select p
from Page p
left join p.points po
left join po.items it
left join it.itemsData id
where p.id = :pid and id.idIdee = :iid", {pid=arguments.id, iid=session.user.idee}, true)>
```
which seems close to it but that's not it ... I sometimes get more than 1 row etc etc.
Any ORM guru knows how I could handle this?
| ORM querying with transitive dependency | CC BY-SA 2.5 | 0 | 2011-02-22T19:50:20.990 | 2011-02-24T19:57:44.220 | 2011-02-24T19:57:44.220 | 65,124 | 65,124 | [
"hibernate",
"database-design",
"orm",
"coldfusion",
"hql"
]
|
5,083,199 | 1 | 5,083,256 | null | 0 | 110 | I have a class Card that holds a reference to an enum with different Card types. The enum is defined as follows:
```
enum Rank
{
Ace = 1,
Two,
Three,
Four,
Five,
Six,
Seven,
Eight,
Nine,
Ten,
Jack,
King,
Queen
}
```
I have a LINQ Query that is supposed to take a List and check if they are in sequence. So that means the difference between any two ranks is only 1.
Query:
```
List<Card> cards = group.ToList();
cards.Sort(SortComparatorByRank);
List<Card> test = cards.Where((x, idx) =>
(idx >= 1 && (int)cards[idx - 1].CardRank == (int)x.CardRank - 1 ||
(idx < cards.Count() - 1 &&
(int)cards[idx + 1].CardRank == (int)x.CardRank + 1))).ToList();
```
However running this, I get this result:

As you can see, Two and Four supposedly follow each other???
The list given to this query does not contain all cards, thats why I need to check the ranking order, etc...
| LINQ query gone wrong | CC BY-SA 2.5 | 0 | 2011-02-22T19:57:16.353 | 2011-02-22T20:17:34.047 | 2011-02-22T19:59:22.423 | 22,656 | 174,614 | [
"linq",
"sorting",
"c#-4.0"
]
|
5,083,372 | 1 | 5,083,413 | null | 0 | 348 | I'm looking to create a display similar to the following screenshot:

The main point is that each list item can be "expanded" to show sub-items. How can I create this in Android? I'm not even sure how to have multiple types of list item renderers, let alone how to accomplish this, but I do know how to generally set up a ListView, its adapter, and the layout.
| How to create "docked" items in a ListView? | CC BY-SA 2.5 | null | 2011-02-22T20:12:18.280 | 2011-02-22T20:15:40.417 | null | null | 128,967 | [
"android",
"android-layout",
"android-listview"
]
|
5,083,454 | 1 | null | null | 0 | 159 | I use this code and the other td's have the same showDetails code
```
echo '<td width=25 onclick="toggleSlijtd('.$row['id'].')"><img title="'.htmlentities($lang['slijtdeel_minus']).'" src="images/icon/arrow_minus.png"></td>
<td width=25 align="right" onclick="setHighlighted(this),showDetails('.$row['id'].');">'.$row['aantal_huidig'].'</td>';
```
showDetails makes the panel come down with some more information, the toggleSlijtd makes the number decrease by one. They are working but:
1. the new number is shown in the wrong place;
2. the new number is only shown when showDetails is used once;

What is wrong with my code? Or should I use an other code completely. I hope not because time is running out.
My Ajax script:
```
var xmlhttp;
var hold_rowid="";
function toggleSlijtd(str)
{
hold_rowid=str;
xmlhttp=GetXmlHttpObject();
if (xmlhttp==null)
{
alert ("Browser does not support HTTP Request");
return;
}
var url="includes/js/ajax_toggle_slijtdeel.php";
url=url+"?q="+str;
url=url+"&sid="+Math.random();
xmlhttp.onreadystatechange=stateChanged;
xmlhttp.open("GET",url,true);
xmlhttp.send(null);
}
function stateChanged()
{
if (xmlhttp.readyState==4)
{
document.getElementById("row"+hold_rowid).innerHTML=xmlhttp.responseText; //this now identifies which cell to target and change.
}
}
function GetXmlHttpObject()
{
if (window.XMLHttpRequest)
{
// code for IE7+, Firefox, Chrome, Opera, Safari
return new XMLHttpRequest();
}
if (window.ActiveXObject)
{
// code for IE6, IE5
return new ActiveXObject("Microsoft.XMLHTTP");
}
return null;
}
```
php file:
```
mysql_select_db($database, $con);
$id = $_GET["q"];
$sql = "SELECT aantal_huidig FROM slijtdelen WHERE id = '".$id."' ";
$query = mysql_query($sql, $con) or die(mysql_error());
// Verminder hoeveelheid
while($myrow = mysql_fetch_assoc($query))
{
$hoeveelheid = ($myrow['aantal_huidig'] - 1);
}
$sql="UPDATE slijtdelen SET aantal_huidig = '".$hoeveelheid."' WHERE id = '".$id."' ";
$query = mysql_query($sql, $con) or die(mysql_error());
// Stuur wel of geen icoon terug
if($hoeveelheid > 0)
{
echo '<td width=25 onclick="toggleSlijtd('.$row['id'].')"><img title="'.htmlentities($lang['slijtdeel_minus']).'" src="images/icon/arrow_minus.png"></td>
<td width=25 align="right">'.$hoeveelheid.'</td>';
}
else
{
echo '';
}
?>
```
Rendered page:
```
</table><table id="top_header" cellspacing="0" cellpadding="0" width="100%">
<tr class="top_table floating header">
<td width=10 class="top_table_start"></td>
<td width=100>Bestelnr. <a href="/slijtdelen.php?sort_name=slt.bestelnummer&sort=asc" title="Sorteer oplopend"><img src="images/icon/asc.png" ></a> <a href="/slijtdelen.php?sort_name=slt.bestelnummer&sort=desc" title="Sorteer aflopend"><img src="images/icon/desc.png" ></a></td>
<td width=350>Omschrijving <a href="/slijtdelen.php?sort_name=slt.omschrijving&sort=asc" title="Sorteer oplopend"><img src="images/icon/asc.png" ></a> <a href="/slijtdelen.php?sort_name=slt.omschrijving&sort=desc" title="Sorteer aflopend"><img src="images/icon/desc.png" ></a></td>
<td width=100 colspan="3">Voorraad <a href="/slijtdelen.php?sort_name=slt.aantal_huidig&sort=asc" title="Sorteer oplopend"><img src="images/icon/asc.png" ></a> <a href="/slijtdelen.php?sort_name=slt.aantal_huidig&sort=desc" title="Sorteer aflopend"><img src="images/icon/desc.png" ></a></td>
<td width=100 colspan="2">In bestelling <a href="/slijtdelen.php?sort_name=slt.in_bestelling&sort=asc" title="Sorteer oplopend"><img src="images/icon/asc.png" ></a> <a href="/slijtdelen.php?sort_name=slt.in_bestelling&sort=desc" title="Sorteer aflopend"><img src="images/icon/desc.png" ></a></td>
<td width=125 colspan="2">Prijs per stuk <a href="/slijtdelen.php?sort_name=slt.prijs &sort=asc" title="Sorteer oplopend"><img src="images/icon/asc.png" ></a> <a href="/slijtdelen.php?sort_name=slt.prijs &sort=desc" title="Sorteer aflopend"><img src="images/icon/desc.png" ></a></td>
<td width=150>Catagorie <a href="/slijtdelen.php?sort_name=cat.catagorie&sort=asc" title="Sorteer oplopend"><img src="images/icon/asc.png" ></a> <a href="/slijtdelen.php?sort_name=cat.catagorie&sort=desc" title="Sorteer aflopend"><img src="images/icon/desc.png" ></a></td>
<td width=150>Leverancier <a href="/slijtdelen.php?sort_name=adr.klantnaam&sort=asc" title="Sorteer oplopend"><img src="images/icon/asc.png" ></a> <a href="/slijtdelen.php?sort_name=adr.klantnaam&sort=desc" title="Sorteer aflopend"><img src="images/icon/desc.png" ></a></td>
<td width=10 class="top_table_end"></td>
</tr><tr onMouseOver="addHighlight(this);" onMouseOut="removeHighlight(this);">
<td onclick="setHighlighted(this),showDetails(106);"></td>
<td onclick="setHighlighted(this),showDetails(106);">980SUTA12</td>
<td onclick="setHighlighted(this),showDetails(106);">Boor HSSE PV10 980SUTA Ø12</td><td width=25 onclick="toggleSlijtd(106)"><img title="Haal één uit voorraad" src="images/icon/arrow_minus.png" /></td>
<td width=25 align="right" onclick="setHighlighted(this),showDetails(106);">12</td><td width=50 onclick="setHighlighted(this),showDetails(106);"></td><td width=65 onclick="setHighlighted(this),showDetails(106);"></td><td width=35 onclick="setHighlighted(this),showDetails(106);"></td><td width=75 align="right">€ 21.02</td><td width=50 onclick="setHighlighted(this),showDetails(106);"></td>
<td onclick="setHighlighted(this),showDetails(106);"></td>
<td onclick="setHighlighted(this),showDetails(106);">Heku Tools</td>
<td onclick="setHighlighted(this),showDetails(106);"></td>
</tr>
<tr>
<td colspan="13"> <div id="details106"></div> </td>
</tr><tr onMouseOver="addHighlight(this);" onMouseOut="removeHighlight(this);">
<td onclick="setHighlighted(this),showDetails(104);"></td>
<td onclick="setHighlighted(this),showDetails(104);">980SUTA121</td>
<td onclick="setHighlighted(this),showDetails(104);">Boor HSSE PV10 980SUTA Ø12,1</td><td width=25 onclick="toggleSlijtd(104)"><img title="Haal één uit voorraad" src="images/icon/arrow_minus.png" /></td>
<td width=25 align="right" onclick="setHighlighted(this),showDetails(104);">4</td><td width=50 onclick="setHighlighted(this),showDetails(104);"></td><td width=65 onclick="setHighlighted(this),showDetails(104);"></td><td width=35 onclick="setHighlighted(this),showDetails(104);"></td><td width=75 align="right">€ 39.32</td><td width=50 onclick="setHighlighted(this),showDetails(104);"></td>
<td onclick="setHighlighted(this),showDetails(104);"></td>
<td onclick="setHighlighted(this),showDetails(104);">Heku Tools</td>
<td onclick="setHighlighted(this),showDetails(104);"></td>
</tr>
<tr>
<td colspan="13"> <div id="details104"></div> </td>
</tr><tr onMouseOver="addHighlight(this);" onMouseOut="removeHighlight(this);">
<td onclick="setHighlighted(this),showDetails(105);"></td>
<td onclick="setHighlighted(this),showDetails(105);">980SUTA61</td>
<td onclick="setHighlighted(this),showDetails(105);">Boor HSSE PV10 980SUTA Ø6,1</td><td width=25 onclick="toggleSlijtd(105)"><img title="Haal één uit voorraad" src="images/icon/arrow_minus.png" /></td>
<td width=25 align="right" onclick="setHighlighted(this),showDetails(105);">5</td><td width=50 onclick="setHighlighted(this),showDetails(105);"></td><td width=65 onclick="setHighlighted(this),showDetails(105);"></td><td width=35 onclick="setHighlighted(this),showDetails(105);"></td><td width=75 align="right">€ 16.09</td><td width=50 onclick="setHighlighted(this),showDetails(105);"></td>
<td onclick="setHighlighted(this),showDetails(105);"></td>
<td onclick="setHighlighted(this),showDetails(105);">Heku Tools</td>
<td onclick="setHighlighted(this),showDetails(105);"></td>
</tr>
<tr>
<td colspan="13"> <div id="details105"></div> </td>
</tr></table>
```
| 2 Ajax divs conflicting | CC BY-SA 2.5 | null | 2011-02-22T20:19:41.770 | 2011-02-23T19:52:27.070 | 2011-02-23T19:52:27.070 | 586,645 | 586,645 | [
"javascript",
"html",
"ajax"
]
|
5,083,811 | 1 | 5,088,067 | null | 1 | 270 | I have a little problem that's been bothering me for the last few months.
First the good news: with the help of the massive SO community I was able to rewrite my ugly URLs into nice ones, e.g. `website.com/page.ast?ln=nl` into `website.com/nl/page`. For that little `.htaccess` Apache magic I'm eternally thankful to the SO community.
But happily developing along, I came across a nasty truth in Google search results...
Google shows the ugly URLs in their search:
`website.com/nl/selfdesign.ast?ln=fa`

While:
1. My website has nice hyperlinks in its menu system: <a href="selfdesign">designing your own website</a>
2. When on the page, that website loads and Firefox's URL bar shows the nice URL: http://website.com/nl/selfdesign
3. My site page's code reveals the canonical following meta:
So, I think my beautified URLs have been uglified by Google. Thanks very much!
How is it possible for Google to show the ugly URLs after all these months I spent beautifying my links?
### Update 2
So how can I redirect URLs like `website.com/nl/webpage.ext?ln=yy` to `website.com/nl/webpage`, essentially removing the unnecessary part which doesn't do anything?
`.xxx?ln=yy` where `xxx` is is a 2 or 3 letter char (extension) and `yy` is a language (can be `nl`, `be`, `fr` but also `zh-cn`, etc.) .
Again anything past and including the `.extension?ln=whatever` can be completely removed and redirected towards.
| Beautified URLs uglified by Google | CC BY-SA 3.0 | 0 | 2011-02-22T20:50:27.403 | 2013-02-19T06:18:18.497 | 2013-02-19T06:18:18.497 | 319,403 | 509,670 | [
"url",
"url-rewriting",
"seo"
]
|
5,083,851 | 1 | 5,084,398 | null | 0 | 3,459 | Using a fresh install of Qt Creator, I am unable to compile anything including any of the demo projects, or any of my own. I installed Qt Creator on a fresh install of XP on VMWare and it works and compiles fine. My computer is running Windows 7 x64. When attempting to build one of the demo projects, there are several build errors as seen in this screenshot:

Also, here is a paste of my Compile Output:
[http://pastebin.com/xjuJbUEC](http://pastebin.com/xjuJbUEC)
It seems like it is using files within ‘C:\Program Files (x86)\Microsoft Visual Studio\VC98’ when it should not be, although I am not too sure. How would I go about fixing this?
| Can't Compile using Qt Creator on Windows 7 x64 | CC BY-SA 3.0 | null | 2011-02-22T20:54:22.693 | 2011-12-07T23:44:45.930 | 2011-12-07T23:44:45.930 | 84,042 | 629,085 | [
"c++",
"qt",
"windows-7",
"64-bit"
]
|
5,083,963 | 1 | 5,084,110 | null | 0 | 12,229 | I have set the following policy with gpedit in a Windows Server 2008 machine that has IE8:

I have a source that tells me that configuration resides in `HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Internet Explorer\Restrictions\NoExtensionManagement` -- but that's a lie. There isn't even an `Internet Explorer` folder under `Software\Policies\Microsoft`.
Moreover, the same source says the setting is under "Computer Configuration\Network\Internet Explorer\Do Not Allow Users to enable or Disable Add-Ons" on gpedit. As you see above, that isn't true either.
OK, the "source" I'm talking about is the US Government: [http://usgcb.nist.gov/usgcb/download_ie8.html](http://usgcb.nist.gov/usgcb/download_ie8.html) -- namely, their IE8 OVAL definitions.
So, in the registry is that setting?
| Where in the registry can I find the current setting of an IE8 policy? | CC BY-SA 2.5 | null | 2011-02-22T21:06:14.263 | 2013-02-19T05:20:08.617 | null | null | 110,800 | [
"internet-explorer-8",
"registry",
"policy",
"oval"
]
|
5,084,077 | 1 | 5,090,135 | null | 5 | 13,948 | I would like to cluster a matrix with kmeans, and be able to plot it as heatmap. It sounds quite trivial, and I have seen many plots like this. I have tried to google atround, but can't find a way round it.
I'd like to be able to plot something like panel A or B on this figure.
Let say I have a matrix with 250 rows and 5 columns. I don't want to cluster the columns, just the rows.
```
m = matrix(rnorm(25), 250, 5)
km = kmeans(m, 10)
```
Then how do I plot those 10 clusters as a heatmap ? You comments and helps is more than welcome.
Thanks.

| R draw kmeans clustering with heatmap | CC BY-SA 2.5 | 0 | 2011-02-22T21:18:07.070 | 2014-09-19T21:30:52.460 | 2012-07-02T08:31:00.710 | 97,160 | 525,563 | [
"r",
"visualization",
"cluster-analysis",
"k-means",
"heatmap"
]
|
5,084,105 | 1 | null | null | 4 | 3,082 | I am working with a datagridview in c#, when the datagridview contains as many rows to fill the size and show a vertical scrollbar and I scroll down to the last row, there's an whitespace with the height of a row.
Here is a screenshot:

Is there a way to avoid this?
| Whitespace after last row on .NET DataGridView | CC BY-SA 4.0 | 0 | 2011-02-22T21:21:58.300 | 2019-03-14T15:41:35.303 | 2019-03-14T15:41:35.303 | 719,186 | 573,572 | [
"c#",
"winforms",
"datagridview"
]
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.