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
sequence |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
3,296,110 | 1 | 3,296,161 | null | 157 | 105,009 | In the standard windows installer there is a divider between the control buttons on the bottom and the main part of the form. Does anyone know how this would be done in winforms/.net? I've tried fiddling around with the border settings on Panel controls etc, but haven't been able to get the same result...

| Draw horizontal divider in winforms | CC BY-SA 2.5 | 0 | 2010-07-21T03:32:40.223 | 2010-07-21T03:44:35.797 | null | null | 6,062 | [
".net",
"winforms"
] |
3,297,552 | 1 | null | null | 12 | 8,664 | I need to plot, in 3D, a set of densities associated to a time series. More precisely, I would like to be able in R to build an image close to this example

This image is taken from [1]. The transparency plays an important role as let us see the trajectory of the "measures" in the x-y plane.
Any help will be greatly appreciated.
[1]: Juban and Kariniotakis, "Uncertainty Estimation of Wind Power Forecasts", presentation at EWEC 2008 - 01 April - Brussels, Belgium. (I can't post the link, google will help interested readers).
| How to plot a set of densities in 3D using R? | CC BY-SA 2.5 | 0 | 2010-07-21T08:45:51.327 | 2012-05-06T16:48:59.783 | 2017-02-08T14:28:59.343 | -1 | 397,700 | [
"r",
"3d",
"plot"
] |
3,297,550 | 1 | null | null | 1 | 179 | I want to encapsulate every resource from the client application with only one web service which can use my classlib.
I'm confused to access to other resources (web services, databases...) from the class library.
Because i think ClassLib should only have classes to reach objects within hierarchy, calculate some things etc.
If i set database queries or method calls from library i will have to maintain its connection strings etc...
What kind of an architecture should i use?


| I need architecture suggestions for a web service | CC BY-SA 2.5 | 0 | 2010-07-21T08:45:32.697 | 2010-07-22T08:07:27.280 | 2017-02-08T14:28:59.010 | -1 | 104,085 | [
"architecture",
"web-services"
] |
3,297,566 | 1 | 3,305,289 | null | 1 | 457 | I've [previously asked](https://stackoverflow.com/questions/3021936/google-web-optimizer-how-long-until-winning-combination) how long it takes for a winning combination to appear on , but now I have another weird problem during an A/B test:
For the past two days has Google announced that there was a "" that had a chance of beating the original variation by . Great!

I decided to leave it running to make sure, but something weird happened: Today Google is saying that they "haven't collected enough data yet to show any significant results" (as shown below). Sure, the figures have changed , but they're still very high: chance of beating the original by .

So, why is Google not so sure now?
How could it have gone from having a statistically significant "High Confidence" winner, to not having enough data to calculate one? Are my numbers too tiny for Google to be absolutely sure or something?
Thanks for any insights!
| Google Web Optimizer (A/B Testing) Why no clear winner? | CC BY-SA 2.5 | 0 | 2010-07-21T08:47:32.587 | 2010-07-22T02:08:42.360 | 2017-05-23T12:17:03.450 | -1 | 199,700 | [
"web",
"google-website-optimizer",
"ab-testing",
"web-optimization"
] |
3,299,607 | 1 | 3,299,791 | null | 0 | 724 | I'm trying to use LINQ to query the following Entity Data Model

based on this db model

I'd like to be able to pull a list of products based on ProductFacets.FacetTypeId.
Normally, I'd use joins and this wouldn't be a problem but I don't quite understand how to query many-to-many tables under the Entity DataModel.
This is an example sql query:
```
select p.Name, pf.FacetTypeId from Products p
inner join ProductFacets pf on p.ProductId = pf.ProductId
where pf.FacetTypeId in(8, 12)
```
| LINQ queries with many-to-many tables in Entity Data Model | CC BY-SA 2.5 | null | 2010-07-21T13:17:13.487 | 2010-07-21T13:39:29.813 | null | null | 43,603 | [
"linq",
"ado.net-entity-data-model"
] |
3,300,313 | 1 | 3,301,055 | null | 0 | 384 | 
So basically, I have two applications. launches but it remains in memory. When is started it needs to be given a pointer to a object which is stored in the first application. The object represented by the pointer needs to be accessible by applications. I am using . I would really appreciate any .
I need something more cross-platform and are specific. And it is not a matter of me not knowing that CALayer's are Mac specific (). I know that pretty damn well, it is just that I want to be using a cross-platform solution instead of a specific one.
| Passing a pointer to an object onto a child application | CC BY-SA 2.5 | 0 | 2010-07-21T14:28:13.617 | 2010-07-21T16:08:15.400 | 2010-07-21T15:26:15.843 | 160,868 | 160,868 | [
"objective-c",
"pointers",
"object",
"shared-memory"
] |
3,302,975 | 1 | null | null | 6 | 583 | Everyone loves to display Digg/Tweet/Like badges on their websites, and the [Disqus Comment System](https://web.archive.org/web/20160417025156/http://blog.disqus.com:80/post/789540337/partial-deployment-with-feature-switches) is starting to take over.
[](https://i.stack.imgur.com/rp5o1.png)
[disqus.com](http://mediacdn.disqus.com/1045/images/embed/disqus-logo.png)
[](https://i.stack.imgur.com/whGBI.png)
[digg.com](http://about.digg.com/files/dbmedium.png)
   
The benefits of those systems from a developers perspective are:
1. You don't have to program the complex, fully-featured logic that those seemingly simple systems require.
2. You don't have to handle the database scaling or application performance issues that might arise if you built a comment/like/digg look-a-like and it became popular
3. All of the data collected becomes part of a global collection of data.
I'm wondering, do you know of any services out there that accomplish the following (each number in the list is a hypothetical different service):
1. Allow you tag some item on your page. Maybe a javascript api that allows users to click "tag this" and they can add 1-5 tags for your blog post, and the service stores your blog post by an identifier (url, database id, etc.), and the tags. Would work exactly like Disqus but for tags.
2. Allow you to vote or rate an item on your page. Similar to the StackOverflow voting system, a service with a javascript api that created a widget for associating a piece of content by id with votes.
I mean, have these things not been invented already??? Or have they been tried and failed? If the comment problem has been solved, it seems crazy that tagging and voting haven't been solved in the same way.
Is anybody working on this, or is there something out there like this already? Or do you have a workaround for making the current systems out there work like this?
Looking forward to your ideas.
Note: I am very familiar with all of the libraries out there (i'm a ruby guy, so all the acts-as gems, etc.) to implement these things yourself. I am asking this question to try to find a fully featured system that is just as easy to use and scalable as the services listed above, requiring only a javascript file. I have scoured the internet for them with no luck, but then again [new services are popping up every day](https://www.appvita.com/).
| Rating/Voting and Tag APIs, do they exist? | CC BY-SA 4.0 | 0 | 2010-07-21T19:21:51.347 | 2019-08-03T09:06:21.507 | 2019-08-03T09:06:21.507 | 4,751,173 | 169,992 | [
"javascript",
"ruby-on-rails",
"tagging",
"rating",
"voting"
] |
3,303,606 | 1 | 7,171,246 | null | 10 | 4,178 | I have a sprite that animates using a sprite sheet. He is only 16x16, but I want to scale him up to around 64x64 in all its pixel-y goodness!

The results are terrible, of course the browser is anti aliasing it. :/
Thanks!
EDIT:
No css needed, here is my draw function.
```
function drawSprite(offsetx:number,offsety:number,posx:number,posy:number){
ctx.drawImage(img, offsetx*32, offsety*32, 32, 16, posx*32, posy*8, 128, 32);
}
```
See it kinda working [here (codepen)](https://codepen.io/DevEarley/pen/xzOMYq)
| Nearest Neighbor rendering in Canvas | CC BY-SA 4.0 | 0 | 2010-07-21T20:37:19.637 | 2018-06-13T18:04:04.273 | 2018-06-13T18:04:04.273 | 167,932 | 167,932 | [
"javascript",
"html",
"canvas",
"sprite",
"nearest-neighbor"
] |
3,303,961 | 1 | 3,304,045 | null | 8 | 5,660 | I'm writing an application with a layered communications interface.
This was done to abstract the communications from the user-interface part of the application and also to make it more scaleable/maintainable.
For instance:

Consider each box in the figure above as a separate class.
The Generic Comms Interface populates string variables describing the transacted data and comms "health," which are in turn copied up to the Application through a series of public function calls. For example, the Application would make a call to the App-Sub-System:
```
class Application
{
private void SomeUpdateFunction()
{
this.textBox1.AppendText(this.AppSubSystem.GetText());
}
}
class AppSubSystem
{
public string GetText()
{
return this.GenericCommsInterface.GetText();
}
}
class GenericCommsInterface
{
public string GetText()
{
string sRetVal = this.sText; // sText is populated by other functions in the class.
this.sText = null; // Suspected race condition is here.
return sRetVal;
}
}
```
`sText` is populated asynchronously by other functions in the class.
I belive a race condition is happening between `string sRetVal = this.sText;` and the following line `this.sText = null;`.
Can someone suggest a way to avoid or prevent this race condition? Would using `StringBuilder` help, or is there another way that I should be doing this?
| Handling Race Conditions in C# | CC BY-SA 3.0 | 0 | 2010-07-21T21:20:32.703 | 2017-07-18T12:59:02.427 | 2017-07-18T12:59:02.427 | 4,390,133 | 214,296 | [
"c#",
"race-condition"
] |
3,305,613 | 1 | null | null | 7 | 3,764 | I would like to know what can I do to fix a grid of plots. The plots are arranged in an array so that all the plots in a row have the same Y axis variable and all the plots in a column have the same X axis variable.
When joined together in a grid this creates a multiplot. I disable the labels on most of the plots excepting the outer ones, since the inner ones have the same variable and scale. However, since the outer plots have labels and axis values, they result in a different size from the other ones.
I was thinking of adding 2 more columns and rows to the grid, for the variable names and the axis range values... then plotting only the variable names on the corresponding grid space and the axis values on another grid space, therefore only plotting the points in the remaining space and getting equal sizes.
EDIT 1:
Thanks to rcs for pointing me toward `align.plot`
Edited align.plot to accept null values (for when having title/text in the axis isnt desired)
Now I'm closer to the goal but the first columun plots are still smaller width than the rest due to the labels.
example code:
```
grid_test <- function ()
{
dsmall <- diamonds[sample(nrow(diamonds), 100), ]
#-----/align function-----
align.plots <- function(gl, ...){
# Obtained from http://groups.google.com/group/ggplot2/browse_thread/thread/1b859d6b4b441c90
# Adopted from http://ggextra.googlecode.com/svn/trunk/R/align.r
# BUGBUG: Does not align horizontally when one has a title.
# There seems to be a spacer used when a title is present. Include the
# size of the spacer. Not sure how to do this yet.
stats.row <- vector( "list", gl$nrow )
stats.col <- vector( "list", gl$ncol )
lstAll <- list(...)
dots <- lapply(lstAll, function(.g) ggplotGrob(.g[[1]]))
#ytitles <- lapply(dots, function(.g) editGrob(getGrob(.g,"axis.title.y.text",grep=TRUE), vp=NULL))
#ylabels <- lapply(dots, function(.g) editGrob(getGrob(.g,"axis.text.y.text",grep=TRUE), vp=NULL))
#xtitles <- lapply(dots, function(.g) editGrob(getGrob(.g,"axis.title.x.text",grep=TRUE), vp=NULL))
#xlabels <- lapply(dots, function(.g) editGrob(getGrob(.g,"axis.text.x.text",grep=TRUE), vp=NULL))
plottitles <- lapply(dots, function(.g) editGrob(getGrob(.g,"plot.title.text",grep=TRUE), vp=NULL))
xtitles <- lapply(dots, function(.g) if(!is.null(getGrob(.g,"axis.title.x.text",grep=TRUE)))
editGrob(getGrob(.g,"axis.title.x.text",grep=TRUE), vp=NULL) else ggplot2:::.zeroGrob)
xlabels <- lapply(dots, function(.g) if(!is.null(getGrob(.g,"axis.text.x.text",grep=TRUE)))
editGrob(getGrob(.g,"axis.text.x.text",grep=TRUE), vp=NULL) else ggplot2:::.zeroGrob)
ytitles <- lapply(dots, function(.g) if(!is.null(getGrob(.g,"axis.title.y.text",grep=TRUE)))
editGrob(getGrob(.g,"axis.title.y.text",grep=TRUE), vp=NULL) else ggplot2:::.zeroGrob)
ylabels <- lapply(dots, function(.g) if(!is.null(getGrob(.g,"axis.text.y.text",grep=TRUE)))
editGrob(getGrob(.g,"axis.text.y.text",grep=TRUE), vp=NULL) else ggplot2:::.zeroGrob)
legends <- lapply(dots, function(.g) if(!is.null(.g$children$legends))
editGrob(.g$children$legends, vp=NULL) else ggplot2:::.zeroGrob)
widths.left <- mapply(`+`, e1=lapply(ytitles, grobWidth),
e2= lapply(ylabels, grobWidth), SIMPLIFY=FALSE)
widths.right <- lapply(legends, grobWidth)
# heights.top <- lapply(plottitles, grobHeight)
heights.top <- lapply( plottitles, function(x) unit(0,"cm") )
heights.bottom <- mapply(`+`, e1=lapply(xtitles, grobHeight), e2= lapply(xlabels, grobHeight), SIMPLIFY=FALSE)
for ( i in seq_along( lstAll ) ) {
lstCur <- lstAll[[i]]
# Left
valNew <- widths.left[[ i ]]
valOld <- stats.col[[ min(lstCur[[3]]) ]]$widths.left.max
if ( is.null( valOld ) ) valOld <- unit( 0, "cm" )
stats.col[[ min(lstCur[[3]]) ]]$widths.left.max <- max( do.call( unit.c, list(valOld, valNew) ) )
# Right
valNew <- widths.right[[ i ]]
valOld <- stats.col[[ max(lstCur[[3]]) ]]$widths.right.max
if ( is.null( valOld ) ) valOld <- unit( 0, "cm" )
stats.col[[ max(lstCur[[3]]) ]]$widths.right.max <- max( do.call( unit.c, list(valOld, valNew) ) )
# Top
valNew <- heights.top[[ i ]]
valOld <- stats.row[[ min(lstCur[[2]]) ]]$heights.top.max
if ( is.null( valOld ) ) valOld <- unit( 0, "cm" )
stats.row[[ min(lstCur[[2]]) ]]$heights.top.max <- max( do.call( unit.c, list(valOld, valNew) ) )
# Bottom
valNew <- heights.bottom[[ i ]]
valOld <- stats.row[[ max(lstCur[[2]]) ]]$heights.bottom.max
if ( is.null( valOld ) ) valOld <- unit( 0, "cm" )
stats.row[[ max(lstCur[[2]]) ]]$heights.bottom.max <- max( do.call( unit.c, list(valOld, valNew) ) )
}
for(i in seq_along(dots)){
lstCur <- lstAll[[i]]
nWidthLeftMax <- stats.col[[ min( lstCur[[ 3 ]] ) ]]$widths.left.max
nWidthRightMax <- stats.col[[ max( lstCur[[ 3 ]] ) ]]$widths.right.max
nHeightTopMax <- stats.row[[ min( lstCur[[ 2 ]] ) ]]$heights.top.max
nHeightBottomMax <- stats.row[[ max( lstCur[[ 2 ]] ) ]]$heights.bottom.max
pushViewport( viewport( layout.pos.row=lstCur[[2]],
layout.pos.col=lstCur[[3]], just=c("left","top") ) )
pushViewport(viewport(
x=unit(0, "npc") + nWidthLeftMax - widths.left[[i]],
y=unit(0, "npc") + nHeightBottomMax - heights.bottom[[i]],
width=unit(1, "npc") - nWidthLeftMax + widths.left[[i]] -
nWidthRightMax + widths.right[[i]],
height=unit(1, "npc") - nHeightBottomMax + heights.bottom[[i]] -
nHeightTopMax + heights.top[[i]],
just=c("left","bottom")))
grid.draw(dots[[i]])
upViewport(2)
}
}
#-----\align function-----
# edge margins
margin1 = 0.1
margin2 = -0.9
margin3 = 0.5
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = x, y = depth, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.text.x = theme_blank(), axis.ticks = theme_blank(), axis.title.x = theme_blank())
plot1 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin2,"lines"), unit(margin3,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = y, y = depth, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.text.x = theme_blank(), axis.ticks = theme_blank(), axis.title.x = theme_blank(), axis.text.y = theme_blank(), axis.title.y = theme_blank())
plot2 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin2,"lines"), unit(margin2,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = z, y = depth, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.text.x = theme_blank(), axis.ticks = theme_blank(), axis.title.x = theme_blank(), axis.text.y = theme_blank(), axis.title.y = theme_blank())
plot3 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin2,"lines"), unit(margin2,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = x, y = price, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.text.x = theme_blank(), axis.ticks = theme_blank(), axis.title.x = theme_blank())
plot4 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin2,"lines"), unit(margin3,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = y, y = price, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.text.x = theme_blank(), axis.ticks = theme_blank(), axis.title.x = theme_blank(), axis.text.y = theme_blank(), axis.title.y = theme_blank())
plot5 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin2,"lines"), unit(margin2,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = z, y = price, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.text.x = theme_blank(), axis.ticks = theme_blank(), axis.title.x = theme_blank(), axis.text.y = theme_blank(), axis.title.y = theme_blank())
plot6 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin2,"lines"), unit(margin2,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = x, y = carat, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.ticks = theme_blank())
plot7 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin3,"lines"), unit(margin3,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = y, y = carat, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.ticks = theme_blank(), axis.text.y = theme_blank(), axis.title.y = theme_blank())
plot8 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin3,"lines"), unit(margin2,"lines")))
plot <- ggplot(data = dsmall) + geom_point(mapping = aes(x = z, y = carat, colour = cut)) + opts(legend.position="none")
plot <- plot + opts(axis.ticks = theme_blank(), axis.text.y = theme_blank(), axis.title.y = theme_blank())
plot9 <- plot + opts(plot.margin=unit.c(unit(margin1, "lines"), unit(margin1,"lines"), unit(margin3,"lines"), unit(margin2,"lines")))
grid_layout <- grid.layout( nrow=3, ncol=3, widths=c(2,2,2), heights=c(2,2,2) )
grid.newpage()
pushViewport( viewport( layout=grid_layout ) )
align.plots( grid_layout,
list( plot1, 1, 1 ),
list( plot2, 1, 2 ),
list( plot3, 1, 3 ),
list( plot4, 2, 1 ),
list( plot5, 2, 2 ),
list( plot6, 2, 3 ),
list( plot7, 3, 1 ),
list( plot8, 3, 2 ),
list( plot9, 3, 3 ) )
}
```
original image:

current progress image:

| using grid and ggplot2 to create join plots using R | CC BY-SA 3.0 | 0 | 2010-07-22T03:35:14.653 | 2012-10-09T04:49:05.047 | 2012-10-09T04:15:12.480 | 210,945 | 398,680 | [
"r",
"ggplot2"
] |
3,306,801 | 1 | null | null | 0 | 272 | here is the requirement:
i have a lable a textbox, and two buttons(+ and - button) on my asp.net page.

so when i click on the plus button it should add the the whole collection of controls to the page(i.e. lable, textbox and two buttons). And when i click on minus button it should remove the collection.

This should go on.meaning whenever i click on any plus button the control collection should get added to the page.
I am wondering what will be the best approach to do it.
Any suggestion?
| ASP.NET:Adding a collection of controls dynamically | CC BY-SA 2.5 | null | 2010-07-22T07:56:02.607 | 2010-07-22T08:48:54.213 | 2010-07-22T08:16:57.650 | 396,506 | 396,506 | [
"c#",
"asp.net",
"ajax"
] |
3,306,920 | 1 | 3,306,983 | null | 6 | 1,627 | I have a form which includes a JQUERY datepicker attatched to an `<input>` on the form. My problem at the moment is that since the input is a text-box, most major browsers attempt to auto-complete entries for the user, which looks very silly over the datepicker:

Browsing the internet, I discovered that way back in the days of IE-5, Microsoft had an attribute for input tags called "autocomplete", which could disable it. However, that was way back then, and that was IE. Checking on W3Schools revealed that HTML5 includes an "autocomplete" attribute for input tags (yes, I was equally surprised that Microsoft was supporting HTML-5 way back in 1999...). However, our website is not on HTML5 yet, so I cannot rely on using the tag and assuming it will work. Taking these into consideration, how then does one disable auto-complete for a single input box in HTML4? Expected browsers are Chrome (latest), Firefox 3.6, Firefox 2.0 and - god help us - perhaps IE6 (although we have warned everyone that we aren't promising anything will actually work if they use IE6! ;) )
(By the way, for anybody worrying out there, I know that this is attempting to change a user's personal browser settings, which is a naughty thing to do normally. However, in this case I believe it's justified, especially considering 90% of my users won't know what auto-complete is or that it even can be turned off...)
| What is the correct way to stop form input boxes auto-completing? | CC BY-SA 2.5 | 0 | 2010-07-22T08:12:44.533 | 2010-07-22T08:22:18.910 | 2010-07-22T08:21:35.480 | 352,636 | 352,636 | [
"html",
"forms",
"autocomplete",
"input"
] |
3,307,621 | 1 | 3,307,685 | null | 4 | 18,957 | I am working on an application specifically for Samsung Galaxy S(I am not the one making decision here) and they want its layout to be pixel-precise accurate.
Can I just use normal 2.1 AVD?
So I tried creating WQVGA432 but it looks like this. I'm not sure why the LinearLayout does not fill up the screen but only use up to the large images with Korean (which I can't scale down, but that's different question).

This is main.xml:
>
```
<RelativeLayout
android:id="@+id/ui_navBar"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="#FF333333"
<!-- This is navigation panel at the top of the page -->
<!-- Top-Left Button, aka Back button -->
<FrameLayout android:id="@+id/ui_topLeftBox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true">
</FrameLayout>
```
```
<!-- Screen name -->
<FrameLayout android:id="@+id/ui_topBox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true">
</FrameLayout>
<!-- Top-Right Button, aka Forward button -->
<FrameLayout android:id="@+id/ui_topRightBox"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true">
</FrameLayout>
</RelativeLayout>
<FrameLayout
android:id="@+id/ui_contentView"
android:layout_width="fill_parent"
android:layout_height="0dip"
android:paddingTop="0px"
android:layout_weight="1">
<!-- Main View -->
<RelativeLayout
android:id="@+id/mainView"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<RelativeLayout
android:id="@+id/topBanner"
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:background="#FFFFCC00"
>
<TextView android:textSize="20sp"
android:textColor="#FF000000"
android:text="EUR/USD"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true"
/>
</RelativeLayout>
<RelativeLayout
android:id="@+id/view1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/topBanner"
android:background="#FF444444">
<CheckBox android:id="@+id/cbx1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_alignParentLeft="true"
/>
<com.vg.library.NumericInput
android:id="@+id/val1Nip"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_toRightOf="@+id/cbx1"
/>
</RelativeLayout>
<com.vg.library.NumericInput
android:id="@+id/val2Nip"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/view1" />
<TextView android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Screen01"
android:layout_below="@+id/val2Nip"
android:layout_alignParentLeft="true" />
</RelativeLayout>
</FrameLayout>
<!-- ExpandBar -->
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
>
<ImageView
android:id="@+id/ui_expandBar"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:src="@drawable/bar"
android:background="#0000"
/>
<FrameLayout
android:id="@+id/ui_drawerView"
android:visibility="gone"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingTop="0px"
android:layout_weight="1"
android:layout_below="@+id/ui_expandBar">
<RelativeLayout
android:id="@+id/ui_drawerContent"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="#FF550000" >
<RelativeLayout
android:id="@+id/m1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="#FF550000" >
<CheckBox android:id="@+id/cbxB"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_alignParentLeft="true"
/>
<com.vg.library.NumericInput
android:id="@+id/valBNip"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_toRightOf="@+id/cbxB"
/>
</RelativeLayout>
</RelativeLayout>
</FrameLayout>
</RelativeLayout>
<RelativeLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="#FF333333"
android:layout_weight="0"
android:layout_gravity="bottom"
>
<!-- This is menu panel at the bottom of the page -->
<com.vg.library.MenuBar
android:id="@+id/ui_menuBar"
android:orientation="horizontal"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:background="#FFAAAA00"
>
<!-- All menu item should go here -->
</com.vg.library.MenuBar>
</RelativeLayout>
```
| How to create AVD that represent Samsung Galaxy S in Eclipse emulator? | CC BY-SA 2.5 | 0 | 2010-07-22T09:57:02.660 | 2012-12-04T16:55:05.553 | 2017-02-08T14:29:03.060 | -1 | 271,736 | [
"android"
] |
3,308,615 | 1 | 3,308,630 | null | 6 | 7,300 | Say I have the following HTML:
```
<head>
<style>
#container {
border: 1px red solid;
}
.floaty {
width: 200px;
float: left;
border: 1px green solid;
}
</style>
</head>
<body>
<div id='container'>
Text inside the container
<div class='floaty'>
Floaty block 1<br/>
Floaty block 1<br/>
Floaty block 1<br/>
</div>
<div class='floaty'>
Floaty block 2<br/>
Floaty block 2<br/>
Floaty block 2<br/>
</div>
<div class='floaty'>
Floaty block 3<br/>
Floaty block 3<br/>
Floaty block 3<br/>
</div>
</div>
</body>
```
This renders as: 
What's the proper CSS way to have the container (red-bordered box) completely surround the floaty green-bordered boxes?
| Proper way to contain floating elements using HTML/CSS? | CC BY-SA 3.0 | 0 | 2010-07-22T12:06:37.903 | 2021-05-09T21:45:25.577 | 2014-02-17T14:31:35.327 | 18,494 | 18,494 | [
"html",
"css"
] |
3,309,685 | 1 | 3,309,901 | null | 43 | 9,451 | I am having some trouble understanding the MVC Pattern. I do understand we are trying to decouple the GUI from the business logic, although I'm having problems understanding how.
From what I understood, the `View`, is what the user sees. So it generally is the window/form. The `Controller` is inbetween the `View` and the `Model`. The Controller will make the data "flow" in both directions. It will also persist state when needed (if I have a wizard with 5 steps, it is the `Controller`'s responsability to ensure they are made in the correct order, etc). The `Model,` is where the core of my application logic lives.
Is this view correct?
To try to turn this into something more meaningful, I'll try to sketch out a simple example with WinForms(no ASP.NET or WPF, please! - to the java crowd, from what I come to understand, Swing works in a similar way to WinForms!), to see if I get it right, and I'll raise the questions I always come to while doing it.
---
Let's assume I have a model that contains just a class (just to make it easier. I know it will make the example look dumb but its easier this way):
```
class MyNumbers {
private IList<int> listOfNumbers = new List<int> { 1, 3, 5, 7, 9 };
public IList<int> GetNumbers() {
return new ReadOnlyCollection<int>(listOfNumbers);
}
}
```
Now it's time to make my `Controller`:
```
class Controller
{
private MyNumbers myNumbers = new MyNumbers();
public IList<int> GetNumbers() {
return myNumbers.GetNumbers();
}
}
```
The `View` should just have a `ListBox` that has as items all the numbers retrieved in `MyNumbers`.
## Now, the first question arises:
Should the `Controller` be responsible for creating `MyNumbers`? In this simple case, I think its acceptable(as `MyNumbers` will do exactly the same, no matter what, and has no associated state). But let's assume I would want to use for all the different Controllers my app has the same instance of `MyNumbers`. I would have to pass to this `Controller`(and all others that need it) that instance of `MyNumbers` that I want to use. Who is going to be responsible for that? In this WinForms examples, would that be the `View`? Or would that be the class that creates the `View`?
Turning the question around: what is the order of instantiation of these 3 parts? What is the code that the "owner" of the `MVC` called to create it?
Should the `Controller` create both the `View` and `Model`? Should the `View` instantiate the `Controller` and the `Controller` the `Model`?
## Second question:
How is the `main` method supposed to look like, assuming I only want my application to have the `Use Case` this `Controller` portrays?
## Third:
Why does in the following MVC diagram, the `View` have an arrow to the `Model`? Shouldn't the `Controller` be always the bridge between both `View` and `Model`?

---
I'll have one or two more questions, but they probably will make more sense asked after I understand this first detail. Or maybe after I understand that first question all the others tear apart.
Thanks!
| Understanding the MVC Pattern | CC BY-SA 2.5 | 0 | 2010-07-22T14:04:42.673 | 2019-08-03T13:09:03.340 | 2017-02-08T14:24:17.460 | -1 | 130,758 | [
"c#",
"java",
".net",
"winforms",
"model-view-controller"
] |
3,310,803 | 1 | 5,410,546 | null | 4 | 13,532 | Using [jQuery UI](http://en.wikipedia.org/wiki/JQuery_UI), I have a tabs plugin and within tab 1 gets loaded a page that contains a table and in each row is a link to a dialog.
Everything works correctly, save the following:
In the dialog is an option to delete the row from which the current dialog was opened from. After confirming, and deleting the row, the tab is refreshed and the new table is shown with the relevant row deleted.
Now, the problem is that after closing the dialog where I did the deletion (either though the JavaScript function that did the deleting, or manually via the close button on the dialog), the dialog retains the data from the deleted row.
For example,
There are three rows listed;
Open dialog from row 2;
Delete;
Dialog closed from the JavaScript function, tab refreshes, now two rows;
The dialog open link in the second row (which used to be row 3) has the same dialog id as the one just opened;
Click open dialog link in row 2;
Dialog displays same as before - for old row 2, instead of current row 2;
Close dialog;
Click open dialog link in row 2;
Displays correctly - data from current row 2;
I don't know if that made any sense... Here's a picture of what happens:

So, the row below the row that gets deleted inherits the dialog id, and when clicked shows the old dialog. If closed, then re-opened, it shows the proper content in the dialog.
I'm using `dialog("close")` currently and have tried `dialog("destroy")`, but that totally kills it, and the row below doesn't open anything...
How can I fix this problem?
---
Dialog instantiation code:
```
<script>
<?php
$ee=1;
foreach($bugs->result() as $rr){
echo "jQuery(\"#dialog_$ee\").dialog({autoOpen:false,width:850,height:550});\n";
$ee++;
}
?>
</script>
```
Then open the dialog:
```
jQuery("#dialog_<?=$i?>").dialog("open");
```
| jQuery UI dialog close doesn't clear dialog | CC BY-SA 4.0 | 0 | 2010-07-22T15:56:02.200 | 2019-11-15T15:23:39.683 | 2019-11-15T15:23:39.683 | 183,254 | 183,254 | [
"jquery",
"jquery-ui",
"jquery-ui-dialog"
] |
3,312,321 | 1 | 5,152,579 | null | 6 | 8,277 | I see the option for specifying three files (left, right, and ancestor), but it doesn't seem to be possible to actually the ancestor.

The bottom pane shows the result of the merge. I'd rather see what the original content was, so I could understand the context for the left and right sides of the conflict. Is this possible? FileMerge has awful help documentation.
| How do you do a 3-way merge in FileMerge? | CC BY-SA 3.0 | 0 | 2010-07-22T18:53:54.423 | 2014-03-02T01:38:51.257 | 2013-07-18T03:37:20.230 | null | 122,763 | [
"macos",
"filemerge"
] |
3,313,136 | 1 | 4,302,571 | null | 6 | 209 | I have two images of yeast plates:
Permissive:

Xgal:

The to images should be in the same spot and roughly the same size. I am trying to use one of the images to generate a grid and then apply that grid to the other image. The grid is made by looking at the colonies on permissive plate, the plate should have 1536 colonies on it. The problem is that the camera that was used to take the images moves a bit up and down and the images can also be shifted slightly due to the other plate not being in exactly the same place.
This then means that when I use the permissive plate to generate the grid on the `xgal` plate the grid shifts. Does anyone know a way in which I can compensate for this? I am using perl with the gd module. Any advice would be greatly appreciated. Thank you
| I need help compensating for the shifting of images when trying to create a grid with one image and apply it on another | CC BY-SA 3.0 | null | 2010-07-22T20:29:17.223 | 2015-12-27T08:17:47.863 | 2015-12-27T08:17:27.903 | 5,576,310 | 241,314 | [
"perl",
"image-processing",
"gd"
] |
3,317,084 | 1 | 3,354,247 | null | 3 | 4,160 | I'm having an issue querying Solr using the following field type:
```
<fieldType name="text_ci" class="solr.TextField" positionIncrementGap="100">
<analyzer>
<tokenizer class="solr.WhitespaceTokenizerFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true"/>
<filter class="solr.SnowballPorterFilterFactory" language="English" protected="protwords.txt"/>
</analyzer>
</fieldType>
```
As you can see it applies the "SnowballPorterFilterFactory" when indexing and querying. If I Index something like
> Mouse stuff and fun
It get's indexed as:

As you can see the word "Mouse" is turned into "Mous" by the "SnowballPorterFilterFactory". Which is what we want. However when we search for
> Mouse*
It doesn't seem to apply the "SnowballPorterFilterFactory" in the same way. I guess due to the * at the end.

My question is.. Is there a way to make the "SnowballPorterFilterFactory" know about wildcards? So that when i Query for
> Mouse*
I don't get 0 results.
Interestingly if i query for
> mous*
The record does come back.
Or can someone offer a better way to query/index this type of field?
Thanks Dave
| Solr's SnowballPorterFilterFactory and Wildcard parameters | CC BY-SA 2.5 | 0 | 2010-07-23T09:51:19.253 | 2010-07-28T15:07:33.883 | 2017-02-08T14:29:04.587 | -1 | 30,317 | [
"indexing",
"solr",
"wildcard",
"filterfactory"
] |
3,317,303 | 1 | 3,317,322 | null | 1 | 398 | 
How can I create this efect with text-shadow?
| How can I create this photoshop effect with text-shadow | CC BY-SA 3.0 | null | 2010-07-23T10:27:06.063 | 2012-09-20T09:38:21.613 | 2017-02-08T14:29:04.950 | -1 | 58,839 | [
"html",
"css",
"photoshop"
] |
3,319,557 | 1 | 3,319,831 | null | 0 | 363 | Hei guys, I have the following problem:
- 
As I can see those arrows are not aligned with the text, I've tried alot of things but I didn't find a solution, mabe you can help me, here is my code:
```
.domains-wrapper .sidebar{
width: 203px;
}
/* For the background */
.domains-wrapper .links .the-top{
background: url(/images/top-sidebar-domains.png) no-repeat;
width: 202px;
height: 7px;
}
/* For the background */
.domains-wrapper .links .repeat{
background: url(/images/repeat-sidebar-domains.png) repeat-y;
width: 202px;
}
/*---HERE STARTS THE CODE FOR THE LIST ITEMS---*/
.domains-wrapper .links .repeat ul{
padding-top: 14px;
padding-bottom: 14px;
padding-left:8px;
padding-right: 8px;
}
.domains-wrapper .links .repeat ul li{
font-size: 12px;
font-weight: bold;
padding-left: 5px;
height: 47px;
border-bottom: 1px solid #f1f1f1;
}
.domains-wrapper .links .repeat ul li.hover{
background-color: #71ab32;
}
.domains-wrapper .links .repeat ul li.active a{
background: url(/images/sidebar-domains-arrows.png) no-repeat 0px 0px;
}
.domains-wrapper .links .repeat ul li a{
display: inline-block;
background: url(/images/sidebar-domains-arrows.png) no-repeat 0px -96px;
padding-left: 29px;
color: #000;
height: 25px;
line-height: 47px;
}
.domains-wrapper .links .repeat ul li.hover a{
background: url(/images/sidebar-domains-arrows.png) no-repeat 0px -46px;
color: #fff;
}
/*---HERE ENDS THE CODE FOR THE LIST ITEMS---*/
/* For the background */
.domains-wrapper .links .bottom{
background: url(/images/bottom-sidebar-domains.png) no-repeat;
width: 202px;
height: 7px;
}
```
```
<div class="links">
<div class="the-top"></div>
<div class="repeat">
<ul>
<li class="active"><a href="#">Link 1</a></li>
<li><a href="#">Link 1</a></li>
<li><a href="#">Link 1</a></li>
<li><a href="#">Link 1</a></li>
</ul>
</div>
<div class="bottom"></div>
</div><!-- end /.links -->
```
What I'm doing
| Css list align problems | CC BY-SA 2.5 | null | 2010-07-23T15:18:17.753 | 2010-07-23T15:44:52.763 | 2017-02-08T14:29:05.960 | -1 | 58,839 | [
"html",
"xhtml",
"css"
] |
3,321,367 | 1 | 3,321,698 | null | 2 | 1,041 | ```
(define pick
(lambda (num lat)
(cond ((null? lat) (quote()))
((= (sub1 num) 0) (car lat))
(else
(pick (sub1 num) (cdr lat))))))
(define brees (quote (a b c d e touchdown g h i)))
(pick 6 brees)
```
The language in DrRacket is set to Advanced Student. It also works fine in the IronScheme console after defining `sub1`.
The error message is:
```
reference to undefined identifier: R
```


| Why does this work in DrRacket but not in Racket from the console | CC BY-SA 2.5 | 0 | 2010-07-23T18:47:39.317 | 2010-08-19T02:05:06.133 | 2010-08-19T02:05:06.133 | 102,022 | 102,022 | [
"recursion",
"lisp",
"scheme",
"racket",
"the-little-schemer"
] |
3,321,772 | 1 | 3,321,806 | null | 13 | 1,511 | I'm trying to add Intellisense to C# code editor based on the richtextbox control. So far, I've got it parsing the entered text to find all variables and their types (works well). The drop down box works well. What I can't get is a proper list of options for the drop-down list box.
How can I get the following list, programmatically:

I have already compiled a list of variables and their types, so when the user presses `.` I know that I have a variable `c` of type `Color`. I just need to know what function to call to get the list I need for the drop-down box.
I've tried this code: [http://www.codeproject.com/KB/cs/diy-intellisense.aspx](http://www.codeproject.com/KB/cs/diy-intellisense.aspx) but couldn't get it to work properly. I've also read a ton of other threads on StackOverflow to no avail. I'd really like to finish this instead of using someone elses drop-in editor component.
Any hints would be appreciated. Thanks.
| Implementing Visual Studio Intellisense | CC BY-SA 3.0 | 0 | 2010-07-23T19:38:31.740 | 2017-08-13T09:09:04.757 | 2017-08-13T09:09:04.757 | 4,220,785 | 20,848 | [
"c#",
"intellisense"
] |
3,322,705 | 1 | 3,322,742 | null | 2 | 3,512 | I'm currently trying to create a ray tracer in C++ but I'm having difficulty writing the .bmp produced at the end. I'm determined to do it manually, so I can learn more about image files and writing them etc. But I'm having some difficulty. I'm fairly new to C++ but have been using Python for a while.
I'm almost there now, I just have one strange problem. Everything is correct up to mid way trough the important colours (which I set to 0), where all sorts of random characters spring up and this continues for the next few bytes, a couple of bytes in to the pixel data. Before and after that everything is fine, but I just can't explain it. My current code is in the edit:
Here is the hex:

the problem area is highlighted
```
#include <iostream>
#include <fstream>
#include <math.h>
using namespace std;
//-------------------------Object list
const int renderSize[2] = {254,254};
float sphere1Pos[3] = {0.0,0.0,0.0}; //first sphere at origin to make calculations easier
float sphere1Radius = 10.0;
float sphere1Colour= (255.0,0.0,0.0);
float light1Pos = (0.0,20.0,0.0); //Above sphere
float light1Intensity = 0.5;
// ------------------------
float dot(float* a,float* b); //Calculates the dot product
struct pixel {
unsigned char R;
unsigned char G;
unsigned char B;
};
//bmp--------------
struct bitmapMagicNumber {
unsigned char magicNumber[2];
};
struct bitmapFileHeader {
unsigned char fileSize;
short reserved1;
long reserved2;
short offset;
};
struct bitmapInformationHeader {
short headerSize;
short padding;
short width;
short height;
short planes;
short bitDepth;
short compression;
short imageSize;
short xPixelsPerMetre;
short yPixelsPerMetre;
short colours;
short importantColours;
};
void setBitmapMagicNumber(bitmapMagicNumber& magicNum){
magicNum.magicNumber[0] = 0x42;
magicNum.magicNumber[1] = 0x4D;
};
void setBitmapFileHeader(bitmapFileHeader& fileHeader,bitmapInformationHeader& informationHeader,pixel pixelArray) {
fileHeader.fileSize = 54 + sizeof(pixelArray);
fileHeader.reserved1 = 0;
fileHeader.reserved2 = 0;
fileHeader.offset = 54;
};
void setBitmapInformationHeader(bitmapInformationHeader& informationHeader){
informationHeader.headerSize = 40;
informationHeader.padding=0;
informationHeader.width = renderSize[0];
informationHeader.height = renderSize[1];
informationHeader.planes = 1;
informationHeader.bitDepth = 24;
informationHeader.compression = 0;
informationHeader.imageSize = 0;
informationHeader.xPixelsPerMetre = 0;
informationHeader.yPixelsPerMetre = 0 ;
informationHeader.colours = 0;
informationHeader.importantColours = 0;
};
void writeBitmap(bitmapMagicNumber& magicNum, bitmapFileHeader& fileHeader,bitmapInformationHeader& informationHeader,pixel pixelArray){
ofstream out("test.bmp",ios::out|ios::binary);
//file header
out.write((char*) &magicNum,2);
out.write((char*) &fileHeader.fileSize,sizeof(fileHeader.fileSize));
if (sizeof(fileHeader.fileSize)<3){
out.write((char*) &informationHeader.padding,1);
}
out.write((char*) &informationHeader.padding,1);
out.write((char*) &fileHeader.reserved1,2);
out.write((char*) &fileHeader.reserved2,2);
out.write((char*) &fileHeader.offset,sizeof(fileHeader.offset));
out.write((char*) &informationHeader.padding,1);
out.write((char*) &informationHeader.padding,1);
//information header
out.write((char*) &informationHeader.headerSize,sizeof(informationHeader.headerSize));
out.write((char*) &informationHeader.padding,1);
out.write((char*) &informationHeader.padding,1);
out.write((char*) &informationHeader.width,sizeof(informationHeader.width));
if (sizeof(informationHeader.width)<4){
out.write((char*) &informationHeader.padding,1);
}
if (sizeof(informationHeader.width)<3){
out.write((char*) &informationHeader.padding,1);
}
if (sizeof(informationHeader.width)<2){
out.write((char*) &informationHeader.padding,1);
}
out.write((char*) &informationHeader.height,sizeof(informationHeader.height));
if (sizeof(informationHeader.height)<4){
out.write((char*) &informationHeader.padding,1);
}
if (sizeof(informationHeader.height)<3){
out.write((char*) &informationHeader.padding,1);
}
if (sizeof(informationHeader.height)<2){
out.write((char*) &informationHeader.padding,1);
}
out.write((char*) &informationHeader.planes,sizeof(informationHeader.planes));
out.write((char*) &informationHeader.bitDepth,sizeof(informationHeader.bitDepth));
out.write((char*) &informationHeader.compression,4);
out.write((char*) &informationHeader.imageSize,4);
out.write((char*) &informationHeader.xPixelsPerMetre,4);
out.write((char*) &informationHeader.yPixelsPerMetre,4);
out.write((char*) &informationHeader.colours,4);
out.write((char*) &informationHeader.importantColours,4);
//pixel data
for (int y=0; y < renderSize[1]; y++) {
for (int x=0; x< renderSize[0]; x++) {
out.write((char*) &pixelArray[x][y],sizeof(pixel));
}
}
out.close();
}
// end bmp-----------
int main() {
pixel pixelArray[renderSize[0]][renderSize[1]];
for (int y=0; y < renderSize[1]; y++) {
for (int x=0; x< renderSize[0]; x++) {
float rayPos[3] = {x,y, -1000.0};
float rayDir[3] = {0.0,0.0,-1.0};
bool intersect;
//for each object in scene, see if intersects. (for now there is only one object to make things easier)
//-------sphere ray intersection....
float distance[3];
distance[0]= rayPos[0]-sphere1Pos[0];
distance[1]= rayPos[1]-sphere1Pos[1];
distance[2]= rayPos[2]-sphere1Pos[2];
float a = dot(rayDir, rayDir);
float b = 2 * dot(rayDir, distance);
float c = dot(distance, distance) - (sphere1Radius * sphere1Radius);
float disc = b * b - 4 * a * c;
if (disc < 0)
intersect=false;
else
intersect=true;
//--------------------
if (intersect==true){
pixelArray[x][y].R = 0;
pixelArray[x][y].G = 0;
pixelArray[x][y].B = 0;
}
else {
pixelArray[x][y].R = 0;
pixelArray[x][y].G = 0;
pixelArray[x][y].B = 0;
}
// trace to lights (as long as another object is not in the way)
}
}
//write .bmp
bitmapMagicNumber magicNum;
bitmapFileHeader fileHeader;
bitmapInformationHeader informationHeader;
setBitmapMagicNumber(magicNum);
setBitmapFileHeader(fileHeader,informationHeader, pixelArray[renderSize[0]][renderSize[1]]);
setBitmapInformationHeader(informationHeader);
writeBitmap(magicNum,fileHeader,informationHeader, pixelArray[renderSize[0]][renderSize[1]]);
}
//calculate dot product
float dot(float* a,float* b)
{
float dp = 0.0;
for (int i=0;i<3;i++)
dp += a[i] * b[i];
return dp;
}
```
| Difficulty writing a Bmp file in C++ manually (using Xcode) | CC BY-SA 3.0 | null | 2010-07-23T22:00:19.870 | 2011-11-26T08:54:13.973 | 2011-11-26T08:54:13.973 | 234,976 | 400,714 | [
"c++",
"image",
"bmp"
] |
3,323,028 | 1 | 3,323,062 | null | 0 | 106 | i have a dataset that looks like this:
```
Bin Frequency
6.0 0
5.9 0
5.8 0
5.7 0
5.6 0
5.5 0
5.4 0
5.3 0
5.2 0
5.1 0
5.0 0
4.9 0
4.8 0
4.7 0
4.6 0
4.5 0
4.4 0
4.3 0
4.2 0
4.1 0
4.0 0
3.9 0
3.8 0
3.7 0
3.6 0
3.5 0
3.4 2
3.3 4
3.2 2
3.1 2
3.0 4
2.9 5
2.8 5
2.7 1
2.6 0
2.5 1
2.4 1
2.3 2
2.2 3
2.1 1
2.0 0
1.9 1
1.8 0
1.7 1
1.6 1
1.5 1
1.4 0
1.3 0
1.2 0
1.1 0
1.0 0
0.9 0
0.8 0
0.7 0
0.6 0
0.5 0
0.4 0
0.3 0
0.2 0
0.1 0
0.0 0
```
and i want to make a google graph that would look like this:
[alt text http://img641.imageshack.us/img641/3761/45343878.png](http://img641.imageshack.us/img641/3761/45343878.png)
thank you for your help!
here's the problem. it is giving me two different plots:

| help formatting a google graph URL | CC BY-SA 2.5 | null | 2010-07-23T23:12:08.030 | 2010-07-23T23:22:43.473 | 2017-02-08T14:29:07.683 | -1 | 117,700 | [
"url",
"image",
"graph"
] |
3,323,541 | 1 | 3,323,754 | null | 10 | 7,194 | I ordered Programming Windows Fifth Edition a few days ago, and started working with it.
I'm starting to learn the win32 api, however, I got a question. The windows do not look modern winxp/win vista/win 7 style at all. How do I fix this?
It currently looks like this, crap font and all.

Thanks in advance!
Machiel
| How can I make the Win32 API window more modern looking? | CC BY-SA 3.0 | 0 | 2010-07-24T02:16:01.220 | 2014-12-03T05:34:40.117 | 2013-12-29T00:34:35.657 | 996,468 | 293,581 | [
"c++",
"c",
"windows",
"winapi",
"interface"
] |
3,325,625 | 1 | 3,325,724 | null | 14 | 5,710 | I want enchanted syntax coloring in comments for C++ language in Visual Studio 2010. For example, I have the following code:
```
/*!
\sa testMeToo()
\param a the first argument.
\param s the second argument.
*/
int testMe(int a,const char *s);
```
In Visual Studio all , and other Doxygen commands are not highlighted. Is it possible to add custom highlighting to Visual Studio?
As for me ideal syntax highlighting for such C++ comments is in Anjuta (GNU/Linux C++ IDE).
Thanks.
I wrote addon for Visual Studio 2010/2012 that highlights Doxygen commands:
[http://visualstudiogallery.msdn.microsoft.com/11a30c1c-593b-4399-a702-f23a56dd8548](http://visualstudiogallery.msdn.microsoft.com/11a30c1c-593b-4399-a702-f23a56dd8548)
This is how it looks like:

| Visual Studio: Syntax highlighting for Doxygen-style C++ comments | CC BY-SA 3.0 | 0 | 2010-07-24T15:20:52.603 | 2023-01-12T20:07:35.243 | 2013-03-15T17:07:00.090 | 401,101 | 401,101 | [
"c++",
"visual-studio",
"syntax-highlighting",
"doxygen"
] |
3,327,139 | 1 | 3,327,245 | null | 0 | 1,708 | I want to show the Android version of a [Model Dialog](http://bit.ly/dc3pXu) with text input however I think the keyboard will be behind the actual activity since dialogs weren't made to have inputs. Is there any way I can get the keyboard to show in an actual dialog.
I did see [this](http://bit.ly/aqgpOL) SO question -- however I'd rather not use an Theme.Dialog'ed activity because I feel like an activity would be too heavy for my purposes. How can I show this Model Dialog with the keyboard input in the foreground?
This is what I am talking about:

| Showing Keyboard with Android Dialog | CC BY-SA 2.5 | 0 | 2010-07-24T22:20:50.617 | 2010-07-25T00:16:06.097 | 2017-02-08T14:29:08.387 | -1 | 354,247 | [
"android",
"user-interface",
"user-input"
] |
3,327,866 | 1 | 3,328,061 | null | 0 | 269 | I have to draw a line between two points using quartz.
At some point I have this code:
```
CGContextBeginPath(ctx);
CGContextMoveToPoint(ctx, lastPoint.x, lastPoint.y);
CGContextAddLineToPoint(ctx, currentPoint.x, currentPoint.y);
CGContextStrokePath(ctx);
```
This lines will create a hard line between the points currentPoint and lastPoint. The line is so hard, like done by stamping a square of pixels from one point to the other.
Can a bitmap be used (for example a little white blurred ball) to substitute this hard brush tip and create a softness on the line? I mean, create a soft line with blurred edges?
Obviously the little white blurred ball should be stamped along the path to accomplish this. Is that possible? How?
See the next picture. The left line is what the code does currently. The right line is what I would like to do.

thanks
| iphone - can a bitmap be stamped in a path in quartz? | CC BY-SA 2.5 | 0 | 2010-07-25T03:23:05.527 | 2010-07-25T04:51:00.973 | null | null | 316,469 | [
"iphone",
"ipad",
"ios4"
] |
3,329,597 | 1 | null | null | 0 | 1,274 | How can I create a page like this?

When I click a link in the left side menu a page must be loaded in the content area, but the whole page must not load.
How to do this using jquery is there any plugin to do that?
| Creating a Vertical menu using jquery | CC BY-SA 3.0 | null | 2010-07-25T14:45:02.740 | 2011-12-02T08:45:39.757 | 2011-12-02T08:45:39.757 | 146,792 | 390,836 | [
"jquery",
"jquery-ui",
"menu"
] |
3,331,176 | 1 | 3,331,372 | null | 90 | 146,834 | The question is very simple. How to get number of video views with YouTube API?

The task is simple but I would like to use that query on large number of videos very often. Is there any way to call their Youtube API and get it? (something like facebook [http://api.facebook.com/restserver.php?method=links.getStats&urls=developers.facebook.com](http://api.facebook.com/restserver.php?method=links.getStats&urls=developers.facebook.com))
| How to get number of video views with YouTube API? | CC BY-SA 3.0 | 0 | 2010-07-25T21:55:37.613 | 2019-12-06T00:38:10.237 | 2012-12-19T01:26:00.810 | 626,833 | 99,821 | [
"javascript",
"youtube-api"
] |
3,333,599 | 1 | 3,333,661 | null | 4 | 4,442 | I'm trying to build a simple heatmap for one of my sites, but it seems a lot trickier that I thought!
1)
2)
I need to track clicks on the site, but unfortunately event.PageX and event.PageY are calculated taking in consideration the whole screen.
---
# Examples
In the first example a click with coordinates [300, 500] will probably be located somewhere around the gorilla (maybe his nostrils! =) ).

In this other example a click with coordinates [300. 500] will probably be located somewhere

---
This would be really interesting to know! Thanks guys! =)
| Click heatmap and mouse coordinates! - Javascript | CC BY-SA 2.5 | 0 | 2010-07-26T09:25:36.257 | 2010-07-26T09:46:05.363 | 2010-07-26T09:32:20.437 | 208,827 | 208,827 | [
"javascript",
"jquery",
"html",
"css",
"heatmap"
] |
3,335,770 | 1 | 3,335,816 | null | 1 | 98 | I inherited a project with drupal and flash, and I'm pretty noobish on the topic so please don't bash me.
What I'm stuck at is that I need to create multiple thumbnails for each uploaded image (5 version to be precise with different settings eg. 150w, 250w,..) I created the presets but I can't seem to understand how imagecache works: it looks like the module builds the thumbnails only after I firs see the images, problem is that after I create the node I'm greeted with this view:

as you may notice some of the fields can have multiple images.
If I'm correct in my assumption that imagecache only builds thumb when you first access the node why I can't see the images but only the icons? Alternatively is it possible to force imagecache to create the different sizes as soon as the images are uploaded?
If not how does imagecache works?
Thanks
| Imagecache with amfphp and flash multiple issues | CC BY-SA 2.5 | null | 2010-07-26T14:26:55.193 | 2010-07-26T14:33:07.603 | null | null | 82,098 | [
"php",
"drupal",
"image",
"thumbnails"
] |
3,336,185 | 1 | 3,841,815 | null | 10 | 6,501 | I can map 1:1 (one-to-one) tables intuitively, like this:

But I cannot understand how to do the same mapping between a table and a VIEW, like this

In this diagram the two entities are represented. If I manually create an association in the entity model, and set up its mapping like this:

Then I get the error:
> Error 3021: Problem in Mapping Fragment starting at line 172: Each of the following columns in table view_EmployeeView is mapped to multiple conceptual side properties:
view_EmployeeView.EmployeeID is mapped to Employeesview_EmployeeView.Employees.id, Employeesview_EmployeeView.view_EmployeeView.EmployeeID
Why would I not get this error with the table-table association? How do I solve this problem? I would like to put some calculated information in a view, but explicitly join to it when I need with the .Include() function.
| Entities framework mapping association between view and table | CC BY-SA 2.5 | 0 | 2010-07-26T15:12:10.447 | 2010-10-01T17:59:36.193 | 2010-10-01T17:59:36.193 | 12,971 | 402,169 | [
"c#",
"entity-framework"
] |
3,337,328 | 1 | 3,339,345 | null | 1 | 395 | Given a model like this

ProductFacets contains the following data:
```
ProductId, FacetTypeId
1, 1
1, 2
2, 1
2, 3
3, 4
3, 5
4, 1
4, 2
```
I'd like to be able to select all Products which have a FacetTypeId of 1 AND 2.
The result set should contain ProductIds 1 and 4
| Sql Server 2008 Select From table with AND style conditions in related tables | CC BY-SA 2.5 | null | 2010-07-26T17:28:59.213 | 2010-07-27T11:50:21.527 | null | null | 43,603 | [
"sql-server-2008"
] |
3,337,450 | 1 | 3,338,766 | null | 1 | 836 | I'm able to save the captured image from a barcode scanner using this code:
```
Microsoft.Win32.SaveFileDialog dlg = new Microsoft.Win32.SaveFileDialog();
dlg.DefaultExt = ".jpg";
dlg.Filter = "JPEG Images (.jpg)|*.jpg|All files (*.*)|*.*";
if (dlg.ShowDialog() == true)
{
using (FileStream file = File.OpenWrite(dlg.FileName))
{
file.Write(e.ImageBuffer, 0, e.ImageSize);
}
}
```
However, I would like to display the captured image using WPF but I get a distorted image.
```
private void _barcodeScannerInstance_SavePhotoEvent(object sender, ImageEventArgs e)
{
SetBitmap(e.ImageBuffer, 350, 263, 96);
}
private void SetBitmap(byte[] image, int width, int height, int dpi)
{
MainWindow.Instance.Dispatcher.Invoke(DispatcherPriority.Normal, (ThreadStart)delegate()
{
BitmapSource bitmapSource = BitmapSource.Create(
width, height, (double)dpi, (double)dpi, PixelFormats.Bgr24, null, image, ((width * 24 + 31) & ~31) >> 3);
HwModeScreen.BarcodeImageCanvas.Children.Clear();
Image myImage = new Image();
myImage.Width = HwModeScreen.BarcodeImageCanvas.ActualWidth;
myImage.Height = HwModeScreen.BarcodeImageCanvas.ActualHeight;
myImage.Stretch = Stretch.Fill;
myImage.Source = bitmapSource;
HwModeScreen.BarcodeImageCanvas.Children.Add(myImage);
});
```
Here is the image I see. It should be a black and white picture of a kleenex box.

Here is the saved jpg file:

| Display captured Jpeg File | CC BY-SA 2.5 | 0 | 2010-07-26T17:46:32.753 | 2011-09-07T17:09:53.460 | 2017-02-08T14:29:10.483 | -1 | 314,087 | [
"c#",
"wpf",
"jpeg"
] |
3,338,277 | 1 | 3,425,788 | null | 2 | 119 | Anyone knows how to build errors like that shown in [Androffice](https://i.stack.imgur.com/NtOdW.png) screenshots on AppBrain ([[http://www.appbrain.com/app/android.androffice][2]](http://www.appbrain.com/app/android.androffice][2]))?
I think that I saw errors like that before. Is that built in Android SDK?

| how to build errors like that shown in Androffice screenshots | CC BY-SA 3.0 | 0 | 2010-07-26T19:29:53.543 | 2012-02-23T16:56:15.897 | 2012-02-23T16:56:15.897 | 202,602 | 202,602 | [
"android",
"validation"
] |
3,338,358 | 1 | 3,339,100 | null | 0 | 502 | We're having this weird bug where if the application is opened and the user changes the windows font size here:

When the font size is changed to extra large, one of our controls `DataContext` is changed to null, and its `DataContextChanged` event is called too.
Not really sure what is going on, nor why or what changes the `DataContext` of the control. Any help would be greatly appreciated.
Thanks!
| Windows Font Size screws up WPF application | CC BY-SA 3.0 | null | 2010-07-26T19:39:51.510 | 2011-09-07T18:25:46.623 | 2017-02-08T14:29:10.820 | -1 | 62,642 | [
"wpf",
"datacontext",
"font-size"
] |
3,338,699 | 1 | 3,339,810 | null | 4 | 1,895 | In my grid I have data in two columns same for couple of rows. Then again couple of other rows will same with different data.I want make them into alternative sections with colors
In below example(image).
```
Rows no 1 to 4 has 'High', 'High'. I want make them gray bgcolor for those rows.
Rows no 5 to 8 has 'High','Low'. I want make them white bgcolor for those rows
Rows no 9 to 12 has 'High','Medium'. I want make them again gray bg color for
those rows.
```

How can we do that?
| how make groups(sections) based on column values in gridview? | CC BY-SA 2.5 | 0 | 2010-07-26T20:24:21.267 | 2010-07-26T23:51:58.727 | 2017-02-08T14:29:11.163 | -1 | 158,008 | [
"c#",
"asp.net",
"vb.net"
] |
3,340,141 | 1 | 3,358,868 | null | 3 | 2,012 | Subject is my real question but i wonder that another issue about web services.
What is the key points of web services to return something?
1. Serializable (Because everything converts to XML before adding them to SOAP Message)
2. ? (What should i do for generic class)
3. ?? (How can i put everything (which are serializable classes) to one return type like Object type)
4. ??? (How can i pass exceptions over Web Services?)
[alt text http://docs.sun.com/source/819-3669/images/saaj-noAttach.gif](http://docs.sun.com/source/819-3669/images/saaj-noAttach.gif)


| How can I send ArrayList over Web Service? | CC BY-SA 2.5 | 0 | 2010-07-27T01:24:59.910 | 2010-07-29T01:38:15.447 | 2017-02-08T14:29:12.320 | -1 | 104,085 | [
"soap",
"web-services",
"return-type"
] |
3,340,226 | 1 | 3,340,240 | null | 9 | 7,294 | How does one tell the designer the default value of a Property when it is not one of the types supported by `DefaultValue()`? For instance, a `Padding`, or a `Font`.
Normally, when you use a Windows Forms control, the default values will be in a normal font in the Properties window, and changed (non-default) values will be in bold. E.g.

In this sample, the default value of `ShowAddress` is `false` and the default value of `ShowName` is `true`. This effect is achieved with the following:
```
[DefaultValue(false)]
public bool ShowAddress {
get { return mShowAddress; }
set {
mShowAddress = value;
Invalidate();
}
}
[DefaultValue(true)]
public bool ShowName { ... }
```
However, when I tried to do something for `Padding`, I failed miserably:
```
[DefaultValue(new Padding(2))]
public Padding LabelPadding { ... }
```
Which of course won't compile.
How on Earth would I do this?
| How does one have the C# designer know the default property for a Padding or other object/struct in C# | CC BY-SA 2.5 | 0 | 2010-07-27T01:44:33.377 | 2014-06-26T23:57:49.603 | 2017-02-08T14:29:12.713 | -1 | 16,299 | [
"c#",
"winforms",
"visual-studio-2008",
"attributes",
"default-value"
] |
3,340,383 | 1 | 4,394,668 | null | 5 | 842 | I'm looking into Paxos and I'm confused about how the algorithm should behave in this contrived example. I hope the diagram below explains the scenario.

A few points:
- - `(instance, proposal_num)`- `(instance, proposal_num, proposal_val)`- -
It seems here that although the protocol is 'correct', i.e. only one value `S2` is chosen, Server1 and Server2 believe that it was chosen because of different proposal numbers.
Does the Paxos algorithm only terminate when the `Decide(...)` message is sent out to the learners? I must be misunderstanding but I thought the choice was made the moment the proposers achieved quorum for their `Propose(...)` messages.
If the choice is only made after the `Decide(...)` message is sent out to the agents, should Server2 terminate its sending of `Decide(1, 5, S2)` when it recovers because it saw a later `Prepare(1, 7)`?
| What is the proper behaviour for a Paxos agent in this scenario? | CC BY-SA 2.5 | null | 2010-07-27T02:32:13.893 | 2016-12-13T13:08:07.617 | 2017-02-08T14:29:13.057 | -1 | 56,332 | [
"algorithm",
"distributed",
"consensus",
"paxos"
] |
3,341,032 | 1 | 3,343,771 | null | 15 | 9,769 | I have a windows form application that has a background. Within it, I have a flowlayoutpanel with a transparent background. When I scroll, the following happens:

I also see some flickering. I've tried all the doublebuffered business, and it doesn't work.
Any suggestions?
| During FlowLayoutPanel scrolling, background distorts + flickers | CC BY-SA 3.0 | 0 | 2010-07-27T05:43:50.917 | 2022-04-18T19:02:18.167 | 2011-12-05T01:46:33.813 | 719,186 | 396,077 | [
"c#",
"scroll",
"transparent",
"flicker",
"flowlayoutpanel"
] |
3,341,900 | 1 | 3,342,173 | null | 3 | 207 | I have the following project structure using a Domain Model, StructureMap and Fluent NHibernate:

The problem I'm having is that Fluent NHibernate requires all of the following to be the bin directory of the website for it to work at runtime:
> - - - - - - - -
The problem I'm having is that not all of these assemblies are output to my website's bin directory. Currently only the items with a `*` are output correctly. The items in are missing from the bin directory.
Now, I would of assumed that the reason for this is because I have not added them as references to my `Fluent NHibernate` project. The only references I currently have are to and . These two references alone are enough to bring through the items marked with a `*`, but they do not bring through the missing items.
So, I then thought that to get them to all come through I'd just add them as references to the `Fluent NHibernate` project. Unfortunately, this made no difference; the same items were still missing from the bin directory.
I've never really understood how visual studios decides which assemblies to copy over. I always assumed it was any assembly marked as , but this doesn't seem to be the case in this scenario.
Of course I could just add all the assembly references into `Website`, but then that'd completed defeat the point of loosely coupling the projects through `StructureMap`.
Does anyone have any idea why the assemblies are missing and how I can get them to copy over correctly?
| Why are some references missed when running my application? | CC BY-SA 2.5 | null | 2010-07-27T08:36:21.520 | 2011-09-27T15:31:18.147 | 2017-02-08T14:29:14.763 | -1 | 44,269 | [
"visual-studio",
"nhibernate",
"visual-studio-2010",
"fluent-nhibernate",
"structuremap"
] |
3,342,121 | 1 | 3,343,989 | null | 2 | 265 | I apologize ahead of time, becuase I'm neither great at explaining things nor flow charts. This is not a specific code problem, but a general question on session security.
I'm trying to eliminate as many potential problems as possible at once. I think this takes care of:
- - - - -
I realize the session can still be sidejacked if both the attacker's IP and user-agent header are the same as authenticated user's. I guess to make that bulletproof you would need SSL?
I would appreciate any critiques, if you can make out what I'm trying to say with the clusterfuck below. This is more or less what I'm doing:
EDIT - another question I had: Is it safe to assume that a user will not have an IP address that changes frequently enough for this to become a problem?

| Is this a secure authentication system for an ajax-driven app? | CC BY-SA 2.5 | 0 | 2010-07-27T09:07:06.973 | 2010-07-27T13:17:07.190 | 2010-07-27T12:19:08.900 | 216,313 | 216,313 | [
"php",
"security",
"authentication",
"session",
"session-hijacking"
] |
3,344,350 | 1 | null | null | 2 | 366 | How would you map the dashed association using ActiveRecord? Is there any ActiveRecord-way of doing it? What I want is to get all unique available promotions for a particular item.

Here are things I thought but I don't really like:
```
class Item < ActiveRecord::Base
has_many :promotions, :finder_sql => "SELECT..FROM promotions..purchase_option_id IN (...)"
end
```
```
my_item.purchase_options.map(&:promotion).uniq
```
`PurchaseOption``Promotion``Item``PromotedPurchaseOption`

```
class Item < ActiveRecord::Base
has_many :promoted_purchase_options
has_many :promotions, :through => :promoted_purchase_options
end
```
I don't think it's a good idea to use or defining new
This won't simply work or will execute inefficient queries if using them:
```
Item.first.promotions.count
Item.first.promotions.available
Promotion.first.items.all
```
| Complex ActiveRecord association definition | CC BY-SA 2.5 | 0 | 2010-07-27T13:55:49.227 | 2010-07-27T14:40:18.347 | 2017-02-08T14:29:15.450 | -1 | 62,368 | [
"ruby-on-rails",
"activerecord",
"associations"
] |
3,345,220 | 1 | 3,354,641 | null | 0 | 1,244 | Is there a way to get the content of a component inside a scroller to be at 100% height.
here is a simple example:
```
<s:Scroller width="100%" height="100%">
<s:viewport>
<s:Group height="100%">
<s:Rect width="10" height="500">
<s:fill>
<s:SolidColor color="0xFF0000"/>
</s:fill>
</s:Rect>
<s:Rect width="10" x="10" height="100%">
<s:fill>
<s:SolidColor color="0x00FF00"/>
</s:fill>
</s:Rect>
<s:Rect width="10" x="20" height="100">
<s:fill>
<s:SolidColor color="0x0000FF"/>
</s:fill>
</s:Rect>
</s:Group>
</s:viewport>
</s:Scroller>
```
If you run this code and scroll down a bit, this is what you get:

As you can see, the green bar (set at 100% height) is just using the height of the viewport, not that of it's parent group, that is stretched by the red one to be 500px high.
Is there a way to fix that?
| Having the content of a s:Scroller viewport at 100% height | CC BY-SA 2.5 | 0 | 2010-07-27T15:28:26.070 | 2010-07-28T15:42:42.853 | 2010-07-27T15:36:42.400 | 138,352 | 138,352 | [
"apache-flex",
"height",
"viewport",
"flex4",
"scroller"
] |
3,346,181 | 1 | 3,346,313 | null | 4 | 9,778 | i am experimenting with html and css and trying to figure out how to make this work... I am just trying to make the #menu float to the right of the h1 but be on the same baseline so... but obviously float:right makes it float to top-right? any way to make it float to bottom-right or align with the bottom of the containing div?
here is the html:
```
<!doctype html>
<html>
<head>
<title>Website.com</title>
<link rel="Stylesheet" href="style.css" type="text/css" />
</head>
<body>
<div>
<h1><a href="#" title="Website.com">Website.com</a></h1>
<div id="menu">
<ul>
<li><a href="#" title="Home">Home</a></li>
<li><a href="#" title="Link1 Description">Link1</a></li>
<li><a href="#" title="Link2 Description">Link2</a></li>
<li><a href="#" title="Link3 Description">Link3</a></li>
<li><a href="#" title="About Website.com">About</a></li>
</ul>
</div>
</div>
<hr />
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur mattis elit et augue pellentesque fermentum semper urna interdum. Nullam egestas augue ut risus molestie mollis ut sed dolor. Curabitur fermentum, lorem sed suscipit euismod, diam urna vulputate sapien, ac venenatis velit eros sed leo. Duis venenatis, metus at scelerisque fringilla, neque arcu dignissim arcu, quis sodales lorem mauris eget tellus. Phasellus fermentum est eget erat pretium mollis. Cras eu nunc dui, sed fermentum libero. Vivamus posuere pellentesque tellus in interdum. Vestibulum eleifend fringilla enim, in vehicula justo tristique a. Aenean congue vestibulum iaculis. Sed tristique interdum lectus, vel aliquam nisi fringilla ac. Mauris ligula nisl, gravida id consequat in, vestibulum at risus. Vivamus vitae massa lorem, vel molestie tellus. Nulla et magna orci. Nunc turpis ipsum, facilisis eget tristique sit amet, scelerisque quis ligula. Mauris in molestie purus. Cras eget magna vel enim imperdiet aliquam.</p>
<p>Vestibulum vel eros lacus, vel viverra magna. Duis mollis nibh ut erat accumsan ut pulvinar ipsum dapibus. Aliquam vehicula tempus fermentum. Morbi ut turpis sem, pretium sodales libero. Vestibulum dapibus, ligula in molestie scelerisque, lacus est aliquam elit, ut vulputate sapien nisl vitae elit. Cras pulvinar mi nisl. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin in est orci. Ut rutrum lobortis quam vitae commodo. Maecenas dapibus aliquam ante eget mattis. Proin justo eros, bibendum quis scelerisque eget, fermentum eu purus. Vivamus viverra ligula a dolor iaculis ullamcorper. Aliquam erat volutpat. Nunc libero nulla, sodales at dictum vel, tempus quis est.</p>
<p>Nullam pharetra tincidunt lectus ac sollicitudin. Duis in venenatis eros. Phasellus malesuada quam vel sapien ultricies tincidunt. Duis condimentum posuere semper. Vivamus eleifend libero eget ligula egestas adipiscing. Proin dapibus leo non urna pellentesque convallis. Suspendisse massa leo, semper vitae tincidunt at, mattis et sapien. Maecenas consequat hendrerit odio et feugiat. Sed dignissim massa a leo sollicitudin imperdiet consequat purus vehicula. Mauris sit amet nulla a turpis porta accumsan. Morbi interdum pellentesque massa, vel accumsan massa aliquam quis. Sed sed ligula neque. In hac habitasse platea dictumst. Curabitur vehicula scelerisque ligula non tincidunt.</p>
<hr />
<p id="footer">Use of this site constitutes acceptance of our <a href="#">User Agreement</a> and <a href="#">Privacy Policy</a>. © 2010 Website.com. All rights reserved.</p>
</body>
</html>
```
and here is the css:
```
body
{
font-family: verdana, sans-serif;
min-width: 800px;
}
h1
{
display: inline;
font-variant: small-caps
}
h1 a
{
color: #090;
text-decoration: none;
}
h1 a:hover
{
color: #0A0;
}
#menu
{
float: right;
display: inline;
margin: 0;
padding: 0;
font-variant: small-caps;
}
#menu ul
{
margin: 0;
padding-left: 0;
float: left;
font-weight: bold;
}
#menu ul li
{
float: left;
display: inline;
}
#menu ul li a
{
color: #090;
background-color: #F3F3F3;
padding: 2px 6px 4px 6px;
text-decoration: none;
}
#menu ul li a:hover
{
font-weight: bolder;
color: #0A0;
background-color: #F3F3F3;
border-bottom: 4px solid #0A0;
padding-bottom: 0;
}
#footer
{
text-align: center;
font-size: x-small;
}
```
here is what is looks like now: 
thanks for help!
| css float:right and vertical align? | CC BY-SA 2.5 | 0 | 2010-07-27T17:24:23.467 | 2010-07-27T18:35:49.140 | null | null | 403,681 | [
"html",
"css"
] |
3,346,280 | 1 | 3,354,748 | null | 0 | 151 | Is it possible to stop the Unloaded, OnApplyTemplate and OnTemplateChanged from triggering when we change the default font size in Windows XP?

It's been causing us some problems and we haven't figured out a good way to handle it. If you know what other events get triggered under this situation, it would help us a lot too.
Thanks!
| Unload event when changing font size in Windows XP | CC BY-SA 2.5 | null | 2010-07-27T17:36:32.253 | 2010-07-28T15:51:52.370 | 2017-02-08T14:29:10.820 | -1 | 62,642 | [
"wpf"
] |
3,347,295 | 1 | 3,347,508 | null | 7 | 2,574 | Screenshot of what is happening:

It is just a list item within an underordered list, this is happening in IE7 and nowhere else.
```
<ul>
<li>Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text. Filler text.</li>
</ul>
.fancybox-entry.computer-policy li {
float:none;
width:100%;
list-style-type:disc;
margin-bottom:10px;
}
.fancybox-entry.computer-policy ul + p {
margin-bottom:20px;
}
.fancybox-entry.computer-policy ul {
margin:5px 0 10px 25px;
}
```
Any help as to why it is doing that and a fix is appreciated.
| Disc to left of list item is displayed at bottom | CC BY-SA 3.0 | null | 2010-07-27T19:40:56.643 | 2013-12-18T16:12:49.357 | 2011-10-28T20:54:49.457 | 757,830 | 26,130 | [
"html",
"css"
] |
3,347,452 | 1 | 4,447,168 | null | 13 | 2,172 | I was wondering if there's anything like Eclipse Perspectives in Visual Studio (2008 or 2010).
For those unfamiliar with Eclipse, here's a [definition of Perspectives](http://www.eclipse.org/articles/using-perspectives/PerspectiveArticle.html):
> A perspective is a visual container
for a set of views and editors
(parts). These parts exist wholly
within the perspective and are not
shared. A perspective is also like a
page within a book. It exists within
a window along with any number of
other perspectives and, like a page
within a book, only one perspective is
visible at any time.
Let me give you a visual example:


Maybe there is nothing like that straight out of the box, but with some plugin. If that's the case, it'll also be a valid answer.
Thanks for your time.
| Is there anything like Eclipse Perspective in Visual Studio? | CC BY-SA 2.5 | 0 | 2010-07-27T20:00:44.663 | 2010-12-15T06:03:49.830 | null | null | 4,386 | [
"visual-studio",
"eclipse",
"perspectives"
] |
3,348,818 | 1 | null | null | 0 | 586 | If you read the title you read my question correctly.
I am wondering how I make my events mimic dayClick so any event selected on that day will select dayClick instead of linking with a url.
Just for insight on what I am doing my calendar currently looks like this:

[http://img.photobucket.com/albums/v451/Plop4152/Screenshot2010-07-27at43348PM.png](http://img.photobucket.com/albums/v451/Plop4152/Screenshot2010-07-27at43348PM.png)
| How do I make fullcalendar events pulled by json mimic dayClick? | CC BY-SA 3.0 | null | 2010-07-27T23:36:53.193 | 2011-12-04T06:48:50.830 | 2011-12-04T06:48:50.830 | 234,976 | 403,979 | [
"fullcalendar"
] |
3,349,229 | 1 | 3,349,460 | null | 2 | 840 | I have created a Area class using Linq-to-SQL.
Now I want to create a partial class of the same name so I can implement validation.
> Error 1 Cannot implicitly convert type
'`System.Data.Linq.Table<SeguimientoDocente.Area>`'
to
'`System.Linq.IQueryable<SeguimientoDocente.Models.Area>`' C:\Users\Sergio\documents\visual
studio
2010\Projects\SeguimientoDocente\SeguimientoDocente\Models\AreaRepository.cs 14 20 SeguimientoDocente
Code:
```
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace SeguimientoDocente.Models
{
public class AreaRepository
{
private SeguimientoDataContext db = new SeguimientoDataContext();
public IQueryable<Area> FindAllAreas()
{
return db.Areas;
}
public Area GetArea(int id)
{
return db.Areas.SingleOrDefault(a => a.ID == id);
}
public void Add(Area area)
{
db.Areas.InsertOnSubmit(area);
}
public void Delete(Area area)
{
db.Areas.DeleteOnSubmit(area);
}
public void Save()
{
db.SubmitChanges();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace SeguimientoDocente.Models
{
public partial class Area
{
}
}
```
Here's a screenshot.

| Error when trying to create a partial class | CC BY-SA 4.0 | null | 2010-07-28T01:19:58.920 | 2019-11-03T15:00:19.873 | 2019-11-03T15:00:19.873 | 472,495 | 112,355 | [
"c#",
"linq-to-sql",
"partial"
] |
3,349,942 | 1 | 3,349,984 | null | 1 | 244 | I have to select checkboxes besed on group column values. If you see below gridview, column 3 (GroupNo) has 1,1,1,1,2,2,2,2....etc (. ).
Now My question is.
In every sectio/Group User must and should select minimun 2 check boxes. so If user select only one check box we need to show a pop up message as " Please select One more check box in that particular section" If User skips the message and move to next section we have to show the same message. We have to force the user to select more than one checkbox in the same section.
Mainly our intention is the check boxes whatever user selected in each section/Group belongs to one Category.
Please help me in this requirement. Thanks in advance.

| Force the user to select minimum two check boxes in each section in gtrid view? | CC BY-SA 2.5 | null | 2010-07-28T04:24:19.780 | 2010-07-28T06:22:14.520 | 2017-02-08T14:29:16.817 | -1 | 158,008 | [
"c#",
"asp.net",
"vb.net"
] |
3,350,670 | 1 | 3,456,241 | null | 3 | 4,009 | I have a few SSRS reports running on SQL Server 2008 Web Edition SP1 on my production web server.
For some reason, CSV and XML export is not offered to me when viewing my reports in the report viewer. This applies to all reports on that server.
As you can see, PDF, Word and Excel still work fine, it's just XML and CSV that are missing:

The reports are rendered on the server side, so that can't be the problem.
I checked rsreportserver.config and the xml and csv export formats are at least still mentioned there in the `<Render>` node. I am not sure if this is all I need for CSV and XML export to work though:
```
<Render>
<Extension Name="XML" Type="Microsoft.ReportingServices.Rendering.DataRenderer.XmlDataReport,Microsoft.ReportingServices.DataRendering"/>
<Extension Name="NULL" Type="Microsoft.ReportingServices.Rendering.NullRenderer.NullReport,Microsoft.ReportingServices.NullRendering" Visible="false"/>
<Extension Name="CSV" Type="Microsoft.ReportingServices.Rendering.DataRenderer.CsvReport,Microsoft.ReportingServices.DataRendering"/>
<Extension Name="PDF" Type="Microsoft.ReportingServices.Rendering.ImageRenderer.PDFRenderer,Microsoft.ReportingServices.ImageRendering"/>
<Extension Name="RGDI" Type="Microsoft.ReportingServices.Rendering.ImageRenderer.RGDIRenderer,Microsoft.ReportingServices.ImageRendering" Visible="false"/>
<Extension Name="HTML4.0" Type="Microsoft.ReportingServices.Rendering.HtmlRenderer.Html40RenderingExtension,Microsoft.ReportingServices.HtmlRendering" Visible="false"/>
<Extension Name="MHTML" Type="Microsoft.ReportingServices.Rendering.HtmlRenderer.MHtmlRenderingExtension,Microsoft.ReportingServices.HtmlRendering"/>
<Extension Name="EXCEL" Type="Microsoft.ReportingServices.Rendering.ExcelRenderer.ExcelRenderer,Microsoft.ReportingServices.ExcelRendering"/>
<Extension Name="RPL" Type="Microsoft.ReportingServices.Rendering.RPLRendering.RPLRenderer,Microsoft.ReportingServices.RPLRendering" Visible="false" LogAllExecutionRequests="false"/>
<Extension Name="IMAGE" Type="Microsoft.ReportingServices.Rendering.ImageRenderer.ImageRenderer,Microsoft.ReportingServices.ImageRendering"/>
<Extension Name="WORD" Type="Microsoft.ReportingServices.Rendering.WordRenderer.WordDocumentRenderer,Microsoft.ReportingServices.WordRendering"/>
</Render>
```
So, what could be the problem here and how do I fix it?
Thanks,
Adrian
| Why is CSV export missing in my SSRS report? | CC BY-SA 2.5 | 0 | 2010-07-28T07:16:33.607 | 2010-08-11T13:17:30.470 | 2017-02-08T14:29:17.830 | -1 | 59,301 | [
"sql-server",
"sql-server-2008",
"ssrs-2008",
"reporting-services"
] |
3,350,892 | 1 | 3,357,395 | null | 75 | 4,768 | I just checked my Chromium task manager and noticed that my `Goats Teleported` count is abnormally high. I thought it might be a good idea to create a browser extension that runs the goat teleportation data through Google Visualizations API and generates some nice reports so I can track it easily and make sure it doesn't get out of hand.
[](https://i.stack.imgur.com/S0jSO.png)
Is it possible to access the `Goats Teleported` count programatically via the chrome extension API? How do you think I should format the reports? I was thinking maybe a pie chart?

| Graph Goat Teleportation Data with Google Vis. API via Chrome Extension | CC BY-SA 4.0 | 0 | 2010-07-28T07:53:52.480 | 2019-08-04T05:11:35.103 | 2019-08-04T05:11:35.103 | 4,751,173 | 886,931 | [
"javascript",
"google-chrome",
"google-chrome-extension",
"google-visualization"
] |
3,352,469 | 1 | 3,353,542 | null | 2 | 1,965 | I have been using CodeDom to do some code generation. It works great, but I haven't found a way to include the generated source code files in a project. I started using T4 and the [T4Toolbox](http://t4toolbox.codeplex.com) to generate code because it supports integration with project files.
Does anyone know if CodeDom supports this functionality too? I'd consider taking a second look at CodeDom if it only supported this one feature.
Here is an example of how I make a source code file with CodeDom:
```
protected void CreateSourceFile(CodeCompileUnit codeCompileUnit,
string fileName,
out string fileNameWithExtension)
{
fileNameWithExtension = string.Format("{0}.{1}",
fileName,
CodeProvider.FileExtension);
var indentedTextWriter =
new IndentedTextWriter(new StreamWriter(fileNameWithExtension,
false),
TabString);
CodeProvider.GenerateCodeFromCompileUnit(codeCompileUnit,
indentedTextWriter,
new CodeGeneratorOptions());
indentedTextWriter.Close();
}
```
That works fine but it just outputs the file to the hard drive somewhere (probably bin folder).
Here is a second example of some code I use with T4, this one specifies the output as part of the project the template is transformed in:
```
public class RDFSClassGenerator : Generator
{
private readonly string rootNamespace;
private readonly string ontologyLocation;
public RDFSClassGenerator(
string rootNamespace,
string ontologyLocation)
{
this.rootNamespace = rootNamespace;
this.ontologyLocation = ontologyLocation;
}
protected override void RunCore()
{
XElement ontology = XElement.Load(ontologyLocation);
var service = new RDFSGeneratorService(ontology);
foreach (MetaClass metaClass in service.MetaClasses)
{
var rdfsClassTemplate = new RDFSClassTemplate(rootNamespace, metaClass);
rdfsClassTemplate.Output.File = "Domain/" + metaClass.Name + ".cs";
rdfsClassTemplate.Render();
}
}
}
```
So the T4 code will output the file into the "Domain" folder of my project. But the CodeGen stuff just outputs the file on disk and doesn't update the project file.
Here is a visual:

| Can CodeDom add Source Code Files to a Project? | CC BY-SA 2.5 | null | 2010-07-28T11:43:34.463 | 2010-07-28T13:53:33.300 | 2017-02-08T14:29:18.517 | -1 | 402,098 | [
"code-generation",
"t4",
"codedom"
] |
3,353,575 | 1 | 3,582,188 | null | 3 | 1,475 | Does anybody know whether one can trigger prism command with a shortcut? What I mean is I want to be able to define binding of a command to keyboard shortcut in declarative manner, like [ClientUI](http://intersoftpt.wordpress.com/2010/04/24/clientui-part-3-comprehensive-mvvm-framework-for-silverlight-development/) does:

Are there any opensource libraries for that purpose? Or maybe code samples?
I found [this question](https://stackoverflow.com/questions/1478094/hotkey-commands-for-silverlight-in-mvvm) but I don't think that it answers mine.
| Triggering Silverlight Prism command with a keyboard shortcut | CC BY-SA 2.5 | 0 | 2010-07-28T13:56:54.890 | 2013-02-21T14:02:51.657 | 2017-05-23T12:08:51.063 | -1 | 291,287 | [
"c#",
"silverlight",
"mvvm",
"command",
"hotkeys"
] |
3,353,582 | 1 | 3,355,224 | null | 3 | 6,300 | I have the following LaTeX file. Notice how the item on the description is very long `...foo...`.
```
\documentclass{article}
\begin{document}
\begin{description}
\item[foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo]
bar
\item[baz]
bang
\end{description}
\end{document}
```
It produces a file like this:

The `foo` is all on one line and will run off the edge. Is there anyway to split the description part across multiple lines so it doesn't run off the edge of the page? I want to be able to do this only in the preamble, since I can't edit the actual body of the document.
| LaTeX - Description list - Split the item across multiple lines | CC BY-SA 2.5 | 0 | 2010-07-28T13:58:20.870 | 2010-07-28T16:42:58.280 | null | null | 161,922 | [
"latex",
"tex",
"text-formatting"
] |
3,353,858 | 1 | 3,354,410 | null | 0 | 276 | I have a LaTeX document like this:
```
\documentclass{article}
\begin{document}
\section{1}
\section{2}
\section{3}
\section{4}
\section{5}
\section{6}
\section{7}
\section{8}
\section{9}
\section{10}
\section{11}
\section{12}
\section{13}
\section{14}
\section{15}
\section{16}
\section{17}
\section{18}
\section{19}
\section{20}
\section{21}
\section{22}
\section{23}
\section{24}
\section{25}
\section{26}
\section{27}
\section{28}
\section{29}
\section{30}
\end{document}
```
Lots of section headings, but no text in
It produces something like this:

As you can see it keeps all the section headings on one page, and won't break it into 2 pages. Everything above 26 has disappeared off the end of the page.
Is there anyway to get LaTeX to split these sections across multiple pages? I can't easily change the actual content of body, since it's autogenerated. I can change the preamble though. Is there anyway to do this by changing the preamble?
| LaTeX - Lots of sections (with no content) running of the edge of the page? | CC BY-SA 2.5 | null | 2010-07-28T14:26:57.327 | 2023-01-07T03:54:01.073 | null | null | 161,922 | [
"latex",
"tex",
"text-formatting"
] |
3,355,058 | 1 | 3,355,170 | null | 33 | 24,820 | I'd like to center a list of left-aligned items.
This is what I currently have:
```
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Shrinkwrapped List</title>
<style type="text/css">
#wrapper {
margin: auto;
width: 500px;
border: solid 1px #CCCCCC;
}
#header {
text-align: center;
font-size: 200%;
}
#content {
text-align: center;
}
#content ul {
text-align: left;
font-size: 150%;
list-style-type: none;
margin: 20px auto;
padding: 0px;
border: solid 1px #666666;
}
</style>
</head>
<body>
<div id="wrapper">
<div id="header">
Shrinkwrapped List
</div>
<div id="content">
<ul>
<li>Lorem ipsum</li>
<li>Dolor sit amet</li>
<li>Consectetur</li>
<li>Adipiscing elit</li>
<li>Morbi odio</li>
<li>Mi blandit vehicula</li>
</ul>
</div>
</div>
</body>
</html>
```
Which produces a page that looks like:

What I really want looks like this:

I can accomplish this by adding `width: 200px;` to `#content ul` but the problem is that I have a lot of lists like this and they all have various widths.
I'd like the `<ul>` to shrink to the content so it can be centered correctly. Or am I going about this the wrong way?
Thanks for any help you can provide.
---
# Solution
Thanks to [KennyTM](https://stackoverflow.com/users/224671/kennytm) and [Magnar](https://stackoverflow.com/users/1123/magnar), here is the solution:
Add these four lines to `#content ul`'s CSS rules:
```
display:-moz-inline-stack;
display:inline-block;
zoom:1;
*display:inline;
```
I've tested this in IE6, IE7, IE8 and Firefox 3.6. The results looks like the second image above and the list always fits to the content of the items.
| Can I center a <ul> with left-aligned <li>s? | CC BY-SA 2.5 | 0 | 2010-07-28T16:24:45.593 | 2022-07-02T21:45:14.647 | 2017-05-23T12:25:42.303 | -1 | 307,338 | [
"html",
"css"
] |
3,355,252 | 1 | 3,355,351 | null | 0 | 92 | I have the following table structure:

I'm trying to populate a combobox of all the Jefes when editing an Area. Meaning I can change who's in charge of an area.
Here is my AreaController.cs code:
```
public ActionResult Edit(int id)
{
Area area = areaRepository.GetArea(id);
JefeRepository jefe = new JefeRepository();
ViewData["Jefes"] = new SelectList(jefe.FindAllJefes(), "Nombre", "Nombre");
return View(area);
}
[AcceptVerbs(HttpVerbs.Post)]
public ActionResult Edit(int id, FormCollection formValues)
{
Area area = areaRepository.GetArea(id);
try
{
UpdateModel(area);
areaRepository.Save();
return RedirectToAction("Details", new { id = area.ID });
}
catch (Exception)
{
foreach (var issue in area.GetRuleViolations())
{
ModelState.AddModelError(issue.PropertyName, issue.ErrorMessage);
}
return View(area);
}
}
```
Note that .FindAllJefes() returns an IQueryable<> collection.
Now in my Edit.aspx file I have the following:
```
<fieldset>
<legend>Informacion Detallada de Area | <%: Model.Nombre %></legend>
<div class="editor-label">
<%: Html.LabelFor(model => model.Nombre) %>
</div>
<div class="editor-field">
<%: Html.TextBoxFor(model => model.Nombre) %>
<%: Html.ValidationMessageFor(model => model.Nombre) %>
</div>
<div class="editor-label">
<%: Html.LabelFor(model => model.IDJefe) %>
</div>
<div class="editor-field">
<%: Html.DropDownList("IDJefe", (SelectList)ViewData["Jefes"], "(Select Jefe)") %>
<%: Html.ValidationMessageFor(model => model.IDJefe) %>
</div>
<p>
<input type="submit" value="Save" />
</p>
</fieldset>
```
I receive this error:
> There is no ViewData item of type
'IEnumerable' that has
the key 'IDJefe'.
| Help me create a dropdownlist of all Jefes in my database! | CC BY-SA 2.5 | null | 2010-07-28T16:45:28.417 | 2010-07-28T17:00:56.113 | null | null | 112,355 | [
"c#",
"asp.net-mvc-2",
"drop-down-menu"
] |
3,356,338 | 1 | null | null | 0 | 551 | I have a table with one TR and two TDs, one of the TDs has more content (i mean with content: other sub tables) than the other one, this results the following:
the TD with the little content stay shrinked (its content stay as is, not expanded) and this happens in case of IE only, firefox and google chrome are fine, both of FF and chrome do expand the smaller TD content to fill 100% of that TD's height, my question is how to expand the content of the smaller TD to fill 100% of its height ?
p.s. I tried height: 100%; on the smaller TD but didn't work ...and this is a dynamic code, means that both TDs are changable with their content according to some criteria ...
look at both screenshots:


thanks so much in advance!
| how to expand content for a TD to cover 100% of its height (IE) | CC BY-SA 2.5 | null | 2010-07-28T18:54:53.133 | 2011-04-08T05:50:26.710 | 2017-02-08T14:29:20.230 | -1 | 359,687 | [
"html",
"css"
] |
3,357,850 | 1 | 3,357,864 | null | 16 | 7,212 | I'm working on a web application that is using Forms authentication.
```
<authentication mode="Forms">
<forms slidingExpiration="true"
loginUrl="~/User.aspx/LogOn"
timeout="15"
name="authToken" />
</authentication>
```
I'm seeing this cookie set in my browser when I log in:

The question is what happens when I put this website in a load balanced model? Where is the ASP.net session cookie being set? I didn't explicitly do it in code, so I assume it's happening behind the scenes somewhere in ASP.Net.
Also, If the session cookie is set by web server A, I assume web server B won't recognize it and treat it as an invalid session. If this is the case, I probably don't want to use it, right?
| Does Forms Authentication work with Web Load Balancers? | CC BY-SA 2.5 | 0 | 2010-07-28T21:53:29.930 | 2015-11-10T10:35:56.990 | 2017-02-08T14:29:21.270 | -1 | 402,098 | [
"asp.net",
"cookies",
"session"
] |
3,358,188 | 1 | 3,358,419 | null | 1 | 2,396 | I have a tableview that is successfully incorporating an NSFetchedResultsController. However, I need the topmost cell in my tableview to read, "Add new object" and have UITableViewCellEditingStyleInsert instead of the default UITableViewCellEditingStyleDelete.
The FetchResultsController wants to check the managedObjectContext for objects--both to determine number of rows and to populate the table cells. The only way I can think to get around this is to create a dummy object, but I feel like there ought to be a more elegant solution.
## UPDATE:
For those who might be curious as to what solution I ended up with, I decided to have my insert cell at the bottom, not the top. Here is the relevant code:
```
- (void)viewDidLoad {
[super viewDidLoad];
// Uncomment the following line to preserve selection between presentations.
//self.clearsSelectionOnViewWillAppear = NO;
self.editing = YES;
self.tableView.allowsSelectionDuringEditing = YES;
self.tableView.delegate = self;
RubricAppDelegate *appDelegate = (RubricAppDelegate *)[[UIApplication sharedApplication] delegate];
managedObjectContext = [appDelegate managedObjectContext];
NSEntityDescription *entity = [NSEntityDescription entityForName:@"myClass" inManagedObjectContext:managedObjectContext];
NSFetchRequest *request = [[[NSFetchRequest alloc] init] autorelease];
[request setEntity:entity];
NSSortDescriptor *sortDescriptor = [[NSSortDescriptor alloc] initWithKey:@"classID" ascending:YES];
NSArray *sortDescriptors = [NSArray arrayWithObject:sortDescriptor];
[request setSortDescriptors:sortDescriptors];
[sortDescriptor release];
fetchedResultsController = [[NSFetchedResultsController alloc]
initWithFetchRequest:request
managedObjectContext:self.managedObjectContext
sectionNameKeyPath:nil cacheName:nil];
NSError *error;
[fetchedResultsController performFetch:&error];
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
NSLog(@"Number of sections = %d", [[fetchedResultsController sections] count]);
return 1;
}
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
// Return the number of rows in the section.
id <NSFetchedResultsSectionInfo> myClass = [[fetchedResultsController sections] objectAtIndex:section];
NSLog(@"Number of classes = %d", [myClass numberOfObjects]);
return ([[fetchedResultsController fetchedObjects] count] + 1);
}
// Customize the appearance of table view cells.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
static NSString *CellIdentifier = @"Cell";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
}
NSLog(@"FRC count + 1 = %d", ([[fetchedResultsController fetchedObjects] count] + 1));
if (indexPath.row == ([[fetchedResultsController fetchedObjects] count])) {
cell.textLabel.text = @"Add New Class";
}
else {
myClass *theClass = [fetchedResultsController objectAtIndexPath:indexPath];
NSLog(@"Class name is: %@", theClass.classTitle);
cell.textLabel.text = theClass.classTitle;
}
return cell;
}
- (UITableViewCellEditingStyle)tableView:(UITableView *)tableView editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath
{
if (indexPath.row == [[fetchedResultsController fetchedObjects] count]) {
return UITableViewCellEditingStyleInsert;
}
return UITableViewCellEditingStyleDelete;
}
```
The result (with some junk data):

Now my only issue is getting the delete functions to work properly. You can follow my post on that issue [here](https://stackoverflow.com/questions/3368087/nsfetchedresultschangedelete-not-being-triggered)
| How can I insert new objects at top of UITableView backed by Core Data/NSFetchedResultsController? | CC BY-SA 2.5 | 0 | 2010-07-28T22:52:57.390 | 2010-08-02T18:24:29.327 | 2017-05-23T12:33:39.247 | -1 | 404,767 | [
"core-data",
"uitableview"
] |
3,358,379 | 1 | 3,367,873 | null | 0 | 103 | I have a list of textual descriptions, each of which a user must score on a scale of 1-5. The number of textual descriptions is variable, so I can't just define a static Grid in XAML.
The following image shows approximately what I'm after:

In ASP.NET, I could bind my list of text items to a Repeater control. For each row, the text would be displayed in a Label, and next to it would be a DropDownList that contains a static list of items. Is there a similar control available in Silverlight?
Should I be using one of these?
- - - -
| Display a variable-sized collection of TextBlocks/ComboBoxes in Silverlight 3 | CC BY-SA 2.5 | null | 2010-07-28T23:30:38.893 | 2010-07-31T11:10:44.560 | 2010-07-31T11:10:44.560 | 17,516 | 731 | [
"silverlight",
"silverlight-3.0"
] |
3,359,676 | 1 | 3,359,701 | null | 0 | 1,598 | I am sending an object that i generated within a class from the server as a result of web service call.
[](https://i.stack.imgur.com/iaUGU.png)
it is returning with __type and it's other attributes from server.

I want to add some function to this object to call from everywhere easly in my files.
How can i achieve this?
Thanks...
| how can i add a function to json object which has __type attribute? | CC BY-SA 4.0 | null | 2010-07-29T05:22:59.707 | 2019-08-04T11:04:11.623 | 2019-08-04T11:04:11.623 | 4,751,173 | 104,085 | [
"javascript",
"jquery",
"function"
] |
3,359,910 | 1 | 3,367,701 | null | 1 | 508 | I following the book "DOM Scripting" by Jeremy Keith and I have hit a wall in trying to get a small image gallery to render correctly in Internet Explorer 6/7.
I have 4 thumbnails which load in a placeholder when clicked using the following code:
```
function showPic(whichpic) {
if (!document.getElementById("placeholder")) return true;
var source = whichpic.getAttribute("href");
var placeholder = document.getElementById("placeholder");
placeholder.setAttribute("src",source);
if (!document.getElementById("description")) return false;
var text = whichpic.getAttribute("title") ? whichpic.getAttribute("title") : "";
var description = document.getElementById("description");
if (description.firstChild.nodeType == 3) {
description.firstChild.nodeValue = text;
}
return false;
}
```
My placeholder is inserted into the page using `createElement("img")`, however when I click a thumbnail the image is compressed to the size of the placeholder that it replaced.
```
function preparePlaceholder() {
if(!document.createElement) return false;
if(!document.createTextNode) return false;
if(!document.getElementById) return false;
if(!document.getElementById("imagegallery")) return false;
var placeholder = document.createElement("img");
placeholder.setAttribute("id","placeholder");
placeholder.setAttribute("src","images/placeholder.gif");
placeholder.setAttribute("alt","Gallery Placeholder");
var description = document.createElement("p");
description.setAttribute("id","description");
var desctext = document.createTextNode("Choose an image");
description.appendChild(desctext);
var gallery = document.getElementById("imagegallery");
insertAfter(placeholder,gallery);
insertAfter(description,placeholder);
}
```
So the result as pictured below is a skewed image:


Live site here: [http://anarchist.webuda.com/](http://anarchist.webuda.com/)
Javascript here: [http://pastebin.com/kaAhjdqk](http://pastebin.com/kaAhjdqk)
HTML here: [http://pastebin.com/Dm5p2Dj6](http://pastebin.com/Dm5p2Dj6)
CSS here: [http://pastebin.com/yiVPiQZe](http://pastebin.com/yiVPiQZe)
| Internet Explorer Javascript Image Problem | CC BY-SA 2.5 | null | 2010-07-29T06:17:59.520 | 2010-07-29T23:17:20.657 | 2010-07-29T22:50:39.687 | 196,834 | 196,834 | [
"javascript",
"internet-explorer",
"image"
] |
3,363,208 | 1 | 3,363,437 | null | 4 | 3,396 | For my own edification, I decided to test the comparative speeds of DataTable.ImportRow vs DataTable.Merge. I found that DataTable.ImportRow was largely slower than DataTable.Merge. On rare occasion, the two functions had an equal processing time. On even rarer occasions, ImportRow was faster than Merge.
Below are my testing results and code.
1. Why is ImportRow slower than Merge?
2. What makes Merge faster?

```
DataTable dt = new DataTable();
dt.Columns.Add("customerId", typeof(int));
dt.Columns.Add("username", typeof(string));
for (int i = 0; i <= 100000; i++)
{
DataRow myNewRow;
myNewRow = dt.NewRow();
myNewRow["customerId"] = 1;
myNewRow["username"] = "johndoe";
dt.Rows.Add(myNewRow);
}
// First Duration
DateTime startTime1 = DateTime.Now;
DataTable dt2 = new DataTable();
dt2 = dt.Clone();
for (int i = 0; i < dt.Rows.Count; i++)
dt2.ImportRow(dt.Rows[i]);
DateTime stopTime1 = DateTime.Now;
// End First Duration
TimeSpan duration1 = stopTime1 - startTime1;
// Second Duration
DateTime startTime2 = DateTime.Now;
DataTable dt3 = new DataTable();
dt3 = dt.Clone();
dt3.Merge(dt);
DateTime stopTime2 = DateTime.Now;
// End Second Duration
TimeSpan duration2 = stopTime2 - startTime2;
```
```
DataTable dt = new DataTable();
dt.Columns.Add("customerId", typeof(int));
dt.Columns.Add("username", typeof(string));
DataColumn[] key = new DataColumn[1];
key[0] = dt.Columns[0];
dt.PrimaryKey = key;
for (int i = 0; i <= 100000; i++)
{
DataRow myNewRow;
myNewRow = dt.NewRow();
myNewRow["customerId"] = i;
myNewRow["username"] = "johndoe";
dt.Rows.Add(myNewRow);
}
// First Duration
//DateTime startTime1 = DateTime.Now;
Stopwatch sw1 = new Stopwatch();
sw1.Start();
DataTable dt2 = new DataTable();
dt2 = dt.Clone();
for (int i = 0; i < dt.Rows.Count; i++)
dt2.ImportRow(dt.Rows[i]);
//DateTime stopTime1 = DateTime.Now;
sw1.Stop();
// End First Duration
TimeSpan duration1 = sw1.Elapsed;
// Second Duration
//DateTime startTime2 = DateTime.Now;
Stopwatch sw2 = new Stopwatch();
sw2.Start();
DataTable dt3 = new DataTable();
dt3 = dt.Clone();
dt3.Merge(dt);
sw2.Stop();
//DateTime stopTime2 = DateTime.Now;
// End Second Duration
TimeSpan duration2 = sw2.Elapsed;
label3.Text = duration1.Milliseconds.ToString();
label4.Text = duration2.Milliseconds.ToString();
```

| ImportRow vs Merge Speed Question | CC BY-SA 2.5 | null | 2010-07-29T13:53:07.117 | 2010-07-29T14:43:33.303 | 2010-07-29T14:43:33.303 | null | null | [
"c#",
"merge",
"datatable"
] |
3,365,119 | 1 | 3,366,139 | null | 3 | 1,755 | I have setup a UITableView (320 wide) with a UITableViewCell created in IB, the cell is also 320 wide. After setting a background image (320 wide) in UITableViewCell (or my subclass to be correct) I have noticed that the cells fall short of the right hand side of the UI (notice the blue on the selected cell and the grey on the one above) Does anyone know what is causing this?

Cheers Gary
| UITableViewCell strange width? | CC BY-SA 2.5 | 0 | 2010-07-29T16:59:39.033 | 2010-07-29T20:38:31.227 | 2017-02-08T14:29:22.620 | -1 | 164,216 | [
"iphone",
"objective-c",
"cocoa-touch"
] |
3,367,897 | 1 | 3,367,967 | null | 3 | 140 | I am trying to remove a massive amount of cruft from a .NET 3.5, VS2008 project and I am somewhat confused as to what gets compiled into an EXE and what isn't.
So for instance, if I double click on my Resources.Resx file, i get the following:

As you can see it states that this bitmap is "Linked at compile time". However, when I go to the path of the file in the Solution Explorer, it says that the Build Action is set to None - thus, from what I understand, the bitmap won't be linked into the EXE.

But at the same time, there is an entry in the Resources.resx. Anyway, I am confused. Would appreciate some clarity on the topic.
| Confused about resources in a .NET project | CC BY-SA 2.5 | null | 2010-07-30T00:05:59.507 | 2010-07-30T00:32:17.680 | null | null | 9,382 | [
"c#",
"visual-studio-2008",
".net-3.5",
"resources"
] |
3,370,342 | 1 | 3,370,350 | null | 1 | 247 | We're having a problem with a side pane that is floated to the right. This pane somehow resizes the first div in the main content, so the div is stretched to the same height as the pane, see illustration below.
The main div has the following css
```
margin: 10px 280px 0 10px;
padding-right: 50px;
```
The side pane has the following css
```
float: right;
width: 270px;
margin: 10px 10px 0 0;
```
What would make this happen? How can I fix it?
This error occurs in Firefox 3.6

| CSS float bug with side pane resizing main content | CC BY-SA 2.5 | null | 2010-07-30T09:47:21.680 | 2012-07-06T12:50:35.047 | 2017-02-08T14:29:25.030 | -1 | 138,023 | [
"html",
"css",
"css-float"
] |
3,371,619 | 1 | 3,473,863 | null | 5 | 5,569 | We have a general organizational table structure, think of it s a Tree or Pyramid Hierarchy. We basically have multiple "trees" we want to show. On for one company, one for another ETC.
Does anyone know of a good way to display this data? SQL Query would be nice, doubt it would be possible, but I wouldn't be against using some OTS tool (preferably free). I would also like to avoid some type of report. I don't need an actual solution just need to know . So if you say SQL if you can give me a 2 table example of showing a root a leave I would be happy.
Structure is pretty general

And each table is linked through a surrogate key CompanyID, CompanyGroupID, etc.
Any suggestions on ways we could display/query for this data? Last resort is to write a quick C# Windows Application...
We would like to see it in tree form:
```
-- 1-Company
-- / \
-- CompanyGroupA CompanyGroupB
-- / \ \
-- CompanyStoreA1 CompanyStoreA1 CompanyStoreB
-- / \ / \
--Employee A B C
```
In attempt to please the masses here is an example test script to populate the query.
```
DECLARE @Company table (id int, name varchar(40) )
INSERT @Company VALUES (1,'Living Things' )
INSERT @Company VALUES (2,'Boring Company' )
DECLARE @CompanyGroup table (id int, name varchar(40), CompanyID int)
INSERT @CompanyGroup VALUES (1,'Pets',1 )
INSERT @CompanyGroup VALUES (2,'Humans',1 )
INSERT @CompanyGroup VALUES (3,'Electronics',2 )
INSERT @CompanyGroup VALUES (4,'Food',2 )
DECLARE @CompanyStore table (id int, name varchar(40), CompanyGroupID int)
INSERT @CompanyStore VALUES (1,'PetsStoreA',1 )
INSERT @CompanyStore VALUES (2,'PetsStoreB',1 )
INSERT @CompanyStore VALUES (3,'PetsStoreC',1 )
INSERT @CompanyStore VALUES (4,'PetsStoreD', 1)
INSERT @CompanyStore VALUES (5,'HumansStore',2 )
INSERT @CompanyStore VALUES (6,'FoodStore',3 )
```
The final solution was pretty awesome I modified the usp_DrawTree to accept varchar vs ints because i had to make my query ids unique. I then just did a select/union all and built the parent child relationship.
```
select * into #TreeData from (
select ID='C' + cast(id as varchar(10)),
ParentID=null,
DataForBox=name + '(' + cast(id as varchar(10)) + ')',
ExtraInfo='',
SortColumn=name
from Company c
)
union all (
select ID='CG' + cast(id as varchar(10)),
ParentID=cg.CompanyID ,
DataForBox=name + '(' + cast(id as varchar(10)) + ')',
ExtraInfo='',
SortColumn=name
from CompanyGroup cg join Company c on c.ID=cg.CompanyID
)
//union all rest of hierarchy
)
```
| SQL Server Query or Tool to show Hierarchical Data | CC BY-SA 2.5 | 0 | 2010-07-30T12:59:45.700 | 2019-08-06T03:08:27.590 | 2017-02-08T14:29:25.733 | -1 | 256,793 | [
"sql-server-2008",
"hierarchical-data"
] |
3,372,804 | 1 | 3,398,765 | null | 1 | 309 | I am having a problem identifying a label on a jQuery generated page.
This is the code of the page (as seen in firebug).

I am trying to find it using this statement,
```
assert(browser.label(:id, "acms-ws-select-label").exists?)
```
Put it fails to find the label. Any ideas on what I am doing wrong?
Update: running the same script in IE with Watir, seems to find the element.
| Trouble find elements with fireWatir on a JQuery created page | CC BY-SA 2.5 | null | 2010-07-30T15:11:13.967 | 2010-08-03T16:50:00.020 | 2017-02-08T14:29:26.080 | -1 | 96,534 | [
"jquery",
"firefox",
"watir",
"firewatir"
] |
3,372,889 | 1 | 3,902,447 | null | 0 | 2,274 | I'm having a problem with overflow and width in Google Chrome/Webkit. This is a follow-up question on [this question](https://stackoverflow.com/questions/3370342/css-float-bug-with-side-pane-resizing-main-content/), there you will find the CSS. I need to have `visibility: hidden` to fix the problem in the first question.
The problem is visible in the screenshots below.
Why does this attribute affect the width in Webkit? Can I solve this without nasty hacks? Or can I re-think my strategy for the right pane?
Main div with `overflow: visible`. The div is stretched to the right pane, as it should be.

Main div with `overflow: hidden`. The right pane is now affecting the main div's width.

| WebKit and overflow: hidden affecting width | CC BY-SA 2.5 | null | 2010-07-30T15:20:05.770 | 2012-03-25T19:44:44.853 | 2017-05-23T12:01:33.300 | -1 | 138,023 | [
"css",
"webkit",
"width",
"overflow",
"column-width"
] |
3,373,544 | 1 | null | null | 2 | 1,165 | I have an existing database containing an article and a blog table. These have common columns such as title, author repeated in the two tables. I want to utilise entity framework to create a Content entity that pulls in the common properties so i can inherit the Content entity in the Article and Blog entity.
The idea being that I can say ok just get me all the content on the site in the last 10 days, i dont care whether its a blog or article. Then when i need to actually fetch an article ill go get the specific entity.
I have set up a content entity base and pulled in all the common blog and goal properties. Problem is what im trying to say in Contents. Ive got TWO mappings one to blog table and one to article table and EF complains that it cant work out which one to goto. I was hoping to add conditions to do this but if i add a blog specific condition (thats not listed in my base class) it complains it cant find the mapping.
I spose my first question is am I looking at this totally backwards in order to make my Contents entity get data from article table and blog table?
Thanks
Phil
Edit : Adding model and db schemas


| Inheritance in entity framework - Table per concrete class? | CC BY-SA 2.5 | null | 2010-07-30T16:38:20.637 | 2012-10-27T00:15:52.120 | 2017-02-08T14:29:27.457 | -1 | 406,922 | [
"c#",
"entity-framework-4"
] |
3,373,636 | 1 | 3,374,381 | null | 7 | 12,755 | I learn about HTTP and need some examples of HTTP PUT method structure, something like this one for HTTP POST method

Can you tell me some, thanks!
| HTTP PUT method structure example | CC BY-SA 2.5 | 0 | 2010-07-30T16:48:57.687 | 2010-07-30T18:31:31.867 | 2017-02-08T14:29:27.813 | -1 | 399,104 | [
"http"
] |
3,374,523 | 1 | 3,374,994 | null | 0 | 266 | When I put an image inline in a table cell, like this:
```
<table border="1" cellspacing="5" cellpadding="5">
<tr>
<td>
<img width="20" height="20">Text
</td>
<td>
Text
</td>
</tr>
</table>
```
…it shifts the vertical alignment of the text in that cell, like this:

I've played around with `vertical-align`, but haven't been able to align the in the two cells. What's the right way to do that?
| Vertical text alignment alongside images | CC BY-SA 2.5 | null | 2010-07-30T18:56:28.647 | 2017-01-17T12:51:53.563 | 2017-01-17T12:51:53.563 | 4,370,109 | 84,745 | [
"html",
"css",
"html-table",
"alignment"
] |
3,377,720 | 1 | null | null | 184 | 220,479 | I'm working on a [ColdFusion](http://en.wikipedia.org/wiki/ColdFusion) project for a while now, and Visual Studio started to behave strange for me at least.
I observed that when I started debugging, it built the project, it started the deploy, and the deploy finished and it was starting to load symbols for my project.
But it was very slow, and I don't know why it started to do this step. What may I have done?
Is this symbol loading step necessary? How can I disable it?
In the Tools -> Options -> Debugging -> Symbols dialog there is no Symbol file (.pdb) location added. And I pointed in my project's debug directory at the field below, and I checked the "Search the above directory only when symbols are ...." checkbox. How should I set up this dialog to turn off symbol loading?
I looked in the Modules window which symbols are loaded, but it says nothing to me. What is the problem?

| Visual Studio loading symbols | CC BY-SA 3.0 | 0 | 2010-07-31T10:34:06.303 | 2021-09-04T20:42:17.493 | 2013-04-17T18:03:23.837 | 664,177 | 287,067 | [
"visual-studio",
"debugging",
"debug-symbols"
] |
3,378,197 | 1 | null | null | 6 | 2,030 | I am developing a small app that display the active mounts in a menu in the NSStatusBar. So far it looks like this:

I want to add an eject button to the right of each menu item (like the left bar in the Finder). I know that I have to create a custom view and set it with the setView: method. The problem is that I am very new to Cocoa and right now I don't know how to dive into the custom view topic. Actually, I programmed a lot but never worked with interfaces so far :). Does anyone of you have a good tutorial for adding a custom view to a NSMenuItem?
I think this app will be very handy because you can hide the mounted icons from your desktop. The problem is that you always have to go back to the finder to unmount a volume...
Thanks for any help or tips you have!
| Cocoa custom view for NSMenuItem | CC BY-SA 4.0 | null | 2010-07-31T13:00:59.120 | 2018-08-03T19:44:56.140 | 2018-08-03T19:44:56.140 | 1,265,393 | null | [
"cocoa",
"nsview",
"nsmenuitem"
] |
3,379,081 | 1 | null | null | 0 | 398 | I'm using Chrome-compatible [SRWare Iron](http://www.srware.net/en/software_srware_iron.php) 5.0.381 on XP, and was checking out what Chrome has to offer to developers, EG inspecting the contents of the DOM of a currently-loaded web page.
But when I hit , the bar is totally empty:

Does someone why this is? Do I need an add-on? Are there other Chrome-compatible tools I should know about?
| Why is Dev Tools bar empty? | CC BY-SA 3.0 | null | 2010-07-31T17:21:32.687 | 2013-05-29T13:19:56.033 | 2013-05-29T13:19:56.033 | 331,508 | 1,196,889 | [
"google-chrome",
"chromium",
"srware-iron"
] |
3,379,994 | 1 | 3,380,076 | null | 4 | 2,396 |


---
I guess it might have something to do with dividing the box in units styled with float:left, and each unit would have a border if on a boxes border.
Help would be very appreciated =)
| Any ideas on how I could implement a grid-view in CSS? - CSS | CC BY-SA 2.5 | 0 | 2010-07-31T22:19:04.670 | 2010-07-31T22:46:53.930 | null | null | 208,827 | [
"html",
"css",
"gridview",
"datagrid"
] |
3,380,561 | 1 | 3,380,607 | null | 2 | 109 | I have a Sql Server 2005 table with following data:

idHearing is the primary key (identity), idCase is a foreign key that may duplicate. StartDate and StartTime specify the date and time of the event - both fields are of DateTime type (for whatever reason these are separate fields). All StartDate data has a time of 12:00:00. All StartTime data has a date of 1/1/1900. IsScheduled and IsOnCalendar are bit fields.
My challenge is to select the latest (in terms of Date/Time) hearing for each idCase. If the StartDate/StartTime are identical (as is in the rows 1 and 2), preference should be given to a row which has IsScheduled and/or IsCalendar on. If those are columns are same as well, then it does not matter which row gets returned.
To make this more complicated, I must do it all in single SELECT statement (because it must be in a view) and I have to return all the columns that you see below.
I've tried several ways, but my SQL-FU isn't strong. Any ideas?
| How to perform a select in a single statement? | CC BY-SA 2.5 | null | 2010-08-01T02:54:05.397 | 2010-08-01T03:26:09.077 | 2010-08-01T03:15:37.933 | 135,152 | 9,382 | [
"sql",
"sql-server",
"sql-server-2005",
"tsql",
"view"
] |
3,381,817 | 1 | 3,381,824 | null | 30 | 70,146 | I need to develop a program in Java to solve some integrals. Integrals like this:

I've looked for some functions to do this, in java.Math but I didn't find anything.
Has anyone an idea to get a solution for this? (Maybe some extra libraries or something like that).
| Solve an Integral in Java | CC BY-SA 4.0 | 0 | 2010-08-01T11:24:09.720 | 2020-01-03T22:13:47.700 | 2020-01-03T22:13:47.700 | 6,461,462 | 333,348 | [
"java",
"math"
] |
3,382,290 | 1 | 3,382,333 | null | 3 | 4,091 | I'm using vhochstein's fork of active_scaffold, which runs quite nicely on rails 3, except for a few small bugs - [http://github.com/vhochstein/active_scaffold](http://github.com/vhochstein/active_scaffold).
In rails 2.3, the following code disables a link:
```
return "<a class='disabled'>#{text}</a>" unless authorized
```
But in Rails 3, it causes the escaped html tags to be printed out instead as in the following photo:

How can I make the content of this return statement render the way it should in rails 3?
The code above, is from the `list_column_helpers.rb` file in vendor/plugins/active_scaffold/helpers/
UPDATE:
Floatless fixed this by suggesting to add `.html_safe` to the code.
I have since found that the folowing change also needs to be made as there's more than one bit of code that is respondible for disabling action links in active_Scaffold:
In /plugins/active_scaffold/frontends/default/views/_list_actions.html.erb change:
```
<%= record.authorized_for?(:crud_type => etc etc etc -%>
By making it use "raw"
i.e.
<%= raw record.authorized_for?(:crud_type => etc etc etc -%>
```
Anyway, thanks to floatless and hopefully mr hochstein will be able to use this stuff.
| rails 3 is printing html tags to screen instead of rendering them | CC BY-SA 2.5 | null | 2010-08-01T14:00:36.263 | 2012-05-31T09:46:29.920 | 2017-02-08T14:29:29.537 | -1 | 227,863 | [
"ruby-on-rails",
"activescaffold",
"ruby-on-rails-3"
] |
3,384,030 | 1 | null | null | 1 | 283 | i have a listview with a bunch of items in it, each item has its own background, the problem is that if i only have one item in a list, the rest of the "empty" slots of the list is black. I tried applying a background around the listview and also on the view that sorrounds it (relativeView) and i get a strange margin around the whole list like the picture at the bottom. The question i have is, how can i remove the actual "borders" around the list so it still fills upp its parent ? .

| backgrounds in listview | CC BY-SA 2.5 | 0 | 2010-08-01T22:44:28.777 | 2013-04-18T09:32:41.590 | 2017-02-08T14:29:29.877 | -1 | 267,822 | [
"android",
"android-listview"
] |
3,384,046 | 1 | 3,385,124 | null | 7 | 132 | I have an element that contains two span tags that each contain some text. The container element sets a font size, then the font size on the second span tag is set to a lower size. When the second span is reduced in font size, the space between the line and the next block element is increased. This occurs in both WebKit and Gecko.
The `p` container element has `{ margin-bottom: 0; padding-bottom: 10px; }` and its following sibling has `{ margin-top: -5px; }`
The following image illustrates the situation and contains a snapshot of the relevant part of the document structure in FireBug.

Why is the spacing beneath the p tag increasing after reducing the font size of the second span tag?
| CSS: Why does reducing the font size of an adjacent inline element increase the overall leading? | CC BY-SA 2.5 | 0 | 2010-08-01T22:51:45.377 | 2010-08-02T05:02:35.297 | 2017-02-08T14:29:30.213 | -1 | 98,389 | [
"css"
] |
3,384,119 | 1 | 3,393,572 | null | 2 | 9,430 | I've searched similar topics but haven't found what I need..
I extended Users model with UserAttributes model, some additional fields added and etc.. now I'm trying to make ModelForm out this.. so I have a little problem in here..
I WANT TO list groups as a ChoiceField not a MultipleChoiceField.. It's a requirement by specification so it must be so.
so here's the code..
```
from django.forms import ModelForm
from django.contrib.auth.models import User
from helpdesk.models.userattributes import *
from django.utils.translation import ugettext as _
class SettingsOperatorsForm(ModelForm):
groups = forms.ChoiceField(
label=_(u'Rights'),
required=True,
choices=["what's in here?"]
)
class Meta:
model = UserAttributes
fields = ('first_name', 'last_name', 'job_title', 'email', 'password', 'is_active', 'groups' )
```
there's auth_group table in database, so i tried to make it like this , but I've got a no form displayed at all:
```
from django.contrib.auth.models import User, Group
groups = forms.ChoiceField(
label=_(u'Rights'),
required=True,
choices=Group.objects.all()
)
```
I think it's better would be just to convert multipleChoiceField to ChoiceField
in plain talk:

should become just SELECT box.
| Django users: get list of group, or how to convert MultipleChoiceField to ChoiceField | CC BY-SA 2.5 | null | 2010-08-01T23:15:41.990 | 2010-08-03T12:11:56.003 | 2010-08-02T01:08:15.320 | 310,662 | 310,662 | [
"python",
"django"
] |
3,384,507 | 1 | 3,384,636 | null | 4 | 22,422 | I'm trying to add a control(Label) inside of a panel.
Please see the code:
```
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace AddControlProgramatically
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
Label lbl = new Label();
for (int x = 0; x <= 3; x++)
{
//create new label location after each loop
//by multiplying the new value of variable x by 5, so the new label
//control will not overlap each other.
lbl.Location = new System.Drawing.Point(52 + (x * 5), 58 + (x * 5));
//create new id and text of the label
lbl.Name = "label_" + x.ToString();
lbl.Text = "Label " + x.ToString();
this.panel1.Controls.Add(lbl);
}
}
}
}
```

Here's the form. What I'm trying to accomplish is to programatically generate 3 diffent control labels. But as you can see, It only displays the last one. Please help me regarding this. I know there's something wrong in my code (cause it's not working).Thanks...
| How to add a control to a Form programmatically? | CC BY-SA 3.0 | 0 | 2010-08-02T01:40:08.643 | 2019-06-24T00:53:53.720 | 2013-02-04T11:46:55.043 | 124,119 | 396,335 | [
"winforms",
"c#-3.0"
] |
3,384,516 | 1 | 3,385,207 | null | 1 | 792 | I have started working on what I expect to become, by far, the largest project I’ve ever done, and I’ve come to the conclusion that I really need to start using some kind of version control beyond my current dated zip files and a txt file of comments. I’ve looked into a number of different options but I’m just not finding anything that I feel is a fit for me.
One of my big complaints is the total lack of a quality GUI in any of the available options, TortoiseSVN seems to be the best of what’s out there, and is still terribly unintuitive (I have nothing against FOSS, but this does seem to be a common problem among OSS projects). Reading the guides and manuals for SVN and other version control systems feels to have a complexity level akin to learning a new programming language.
I’m a solo developer, so I require very limited (if any) merge support and branching capabilities, no real need for multi-user systems, I have no need for distributed repositories. Basically what I would like is something akin to an automation of my zipping process with organizational support, commenting and basic diff options.
I have been toying with the idea of rolling my own program to fit my needs, to those ends I tossed together a very basic GUI mock-up to figure out what it would look like. Please ignore any spelling and organization/logic mistakes.
Please see mock-up here:

This is little more then a "napkin sketch" really. The way I envision functionality is that you would drag a version out of the tree and drop it where you wanted it. It would create a directory containing that version of your project. There would be a hidden file with in the directory that would contain the version information. When you wanted to create a new version, you would drag and drop that folder into the tree view. If you were working with a Version that was not the most current it would create a branch. It would check for file changes/moves/renames and prompt for general version, and specific file comments.
My Question here is multifold. Is there anything out there similar to what I’m looking for? (I’m open to reasonably priced non-free options).
If not, would there be any call for this kind of a program in the programming community at large that would make it worthwhile to polish the program as an end user product?
-- I know what you mean here; I would consider multi-user support as something I would be adding to the system in a later version, and would plan accordingly. As for merge support, I would never work with more than a small team on any of my projects and thus would have no need for anything more than the basic merge support. -- I guess it would have been more clear to say that I disagree with the concepts behind Distributed Repositories and simply would not use them. I’m not arguing the need and usefulness of these features in a large business project, or in a large FOSS project – but I wouldn’t use Oracle to keep track of my friend’s phone numbers. While a custom GUI is a good suggestion, it really isn’t a project for me. IMHO it exemplifies what I see as the primary problem in the development of OSS systems such as SVN, being built from various components wrapped around and built on top of one another leads to a highly unintuitive system (in general, not just the GUI) with no clear design or focus.
| Simple GUI Revision Control | CC BY-SA 3.0 | 0 | 2010-08-02T01:43:54.393 | 2013-04-18T09:52:46.133 | 2013-04-18T09:52:46.133 | 664,177 | 408,235 | [
"version-control"
] |
3,387,101 | 1 | 3,387,172 | null | 2 | 4,151 | I have a html tag with inline CSS style like: `<body><div style="position:absolute;top:100px;"></body>` and I want to override this inline position property. So, I wrote a CSS rule like this:
`body > div[style]{position:relative !important;top:0px !important;}`
The above code works in Firefox. But in IE7 it does not work. Am I missing anything for IE?
PS: Even though I could see my overridden attributes in Firebug lite window, it's not affecting anything on my page. (Plz refer the [attached image](https://i187.photobucket.com/albums/x201/talktoveera/inline.png)).

| Overriding inline CSS styles in IE7 | CC BY-SA 2.5 | null | 2010-08-02T11:05:07.697 | 2010-08-02T11:28:15.293 | 2017-02-08T14:29:31.233 | -1 | 42,372 | [
"html",
"css",
"inline-styles"
] |
3,388,598 | 1 | 3,388,666 | null | 1 | 219 | does anyone know what component this app is using???

I know it use uipagecontrol to control the page
but i don't know what they use to control the button
| need help with iphone movable button? | CC BY-SA 3.0 | null | 2010-08-02T14:16:13.537 | 2011-07-26T15:44:55.330 | 2011-07-26T15:44:55.330 | null | 408,721 | [
"iphone",
"user-interface"
] |
3,389,764 | 1 | null | null | 1 | 192 | I have a Article and Blog tables that I want to represent as a Content Entity. I have mapped both tables to the Content entity however when I query using a ObjectSet.Take(20) only the article table is being hit in the dbase. Am i wrong in thinking (hoping) the query should look where contentType = 1 and 2?
Ta
SQL query looks like this...
```
SELECT
[Extent1].[RhythmyxContentId] AS [RhythmyxContentId],
[Extent1].[PublishDate] AS [PublishDate],
[Extent1].[Title] AS [Title],
[Extent1].[Promo] AS [Promo],
[Extent1].[AuthorUid] AS [AuthorUid],
[Extent1].[Body] AS [Body],
[Extent1].[IsDeleted] AS [IsDeleted],
[Extent1].[IsLive] AS [IsLive],
[Extent1].[UpdateDate] AS [UpdateDate],
[Extent1].[CreatedDate] AS [CreatedDate],
[Extent1].[Slug] AS [Slug],
[Extent1].[ContentCategoryId] AS [ContentCategoryId]
FROM [dbo].[tArticle] AS [Extent1]
WHERE [Extent1].[ContentType] = CAST( '1' AS int)
```
Heres the entity...

| Entity Framework Multiple Table to Single Entity isnt querying both tables | CC BY-SA 2.5 | 0 | 2010-08-02T16:35:00.530 | 2012-01-13T10:34:07.867 | 2017-02-08T14:29:31.577 | -1 | 406,922 | [
"c#",
"entity-framework"
] |
3,389,938 | 1 | 3,393,063 | null | 27 | 17,446 | I'm using the `TabControl` class in WPF and I've noticed that the content of each `TabItem` has a default margin of 4 pixels on all sides.
Sample code:
```
<Window x:Class="TabControlPadding.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Window1" Height="300" Width="300">
<Grid>
<TabControl Margin="10">
<TabItem Header="Tab 1">
<Grid Background="Pink"/>
</TabItem>
<TabItem Header="Tab 2">
<Grid Background="LightBlue"/>
</TabItem>
</TabControl>
</Grid>
</Window>
```
Screenshot:

I'd like to get rid of this margin (reduce it to zero), but or anything heavy like that.
Is there a simple way I can do this in a very targeted manner?
| How to remove the default margin on the content of a TabItem? | CC BY-SA 3.0 | 0 | 2010-08-02T16:53:21.523 | 2013-04-27T23:57:59.590 | 2013-02-11T13:18:55.853 | 8,705 | 8,705 | [
"wpf",
"tabcontrol",
"margin",
"tabitem"
] |
3,389,981 | 1 | 3,390,197 | null | 1 | 82 | I'm currently working on a website, and when I test the website locally, everything looks fine, but when I test the website over an RDP connection to the the styles handling is all jacked around. The fonts are all fixed height, the browser settings haven't changed, I just refreshed the page after I reconnected over RDP.
:

(to the same machine, same browser, same session, just refreshed):

This isn't the only example, this is a site-wide issue. I can, of course, go through and try to shoehorn everything to work a little better over an RDP connection, in most instances, I'm just hoping there's a less time-consuming fix.
| Looking for a way to disable special handling of CSS on IE8 over an RDP connection? | CC BY-SA 2.5 | null | 2010-08-02T16:58:23.387 | 2010-08-02T17:25:25.027 | null | null | 135,786 | [
"html",
"internet-explorer-8",
"remote-desktop"
] |
3,390,255 | 1 | 3,398,627 | null | 0 | 2,939 | I have a Telerik RadGrid on my aspx web page. I notice that when I run my web application I get an extra space at the end as the below picture illustrates. I'm not sure why this shows up, I checked the markup and there is no extra column, hidden or otherwise, after the last column with the Drop link. I also looked at the RadGrid properties and there's nothing there that seems to indicate that there's anything additional that is being rendered. That extra space does not show up in the visual designer, so I'm not sure what is causing it. Any help is appreciated.

Markup for the RadGrid is shown below:
```
<telerik:RadGrid ID="RadGrid1" runat="server" DataSourceID="SqlDataSource1" OnItemCreated="RadGrid1_ItemCreated"
OnDeleteCommand="RadGrid1_DeleteCommand" GridLines="None" AllowSorting="True"
Skin="Web20" PageSize="20" FooterStyle-Wrap="false" >
<MasterTableView EditFormSettings-PopUpSettings-Modal="True" EditMode="PopUp" DataSourceID="SqlDataSource1"
AutoGenerateColumns="False" DataKeyNames="ID" ShowFooter="True" AllowPaging="True">
<Columns>
<telerik:GridBoundColumn DataField="Date Submitted" DataType="System.DateTime" HeaderText="Date Submitted"
ReadOnly="True" SortExpression="Date Submitted" UniqueName="Date Submitted">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="ReqCategory" HeaderText="ReqCategory" SortExpression="ReqCategory"
UniqueName="ReqCategory" Visible="False">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Title" HeaderText="Title" SortExpression="Title"
UniqueName="Title">
</telerik:GridBoundColumn>
<%-- <telerik:GridBoundColumn DataField="Description" HeaderText="Description"
SortExpression="Description" UniqueName="Description">
</telerik:GridBoundColumn>--%>
<telerik:GridBoundColumn DataField="Owner" HeaderText="Owner" SortExpression="Owner"
UniqueName="Owner">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Requestor" HeaderText="Requestor" SortExpression="Requestor"
UniqueName="Requestor">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Status" HeaderText="Status" SortExpression="Status"
UniqueName="Status">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Requested Completion" HeaderText="Requested Completion"
SortExpression="Requested Completion" UniqueName="Requested Completion">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Estimated Completion" HeaderText="Estimated Completion"
SortExpression="Estimated Completion" UniqueName="Estimated Completion">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Ticket Submitted By" HeaderText="Ticket Submitted By"
SortExpression="Ticket Submitted By" UniqueName="Ticket Submitted By">
</telerik:GridBoundColumn>
<telerik:GridTemplateColumn HeaderText="View Ticket" UniqueName="TemplateViewColumn">
<ItemTemplate>
<asp:HyperLink ID="ViewLink" runat="server" Text="View"></asp:HyperLink>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderText="Edit Ticket" UniqueName="TemplateEditColumn">
<ItemTemplate>
<asp:HyperLink ID="EditLink" runat="server" Text="Edit"></asp:HyperLink>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridButtonColumn HeaderText="Drop Ticket" Text="Drop" CommandName="Delete"
UniqueName="Drop" ConfirmText="Are you sure you want to drop this ticket?" ConfirmTitle="Drop Ticket" ConfirmDialogType="RadWindow">
</telerik:GridButtonColumn>
</Columns>
<EditFormSettings>
<PopUpSettings Modal="True"></PopUpSettings>
</EditFormSettings>
</MasterTableView>
</telerik:RadGrid>
```
| Extra space at the end of a Telerik RadGrid | CC BY-SA 2.5 | null | 2010-08-02T17:33:14.420 | 2010-08-03T16:34:05.117 | 2017-02-08T14:29:31.917 | -1 | 94,541 | [
"asp.net",
"html",
"visual-studio",
"telerik"
] |
3,392,407 | 1 | 3,392,427 | null | 3 | 89 | 
How do I switch off this bottom bit? Can't seem to find it in the docs, can do just about everything else...
```
config.??? = false;
```
Answers on a postcard boys and girls.
:D
| How do I switch off this part of CK editor? | CC BY-SA 2.5 | null | 2010-08-02T22:52:10.950 | 2010-08-02T22:56:17.477 | 2010-08-02T22:55:13.140 | 339,850 | 269,404 | [
"javascript",
"jquery",
"richtextbox",
"ckeditor",
"config"
] |
3,393,918 | 1 | 3,394,241 | null | 9 | 10,604 | I am using a gallery layout in my application. It is working when the user moves the pictures in the gallery from left to right (it is infinite that means elements are repeated again). But when the user moves from right to left and reaches the first element, it doesn't. After then no elements are coming. But I want to repeat elements from this side also. Can you give me some suggestions?
```
Gallery g = (Gallery) findViewById(R.id.gallery);
g.setAdapter(new ImageAdapter(this));
g.setFocusable(true);
g.setSelection((int)(Integer.MAX_VALUE / 2) - (Integer.MAX_VALUE / 2)% mImageIds.length);
g.setOnItemClickListener(new OnItemClickListener() {
public void onItemClick(AdapterView<?> parent, View v, int position, long id)
{
try {
imageid=position;
((ImageView)findViewById(R.id.ImageViewlarge)).setImageResource(mImageIds[position]);
((TextView)findViewById(R.id.TextViewImageName)).setText(imgNames[position]);
mp = MediaPlayer.create(SeaSpell.this,audioTrack[position]);
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
});
}
```

How can I make my gallery view circular? I am able to do it from left to right infinitely, but when I drag from right to left it is showing the end point.
| How to implement an endless gallery in Android? | CC BY-SA 3.0 | 0 | 2010-08-03T05:59:00.450 | 2014-02-27T13:11:24.787 | 2013-01-11T13:38:16.937 | 368,354 | 254,790 | [
"android",
"gallery",
"adapter"
] |
3,394,289 | 1 | 3,395,484 | null | 47 | 8,886 | My team is currently thinking of moving our existing MDI-based application to a more modern, docking-based approach. We're still thinking, but we'd like to move it to something like VS2010's docking and visual look:

This has the following features:
- - - -
on either what library/ies I haven't found, or how to use the ones I have found to achieve something like this.
- [AutomatedQA's docking library](http://www.automatedqa.com/products/aqdocking/)
---
- - [end-of-lifed AutomatedQA's docking library](http://smartbear.com/forums/forum/post/?mode=singleThread&thread=3825fd1d-68b9-419f-b86a-bb43b4eaece0)- [They are now implementing it](http://community.devexpress.com/blogs/ctodx/archive/2011/04/26/sneak-peek-visual-studio-dock-style-for-vcl-docking-library-coming-in-v2011-1.aspx)
---
I've found the following libraries. Here's an overview:
## Inbuilt VCL docking
This allows forms to be docked on other forms or TWinControls, but appears to be quite basic. Forms drag using an XOR painted outline, which works very badly on Vista and Win7. There is a TTabDockSet control for tabbed docked forms, but I can't figure out how to control how the docked forms' titles render once docked. I think implementing docking side-by-side will have to be done manually, creating new docksite panels on the fly. The RAD Studio IDE's docking windows are a bit slicker than this (transparent rectangles when dragging a form, for example) which is odd, since I thought it used the VCL docking support.
## JVCL docking
This looks a bit more of a decent solution that the inbuilt VCL docking. It supports docking on any edge or the client, and shows an alphablended rectangle where the form will dock.

It appears to be quite buggy (dropping a second form on top of a first is allowed, but freezes the program) and has no inbuilt tabbed dock support or any kind of drop-location widget.
## LMD Docking Pack
This looks promising: while it doesn't seem to directly dock forms, it has docking panels and controls / frames are placed on that. Existing forms could be migrated to frames. It also has a docking widget and tabbed dock support.
However, the demo seems to be quite unreliable. I've got the latest evaluation version installed, and creating a new project with a dock site and several panels and pressing Run causes the following:

This is crashing in the form component streaming. Visually examining the DFM file doesn't show anything wrong, but there's an opaque binary blob for the layout information that may be causing it. This is not especially encouraging in an evaluation version.
## DevExpress ExpressDocking
I had high hopes for this: I've never used any DevExpress controls before but they have a good reputation. But their demo program was really disappointing:

The control is flickery and doesn't seem to theme well with Windows, even using the XP style. It does have tabbed docking but it uses an XOR-ed outline - something that doesn't work well on XP or Vista. It also does not have any sort of docking widget. Frankly, it looks like it hasn't been updated since the Windows XP days. [This is being improved](http://community.devexpress.com/blogs/ctodx/archive/2011/04/26/sneak-peek-visual-studio-dock-style-for-vcl-docking-library-coming-in-v2011-1.aspx).
## AutomatedQA / SmartBear docking library
This is the most promising of all the libraries so far.

I regularly use [AQTime](http://www.automatedqa.com/products/aqtime/), an excellent profiler which appears to be written using their own docking library, and it works well. However, the latest version of the docking library trial download is for RAD Studio 2009, and the advice given for installing into 2010 is that it's unsupported, and you should recompile the source. The demo doesn't come with source, and we don't have RS2009, and the installer refuses to install unless we do, and even if we manged to get it to install we can't use it since we would need to recompile the non-existent source.
I've been in touch with their support team, and they pointed me to [this thread](http://www.automatedqa.com/newsgroups/d.cgi?cmd=xover&group=automatedqa.public.aqdocking&related=883&utag=). I also found another thread with [customers asking much the same thing](http://www.automatedqa.com/newsgroups/d.cgi?cmd=article&group=automatedqa.public.aqdocking&item=858&utag=). I've replied and hope to hear better news. I'm not keen to recommend we buy a product I can't evaluate, especially when it's not supported for our IDE.
- I have ended up buying this library. In spite of problems evaluating (it works in D2007, and I had a copy of that) it seems the easiest to use of all the libraries, and also the most powerful - it's easy to write a theme for it, for example. I'd definitely recommend it if you need to select a docking library too.- [This library is no longer being sold, but may be open-sourced soon](http://smartbear.com/forums/forum/post/?mode=singleThread&thread=3825fd1d-68b9-419f-b86a-bb43b4eaece0).
## What have I missed?
That's everything I've found so far. What now?
- - -
Thanks for your input :)
| Recommendations for a docking library for Delphi / C++Builder? | CC BY-SA 3.0 | 0 | 2010-08-03T07:06:05.403 | 2014-08-19T13:46:03.567 | 2014-08-19T13:46:03.567 | 121,689 | 121,689 | [
"delphi",
"c++builder",
"dock",
"dockpanel-suite"
] |
3,396,485 | 1 | 5,171,066 | null | 9 | 5,025 | Whenever I open some help within eclipse I get a page saying:
> Server Error. The following error occurred: [code=CANT_CONNECT_LOOPBACK] Cannot connect due to potential loopback problems
I'm running Ubuntu 10.04.
Any ideas what this can be?
Some commands outputs (some private info replaced):
```
$ ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:xx:xx:xx:xx:xx
inet addr:123.12.123.235 Bcast:123.12.456.255 Mask:255.255.254.0
inet6 addr: fe80::xxx:eff:xxxx:xxxx/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1343040 errors:0 dropped:0 overruns:0 frame:0
TX packets:1133672 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:829265876 (829.2 MB) TX bytes:242912202 (242.9 MB)
Memory:f3200000-f3220000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:125 errors:0 dropped:0 overruns:0 frame:0
TX packets:125 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:15910 (15.9 KB) TX bytes:15910 (15.9 KB)
$ route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
123.12.123.0 0.0.0.0 255.255.254.0 U 1 0 0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth0
0.0.0.0 123.12.456.254 0.0.0.0 UG 0 0 0 eth0
$ sudo netstat -anp
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 765/portmap
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 871/sshd
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 1181/cupsd
tcp 0 0 0.0.0.0:52068 0.0.0.0:* LISTEN 786/rpc.statd
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 1186/mysqld
tcp 0 0 0.0.0.0:53709 0.0.0.0:* LISTEN -
tcp 0 0 123.12.123.235:755 123.12.5.48:2049 ESTABLISHED -
tcp 0 0 123.12.123.235:60793 123.12.5.129:8080 ESTABLISHED 2264/firefox-bin
tcp 0 0 123.12.123.235:57940 123.12.5.43:8080 ESTABLISHED 2264/firefox-bin
tcp 0 0 123.12.123.235:57928 123.12.5.43:8080 CLOSE_WAIT 2247/google-chrome
tcp 0 0 123.12.123.235:35767 123.12.5.129:8080 ESTABLISHED 2247/google-chrome
tcp 0 0 123.12.123.235:57930 123.12.5.43:8080 ESTABLISHED 2247/google-chrome
tcp 0 0 123.12.123.235:57931 123.12.5.43:8080 CLOSE_WAIT 2247/google-chrome
tcp6 0 0 :::80 :::* LISTEN 1278/apache2
tcp6 0 0 :::22 :::* LISTEN 871/sshd
tcp6 0 0 ::1:631 :::* LISTEN 1181/cupsd
tcp6 0 0 :::55934 :::* LISTEN 1956/eclipse
tcp6 0 0 :::5900 :::* LISTEN 1792/vino-server
udp 0 0 0.0.0.0:35631 0.0.0.0:* 912/avahi-daemon: r
udp 0 0 0.0.0.0:962 0.0.0.0:* 786/rpc.statd
udp 0 0 0.0.0.0:68 0.0.0.0:* 1575/dhclient
udp 0 0 0.0.0.0:46149 0.0.0.0:* -
udp 0 0 0.0.0.0:5353 0.0.0.0:* 912/avahi-daemon: r
udp 0 0 0.0.0.0:111 0.0.0.0:* 765/portmap
udp 0 0 0.0.0.0:36211 0.0.0.0:* 786/rpc.statd
udp 0 0 123.12.123.235:123 0.0.0.0:* 1689/ntpd
udp 0 0 127.0.0.1:123 0.0.0.0:* 1689/ntpd
udp 0 0 0.0.0.0:123 0.0.0.0:* 1689/ntpd
udp6 0 0 fe80::227:eff:fe07::123 :::* 1689/ntpd
udp6 0 0 ::1:123 :::* 1689/ntpd
udp6 0 0 :::123 :::* 1689/ntpd
```
`Active UNIX domain sockets (servers and established)` due to post size limit.
My proxy bypass settings:

| Eclipse help won't show under Ubuntu | CC BY-SA 2.5 | 0 | 2010-08-03T12:36:25.210 | 2011-03-02T17:22:38.123 | 2010-09-01T06:43:44.547 | 377,031 | 377,031 | [
"eclipse",
"ubuntu"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.