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,891,942 | 1 | 3,964,971 | null | 3 | 666 |
[http://cure.org/curekids/kenya/2010/02/joseph_muchiri/](http://cure.org/curekids/kenya/2010/02/joseph_muchiri/)

When you look at the page, you'll see a toolbar sort of dash at the top of the page, but just below the site header (its the piece that says "CUREkids").
When you hover over any area of that toolbar there is a small green tab on the left that animates out from behind it (its the piece with the question mark on it). When clicked, the tab toggles open a descriptive [Slidedeck](http://www.slidedeck.com/) interface. So far all is well.
The problem is that if you mouse across the toolbar too quickly, there is a screwy glitch that causes the jQuery rules to fire in a strange way that results in the tab coming out from behind, but going back in overtop of the toolbar.
The way the script works is that the tab is hidden behind the toolbar by default, and the jQuery first animates it left to come out away from the toolbar, then changes the z-index to bring it actually over top of the toolbar element for maximum usability and clicking area on the tab. All this happens on mouseOver. On mouseOut the reverse occurs (z-index changed to lower than the toolbar, and then animates right back to where it was located).
I think there must be an issue with how the script is written that possibly could be tweaked so that when the mouseOver event happens so quickly it doesn't result in the overlap bug.
All help is appreciated.
| jQuery animation glitch: functions fire in wrong order when mousing across to quickly | CC BY-SA 3.0 | null | 2010-10-08T15:18:35.063 | 2011-10-28T21:14:00.253 | 2011-10-28T21:14:00.253 | 757,830 | 185,973 | [
"jquery",
"user-interface",
"function",
"jquery-animate",
"togglebutton"
] |
3,892,049 | 1 | 3,893,565 | null | 1 | 2,213 | I have edittext and a button below edittext.
edittext has width as fill_parent and height as wrap_content.
My messages covers full screen, due to this my button is not visible it hides below virtual keyboard
can any one sort this problem.
Thanks.


| EditText in Android | CC BY-SA 2.5 | 0 | 2010-10-08T15:31:46.877 | 2010-10-08T19:08:33.770 | null | null | 435,025 | [
"android"
] |
3,892,103 | 1 | 3,892,114 | null | 5 | 362 | In the following HTML/CSS, why is the link color green and not blue, i.e. why does "p.description" override "#nav" but "p.description a" does not override "#nav a"?

```
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
<style type="text/css">
#nav {
color: black;
}
#nav a {
color: green;
}
p.description {
color:red;
}
p.description a {
color:blue;
}
</style>
</head>
<body>
<div id="nav">
<p class="description">This is a test and <a href="#">this is a link</a>.</p>
</div>
</body>
</html>
```
| Why does hyperlink style not cascade in CSS? | CC BY-SA 2.5 | 0 | 2010-10-08T15:38:19.843 | 2011-02-25T13:44:50.943 | 2011-02-25T13:44:50.943 | 106,224 | 4,639 | [
"css",
"css-selectors"
] |
3,892,189 | 1 | 3,892,212 | null | 0 | 1,546 | I want to create a new instance of a form in a BackgroundWorker. I've noticed that when I do this, the newly launched form freezes.

Why does this form freeze? How can I get around this?
| Creating an instance of a form in a BackgroundWorker | CC BY-SA 2.5 | null | 2010-10-08T15:48:43.890 | 2010-10-08T15:53:09.480 | null | null | 217,649 | [
"c#",
"forms"
] |
3,892,584 | 1 | 3,892,706 | null | 0 | 97 | I'm using a Tab Bar Controller in Interface Builder with 3 navigation controllers. IB is not allowing me to put more than one object in a view controller. For instance, I can't place both an image and a rect button or two images etc...
anyone know if i'm making a mistake here?
i hope i explained it clearly enough. i've attached a screen shot
thanks in advance.

| tab bar controller and placing objects | CC BY-SA 2.5 | null | 2010-10-08T16:43:42.493 | 2010-10-08T16:58:07.547 | 2010-10-08T16:53:39.677 | 388,458 | 388,458 | [
"iphone",
"interface-builder",
"uitabbarcontroller"
] |
3,892,749 | 1 | 3,892,778 | null | 0 | 995 | Can anyone give me some advice as to how to clean up a string in Visual Basic .NET? I'm creating a string as a report with line breaks. However, the string is built based off of screen scrapes from a TN3270 emulator. The string is saved successfully with all of the data I require, but those annoying rectangle symbols show up once I send it to a notepad text file. Do you know anyway I can strip those out and clean up the output? 
| Cleaning up a String in Visual Basic - Those Annoying Rectangles | CC BY-SA 2.5 | null | 2010-10-08T17:04:04.927 | 2013-01-06T15:36:35.530 | 2010-10-20T03:48:16.757 | 210,916 | 200,626 | [
"vb.net",
"file-io",
"notepad"
] |
3,892,984 | 1 | 3,893,040 | null | 1 | 2,016 | 
Is the above output in the format that should be expected from xxd or does the presence of the bizzare characters on the right suggest i've done something wrong?
I'm attempting to serialise a simple linked list and that's the output i get. Would failing to remove the sentinal character "\0" from the serialisation cause the error?
| xxd binary dump problems | CC BY-SA 2.5 | null | 2010-10-08T17:44:55.017 | 2010-10-08T18:03:06.513 | null | null | 234,712 | [
"c",
"hexdump"
] |
3,893,276 | 1 | null | null | 0 | 3,127 | How can I achieve a layout like this?
[](http://dl.dropbox.com/u/2792776/screenshots/2010-10-08_1420.png)
Right now I'm using this HTML:
```
<div class="image">
<img>
<div class="caption">
Caption Text
</div>
</div>
```
And this CSS:
```
.image {
background-color: #2A2A2A;
}
img {
max-width: 590px;
}
```
But the `.image` box is too big (since it expands to fit its parent):

| Correctly aligning image captions | CC BY-SA 2.5 | null | 2010-10-08T18:27:52.950 | 2010-10-08T19:37:50.127 | 2010-10-08T18:40:39.570 | 25,068 | 25,068 | [
"html",
"css",
"image",
"layout",
"caption"
] |
3,893,429 | 1 | 3,893,455 | null | 4 | 1,667 | I'm designing an application that will use , and we have this that we need to map in our database. Some thing that looks like this (I'm pretty sure you all know what I'm talking about but I'll include a piece of the ERD just in case):

So it will have data stored that looks like this:
```
[1 | 0]
[2 | 1]
[3 | 2]
[4 | 2]
```
In other words:
```
Department 1
|__Department 2
|___Department 3
|___Department 4
```
And so on...
This will improve the number of records required on the table and the Data can be accessed using a [CONNECT BY](http://psoug.org/reference/connectby.html) command, just having 1 recor per department. We usually go for this tree structure as solution, but in this new application performance is a critical, so I was wondering what if I have a flattened-out table that would look like this.
```
[1 | 0]
[2 | 1]
[3 | 1]
[3 | 2]
[4 | 1]
[4 | 2]
```
This allows you to have very obvious relationships without having to know the parent Department for a given child to know who their upper hierarchy Departments are. But this increases the amount of data required since you need a record for each level a Department is in, meaning that if a have a Department 15 levels below the top one we would require 15 records for it.
The Department is pretty big so this may end up being a huge table (about 2 million records).
Ok, so after the brief introduction, this is the question; Has someone actually tried this that could tell me what is faster/less expensive for the DB between this two options, the huge flat table or the small tree one?
| Whats faster in Oracle? Small table with tree structure vs. Huge flat table | CC BY-SA 2.5 | null | 2010-10-08T18:48:17.420 | 2011-08-04T10:18:41.663 | 2010-10-08T18:54:24.977 | 135,152 | 69,966 | [
"sql",
"oracle",
"database-design",
"oracle10g",
"query-optimization"
] |
3,893,476 | 1 | 7,420,858 | null | 2 | 7,849 | In FF, Opera, IE the CKEditor is working and looks great. But in Chrome and Safari it is not sizing correctly, and is extending past the container that it is inside. I assume this is because Chrome and Safari are currently the most standards compliant. See the images below.


I tried removing all of my CSS files to see if it was my css causing the issue, but that did not fix it either. Here is my call to CKEditor
```
//Make all textareas use the ckeditor
$('textarea.WYSIWYG').ckeditor({
toolbar: [
['Styles', 'Format'],
['Bold', 'Italic', 'NumberedList', 'BulletedList', 'Link']
],
height: 100,
width: "225px",
enterMode : CKEDITOR.ENTER_BR,
resize_enabled: false
});
```
Any ideas what could cause this?
Here is a VERY dumbed down version of the code still causing the error.
```
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<title>Title</title>
<script type="text/javascript" src="library/javascript/global/JQuery.core.js"></script>
<script type="text/javascript" src="resources/local_javascript/ckeditor/ckeditor.js"></script>
<script type="text/javascript" src="resources/local_javascript/ckeditor/adapters/jquery.js"></script>
<script type="text/javascript" src="resources/local_javascript/base.js"></script>
</head><body>
<div id="outerWrapper">
<table id="FAQTable">
<tr id="editingRow">
<td class="fixedWidth">
<textarea class="WYSIWYG" id="FAQQuestionInput" rows="5" cols="1"></textarea>
</td>
<td class="fixedWidth">
<textarea class="WYSIWYG" id="FAQAnswerInput" rows="5" cols="1"></textarea>
</td>
</tr>
</table>
</div>
```
And here is the new image

| CKEditor textarea extending out past box in Chrome and Safari | CC BY-SA 2.5 | null | 2010-10-08T18:54:04.930 | 2016-01-29T12:56:31.760 | 2010-10-08T21:07:39.927 | 244,061 | 244,061 | [
"javascript",
"jquery",
"google-chrome",
"ckeditor"
] |
3,893,592 | 1 | 3,894,434 | null | 2 | 1,073 | For some reason, I have to move a lot of C# code from Visual Studio 2010 to Visual Studio 2008.
I edited my sln file to reflect the changes
```
Microsoft Visual Studio Solution File, Format Version 11.00
```
to
```
Microsoft Visual Studio Solution File, Format Version 10.00
```
It allowed the solution to be loaded into VS2008. Afterwards I edited every csproj to target the Framework .NET 3.5
This allowed the projects to compile
I can run it in Release mode "correctly" (with some bugs due to modifications from .NET 4.0 specifics to 3.5 equivalent)
Now I got the following error message in debug mode

My google fu revealed that I could screw up the registry while searching for "The application you are trying to debug uses a version". It pointed me to [this page](http://msdn.microsoft.com/en-us/library/ms241897(v=VS.90).aspx)
I'm pretty sure there is an error on this page where it refers to 8.0 for both 2005 and 2008 help pages. So I did that, I created the registry key `CLRVersionForDebugging` with value "v3.5" just like the directory in `C:\Windows\Microsoft.NET\Framework` shows
Now I get the following message :

I can't find relevant information to solve this problem. This is a huge pain. I don't want to recreate the projects manualy, there are hundred of source/configuration files. Any help would be greatly appreciated.
Here is an example of a project file which will not debug
```
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<ProductVersion>9.0.21022</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{61547F81-8F73-4E38-ACDB-B51253A90EBC}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>FlowchartEditor</RootNamespace>
<AssemblyName>FlowchartEditor</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<TargetFrameworkProfile>
</TargetFrameworkProfile>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
<PlatformTarget>x86</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
<PlatformTarget>x86</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Editor.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Editor.Designer.cs">
<DependentUpon>Editor.cs</DependentUpon>
</Compile>
<Compile Include="EditorMDI.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="EditorMDI.Designer.cs">
<DependentUpon>EditorMDI.cs</DependentUpon>
</Compile>
<Compile Include="OutputSignalSelect.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="OutputSignalSelect.Designer.cs">
<DependentUpon>OutputSignalSelect.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="PropertiesEditor.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="PropertiesEditorDisplayUnit.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="ToolboxForm.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="ToolboxForm.Designer.cs">
<DependentUpon>ToolboxForm.cs</DependentUpon>
</Compile>
<EmbeddedResource Include="Editor.resx">
<DependentUpon>Editor.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="EditorMDI.resx">
<DependentUpon>EditorMDI.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="OutputSignalSelect.resx">
<DependentUpon>OutputSignalSelect.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="PropertiesEditor.resx">
<DependentUpon>PropertiesEditor.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
<SubType>Designer</SubType>
</EmbeddedResource>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
<DesignTime>True</DesignTime>
</Compile>
<EmbeddedResource Include="ToolboxForm.resx">
<DependentUpon>ToolboxForm.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<None Include="app.config" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\flowchart\flowchart\flowchart\flowchart.csproj">
<Project>{4E7DDA00-651D-4CC0-833C-83E60ADE552B}</Project>
<Name>flowchart</Name>
</ProjectReference>
<ProjectReference Include="..\PluginMiddleMan\PluginMiddleMan.csproj">
<Project>{CDACB6A0-6DEC-48B6-B3B1-628968B50F5C}</Project>
<Name>PluginMiddleMan</Name>
</ProjectReference>
<ProjectReference Include="..\ToolBox\ToolBox.csproj">
<Project>{D937E1F4-1B9F-4567-B28E-EED24AA31C9C}</Project>
<Name>ToolBox</Name>
</ProjectReference>
<ProjectReference Include="..\WinFormsUI\WinFormsUI.csproj">
<Project>{C75532C4-765B-418E-B09B-46D36B2ABDB1}</Project>
<Name>WinFormsUI</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
```
| Problem downgrading from C# 2010 to 2008 | CC BY-SA 2.5 | null | 2010-10-08T19:12:33.620 | 2010-10-08T23:21:40.577 | 2010-10-08T22:02:43.080 | 6,367 | 6,367 | [
"c#",
".net",
"visual-studio-2008",
"visual-studio-2010",
"downgrade"
] |
3,894,104 | 1 | 3,894,288 | null | 1 | 573 | I had problems with Umlauts in ASCII so I encode my Stream as UTF-8 now, which works, but it brings up a problem. I normally read 4 Bytes before ARTIST to determine the length of ARTIST=WHOEVER using
```
UTF8Encoding enc = new UTF8Encoding();
string response = enc.GetString(message, 0, bytesRead);
int posArtist = response.IndexOf("ARTIST");
BitConverter.ToInt32(message, posArtist - 4);
```
This works for ASCII perfectly.
Here is an example-screenshot from a hex-editor:

"ARTIST=M.A.N.D.Y. vs. Booka Shade" Length = 21
However that doesn't work for the UTF8-encoded stream.
Here is a screenshot:

"ARTIST=Paulseq" Length = E but in the picture its 2E.
What am I doing wrong here?
| Can't read Integer in Stream after encoding it as UTF-8 instead of ASCII | CC BY-SA 2.5 | 0 | 2010-10-08T20:34:24.897 | 2010-10-08T21:04:24.497 | 2010-10-08T20:57:27.760 | 446,835 | 446,835 | [
"c#",
".net",
"encoding"
] |
3,894,720 | 1 | null | null | 1 | 135 | I am writing an application and I am at this point at the workflow:
```
-File A doesn't exist?
-Copy file B to file A
-Error?
-Copy file B to file A with higher privileges
```
The problem is in the `Copy file B to file A with higher privileges' step. I am new to asking the admin for his/her password. I'd like a window similar to this, where the admin can enter the password so the file can be copied to an otherwise unwritable location:

I have totally no idea where to start, can someone help me out? Thanks! :D
| Copying a file to a directory that might not be writable by the application | CC BY-SA 2.5 | 0 | 2010-10-08T22:21:10.660 | 2010-10-08T22:27:11.693 | null | null | null | [
"objective-c",
"cocoa",
"unix",
"privileges"
] |
3,894,827 | 1 | 3,895,830 | null | 4 | 5,655 | Here are two images of the same android phone, once in Portrait mode, once in Landscape mode.


Shouldn't one resolution be the opposite of the other? I.e. if one is 800x1360, the other should be 1360x800? What's going on here? If I try the same thing on my ipod touch, it reports the same resolution regardless of orientation. Also, on the android phone, the resolution appears to change as you zoom in and out or scroll around the page.
I'm trying to figure out how to handle the "reported" resolution of an android phone in CSS, which I can't do until I know exactly which resolution it reports. :(
| What's the deal with Android web browser resolution? | CC BY-SA 2.5 | null | 2010-10-08T22:47:59.443 | 2010-10-09T05:24:16.107 | 2010-10-08T22:54:43.953 | 13,500 | 13,500 | [
"android",
"browser",
"resolution"
] |
3,895,163 | 1 | 3,895,578 | null | 3 | 2,195 | I'm currently completely baffled by the problem I'm having. I'm writing a plug-in for another application that provides a public .NET API. I've created a class named `Room` and I am using a PropertyGrid to allow users to see and edit the properties of the `Room` instances. A few properties are restricted to a set of standard values. Thus I am using custom TypeDescriptors with `GetStandardValues()` overrides to get the property grid to show a drop down for those properties.
This was all working just fine. I was getting drop downs, and I could edit values no problem. Yet now for some reason when I select an `Room` the PropertyGrid shows the properties with the type descriptors as a black box.

If I click on the box it turns white and I get a blinking cursor, yet I can't type anything. If I then select another Room my program crashes with the following exception:
```
System.InvalidCastException was caught
Message=Unable to cast object of type 'DVAMC.Room' to type 'DVAMC.Room'.
Source=DVAMC
StackTrace:
at DVAMC.BuildingTypeConverter.GetStandardValuesSupported(ITypeDescriptorContext context) in C:\Documents and Settings\eric.anastas\My Documents\_SVN WC\DVAMC Working\BuildingTypeConverter.cs:line 14
at System.Windows.Forms.PropertyGridInternal.GridEntry.get_Flags()
at System.Windows.Forms.PropertyGridInternal.GridEntry.get_NeedsDropDownButton()
at System.Windows.Forms.PropertyGridInternal.PropertyDescriptorGridEntry.get_NeedsDropDownButton()
at System.Windows.Forms.PropertyGridInternal.PropertyGridView.SelectRow(Int32 row)
at System.Windows.Forms.PropertyGridInternal.PropertyGridView.SelectGridEntry(GridEntry gridEntry, Boolean fPageIn)
at System.Windows.Forms.PropertyGridInternal.PropertyGridView.GridPositionData.Restore(PropertyGridView gridView)
at System.Windows.Forms.PropertyGridInternal.PropertyGridView.Refresh(Boolean fullRefresh, Int32 rowStart, Int32 rowEnd)
at System.Windows.Forms.PropertyGridInternal.PropertyGridView.Refresh()
at System.Windows.Forms.PropertyGrid.Refresh(Boolean clearCached)
at System.Windows.Forms.PropertyGrid.set_SelectedObjects(Object[] value)
at System.Windows.Forms.PropertyGrid.set_SelectedObject(Object value)
at DVAMC.RoomDetailsForm.set_RoomDetailsSelectedRoom(Room value) in C:\Documents and Settings\eric.anastas\My Documents\_SVN WC\DVAMC Working\RoomDetailsForm.cs:line 115
at DVAMC.RoomDetailsForm.roomListTreeView_SelectionChanged(Object sender, EventArgs e) in C:\Documents and Settings\eric.anastas\My Documents\_SVN WC\DVAMC Working\RoomDetailsForm.cs:line 159
at BrightIdeasSoftware.ObjectListView.OnSelectionChanged(EventArgs e)
at BrightIdeasSoftware.ObjectListView.HandleApplicationIdle(Object sender, EventArgs e)
at System.Windows.Forms.Application.ThreadContext.System.Windows.Forms.UnsafeNativeMethods.IMsoComponent.FDoIdle(Int32 grfidlef)
at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.RunDialog(Form form)
at System.Windows.Forms.Form.ShowDialog(IWin32Window owner)
at System.Windows.Forms.Form.ShowDialog()
at DVAMC.RoomDetailsCmd.Execute(ExternalCommandData commandData, String& message, ElementSet elements) in C:\Documents and Settings\eric.anastas\My Documents\_SVN WC\DVAMC Working\RoomDetailsCmd.cs:line 44
InnerException:
```
The last item in the stack trace points to my BuildingTypeConverter.GetStandardValuesSupported() method which is shown below.
```
GetStandardValuesSupported(System.ComponentModel.ITypeDescriptorContext context)
{
Room r = (Room)context.Instance; //this is line 14 referenced by the InvalidCastException's stack trace
if (r.IsLinked)
{
return true;
}
else
{
return false;
}
}
```
Now if I set a breakpoint at line 14 above and try to debug the debugger does not break at the breakpoint. In addition, if I add arbitrary code before the cast the stack trace from the InvalidCastException always seems to reference to first line of GetStandardValues() regardless of what it is. For example I tried the following.
```
public override bool GetStandardValuesSupported(System.ComponentModel.ITypeDescriptorContext context)
{
string s = "hello world"; //FIRST LINE
int i = 0;
Room r = (Room)context.Instance;
.....
```
I still got the same InvalidCastException. Yet it's stack trace reference the first line above where I initialize `string s`. In addtion, if I tried to set a breakpoint on this first line it was also not triggered.
Like I said before this working just fine a day or so ago. I've even tried rolling back to previous revisions in my SVN repository. I've gone as far back as the first revision were I created the custom Type Descriptor class but still run into the problem with the `InvalidCastExceptions`. Does anyone have any idea what's going on?
| InvalidCastException casting object to its own type | CC BY-SA 2.5 | null | 2010-10-09T00:24:41.070 | 2010-10-09T03:26:26.130 | null | null | 88,427 | [
"c#",
"propertygrid",
".net",
"typedescriptor"
] |
3,895,302 | 1 | 3,909,314 | null | 2 | 1,288 | I have a solution with quite a few different MasterPages / BasePages which all inherit from somewhere else. My problem is that I have a virtual string in BaseMaster, which is overridden by BaseManagement, but when I try to access this string I always get the base value
The point of inheriting masters and pages is obviously to avoid having duplicate code everywhere.
Maybe it has something to do with the fact that I "need" `protected void Page_Load(object sender, EventArgs e)` at every master no matter

So, here's an snippet from Base.Master.cs
```
public abstract partial class BaseMaster : MasterPage, IRewritablePageElement
{
public BasePage BasePage { get { return Page as BasePage; } }
public BaseMaster Self { get { return (BaseMaster)this.Page.Master; } }
public virtual string accessUri { get { return "/"; } }
public string AccessUri { get { return Self.accessUri; } }
protected void Page_Load(object sender, EventArgs e)
{
this.OnPageLoad(sender, e);
}
/// <summary>
/// If we want to do something on page load, we override the following method
/// </summary>
public virtual void OnPageLoad(object sender, EventArgs e)
{
SetCacheability();
RedirectSiteDown();
RedirectUnregisteredUsers();
RedirectUnprivilegedUsers();
if(!IsPostBack)
{
PopulateMenu();
...
```
As you already noticed,
```
public BaseMaster Self { get { return (BaseMaster)this.Page.Master; } }
public virtual string accessUri { get { return "/"; } }
public string AccessUri { get { return Self.accessUri; } }
```
is as ugly as it gets, since it should just be
```
public virtual string AccessUri { get { return "/"; } }
```
but the code somehow manages to get all the way down to a level where AccessUri is "/" even though it has been overriden with "/a/" somewhere at a higher level:
```
public partial class BaseManagementMaster : BaseMaster
{
public override string accessUri { get { return "/a/"; } }
protected void Page_Load(object sender, EventArgs e)
{
}
}
```
If not for the `Self` thingy, here AccessUri is still "/". which makes absolutely no sense.
Also, the fact that I have to re-declare Page_Load methods makes very little sense too.
Is there a clean way to do master page inheritance, is it even realistically possible?
| C# ASP.NET MasterPage nested inheritance is evil | CC BY-SA 2.5 | 0 | 2010-10-09T01:21:24.627 | 2010-10-11T19:26:33.987 | null | null | 389,745 | [
"c#",
"asp.net",
"inheritance",
"webforms",
"master-pages"
] |
3,895,406 | 1 | 3,895,423 | null | 3 | 3,142 | I have a query that fetches employee's name, date, working hours, wage and calculate salary based on working hours * wage.
The minutes in working hours that is being calculated are discarded. I only get the value in full hour. Snapshot example:
My main concern is on workingHours and wageAmount

workingHours is displayed as 5. Here is the time sheet snapshot:

As you see shift starts at 10:30 AM and ends at 4:00 PM (excluding lunch time), so the actual total hours is 4 and a half not 5.
Here is the query snippet that calculates the hours:
```
DATEDIFF(HOUR, shiftStart.timeEntered, shiftEnd.timeEntered) - DATEDIFF(HOUR, lunchStart.timeEntered, lunchEnd.timeEntered) AS workingHours,
```
Since i will be counting the minutes, i will have to calculate the wage per minute so i will have to put the following code that calculates wage per minute:
```
ROUND((((DATEDIFF(HOUR, shiftStart.timeEntered, shiftEnd.timeEntered) - DATEDIFF(HOUR, lunchStart.timeEntered, lunchEnd.timeEntered)) * 60) * (cast(((w.wageAmount/60)-((w.wageAmount/60)%.001)) as decimal (18,3)))), 0) AS "SalaryPerMin",
```
| How to Calculate Working Hours including Minutes? | CC BY-SA 2.5 | null | 2010-10-09T02:08:43.957 | 2010-10-09T06:54:35.850 | 2010-10-09T03:58:09.527 | 372,445 | 372,445 | [
"sql",
"sql-server",
"tsql"
] |
3,895,493 | 1 | 3,895,500 | null | 1 | 76 | For some reason I think I'm forgetting something here. Below is my code:
```
<style type="text/css">
#content {
width: 400px;
height: 100px;
background: orange;
padding: 10px;
}
</style>
<div id="content">
<h1>what</h1>
foofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoofoo
</div>
```
When that loads, it shows this:

[http://grab.by/6Mhp](http://grab.by/6Mhp)
The text is not inside the box. Why...? And how to fix?
| Simple HTML/CSS positioning issue | CC BY-SA 3.0 | null | 2010-10-09T02:42:11.353 | 2012-03-06T10:32:41.353 | 2011-12-11T04:42:44.343 | 234,976 | 470,809 | [
"html",
"css"
] |
3,895,855 | 1 | 3,896,728 | null | 3 | 4,252 | I am trying to represent a stem and leaf plot in a tabular environment in LaTeX using the following:
```
\begin{table}[htbp]
\centering
\caption{Stem Plot of sit ups, Key: $1 | 1= 1.1$}
\begin{tabular}{r|l@{\hspace{4 pt}}l@{\hspace{4 pt}}l@{\hspace{4 pt}}l@{\hspace{4 pt}}l@{\hspace{4 pt}}l@{\hspace{4 pt}}l@{\hspace{4 pt}}l@{\hspace{4 pt}}l@{\hspace{4 pt}}}
\multirow{2}{*}{} Stem & Leaf \\
\hline
1 & 1 & 1 & 2 & 3 & 3 & 4 & 4 & & \\
1 & 5 & 6 & 6 & 8 & & & & & \\
2 & 0 & 3 & & & & & & & \\
2 & 7 & 8 & & & & & & & \\
3 & & & & & & & & & \\
3 & 5 & 7 & 8 & 8 & & & & & \\
4 & 0 & 0 & 0 & 1 & 2 & 4 & 4 & 4 & \\
4 & 5 & 5 & 6 & 7 & 7 & 7 & 8 & 8 & 9 \\
\end{tabular}
\label{tab:addlabel}
\end{table}
```
But when I do this, the 2nd column has is too wide and there is a gap between the 2nd and 3rd column of leaf values. How can I make it so that the 'Leaf' cell overlaps into the next column or somehow remove the gap?

| LaTeX top row on a stem and leaf plot table | CC BY-SA 2.5 | null | 2010-10-09T05:41:59.863 | 2020-10-01T04:06:33.163 | 2017-01-14T23:20:46.187 | 4,370,109 | 150,851 | [
"latex"
] |
3,895,984 | 1 | null | null | 0 | 1,750 | Assigning value to `<li>` tag using its id displays me error in IE 6 and IE7,,
Previously I was doing this:
```
document.getElementById("grandtotaldisplay").innerHTML = "TOTAL PRICE : $"+variable;
```
this throws me error in IE6 and IE7 as:

Then I tried with jQuery library as suggested my others.. then also I was prompted with same error as displayed above.
here is how I used the jQuery .html()
$("#grandtotaldisplay").html("TOTAL PRICE : $"+variable);
I am facing this issue in IE6 and IE7
How should I resolve it..please help.
>
below is the `<li>` tag where i need to place the required value using javascript
```
<li class="bannerprice" id="grandtotaldisplay">TOTAL PRICE : $0</li>
```
| Assigning value to <li> tag using its id displays me error in IE 6 and IE7 | CC BY-SA 2.5 | 0 | 2010-10-09T06:47:48.033 | 2010-10-09T07:02:59.047 | 2010-10-09T07:02:59.047 | 333,255 | 184,814 | [
"javascript",
"jquery",
"internet-explorer-6",
"innerhtml"
] |
3,896,118 | 1 | 3,896,132 | null | 0 | 1,354 | This is the mark-up I have to work with, The form is created via a wordpress plugin so I do not have control over the HTML,
```
<div class="wpcf7" id="wpcf7-f1-p214-o1">
<form action="/testing/contact-us/#wpcf7-f1-p214-o1" method="post" class="wpcf7-form">
<div style="display: none;">
<input type="hidden" name="_wpcf7" value="1" />
<input type="hidden" name="_wpcf7_version" value="2.4.1" />
<input type="hidden" name="_wpcf7_unit_tag" value="wpcf7-f1-p214-o1" />
</div>
<fieldset>
<span class="wpcf7-form-control-wrap Name"><input type="text" name="Name" value="Name" class="wpcf7-text wpcf7-validates-as-required" size="40" /></span><br />
<span class="wpcf7-form-control-wrap your-email"><input type="text" name="your-email" value="Email Address" class="wpcf7-text wpcf7-validates-as-email wpcf7-validates-as-required" size="40" /></span><br />
<span class="wpcf7-form-control-wrap telephone"><input type="text" name="telephone" value="Telephone" class="wpcf7-text wpcf7-validates-as-required" size="40" /></span><br />
<span class="wpcf7-form-control-wrap company"><input type="text" name="company" value="Company" class="wpcf7-text wpcf7-validates-as-required" size="40" /></span><br />
<input type="submit" value="Send" class="wpcf7-submit" /><br />
</fieldset>
<fieldset>
<span class="wpcf7-form-control-wrap town-city"><textarea name="town-city" class="wpcf7-validates-as-required" cols="40" rows="10">Atleast town/city</textarea></span><br />
</fieldset>
<fieldset>
<span class="wpcf7-form-control-wrap your-enquiry"><textarea name="your-enquiry" class="wpcf7-validates-as-required" cols="40" rows="10">Enter your enquiry</textarea></span><br />
</fieldset>
<div class="wpcf7-response-output wpcf7-display-none"></div>
</form>
```
And this is my current CSS,
```
.page-id-214 input{
margin:0px 0px 10px 0px;
width:231px;
border:1px solid #aaaaaa;
float:left;
clear:left;
}
```
I am trying to make it look like this,

Currently I can only get all the elements sitting on top of each other
```
.page-id-214 textarea {
width:206px;
height:109px;
float:left;
}
```
| css help I need to float two text areas next to 4 inputs | CC BY-SA 3.0 | null | 2010-10-09T15:17:55.550 | 2014-04-08T19:48:04.657 | 2014-04-08T19:48:04.657 | 3,447,910 | 307,007 | [
"html",
"css",
"wordpress"
] |
3,896,200 | 1 | 3,919,116 | null | 1 | 1,596 | Although new to silverlight, I have produced a clickable map. [Note: it is better than using html tags because the contours of the map match the exact contour of each area, and it is easy to produce a context menu).
I had to resize the map and now it is adding a whole new scrollbar to the browser window: I now have TWO vertical scrollbars. Not good for accessibility and usability.
Question is: Why am I getting this extra scrollbar?
HTML:
```
<div id="silverlightControlHost" style="padding: 0px; border: 2px solid #999; margin: 5px;
width: 575px; height: 525px;">
<object data="data:application/x-silverlight-2," type="application/x-silverlight-2"
width="575" height="525">
<param name="source" value="../ClientBin/RegionsES.xap" />
<param name="onError" value="onSilverlightError" />
<param name="background" value="white" />
<param name="minRuntimeVersion" value="3.0.40818.0" />
<param name="autoUpgrade" value="true" />
<a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=3.0.40818.0" style="text-decoration: none">
<img src="http://go.microsoft.com/fwlink/?LinkId=161376" alt="Get Microsoft Silverlight"
style="border-style: none" />
</a>
</object>
<iframe id="_sl_historyFrame" style="visibility: hidden; height: 0px; width: 0px;
border: 0px"></iframe>
</div>
```
what it looks like:

Any suggestions?
| Silverlight control adding a scrollbar to the browser window | CC BY-SA 2.5 | 0 | 2010-10-09T15:36:25.563 | 2010-10-13T09:27:40.063 | null | null | 271,087 | [
"html",
"silverlight",
"silverlight-3.0",
"scrollbars"
] |
3,896,208 | 1 | 3,896,265 | null | 1 | 237 | I have a couple links on this page ([http://tuscaroratackle.com](http://tuscaroratackle.com)) that are ending up at unexpected positions in their :active state. The links are absolutely positioned, so I'm guessing the issue is partly due to that. But I can't figure out what rules are getting applied on :active to make them shift down and to the left so far. I do have one rule that makes them "depress" a bit on active ( `a:active {position:relative; top:1px;}` ) but can't quite figure out why they are shifting so badly.
The links in question are these:

it's the "See Rods" link that appears on hover. If you click you'll see the awkward resulting positioning.
| Absolutely positioned links shifting to unexpected position on click (a:active) | CC BY-SA 3.0 | null | 2010-10-09T15:37:29.910 | 2011-10-28T21:16:36.177 | 2011-10-28T21:16:36.177 | 757,830 | 185,973 | [
"css",
"css-position"
] |
3,896,647 | 1 | 3,896,972 | null | 0 | 806 | I made an app which plays the song on clicking on the image of artist.(see image attached). Each artist image is implemented on button and on clicking this button, a function is being called which first downloads and then plays the song. I passed this method(function) in a thread but problem is that every time when I click on the image of artist(button) new threads starts running and then multiple songs gets started playing concurrently. How can I use "NSOperation and NSOperationQueue" so that only one song will run at a time . Please help.
Thanks in advance

| How to use NSOperation and NSOperationQueue | CC BY-SA 2.5 | null | 2010-10-09T08:52:26.347 | 2010-10-09T16:51:48.300 | null | null | 390,423 | [
"iphone"
] |
3,896,859 | 1 | 3,896,886 | null | 2 | 665 | Having read [this](http://igoro.com/archive/gallery-of-processor-cache-effects/) article I tried to reproduce the example on my Mac. However my curve for the first example looks completely different and I don't understand why..

My code is below:
```
#include <mach/mach_time.h>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
void mach_absolute_difference(uint64_t end, uint64_t start, struct timespec *tp) {
uint64_t difference = end - start;
static mach_timebase_info_data_t info = {0,0};
if (info.denom == 0)
mach_timebase_info(&info);
uint64_t elapsednano = difference * (info.numer / info.denom);
tp->tv_sec = elapsednano * 1e-9;
tp->tv_nsec = elapsednano - (tp->tv_sec * 1e9);
}
int main(void)
{
int len = 64 * 1024 * 1024;
int *arr = (int *)malloc(sizeof(int)*len);
uint64_t start,end;
struct timespec tp;
start = mach_absolute_time();
for (int i = 0; i <len; i += K)
arr[i] = 0;
end = mach_absolute_time();
mach_absolute_difference(end, start, &tp);
FILE *fp;
fp=fopen("simple_array.log", "a+");
fprintf(fp, "%i\t%ld\t%ld\n", K, tp.tv_sec,
tp.tv_nsec);
fclose(fp);
free(arr);
return 0;
}
```
I measured the time as described in [this blog](http://www.wand.net.nz/~smr26/wordpress/2009/01/19/monotonic-time-in-mac-os-x/), hoping that it's correct. I'm also wondering what I should use to either measure execution time or CPU cycles on a Mac. Or even nicer it would be see the amount of cache hit/misses for a certain function. Shark however only shows l2 cache misses in percentages.
Update this is it when compiled for 32 bit, note that the int size changes from 8 bytes to 4 bytes

| Reproducing "Gallery of processor cache effects" | CC BY-SA 2.5 | null | 2010-10-09T16:24:07.237 | 2010-10-09T16:39:05.057 | 2010-10-09T16:39:05.057 | 44,232 | 44,232 | [
"c",
"macos",
"caching",
"hardware"
] |
3,896,891 | 1 | 10,134,790 | null | 3 | 9,219 | Does jQuery UI support showing the number inside the Progressbar, like this:

| Is there a way to show the percentage number inside the jQuery UI Progressbar? | CC BY-SA 3.0 | 0 | 2010-10-09T16:31:28.840 | 2015-04-07T13:34:18.870 | 2015-04-07T13:34:18.870 | 2,548,155 | 4,653 | [
"jquery-ui",
"progress-bar"
] |
3,897,194 | 1 | 3,897,316 | null | 0 | 225 | 
Above is my data model diagram.
Everytime i create a Car whcih contains a model and make, it adds a car object to core data.
The problem is that it also adds 1 make and 1 model to the core data, so i get duplicates.
for example, in the following code, it saves 1 car object 2 models, and 2 makes,
so I get a duplicate Make in my table (2 "Nissan").
How can i avoid this? is it possible to create primary keys?
```
- (void)MyCode
{
[self AddCar:@"Nissan" @"Rogue"];
[self AddCar:@"Nissan" @"Murano"];
}
- (void)AddCar :(NSString*)_make :(NSString*)_model
{
Car *car = [[Car alloc] initWithEntity:[NSEntityDescription entityForName:@"Car"
inManagedObjectContext:self.managedObjectContext]
insertIntoManagedObjectContext:self.managedObjectContext];
Make *make = [[Make alloc] initWithEntity:[NSEntityDescription entityForName:@"Make"
inManagedObjectContext:self.managedObjectContext]
insertIntoManagedObjectContext:self.managedObjectContext];
make.name = _make;
Model *model = [[Model alloc] initWithEntity:[NSEntityDescription entityForName:@"Model"
inManagedObjectContext:self.managedObjectContext]
insertIntoManagedObjectContext:self.managedObjectContext];
model.name = _model;
car.make = make;
car.model = model;
[self saveContext];
}
```
| iPhone - Core Data Questions? | CC BY-SA 2.5 | null | 2010-10-09T17:47:23.430 | 2010-10-09T18:22:51.630 | 2010-10-09T17:58:24.013 | 242,769 | 242,769 | [
"iphone",
"core-data",
"primary-key"
] |
3,897,231 | 1 | 3,919,970 | null | 0 | 5,364 | I have the following stacked column chart and I'm would like to customize the labels for the datapoints in each series so they were similar to '4:00 - 4:30 (class name)' next datapoints in the series would be '4:30 - 5:00 (class name)' and so on.

| how to customize series datapoint labels with ms chart control | CC BY-SA 2.5 | null | 2010-10-09T18:01:57.373 | 2010-10-13T00:13:58.370 | null | null | 185,961 | [
"c#",
"charts",
"mschart"
] |
3,897,206 | 1 | 3,900,411 | null | 1 | 4,654 | I am working with the MS chart controls stackedcolumn chart type and I want the y axis labels to increment by 15 minute intervals between 4 pm and 9 pm. I have attached an image of what the chart looks like and have attached the sample code that generated the image.

```
<asp:Chart ID="Chart1" runat="server" Height="296px" Width="412px" BackColor="#D3DFF0"
Palette="BrightPastel" BorderDashStyle="Solid" BackGradientStyle="TopBottom"
BorderWidth="2" BorderColor="26, 59, 105">
<Legends>
<asp:Legend TitleFont="Microsoft Sans Serif, 8pt, style=Bold" BackColor="Transparent"
Font="Trebuchet MS, 8.25pt, style=Bold" IsTextAutoFit="False" Enabled="False"
Name="Default">
</asp:Legend>
</Legends>
<BorderSkin SkinStyle="Emboss"></BorderSkin>
<Series>
<asp:Series Name="Series1" ChartType="StackedColumn" BorderColor="180, 26, 59, 105"
Color="220, 65, 140, 240" YValueType="Time" IsValueShownAsLabel="True"
LabelFormat="{0:HH:mm:ss}">
</asp:Series>
<asp:Series Name="Series2" ChartType="StackedColumn" BorderColor="180, 26, 59, 105"
Color="220, 252, 180, 65" YValueType="Time" IsValueShownAsLabel="True"
LabelFormat="{0:HH:mm:ss}">
</asp:Series>
<asp:Series Name="Series3" ChartType="StackedColumn" BorderColor="180, 26, 59, 105"
Color="220, 224, 64, 10" YValueType="Time" IsValueShownAsLabel="True"
LabelFormat="{0:HH:mm:ss}">
</asp:Series>
<asp:Series Name="Series4" ChartType="StackedColumn" BorderColor="180, 26, 59, 105"
Color="220, 5, 100, 146" YValueType="Time" IsValueShownAsLabel="True"
LabelFormat="{0:HH:mm:ss}">
</asp:Series>
</Series>
<ChartAreas>
<asp:ChartArea Name="ChartArea1" BorderColor="64, 64, 64, 64" BorderDashStyle="Solid"
BackSecondaryColor="Transparent" BackColor="64, 165, 191, 228" ShadowColor="Transparent"
BackGradientStyle="TopBottom">
<Area3DStyle Rotation="10" Inclination="15" WallWidth="0" />
<Position Y="3" Height="92" Width="92" X="2"></Position>
<AxisY LineColor="64, 64, 64, 64" LabelAutoFitMaxFontSize="8">
<LabelStyle Font="Trebuchet MS, 8.25pt, style=Bold" />
<MajorGrid LineColor="64, 64, 64, 64" />
</AxisY>
<AxisX LineColor="64, 64, 64, 64" LabelAutoFitMaxFontSize="8">
<LabelStyle Font="Trebuchet MS, 8.25pt, style=Bold" />
<MajorGrid LineColor="64, 64, 64, 64" />
</AxisX>
</asp:ChartArea>
</ChartAreas>
</asp:Chart>
```
And in the code behind I bind some testing data:
```
private void BindChart()
{
Random random = new Random();
//each series is a class?
//section count to be determined dynamically
//is the number of 'pool sections' (a pool can hold mulitiple classes)
int intSectionCount = 4;
for (int pointIndex = 0; pointIndex < intSectionCount; pointIndex++)
{
//Series are the number of classes per section and the points are the start times of the class?
//these numbers stack on top of each other.
//What if vacant time slots or grace periods alloted to time before classes start
//determine real datetime based on excel spreadsheet data
int sec = 0;
int min = ((int)random.Next(1, 2) == 1) ? 0 : 30;
int hour = (int)random.Next(16, 18);
int day = DateTime.Now.Day;
int month = DateTime.Now.Month;
int year = DateTime.Now.Year;
System.DateTime y = new DateTime(year, month, day, hour, min, sec);
Chart1.Series["Series1"].Points.AddY(y.ToOADate());
//increment
y = y.AddMinutes(30);
Chart1.Series["Series2"].Points.AddY(y.ToOADate());
//increment
y = y.AddMinutes(30);
Chart1.Series["Series3"].Points.AddY(y.ToOADate());
//increment
y = y.AddMinutes(30);
Chart1.Series["Series4"].Points.AddY(y.ToOADate());
//Chart1.Series["Series1"].Points.AddY(Math.Round((double)random.Next(45, 95),0));
//Chart1.Series["Series2"].Points.AddY(Math.Round((double)random.Next(5, 75),0));
//Chart1.Series["Series3"].Points.AddY(Math.Round((double)random.Next(5, 95),0));
//Chart1.Series["Series4"].Points.AddY(Math.Round((double)random.Next(35, 95),0));
}
}
Chart1.ChartAreas[0].AxisY.Minimum = (new DateTime(2010, 10, 31, 16, 00, 00)).ToOADate();
Chart1.ChartAreas[0].AxisY.Maximum = (new DateTime(2010, 10, 31, 21, 00, 00)).ToOADate();
Chart1.ChartAreas[0].AxisY.IsReversed = true;
```
| how to increment y axis values by 15 minutes using ms chart controls | CC BY-SA 2.5 | null | 2010-10-09T17:54:28.873 | 2010-10-10T13:06:13.543 | 2010-10-09T18:33:36.193 | 185,961 | 185,961 | [
"c#",
"charts",
"mschart"
] |
3,897,396 | 1 | 3,897,808 | null | 41 | 151,194 | Is it possible to make a table row expand and collapse? Can anyone refer me to a script or an example?
I prefer jQuery if possible. I have a drawing concept I would like to achieve:

| Can a table row expand and close? | CC BY-SA 4.0 | 0 | 2010-10-09T18:42:24.307 | 2022-01-27T04:10:20.400 | 2020-01-04T01:33:08.850 | 6,461,462 | 297,791 | [
"jquery",
"tablelayout"
] |
3,897,479 | 1 | 3,898,519 | null | 5 | 2,884 | I want to create a graph (Graph Theory) where certain edges have a different colour to other edges, which would be used to highlight a path in the graph from one vertex to another.
Here are some examples which have different coloured edges [http://demonstrations.wolfram.com/AGraphTheoryInterpretationOfTheSumOfTheFirstNIntegers/](http://demonstrations.wolfram.com/AGraphTheoryInterpretationOfTheSumOfTheFirstNIntegers/) and [http://demonstrations.wolfram.com/Ramsey336/](http://demonstrations.wolfram.com/Ramsey336/). I looked at source code for these but those solutions seem complicated. I need a simple example to work from. I reckon I need to use the EdgeRenderingFunction as one of the options for `GraphPlot`.
Additionally under [EdgeRenderingFunction](http://reference.wolfram.com/mathematica/ref/EdgeRenderingFunction.html) documentation in "More
Information" part it says:

This looks useful but unfortunately there is no coded examples to try.
Taking that very literally I tried things like
> GraphPlot[{1 -> 2, 2 -> 3, 3 -> 4, 4
-> 1, 2 -> 4, 4 -> 5, 4 -> 6}, VertexLabeling -> True,
EdgeRenderingFunction -> g[{1, 2}, {1,
2}, Red]]
But that wouldn't work. It will take something more clever than that.
| Creating a graph with edges of different colours in Mathematica | CC BY-SA 3.0 | null | 2010-10-09T19:07:57.703 | 2012-05-14T23:08:14.290 | 2012-01-02T22:12:57.897 | 615,464 | 253,380 | [
"colors",
"wolfram-mathematica",
"graph-theory",
"edges"
] |
3,897,653 | 1 | null | null | 0 | 328 | I have the Eclipse for Java EE Developers, and when I'm trying to create a new server runtime, I don't see in that list Apache Tomcat, or Glassfish v3 Prelude servers.
Where are they?
I tried to 'Download additional servers' but I see only 5 versions of Geronimo and a Jetty server, no apache and other Glassfish versions.
What update site should I use to integrate those additional servers into Eclipse?
Here I have the image:

Thanks!
| eclipse servers | CC BY-SA 2.5 | null | 2010-10-09T20:03:31.520 | 2010-10-10T17:38:25.877 | 2010-10-09T23:27:38.373 | 6,309 | 300,590 | [
"eclipse",
"eclipse-plugin"
] |
3,897,773 | 1 | 4,116,150 | null | 2 | 523 | I'm trying to create a scroll view that works like Apple's Pages app on the iPad. See pic below. I can create a similar scroll view with subviews containing the individuals pages, spaced apart as shown, and with pagingEnabled, it scrolls OK, but I want to achieve a scrolling effect that keeps the subviews centered once they've scrolled completely into view. So I want each page to scroll to a centered position in the scrollview, but as the pagingEnabled behavior scrolls the entire bounds left or right, I end up with a partial page or pages showing. What would be a good approach to this?
Thanks!
//Scott

| Creating a ScrollView that works like Pages | CC BY-SA 2.5 | 0 | 2010-10-09T20:31:43.577 | 2012-07-05T20:37:23.073 | null | null | 81,524 | [
"ipad",
"uiscrollview"
] |
3,898,814 | 1 | 3,899,020 | null | 1 | 8,332 | I have been trying to decipher what this output means, but I just can't seem to figure it out. Does anybody know what is going on here?

I have even tried running the lines one by one and the errors only show up when the final line (show) is executed.
| General::ivar: ... is not a valid variable | CC BY-SA 2.5 | 0 | 2010-10-10T02:50:12.020 | 2010-10-10T04:23:14.680 | null | null | 355,325 | [
"wolfram-mathematica"
] |
3,898,905 | 1 | 3,899,022 | null | 1 | 787 | The problem exists at `017D0B5F call eax` :
```
017D0B56 mov esi,esp
017D0B58 mov edx,dword ptr [ebp-20h]
017D0B5B push edx
017D0B5C mov eax,dword ptr [ecx+8]
017D0B5F call eax
017D0B61 cmp esi,esp
017D0B63 call @ILT+2525(__RTC_CheckEsp) (17C49E2h)
017D0B68 cmp dword ptr [ebp-2Ch],0
017D0B6C je CSourceStream::DoBufferProcessingLoop+10Ah (17D0B8Ah)
017D0B6E mov eax,dword ptr [ebp-2Ch]
017D0B71 push eax
017D0B72 push offset string "Deliver() returned %08x; stoppin"... (17F7278h)
```
Here's the corresponding source:
```
// Virtual function user will override.
hr = FillBuffer(pSample);
if (hr == S_OK) {
hr = Deliver(pSample);
pSample->Release();
// downstream filter returns S_FALSE if it wants us to
// stop or an error if it's reporting an error.
if(hr != S_OK)
{
DbgLog((LOG_TRACE, 2, TEXT("Deliver() returned %08x; stopping"), hr));
return S_OK;
}
```
Is it possible to infer which line in source has the problem according to disassembly?
What does `__RTC_CheckEsp` mean ?
Reproducing in debugger


| Is it possible to infer which line in source has the problem according to disassembly? | CC BY-SA 2.5 | null | 2010-10-10T03:36:04.803 | 2011-08-28T19:46:10.467 | 2011-08-28T19:46:10.467 | 196,844 | 454,770 | [
"c++",
"windows",
"visual-studio",
"disassembly",
"dia-sdk"
] |
3,899,007 | 1 | 3,899,045 | null | 0 | 1,312 | Had a look over SO but I can't see any threads which address my problem.
I have a conceptual architecture, where there is a central server, which allows clients to connect to it via XML web services. There are 2 types of client, producers and consumers.
The system is built in C# using WCF WebServices, specifically IIS webservices (though this can be changed if necessary)
Producers publish information to the server, and consumers consume information uploaded by a producer.
The conundrum... Consumers need to somehow subscribe to an event on the server, which is thrown when a producer updates the web server, downloading new content and displaying it if necessary.
I don't want to use a polling mechanism, but can't see a way to subsribe to server events in a client.
Very basic architecture... Workstations could be the same PC running 2 services, or they could be 2 separate PC's on different networks. They don't about each other, so all comms are done through the webservice.
This application is for a messaging network, based on radio paging.

| Web services, handling server events on the client | CC BY-SA 2.5 | null | 2010-10-10T04:20:05.357 | 2010-10-10T04:32:32.130 | null | null | 200,653 | [
"c#",
"asp.net",
"web-services",
"events",
"event-handling"
] |
3,899,138 | 1 | 3,899,316 | null | 7 | 11,919 | I am adding a validation rule to a textbox (following examples on [WPF 4 Unleashed](http://adamnathan.net/) by Adam Nathan)
When starting an application, I am faced with the following cryptic error message
> Provide value on 'System.Windows.Data.Binding' threw an exception

Here is the full source code
```
<Window.Resources>
<Style x:Key="controlStyle" TargetType="{x:Type Control}">
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="RenderTransform">
<Setter.Value>
<RotateTransform Angle="20" />
</Setter.Value>
</Setter>
<Setter Property="Foreground" Value="Black" />
</Trigger>
</Style.Triggers>
<Setter Property="FontSize" Value="22" />
<Setter Property="Background" Value="Purple" />
<Setter Property="Foreground" Value="White" />
<Setter Property="Height" Value="50" />
<Setter Property="Width" Value="50" />
<Setter Property="RenderTransformOrigin" Value=".5,.5" />
<Setter Property="RenderTransform">
<Setter.Value>
<RotateTransform Angle="10" />
</Setter.Value>
</Setter>
<Setter Property="TextBox.TextAlignment" Value="Right" />
</Style>
<Style x:Key="textBoxStyle" TargetType="{x:Type TextBox}">
<Style.Triggers>
<Trigger Property="Validation.HasError" Value="True">
<Setter Property="Background" Value="Red" />
<Setter Property="ToolTip"
Value="{Binding RelativeSource={RelativeSource Self}, Path=(Validation.Errors)[0].ErrorContent}" />
</Trigger>
</Style.Triggers>
</Style>
</Window.Resources>
<StackPanel Orientation="Vertical">
<StackPanel Orientation="Horizontal">
<TextBox Style="{StaticResource textBoxStyle}">
<TextBox.Text>
<Binding>
<Binding.ValidationRules>
<local:JpgValidationRule />
</Binding.ValidationRules>
</Binding>
</TextBox.Text>
</TextBox>
</StackPanel>
<StackPanel Orientation="Horizontal">
<Button Style="{StaticResource controlStyle}">1</Button>
<ComboBox Style="{StaticResource controlStyle}">
<ComboBox.Items>2</ComboBox.Items>
</ComboBox>
<Expander Style="{StaticResource controlStyle}" Content="3" />
<TabControl Style="{StaticResource controlStyle}">
<TabControl.Items>4</TabControl.Items>
</TabControl>
<ToolBar Style="{StaticResource controlStyle}">
<ToolBar.Items>5</ToolBar.Items>
</ToolBar>
<!--<InkCanvas Style="{StaticResource controlStyle}" />-->
<TextBox Style="{StaticResource controlStyle}" Text="7" />
</StackPanel>
</StackPanel>
```
```
using System.Globalization;
using System.IO;
using System.Windows.Controls;
namespace StylesDemo
{
public class JpgValidationRule : ValidationRule
{
public override ValidationResult Validate(object value, CultureInfo cultureInfo)
{
string fileName = value.ToString();
// Reject nonexistent files:
if (!File.Exists(fileName))
return new ValidationResult(false, "Value is not a valid file!");
// Reject files that don't end in .jpg:
if (Path.GetExtension(fileName).ToUpper() != ".JPG")
return new ValidationResult(false, "Value is not a .jpg file!");
return new ValidationResult(true, null);
}
}
}
```
| Provide value on 'System.Windows.Data.Binding' threw an exception | CC BY-SA 2.5 | null | 2010-10-10T05:27:46.177 | 2010-11-09T07:19:21.577 | 2010-11-09T07:19:21.577 | 228,755 | 4,035 | [
"wpf",
"exception",
"data-binding",
"wpf-4.0"
] |
3,899,168 | 1 | null | null | 2 | 245 | What is the purpose of `base()` in the following code?
```
class mytextbox : TextBox
{
public mytextbox() : base()
{
this.Text = "stack";
}
}
```
---
Why At design time messages are displayed ؟
my code :
```
class Class1:TextBox
{
public Class1()
{
this.Resize += new EventHandler(Class1_Resize);
}
void Class1_Resize(object sender, EventArgs e)
{
MessageBox.Show("Resize");
}
}
```

| What is the code : base() | CC BY-SA 3.0 | 0 | 2010-10-10T05:45:43.340 | 2011-08-31T14:16:43.393 | 2011-08-31T14:16:43.393 | 1,288 | 471,352 | [
"c#",
"class",
"inheritance",
"constructor",
"default-constructor"
] |
3,899,312 | 1 | 3,899,984 | null | 3 | 1,834 | I have this strange bug with my popup menu. It happens rarely and seemingly randomly. The problem is when I have a submenu in my JPopupMenu - when I select the submenu, main menu disappears and the submenu is painted incorrectly (it's like the buffer of main menu is painted over the submenu). I can still navigate it using keyboard.
Here are some screenshots:
This is how it should look like

And this is what it looks like when the bug appears:

So that glitch on the second picture is where the submenu should've been.
What could cause this? There are no exceptions thrown, it doesn't seem platform-related, so I have no idea how to narrow this down. Please help.
Below is a sscce that reproduces the problem:
```
import javax.swing.*;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
public class Test {
private static Popup popup;
public static void main(String[] args) {
final JFrame frame = new JFrame();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.getContentPane().addMouseListener(new MouseAdapter() {
@Override
public void mousePressed(MouseEvent e) {
showMenu(e);
}
@Override
public void mouseReleased(MouseEvent e) {
showMenu(e);
}
private void showMenu(final MouseEvent e) {
if (e.isPopupTrigger()) {
JPopupMenu menu = new JPopupMenu();
JMenu subMenu = new JMenu("SubMenu");
menu.add(subMenu);
subMenu.add("Item 1");
subMenu.add("Item 2").addMouseMotionListener(new MouseAdapter() {
@Override
public void mouseMoved(MouseEvent e) {
hidePopup();
// this is where I call the hide twice, in my case it was
// caused by some action or mouse listener calling it twice
hidePopup();
showPopup(e, frame);
}
});
subMenu.add("Item 3");
menu.show(frame.getContentPane(), e.getX(), e.getY());
}
}
private void showPopup(MouseEvent e, JFrame frame) {
PopupFactory popupFactory = PopupFactory.getSharedInstance();
JToolTip toolTip = new JToolTip();
toolTip.setTipText("wfkwdlpfhd ");
popup = popupFactory.getPopup(frame, toolTip, e.getXOnScreen(), e.getYOnScreen());
popup.show();
}
private void hidePopup() {
if (popup != null)
popup.hide();
}
});
frame.setSize(300, 300);
frame.setLocationRelativeTo(null);
frame.setVisible(true);
}
}
```
| JPopupMenu bug/glitch(?) when showing submenu | CC BY-SA 2.5 | 0 | 2010-10-10T06:41:26.580 | 2011-03-08T15:35:29.970 | 2011-03-08T15:35:29.970 | 143,585 | 143,585 | [
"java",
"swing",
"submenu",
"jpopupmenu"
] |
3,899,463 | 1 | 3,899,478 | null | 118 | 146,867 | How can I prevent the textarea from stretching beyond its parent DIV element?
I have this textarea inside a table which is inside a DIV and it seems that it causes the entire table to stretch out of its bounds.
You can see an example of the same situation even in a more simple case, just putting a text area inside a div (like what is used here in www.stackoverflow.com)
You can see from the images below that the textarea can stretch beyond the size of its parent? How do I prevent this?
I'm kind of new to CSS so I don't really know what CSS attributes should I be using. I tried several like , and .
But they don't seem to do the trick.
Anything else I might have missed?


UPDATE:
HTML
CSS
```
textarea {
max-width: 50%;
}
#container {
width: 80%;
border: 1px solid red;
}
#cont2{
width: 60%;
border: 1px solid blue;
}
```
If you put this code inside the [http://jsfiddle.net](http://jsfiddle.net),
you will see that they act differently. Although the textarea is limited to the percentage declared in its css style, it is still possible to get it to cause its parent table to be as large as it wants to be, and then you can see that it spills over its parent border.
Any thoughts on how to fix this?
| How can I prevent the textarea from stretching beyond his parent DIV element? (google-chrome issue only) | CC BY-SA 3.0 | 0 | 2010-10-10T07:44:40.543 | 2019-09-12T08:17:33.737 | 2014-04-11T15:09:47.527 | 579,240 | 249,616 | [
"css",
"google-chrome",
"textarea"
] |
3,899,896 | 1 | 3,900,010 | null | 2 | 158 | One of my application is an engine that executes some complex calculations. These calculations may take several hours. I want to know the activity of this engine among time.
If you are using H[udson CI server](http://hudson-ci.org/), there is such a feature in `Administration > Usages statistics` option. Here is an example:

In my application, I already have a function that returns the number of calculations. So my idea is to periodically call this method, for example every 10 minutes (using [Quartz](http://www.quartz-scheduler.org/)) in order to retrieve the number of running calculations and store it in a `int[]`. Every day, this `int[]` is stored in an external file, and cleaned. So after some days, the content of this file will look like:
```
data.20101008=1;2;1;0;1;1;0;0;0;0;....;0
data.20101009=1;0;1;1;0;0;0;0;3;2;....;0
data.20101010=1;2;1;0;1;1;2;3;4;4;....;2
...
```
(I simplified a little this processing, as I want to update this file more frequently, in case of engine shutdown, or something like that)
To summarize, my idea is to store in a `properties` file the number of running calculations for a specific day. Eventually, I can provide a function that returns this data as a `Map<Date, int[]>`.
Finally, I will use [JFreeChart](http://www.jfree.org/jfreechart/) to display these data in a graphical
What do you think of this idea? Any advice to enhance this process?
Note that this functionality is one a feature, so I don't want to build too complex systems.
I am using Java 6.
| Getting statistics of the activity of my engine | CC BY-SA 2.5 | null | 2010-10-10T10:19:32.920 | 2011-03-24T09:13:11.710 | null | null | 26,457 | [
"java",
"statistics"
] |
3,899,903 | 1 | 4,015,730 | null | 10 | 6,375 | I'm toying with a small game on my iPad using cocos2d and I've run into some performance worries. I have a 512x512 image tiled as my background. That gives me around 40fps with 20 sprites (in a `CCSpriteBatchNode`), the code for the background is this:
```
CCSprite *background;
background = [CCSprite spriteWithFile:@"oak.png" rect : CGRectMake(0,
0,
size.width,
size.height)];
background.position = ccp( size.width /2 , size.height/2 );
ccTexParams params = {GL_LINEAR,GL_LINEAR,GL_REPEAT,GL_REPEAT};
[background.texture setTexParameters: ¶ms];
```
If I remove the background I get a solid 60fps.
I've tried converting the image to PVRTC and that did give an extra fps or two. I get identical framerates using a 1024x768 image instead of the tiled version.
Since my background will remain axis aligned, unscaled and generally static. I figure there should be a faster way to draw it than having it as a regular `CCSprite`?

| How to draw a background fast in cocos2d? | CC BY-SA 2.5 | 0 | 2010-10-10T10:20:34.403 | 2011-11-09T05:28:38.577 | 2020-06-20T09:12:55.060 | -1 | 914 | [
"iphone",
"objective-c",
"performance",
"ipad",
"cocos2d-iphone"
] |
3,899,973 | 1 | 3,901,577 | null | 0 | 1,175 | 
All works good if I insert sdl-config output manually.
How to fix this bug?
```
g++ -O3 -c 'sdl-config --cflags' test.cpp
g++.exe: sdl-config --cflags: no such dile or directory
```
| mingw g++ cant see sdl-config | CC BY-SA 2.5 | null | 2010-10-10T10:42:07.893 | 2010-10-10T18:23:12.403 | 2010-10-10T17:22:25.040 | 56,338 | 404,949 | [
"c++",
"windows",
"linux",
"unix",
"mingw"
] |
3,900,380 | 1 | null | null | 2 | 248 | I need a handy jQuery tool (plugin) to work with the map.
The project has narisovanaya map with cities marked on it, the possible routes.
Example

I want to:
- -
Now inclined to think that would work to implement the map through the canvas, but is not sure whether it is convenient to display the div with information about the city.
Maybe someone encountered a similar problem and help me avoid mistakes.
| I need a handy jQuery tool (plugin) to work with the map | CC BY-SA 2.5 | 0 | 2010-10-10T12:57:11.560 | 2010-10-10T13:32:29.820 | null | null | 309,067 | [
"jquery",
"dictionary",
"canvas",
"imagemap"
] |
3,900,392 | 1 | 3,900,422 | null | 8 | 8,766 | I am trying to draw a repeating background image in my NSView, I have this till now:
```
// INIT
- (id)initWithFrame:(NSRect)frame {
if (self = [super initWithFrame:frame]) {
self.backgroundImage = [NSImage imageNamed:@"progressBackground.pdf"];
}
return self;
}
// DRAW
- (void)drawRect:(NSRect)dirtyRect {
// Draw the background
[backgroundImage drawInRect:[self bounds]
fromRect:NSMakeRect(0.0f, 0.0f, backgroundImage.size.width, backgroundImage.size.height)
operation:NSCompositeSourceAtop
fraction:1.0f];
NSLog(@"%dx%d", backgroundImage.size.width, backgroundImage.size.height);
}
```
However, the view stretches the image to fill itself. I want the image to repeat instead.

(the black strokes are fixed already)
Also, something strange happens, as the console says the size of the image equals `-2109897792x0`, but the image really is `32x32`! WTF?!
Could someone help me, please? Thanks.
| Repeating background image in an NSView | CC BY-SA 3.0 | 0 | 2010-10-10T12:59:43.973 | 2013-12-29T21:28:57.513 | 2011-09-14T05:18:05.853 | null | null | [
"cocoa",
"drawing",
"nsview",
"nsimage"
] |
3,900,447 | 1 | 3,908,986 | null | 1 | 408 | I've a problem with the animation method.
```
<div id="containment">
<div id="child1">C1</div>
<div id="child2">C2</div>
<div id="child3">C3</div>
</div
```
C1 to C3 are draggable elements, and I haven't applied any constraint on it, because when I'm out of #containment, I automatically resize it.
```
$("#containment > div").bind("dragstop", function(event, ui) {
var size = $.extend({}, $("#containment").data("originalSize"));
$.each($("#containment > div"), function(index, d) {
width = parseInt($(d).css("left"), 10) + parseInt($(d).outerWidth(), 10);
height = parseInt($(d).css("top"), 10) + parseInt($(d).outerHeight(), 10);
size.width = (width > size.width) ? (width + 50) : size.width;
size.height = (height > size.height) ? (height + 50) : size.height;
});
$("#containment").animate({
width: size.width,
height: size.height
}, 'slow');
});
```
Problem is, when dragstop is fired, the child I moved out is hidden and appears only when the #containment animation is over it.
In my Screen B1 and B2 have the same size, just B1 isn't totally visible because animation is running...

Thanks
| jQuery containment animation | CC BY-SA 2.5 | null | 2010-10-10T13:18:48.880 | 2010-10-11T18:37:12.970 | null | null | 466,227 | [
"jquery",
"jquery-animate"
] |
3,900,722 | 1 | 3,936,851 | null | 0 | 2,698 | I have one QTableView object and when I am switching from showIndicators to showIndiValues I am getting this ugly empty header line. Where is the problem?

```
void DBTableView::showIndicators()
{
enum {
indicators_Id = 0,
indicators_Name = 1,
indicators_CondName = 2,
indicators_MeasureName = 3,
indicators_Description = 4,
indicators_Responsible = 5
};
QSqlQueryModel *model = new QSqlQueryModel;
model->setQuery("SELECT * FROM viewIndicators");
model->setHeaderData(indicators_Id, Qt::Horizontal, tr("ID"));
model->setHeaderData(indicators_Name, Qt::Horizontal, tr("Name"));
model->setHeaderData(indicators_CondName, Qt::Horizontal, tr("Condition Name"));
model->setHeaderData(indicators_MeasureName, Qt::Horizontal, tr("Measure"));
model->setHeaderData(indicators_Description, Qt::Horizontal, tr("Description"));
model->setHeaderData(indicators_Responsible, Qt::Horizontal, tr("Responsible"));
/* TableView part */
setModel(model);
hideColumn(indicators_Id);
QHeaderView *horizontalHeader = this->horizontalHeader();
horizontalHeader->setStretchLastSection(true);
QHeaderView *verticalHeader = this->verticalHeader();
verticalHeader->setStretchLastSection(true);
setSelectionBehavior(QAbstractItemView::SelectRows);
setColumnWidth(indicators_Id, 0);
setColumnWidth(indicators_Name, 400);
setColumnWidth(indicators_CondName, 120);
setColumnWidth(indicators_MeasureName, 120);
setColumnWidth(indicators_Description, 400);
createIndicatorContextMenu();
show();
}
void DBTableView::showIndiValues()
{
enum {
iv_Id = 0,
indicatorId = 1,
indicatorName = 2,
intervalName = 3,
iv_DataValue = 4,
iv_DataDate = 5,
iv_DataBirth = 6
};
QSqlQueryModel *model = new QSqlQueryModel;
model->setQuery("SELECT * FROM viewIndiValues");
model->setHeaderData(iv_Id, Qt::Horizontal, tr("ID"));
model->setHeaderData(indicatorId, Qt::Horizontal, tr("Indicator ID"));
model->setHeaderData(indicatorName, Qt::Horizontal, tr("Indicator name"));
model->setHeaderData(intervalName, Qt::Horizontal, tr("Interval name"));
model->setHeaderData(iv_DataValue, Qt::Horizontal, tr("Value"));
model->setHeaderData(iv_DataDate, Qt::Horizontal, tr("Date"));
model->setHeaderData(iv_DataBirth, Qt::Horizontal, tr("Creation date"));
setModel(model);
hideColumn(iv_Id);
hideColumn(indicatorId);
QHeaderView *horizontalHeader = this->horizontalHeader();
horizontalHeader->setStretchLastSection(false);
QHeaderView *verticalHeader = this->verticalHeader();
verticalHeader->setStretchLastSection(false);
setSelectionBehavior(QAbstractItemView::SelectItems);
setColumnWidth(indicatorName, 400);
setColumnWidth(intervalName, 200);
setColumnWidth(iv_DataValue, 200);
setColumnWidth(iv_DataDate, 120);
setColumnWidth(iv_DataBirth, 120);
createIndiValueContextMenu();
show();
}
```
| QTableView and empty header and column | CC BY-SA 2.5 | null | 2010-10-10T14:36:09.210 | 2010-10-14T19:33:53.540 | 2010-10-10T15:45:29.870 | 262,732 | 262,732 | [
"qt",
"qtableview"
] |
3,900,833 | 1 | 3,902,049 | null | 4 | 10,203 | I used this on a form and created it like 10 times. That was ok, until I tried to pass this number. Then it started eating system resources. Is there any way I could create a component like this? It is for a Simulator project, 8bits needed to indicate the value of the register in binary.

any help, comments, ideas are really appreciated.
ty.
| Custom Control Creation in Delphi | CC BY-SA 4.0 | 0 | 2010-10-10T15:10:17.803 | 2019-12-30T16:21:18.003 | 2019-12-30T16:21:18.003 | 49,925 | 439,219 | [
"delphi",
"delphi-7",
"custom-component"
] |
3,900,852 | 1 | 3,901,693 | null | 2 | 612 | I'm trying to fill a `DataGrid` with an anonymous type generated by a LINQ query. When I put the query results in a list box, it appears fine. However, when I put the query results in a data grid, the correct number of rows are generated, but the cells are empty.

(The data grid is on the left, with the list box on the right.)
Assigning the data source:
```
testListBox.ItemsSource = debtPerUser.ItemsSource = ExpenseViewModel.getDebtData(username);
```
The XAML:
```
<sdk:DataGrid Height="222" HorizontalAlignment="Left" Margin="31,89,0,0" Name="debtPerUser" VerticalAlignment="Top" Width="516" AutoGenerateColumns="True" />
<ListBox Height="222" HorizontalAlignment="Left" Margin="567,89,0,0" Name="testListBox" VerticalAlignment="Top" Width="173" />
```
What could I be doing wrong here?
getDebtData:
```
internal static IEnumerable getDebtData(string username)
{
IEnumerable<String> users = getUsersInvolving(username);
var debt = from user in users
select new {
User = user,
Net = owedBetween(username, user) - owedBetween(user, username)
};
return debt.Where(d => d.Net != 0);
}
```
: It works when I'm not using an anonymous query type. Perhaps that's the problem?
| Silverlight: Empty Data Grid | CC BY-SA 2.5 | 0 | 2010-10-10T15:15:00.943 | 2010-10-10T18:50:44.547 | 2010-10-10T18:34:03.543 | 147,601 | 147,601 | [
"c#",
"silverlight",
"linq"
] |
3,900,916 | 1 | 3,900,971 | null | 4 | 4,984 | Just wondering if it's possible to add a button like the "Clear History", "Clear Cookies" etc buttons in the Safari preferences to your own app's settings bundle? Been digging through the dev docs and can't find any plist specifier for a button, so I'm wondering if this is an internal API for the Apple guys?
After you hit the button, you get an action sheet asking you whether you really want to do it, and then presumably there is some callback based on the user's input.
Also noticed that the Nike + iPod settings have a clear button in them, but again, that app might have access to internal APIs that we don't.

| Adding a button to an iPhone prefs / settings bundle? | CC BY-SA 2.5 | null | 2010-10-10T15:34:24.440 | 2012-08-22T05:28:03.003 | null | null | 288,502 | [
"iphone",
"plist",
"preferences"
] |
3,901,220 | 1 | null | null | 2 | 1,813 | Why are messages displayed at design-time?
My code is :
```
class Class1 : TextBox
{
public Class1()
{
this.Resize += new EventHandler(Class1_Resize);
}
void Class1_Resize(object sender, EventArgs e)
{
MessageBox.Show("Resize");
}
}
```
Pic :

| Winforms: Why do events fire at design-time? | CC BY-SA 2.5 | null | 2010-10-10T16:55:43.910 | 2010-10-10T17:01:52.367 | 2010-10-10T17:01:52.367 | 412,770 | 471,352 | [
"c#",
".net",
"winforms",
"events",
"windows-forms-designer"
] |
3,901,322 | 1 | 3,901,500 | null | 2 | 145 | I have a project that I am working on and I can't figure out which would be a "better" table relationship schema.
The scope of the area in question are:
- User uploads documents (become the owner/author)- User can share document with other users (set share rights)- Any user who has access to document can checkout the document (exclusive lock)
My original schema looks like this:

Benefits are:
- only one user can be author. (authorid)- Rights table contain only "sharerights" (Read, Write)- User has easy distinction as to which files they "own" (authorid) vs sharedfiles (sharedfiles table). (this one is a weak benefit, I know)
After thinking things through I thought that this might be a better schema:

Benefits are:
- All document associations are located in one location (UserFiles)- Future ability to allow multiple authors/owner of a single document
Rights table would now have Read, Write, and Owner. As soon as a document was uploaded by a user, an automatic association would be made to a new document and the user would be given "owner" rights.
This led me to the final schema:

Benefits are:
-
The only problem with this last model is that I plan to add "special" user for each department so that a user could share a document to an entire department. So I am not sure if I want to associate the share association to the checkoutID (if that makes sense). The query for the users files would look like "select all files where userfiles.userid = me.userid || (userfiles.id == SpecialDepID && me.depid == SpecialDepID)" (major pseudo code)
It has been a long time since I have done database schemas and this one design decision is really racking my brain. It is really bugging me as to which design would be "better" and by better I mean better design principles, better decision based off of previous experience, allows for easier "growth" in the design, etc. Please let me know your thoughts!
## FINAL SOLUTION
With the help from Michael Madsen the final solution looks like:

There will be a trigger on UserFiles for delete which will determine if a lock should be deleted when a relationship is removed.
| Proper Table Schema | CC BY-SA 3.0 | 0 | 2010-10-10T17:24:46.157 | 2017-06-11T13:49:32.543 | 2017-06-11T13:49:32.543 | 4,370,109 | 207,305 | [
"sql-server",
"database-design",
"schema",
"database-schema"
] |
3,901,404 | 1 | 3,951,892 | null | 7 | 2,713 | How can I detect the difference between 2 images, creating a mask of the area that's different in order to process the area that's common to both images (gaussian blur for example)?

I'm currently using this code to get the RGBA value of pixels:
```
+ (NSArray*)getRGBAsFromImage:(UIImage*)image atX:(int)xx andY:(int)yy count:(int)count
{
NSMutableArray *result = [NSMutableArray arrayWithCapacity:count];
// First get the image into your data buffer
CGImageRef imageRef = [image CGImage];
NSUInteger width = CGImageGetWidth(imageRef);
NSUInteger height = CGImageGetHeight(imageRef);
CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB();
unsigned char *rawData = malloc(height * width * 4);
NSUInteger bytesPerPixel = 4;
NSUInteger bytesPerRow = bytesPerPixel * width;
NSUInteger bitsPerComponent = 8;
CGContextRef context = CGBitmapContextCreate(rawData, width, height,
bitsPerComponent, bytesPerRow, colorSpace,
kCGImageAlphaPremultipliedLast | kCGBitmapByteOrder32Big);
CGColorSpaceRelease(colorSpace);
CGContextDrawImage(context, CGRectMake(0, 0, width, height), imageRef);
CGContextRelease(context);
// Now your rawData contains the image data in the RGBA8888 pixel format.
int byteIndex = (bytesPerRow * yy) + xx * bytesPerPixel;
for (int ii = 0 ; ii < count ; ++ii)
{
CGFloat red = (rawData[byteIndex] * 1.0) / 255.0;
CGFloat green = (rawData[byteIndex + 1] * 1.0) / 255.0;
CGFloat blue = (rawData[byteIndex + 2] * 1.0) / 255.0;
CGFloat alpha = (rawData[byteIndex + 3] * 1.0) / 255.0;
byteIndex += 4;
UIColor *acolor = [UIColor colorWithRed:red green:green blue:blue alpha:alpha];
[result addObject:acolor];
}
free(rawData);
return result;
}
```
The problem is, the images are being captured from the iPhone's camera so they are not exactly the same position. I need to create areas of a couple of pixels and extracting the general color of the area (maybe by adding up the RGBA values and dividing by the number of pixels?). How could I do this and then translate it to a CGMask?
I know this is a complex question, so any help is appreciated.
Thanks.
| Create a mask from difference between two images (iPhone) | CC BY-SA 3.0 | 0 | 2010-10-10T17:48:31.653 | 2012-12-09T20:39:49.170 | 2012-12-09T20:39:49.170 | 289,251 | 289,251 | [
"iphone",
"image-processing",
"core-graphics",
"mask"
] |
3,901,537 | 1 | 3,901,552 | null | 1 | 78 | I copy pasted the code from [http://jqueryui.com/demos/slider/range.html](http://jqueryui.com/demos/slider/range.html) for local testing. And what I see is different from what the url shows. When I click the slider "big dots" (used to change the value) the dot image gets a dotted border around it and it doesn't go away after I release the click until I focus another element on the page.
Here's how it looks in my local test (using Vader theme makes it easy to see):

Why this doesn't happen on the example from jQueryUI demos?
| Jquery sliders behaves differently than example from documentation | CC BY-SA 2.5 | null | 2010-10-10T18:14:17.147 | 2010-10-10T18:18:56.237 | 2010-10-10T18:18:56.237 | 139,010 | 466,129 | [
"javascript",
"jquery",
"html",
"image",
"jquery-ui"
] |
3,901,603 | 1 | null | null | 31 | 61,077 | I need circular progress indicator. How should I implement this?
What I'm looking for is what jQuery UI has in their planning page, but its not yet implemented. I'm just curious if anyone has implemented this before. See item 6 in following image.

[http://wiki.jqueryui.com/ProgressIndicator](http://wiki.jqueryui.com/ProgressIndicator)
| Circular progress indicator with jQuery | CC BY-SA 3.0 | 0 | 2010-10-10T18:31:53.173 | 2015-08-25T08:01:57.187 | 2015-08-25T08:00:58.563 | 444,991 | 159,793 | [
"jquery",
"progress-bar"
] |
3,901,752 | 1 | 3,901,806 | null | 6 | 10,031 | My app. contains the window in the picture:

The ItemsSource of the DataGrid is set to _editList ( ).
The data grid is set to .
The Vendor Name text box has the binding set as :
This works well. However, as it is the Vendor Name cell only updates when the user is done typing in the Vendor Name textbox and clicks on something else. Say I want to change the vendor name to "John Lennon II" . I have to click on the textbox and type the characters I want to add and than I have to click on something else and only then the datagrid makes the update.
I want to make the update happen as the user types the characters....Is this possible ?
Regards,
Sebastian
| DataGrid , TextBox - binding and instant updates | CC BY-SA 2.5 | 0 | 2010-10-10T19:06:39.657 | 2011-07-10T02:17:18.040 | null | null | 275,289 | [
"wpf",
"datagrid",
"binding"
] |
3,901,792 | 1 | 3,902,000 | null | 3 | 3,974 | In Apple's Provisioning Portal "How To" under Certificates, there is a section called "Saving your Private Key and Transferring to other Systems". Now this is what I'm doing (I have rebuilt my machine with a new HDD and therefore have access to my previous OS build) and I'm looking to backup my private key so I can install it on my new OS build and start codesigning iPhone Applications again.
The problem is, in the [how to](https://developer.apple.com/ios/manage/certificates/team/howto.action), it says to backup the "<First Name> <Last Name> public certificate that is paired with it." (although the image is a private key):

And so when I checked my KeyChain, I've found 9 Private keys and 9 Public keys with my name on, so how do I know what I'm looking for?
I found in the first private key, it has this access control:

But when importing this I get a message saying it cannot import :(
So really, I just want to know which one I need to import - I guess I can try trial and error with them but would like to know either way.
| Moving Xcode certificate to new system for iPhone Dev | CC BY-SA 2.5 | 0 | 2010-10-10T19:15:50.977 | 2010-10-10T20:31:05.020 | 2010-10-10T20:31:05.020 | 143,979 | 143,979 | [
"iphone",
"xcode",
"certificate"
] |
3,901,986 | 1 | 3,902,174 | null | 0 | 941 | another homework assignment here thats kind of unclear on the requirements. It is a forms program that assigns people to seats on an airplane. The part that is losing me is that its telling me to display the passenger manifest in a list box, but then its telling me to display it in a list box. Then it calls it a rich text box again. The screenshots provided with the assignment only show one display box. One of the events that is supposed to be included is a double click on an item in the manifest display. When the flight is closed, it tallies up your first class and business class passengers and displays that info in the same display box.
So my question is, was list box somehow incorporated into the rich text box? I thought maybe it was just overlayed, but later screenschots show the display box filled and scrolled down, as if it were all the same text box, rather than just a list box or rich text. I'm confused. Obviously, I'm not looking for anyone to do my work for me, but it doesn't appear this was covered in our material. Online class, so I don't get a lot of instructor feedback on stuff like this, unfortunately. Can anyone offer to shed any light on this?

| Combining list boxes into rich text boxes? | CC BY-SA 2.5 | null | 2010-10-10T20:09:11.307 | 2010-10-10T20:59:49.837 | 2010-10-10T20:18:14.880 | 50,913 | 462,631 | [
"c#",
"winforms",
"listbox",
"richtextbox"
] |
3,902,218 | 1 | 4,785,383 | null | 0 | 950 | Opera has unacceptable rendering of image-bullet positioning of list items.
[Look at demo page with Opera and different browser.](http://rayz.ru/misc/askdev/list-style-image/list.html)
```
/* body {line-height:150%;} */
ul {list-style: none outside url('img/bullet-lilac.gif');
```
```
<ul>
<li><a href="">Ut enim ad minim veniam</a></li>
<li>Sample item</li>
</ul>
```
Bullets in `Opera` are indented to top of the line. That's too bad. Is there any solutions of some kind of hacks?
Not interested in `background-image` tricks.
. `Opera` on background, `Chrome` on foreground

| "list-style-image" picture identation in Opera via CSS | CC BY-SA 2.5 | null | 2010-10-10T21:12:13.443 | 2012-02-25T22:16:01.763 | 2012-02-25T22:16:01.763 | 246,246 | 81,430 | [
"css",
"opera",
"html-lists"
] |
3,902,357 | 1 | 3,902,387 | null | 4 | 117 | [http://elektrikhost.com/](http://elektrikhost.com/)
You see the penguins thats over the header on the columns? I'm trying to get them to be over the header and list. I'm wondering what would you do? use position absolute, or relative? I'm stuck.
HTML:
```
<section class="starter">
<img src="../images/plan-icon.png" width="62" height="73" alt="Plan Icon">
<h2>Starter Plan</h2>
<ul>
<li><span>5GB Disk Space</span></li>
<li><span>Unmetered Bandwidth</span></li>
<li><span>Unlimited Add-on Domains</span></li>
<li><span>Unlimited Subdomains</span></li>
<li><span>Unlimited Email/FTP Accounts</span></li>
<li><span>Unlimited MySQL Databases</span></li>
<li><span>Shell access upon request</span></li>
</ul>
<img src="images/starterplan.png" width="192" height="51" alt="Starter Plan">
</section><!-- //.starter -->
```
.plan-icon is the image.
Needs to look like this:

| How would you position these images? | CC BY-SA 2.5 | null | 2010-10-10T21:49:40.587 | 2010-10-10T22:51:46.153 | null | null | 363,551 | [
"css",
"image",
"position"
] |
3,902,497 | 1 | null | null | 0 | 1,093 | I have been searching far and wide for a solution on how to offer slow motion and fast motion options for users that upload video to my webstie. There is an implementation on Google Video that has exactly what I am looking for: the option to speed up or slow down the video and continue to play the audio. The screenshot is below.
I know that Flowplayer has an option to slow down or speed up video when implemented with Wowza server. However, when using that approach, there is no sound.
I have also seen the option from Enounce called MySpeed that allows video to be slowed or quickened, but this requires a browser plugin which is too much of a barrier for our users.
So here's the question: How does Google do it? How can you add an option to a flash player to slow down or speed up video?
Here is a screen shot. You can see the option to change the speed of the video to 1.5x. It also has options to go to 0.5x, 1.25x, 1.5x, 1.75x, 2.0x, 2.5x, and 3.0x.

| How does Google Video allow for slow motion and fast motion? | CC BY-SA 2.5 | null | 2010-10-10T22:32:08.677 | 2010-11-24T14:50:48.950 | null | null | 61,195 | [
"flash",
"video-streaming",
"media",
"video-encoding"
] |
3,902,523 | 1 | 3,902,569 | null | 1 | 1,667 | 
I am keep getting this error while uploading..I have no idea what this error are and how to resolve them...my build was successful(there are some warnings) my application is tested on iOS 4.1...any help is highly appreciated.
Thanks
| What could be the reason for the error? Please see detail showing image of error | CC BY-SA 2.5 | null | 2010-10-10T22:43:10.337 | 2012-03-16T18:21:20.583 | null | null | 459,000 | [
"iphone"
] |
3,902,629 | 1 | 4,178,239 | null | 15 | 17,591 | I'm having trouble adding the nice shadow on focus for an input box on my ipad for safari.
Here's my code
```
/* remember to define focus styles! */
:focus {
outline: 0;
}
input[type=text]{
width: 494px;
height: 44px;
line-height: 44px;
font-size: 24px;
border: 2px solid #666666;
}
input:focus{
-webkit-box-shadow:0 0 15px #ffffff;
-moz-box-shadow: 0 0 15px #ffffff;
box-shadow:0 0 15px #ffffff;
}
```
I'm using eric meyer's reset.
I want it to look like this:

Any ideas?
Thanks guys.
Jason
| box shadow on an ipad / safari | CC BY-SA 2.5 | 0 | 2010-10-10T23:24:13.010 | 2015-10-08T07:40:59.683 | null | null | 311,465 | [
"ipad",
"safari",
"input",
"focus",
"css"
] |
3,902,701 | 1 | 3,902,741 | null | 3 | 1,334 | I have the following window in my app:

The list is declared as : ; and the datagrid is populated via :
The "New" button creates a new Vendor and adds the vendor the _editList.
Unfortunately.... the new vendor does not show up in the datagrid........any ideas on how to make the new item show up ??
Regards,
Sebastian
| WPF datagrid binding : add new item | CC BY-SA 2.5 | null | 2010-10-10T23:52:14.703 | 2010-10-27T14:25:58.093 | null | null | 275,289 | [
"wpf",
"datagrid",
"binding"
] |
3,902,833 | 1 | 3,902,850 | null | 0 | 1,911 | I have a mystery 1px bottom border showing up in Safari and Chrome (I guess a WebKit thing). Firefox displays it fine.
The button below should sit flush with the bar beneath. There should not be that 1px line separating them.

I've played around with `height`, `border`, `position`, `padding` and `margin` but haven't been able to figure this one out.
Changing `bottom: 0` to `bottom: -5px` in Web Inspector still produces the line.
There are quite a lot of styles going into it, so I'll try and amalgamate the cascade.
```
#tell-a-friend {
background-repeat:no-repeat;
display:block;
height:33px;
margin-right:0;
position:absolute;
float:right;
font-size:1.2em;
margin-right:0.8em;
background-position:right 0;
bottom:0;
height:35px !important;
left:682px;
width:82px;
}
```
Then again, I may be better off [linking to the site](https://www.bustersdirect.com.au/).
The CSS is minified, so use Web Inspector to view the CSS.
I've tried everything I can think of right now, so I'm going to see if you guys can help me :)
Many thanks!
| Mystery 1px border in WebKit | CC BY-SA 2.5 | null | 2010-10-11T00:30:26.120 | 2010-10-11T00:51:24.800 | null | null | 31,671 | [
"css",
"webkit"
] |
3,903,011 | 1 | 3,904,046 | null | 2 | 1,302 | I'm having quite a bit of trouble trying to get inheritance to work in EF4. The original model is quite large, however I have managed to replicate it in a model of just two entities.
Essentially the two tables are "Asset" and "Questionnaire". Questionnaire inherits Asset (i.e. Questionnaire is an Asset). They do this by Questionnaire having an AssetID linking back to the Asset. Technically the design may not be the best however I'm trying to make this work for a 10 year old database without any major redesigns...
So given that, the tables are:
- -
- - -
The model for this is extremely simplistic - essentially it is:

The EDMX file for this is:
```
<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx Version="2.0" xmlns:edmx="http://schemas.microsoft.com/ado/2008/10/edmx">
<!-- EF Runtime content -->
<edmx:Runtime>
<!-- SSDL content -->
<edmx:StorageModels>
<Schema Namespace="SnapServerModel.Store" Alias="Self" Provider="System.Data.SqlClient" ProviderManifestToken="2008" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns="http://schemas.microsoft.com/ado/2009/02/edm/ssdl">
<EntityContainer Name="SnapServerModelStoreContainer">
<EntitySet Name="Asset" EntityType="SnapServerModel.Store.Asset" store:Type="Tables" Schema="dbo" />
<EntitySet Name="Content_Questionnaire" EntityType="SnapServerModel.Store.Content_Questionnaire" store:Type="Tables" Schema="dbo" />
<AssociationSet Name="FK_Content_Questionnaire_Asset" Association="SnapServerModel.Store.FK_Content_Questionnaire_Asset">
<End Role="Asset" EntitySet="Asset" />
<End Role="Content_Questionnaire" EntitySet="Content_Questionnaire" />
</AssociationSet>
</EntityContainer>
<EntityType Name="Asset">
<Key>
<PropertyRef Name="AssetID" />
</Key>
<Property Name="AssetID" Type="uniqueidentifier" Nullable="false" />
</EntityType>
<EntityType Name="Content_Questionnaire">
<Key>
<PropertyRef Name="Id" />
</Key>
<Property Name="Id" Type="uniqueidentifier" Nullable="false" />
<Property Name="AssetID" Type="uniqueidentifier" Nullable="false" />
</EntityType>
<Association Name="FK_Content_Questionnaire_Asset">
<End Role="Asset" Type="SnapServerModel.Store.Asset" Multiplicity="1" />
<End Role="Content_Questionnaire" Type="SnapServerModel.Store.Content_Questionnaire" Multiplicity="*" />
<ReferentialConstraint>
<Principal Role="Asset">
<PropertyRef Name="AssetID" />
</Principal>
<Dependent Role="Content_Questionnaire">
<PropertyRef Name="AssetID" />
</Dependent>
</ReferentialConstraint>
</Association>
</Schema></edmx:StorageModels>
<!-- CSDL content -->
<edmx:ConceptualModels>
<Schema Namespace="SnapServerModel" Alias="Self" xmlns:annotation="http://schemas.microsoft.com/ado/2009/02/edm/annotation" xmlns="http://schemas.microsoft.com/ado/2008/09/edm">
<EntityContainer Name="SnapServerEntities" annotation:LazyLoadingEnabled="true">
<EntitySet Name="Assets" EntityType="SnapServerModel.Asset" />
<AssociationSet Name="FK_Content_Questionnaire_Asset" Association="SnapServerModel.FK_Content_Questionnaire_Asset">
<End Role="Asset" EntitySet="Assets" />
<End Role="Content_Questionnaire" EntitySet="Assets" />
</AssociationSet>
</EntityContainer>
<EntityType Name="Asset">
<Key>
<PropertyRef Name="AssetID" />
</Key>
<Property Type="Guid" Name="AssetID" Nullable="false" />
<NavigationProperty Name="Content_Questionnaire" Relationship="SnapServerModel.FK_Content_Questionnaire_Asset" FromRole="Asset" ToRole="Content_Questionnaire" />
</EntityType>
<EntityType Name="Content_Questionnaire" BaseType="SnapServerModel.Asset">
<Property Type="Guid" Name="Id" Nullable="false" />
<NavigationProperty Name="Asset" Relationship="SnapServerModel.FK_Content_Questionnaire_Asset" FromRole="Content_Questionnaire" ToRole="Asset" />
</EntityType>
<Association Name="FK_Content_Questionnaire_Asset">
<End Type="SnapServerModel.Asset" Role="Asset" Multiplicity="1" />
<End Type="SnapServerModel.Content_Questionnaire" Role="Content_Questionnaire" Multiplicity="1" />
<ReferentialConstraint>
<Principal Role="Asset">
<PropertyRef Name="AssetID" />
</Principal>
<Dependent Role="Content_Questionnaire">
<PropertyRef Name="AssetID" />
</Dependent>
</ReferentialConstraint>
</Association>
</Schema>
</edmx:ConceptualModels>
<!-- C-S mapping content -->
<edmx:Mappings>
<Mapping Space="C-S" xmlns="http://schemas.microsoft.com/ado/2008/09/mapping/cs">
<EntityContainerMapping StorageEntityContainer="SnapServerModelStoreContainer" CdmEntityContainer="SnapServerEntities">
<EntitySetMapping Name="Assets">
<EntityTypeMapping TypeName="IsTypeOf(SnapServerModel.Asset)">
<MappingFragment StoreEntitySet="Asset">
<ScalarProperty Name="AssetID" ColumnName="AssetID" />
</MappingFragment>
</EntityTypeMapping>
<EntityTypeMapping TypeName="IsTypeOf(SnapServerModel.Content_Questionnaire)">
<MappingFragment StoreEntitySet="Content_Questionnaire">
<ScalarProperty Name="Id" ColumnName="Id" />
<ScalarProperty Name="AssetID" ColumnName="AssetID" />
</MappingFragment>
</EntityTypeMapping>
</EntitySetMapping>
</EntityContainerMapping>
</Mapping>
</edmx:Mappings>
</edmx:Runtime>
<!-- EF Designer content (DO NOT EDIT MANUALLY BELOW HERE) -->
<Designer xmlns="http://schemas.microsoft.com/ado/2008/10/edmx">
<Connection>
<DesignerInfoPropertySet>
<DesignerProperty Name="MetadataArtifactProcessing" Value="EmbedInOutputAssembly" />
</DesignerInfoPropertySet>
</Connection>
<Options>
<DesignerInfoPropertySet>
<DesignerProperty Name="ValidateOnBuild" Value="true" />
<DesignerProperty Name="EnablePluralization" Value="True" />
<DesignerProperty Name="IncludeForeignKeysInModel" Value="True" />
</DesignerInfoPropertySet>
</Options>
<!-- Diagram content (shape and connector positions) -->
<Diagrams>
<Diagram Name="Model1">
<EntityTypeShape EntityType="SnapServerModel.Asset" Width="1.5" PointX="0.75" PointY="2.125" Height="1.4033821614583335" />
<EntityTypeShape EntityType="SnapServerModel.Content_Questionnaire" Width="1.5" PointX="3" PointY="2.125" Height="1.4033821614583339" />
<AssociationConnector Association="SnapServerModel.FK_Content_Questionnaire_Asset" >
<ConnectorPoint PointX="2.25" PointY="2.4133455403645834" />
<ConnectorPoint PointX="3" PointY="2.4133455403645834" />
</AssociationConnector>
<InheritanceConnector EntityType="SnapServerModel.Content_Questionnaire" ManuallyRouted="false" >
<ConnectorPoint PointX="2.25" PointY="2.8266910807291667" />
<ConnectorPoint PointX="3" PointY="2.8266910807291667" />
</InheritanceConnector>
</Diagram>
</Diagrams>
</Designer>
</edmx:Edmx>
```
Now my problem is that no matter what I've tried - I'm getting two error messages:
1. Error 1 Error 3002: Problem in mapping fragments starting at line 87:Potential runtime violation of table Content_Questionnaire's keys (Content_Questionnaire.Id): Columns (Content_Questionnaire.Id) are mapped to EntitySet Assets's properties (Assets.Id) on the conceptual side but they do not form the EntitySet's key properties (Assets.AssetID).
2. Error 2 Error 3003: Problem in mapping fragments starting at line 87:All the key properties (Assets.AssetID) of the EntitySet Assets must be mapped to all the key properties (Content_Questionnaire.Id) of table Content_Questionnaire.
How on earth do I get rid of these errors?
It is probably something completely obvious that I am missing - however help or even a nudge in the right direction would be greatly appreciated. I've been getting a few grey hairs trying to work through this one today!
Thanks in advance for any help you may be able to shed.
| EF4 Inheritance issues using Table per Type | CC BY-SA 2.5 | null | 2010-10-11T01:32:05.580 | 2010-10-11T06:56:16.150 | null | null | 158,128 | [
"c#",
"entity-framework",
"entity-framework-4"
] |
3,903,085 | 1 | 3,903,168 | null | 4 | 2,956 | I'm building a UITableView similar to iPod.app's album browsing view:

I'm importing all the artists and album artworks from the iPod library on first launch. Saving everything to CoreData and getting it back into an NSFetchedResultsController. I'm reusing cell identifiers and in my `cellForRowAtIndexPath:` method I have this code:
```
Artist *artist = [fetchedResultsController objectAtIndexPath:indexPath];
NSString *identifier = @"bigCell";
SWArtistViewCell *cell = (SWArtistViewCell*)[tableView dequeueReusableCellWithIdentifier:identifier];
if (cell == nil)
cell = [[[SWArtistViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:identifier] autorelease];
cell.artistName = artist.artist_name;
cell.artworkImage = [UIImage imageWithData:artist.image];
[cell setNeedsDisplay];
return cell;
```
My SWArtistViewCell cell implements the `drawRect:` method to draw both the string and image:
```
[artworkImage drawInRect:CGRectMake(0,1,44,44)]
[artistName drawAtPoint:CGPointMake(54, 13) forWidth:200 withFont:[UIFont boldSystemFontOfSize:20] lineBreakMode:UILineBreakModeClip];
```
Scrolling is still choppy and I just can't figure out why. Apps like iPod and Twitter have butter smooth scrolling and yet they both draw some small image in the cell as I do.
All my views are opaque. What am I missing?
: here's what Shark says:
I'm not familiar with Shark. Any pointer as of what are these symbols related to? When I look at the trace of these, they all point to my drawRect: method, specifically the UIImage drawing.

Would it point to something else if the chokehold was the file reading? Is it definitely the drawing?
I've done as pothibo suggested and added an artworkImage method to my Artist class that retains the image created with imageWithData:
```
- (UIImage*)artworkImage {
if(artworkImage == nil)
artworkImage = [[UIImage imageWithData:self.image] retain];
return artworkImage;
}
```
So now I can directly set the retained image to my TableViewCell as follow:
```
cell.artworkImage = artist.artworkImage;
```
I also set my setNeedsDisplay inside the setArtworkImage: method of my tableViewCell class. Scrolling is still laggy and Shark shows exactly the same results.
| Scrolling performance and UIImage drawing | CC BY-SA 3.0 | 0 | 2010-10-11T01:56:26.153 | 2019-06-09T13:21:27.510 | 2011-10-28T21:19:06.597 | 757,830 | 87,158 | [
"iphone",
"performance",
"image",
"uitableview",
"scroll"
] |
3,903,294 | 1 | 3,903,524 | null | 1 | 240 | I want to make an animation like SwichView example in "Beginning iPhone development". My animation code:
```
[UIView beginAnimations:@"View Flip" context:nil];
[UIView setAnimationDuration:1.25];
[UIView setAnimationCurve:UIViewAnimationCurveEaseInOut];
[UIView setAnimationTransition:
UIViewAnimationTransitionFlipFromRight
forView:self.view cache:YES];
[blueViewController viewWillAppear:YES];
[yellowViewController viewWillDisappear:YES];
[blueViewController.view removeFromSuperview];
[self.view insertSubview:yellowViewController.view atIndex:0];
[yellowViewController viewDidDisappear:YES];
[blueViewController viewDidAppear:YES];
[UIView commitAnimations];
```

But i want my Toolbar don't "flip" with another view. I don't want it perform any animation. Can i do it?
Here is SwitchView example:
[http://www.mediafire.com/?lirh0ydcy6c2f9d](http://www.mediafire.com/?lirh0ydcy6c2f9d)
| Apply animation in specified UIView? | CC BY-SA 2.5 | null | 2010-10-11T03:08:03.183 | 2012-03-03T10:01:58.847 | null | null | 122,456 | [
"iphone",
"objective-c",
"ios"
] |
3,903,536 | 1 | 3,907,009 | null | 0 | 1,167 | The following print screen shows list of resources file embedded into the package. Is it possible to organize the highlighted resources (SE_BUG...SY_VIEW) into hierarchy way ? What i mean here is that can I create a call under the and move all the highlighted resources (SE_BUG...SY_VIEW) into the ? In other words, I want to achieve the highlighted resources in well organized such as the way of .

| Delphi: Organize RCData into hierarchy way | CC BY-SA 2.5 | null | 2010-10-11T04:35:03.407 | 2010-10-11T14:15:11.647 | null | null | 438,584 | [
"delphi",
"resources"
] |
3,903,538 | 1 | null | null | 11 | 2,615 | I'm trying to calculate the absolute deviation of a vector [online](http://en.wikipedia.org/wiki/Online_algorithm), that is, as each item in the vector is received, without using the entire vector. The absolute deviation is the sum of the absolute difference between each item in a vector and the mean:
> 
I know that the variance of a vector can be calculated in such a manner. Variance is similar to absolute deviation, but each difference is squared:
> 
The online algorithm for variance is as follows:
```
n = 0
mean = 0
M2 = 0
def calculate_online_variance(x):
n = n + 1
delta = x - mean
mean = mean + delta/n
M2 = M2 + delta*(x - mean) # This expression uses the new value of mean
variance_n = M2/n
return variance_n
```
Is there such an algorithm for calculating absolute deviance? I cannot formulate a recursive definition myself, but wiser heads may prevail!
| Online algorithm for calculating absolute deviation | CC BY-SA 2.5 | 0 | 2010-10-11T04:36:09.853 | 2010-10-12T02:42:18.367 | 2010-10-12T02:42:18.367 | 90,527 | 103,225 | [
"algorithm",
"language-agnostic",
"math",
"statistics"
] |
3,903,594 | 1 | 3,903,608 | null | 0 | 63 | 
i'm test a regular expression,i curious about the match result,
the symbol * is greendy,in my option,the result shuld only match 1 result,
like belows:
```
<script language=javascript>
ati('#', '../../../UpLoadFile/Product/20101010162153846.jpg', '加厚青色围脖');
}
</script>
<script language=javascript>
ati
```
but the result is not what i expect,any one could help me explain it,thank you?
| regular expression problem | CC BY-SA 2.5 | null | 2010-10-11T04:51:09.070 | 2010-10-11T04:55:42.973 | null | null | 446,929 | [
"regex",
"greedy"
] |
3,903,607 | 1 | null | null | 6 | 341 | 
When an dialog pops up,which line actually has/ the problem, the line hinted by green arrow or the line above?
Is there any official reference for this corner case?
So far it still seems that both are possible.Can anyone come up with a final conclusion?
| About debug UI of visual studio | CC BY-SA 2.5 | null | 2010-10-11T04:55:10.587 | 2010-10-16T10:29:25.943 | 2020-06-20T09:12:55.060 | -1 | 471,944 | [
"visual-studio",
"debugging"
] |
3,903,747 | 1 | 3,903,764 | null | 5 | 31,116 | 
```
<!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" dir="ltr">
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.0/jquery.min.js" type="text/javascript"></script>
<style type="text/css">
.connection {
cursor:pointer;
display:block;
height:80px;
position:absolute;
width:50px;
}
.ui-widget-content {
color:#FFFFFF;
}
.ui-corner-all {
-moz-border-radius:6px 6px 6px 6px;
}
.ui-widget-content {
background:url("images/ui-bg_inset-soft_25_000000_1x100.png") repeat-x scroll 50% bottom #000000;
border:1px solid #666666;
color:#FFFFFF;
}
.ui-widget {
font-family:Segoe UI,Arial,sans-serif;
font-size:1.1em;
}
.con-text {
font-size:0.7em;
margin-top:-0.7em;
padding:2px;
}
.conimage {
background:url("access-link-card.png") no-repeat scroll 0 0 transparent;
}
.con-icon {
margin:0 auto;
text-align:center;
z-index:100;
background: url("access-link-card.png") no-repeat;
padding-left: 34px;
}
</style>
</head>
</head>
<body>
<div class="connection ui-draggable" id="connection-581" style="left: 435px; top: 123px;">
<div class="con-icon" id="con_icon-581">
<div class="con-text ui-widget ui-widget-content ui-corner-all" id="con-text-581"> Rahul3
</div>
</div>
</div>
</body>
</html>
```
i want this image in the left corner of div con-text or con-icon as badge,
image is coming not full size please help how the image will come in full size
regards
rahul
| want to add image left corner of div | CC BY-SA 2.5 | null | 2010-10-11T05:40:33.333 | 2010-10-11T06:47:52.470 | 2010-10-11T06:47:52.470 | 434,893 | 434,893 | [
"css",
"image",
"html",
"background"
] |
3,904,064 | 1 | 3,927,195 | null | 4 | 2,174 | Is there a way to make my textview wrap around other views? For example in the picture, is there a way to get it to wrap to the edge once it gets below the imageview?

This is my xml
```
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@android:color/white">
<LinearLayout android:id="@+id/AUTHOR_TITLE"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_alignParentTop="True">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="20dip"
android:text="Author Name"
/>
</LinearLayout>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/AUTHOR_TITLE">
<ImageView android:id="@+id/PICTURE"
android:layout_alignParentLeft="True"
android:layout_alignParentTop="True"
android:src="@drawable/icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<TextView android:id="@+id/DESCRIPTION"
android:layout_toRightOf="@id/PICTURE"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF OMGTESTLOLWTF
OMGTESTLOLWTF "/>
</RelativeLayout>
</RelativeLayout>
```
I'm really surprised that no one's done this yet =\ Sigh.
| Having a view wrap around another view | CC BY-SA 2.5 | null | 2010-10-11T07:01:00.843 | 2016-01-19T16:58:53.330 | 2010-10-19T21:27:54.960 | 375,874 | 375,874 | [
"android",
"textview"
] |
3,904,097 | 1 | 3,904,215 | null | 1 | 427 | 
remote ftp server is microsoft ftp.
so, i suspect that this is a bug.
can anyone knows what happend?
| vim's netrw plugin show error message:"The system cannot find the file specified." when change remote directory via FTP | CC BY-SA 2.5 | 0 | 2010-10-11T07:04:57.530 | 2010-10-11T07:21:22.797 | null | null | 298,553 | [
"vim",
"ftp",
"netrw"
] |
3,904,148 | 1 | 3,904,229 | null | 3 | 9,454 | I wanna gather the latest information of a user from the User Model and store it in the session.
so i am doing this
// Before Render
function beforeRender() {
```
if($this->Session->check('Auth.User')) {
$this->User->recursive = -1;
$currentUser = $this->User->read(null, $this->Session->read('Auth.User.id'));
$this->set(compact('currentUser'));
}
```
}
It works fine until am in the User model.
When i go to the pages it gives me an error because User->read doesnt work as that model is not attached there.
Whats the best solution for ?
1. I want the latest information of the Loggedin User on every page of the site.
2. Latest and not Auth.User from the session because - when i edit the profile content like name or photo. it still references to the old data that was stored when user had logged on.
3. It has to be displayed on every page like the Stackoverflow User info at the top

Which is the best way to do it ?
| Cakephp: How to read User Data in Session? | CC BY-SA 2.5 | 0 | 2010-10-11T07:11:02.873 | 2010-10-11T12:42:22.493 | null | null | 155,196 | [
"database",
"session",
"cakephp",
"cakephp-1.3"
] |
3,904,204 | 1 | 3,904,228 | null | 1 | 1,609 | Hai all,
I am doing c#.NET application to calculate different formulas and give result to user,users can enter any formula and each formula values are stored in database like this.

After saving like this i want to calculate the result.When calculating the result,application ask values for `variables`.But how can i calculate with this values.
Please help to retrieve each values from database and calculate the result.
| Converting string formula to mathematical formula in c# | CC BY-SA 2.5 | 0 | 2010-10-11T07:19:42.700 | 2010-10-11T07:22:53.320 | null | null | 434,910 | [
"c#",
"winforms",
"sql-server-2008"
] |
3,904,304 | 1 | 3,904,564 | null | 13 | 23,816 | I'm new to C/C++ and I've been cracking my head but still got no idea how to make an "structure" like this

It's supposed to be a 3D dynamic array using pointers.
I started like this, but got stuck there
```
int x=5,y=4,z=3;
int ***sec=new int **[x];
```
It would be enough to know how to make it for a static size of y and z;
Please, I'd appreciate that you help me.
Thanks in advance.
| 3D array C++ using int [] operator | CC BY-SA 2.5 | 0 | 2010-10-11T07:34:05.040 | 2018-02-05T10:38:25.597 | 2011-11-04T19:47:41.083 | 191,596 | 220,503 | [
"c++",
"arrays",
"pointers",
"multidimensional-array",
"dynamic-arrays"
] |
3,904,575 | 1 | null | null | 12 | 8,301 | I have a background thread that loads images and displays them in the main thread. I noticed that the background thread has almost nothing to do, because the actual image decoding seems to be done in the main thread:

So far I’ve tried calling `[UIImage imageNamed:]`, `[UIImage imageWithData:]` and `CGImageCreateWithJPEGDataProvider` in the background thread with no difference. Is there a way to force the decoding to be done on the background thread?
There’s already [a similar question](https://stackoverflow.com/questions/1815476) here, but it does not help. As I wrote there, I tried the following trick:
```
@implementation UIImage (Loading)
- (void) forceLoad
{
const CGImageRef cgImage = [self CGImage];
const int width = CGImageGetWidth(cgImage);
const int height = CGImageGetHeight(cgImage);
const CGColorSpaceRef colorspace = CGImageGetColorSpace(cgImage);
const CGContextRef context = CGBitmapContextCreate(
NULL, /* Where to store the data. NULL = don’t care */
width, height, /* width & height */
8, width * 4, /* bits per component, bytes per row */
colorspace, kCGImageAlphaNoneSkipFirst);
NSParameterAssert(context);
CGContextDrawImage(context, CGRectMake(0, 0, width, height), cgImage);
CGContextRelease(context);
}
@end
```
That works (forces the image to decode), but it also triggers an apparently expensive call to `ImageIO_BGR_A_TO_RGB_A_8Bit`.
| Decode images in background thread? | CC BY-SA 2.5 | 0 | 2010-10-11T08:22:27.730 | 2012-06-16T00:44:20.750 | 2017-05-23T11:53:20.880 | -1 | 17,279 | [
"iphone",
"cocoa-touch",
"uikit",
"ios",
"core-graphics"
] |
3,904,768 | 1 | 3,904,886 | null | 2 | 1,772 | maybe some of you know that there are GPS tools out there that are used in Motorsports. A lot of them deliver the following function: If you drive with your car and you press a button at a certain point this GPS Coordinate will be stored and every time you drive over this coordinate a LapTime will be stored. For a small application a need a similar function. But here is my problem: Since you will never hit the exact Coordinate twice these tools store the coordinates of a Line and if you hit one of the coordinates of this line the Lap is finished. How do I calculate such a line? If you look at my Picture, the red dot is the coordinate where the user hits the button to start a lap and the green Line is what the device stores and uses as a virtual finish line and not only the Coordinate where the red dot is. Any Idea how I can calculate such a line? I really don't get it since the line is never ideal directed to north or south.

Thank you very much
twickl
| How to calculate the GPS Coordinates 5m Left and Right from you Position? | CC BY-SA 2.5 | 0 | 2010-10-11T08:53:44.410 | 2011-12-05T06:11:40.213 | null | null | null | [
"gps",
"coordinates"
] |
3,904,923 | 1 | 7,163,908 | null | 0 | 1,111 | when loading lots of objects, I get a OOM-Exception. After analyzing the heap with a profiler, I see that there's a lot of memory in org/hibernate/util/IdentityMap which references a LinkedHashMap containing thousands of Entrys. What are those objects used for?
I'm really thankful for all kinds of information...

| Hibernate: OOM-Exception, problem with IdentityMap? | CC BY-SA 2.5 | null | 2010-10-11T09:20:56.577 | 2011-08-23T15:55:24.553 | null | null | 27,404 | [
"hibernate",
"out-of-memory",
"heap-dump"
] |
3,905,634 | 1 | 3,905,673 | null | 2 | 625 | in Images, can be found in the bottom
---
I'm having some trouble to get how Forms work in MVC (as I'm a WebForms Developer and really wanna start using MVC in one big project)
I took the and add a simple ViewModel to it
```
namespace TestForms.Models
{
public class myFormViewModel
{
public myFormViewModel() { this.Options = new List<myList>(); }
public string Name { get; set; }
public string Email { get; set; }
public List<myList> Options { get; set; }
}
public class myList
{
public myList() { this.Value = this.Name = ""; this.Required = false; }
public string Name { get; set; }
public string Value { get; set; }
public string Type { get; set; }
public bool Required { get; set; }
}
}
```
Created a , passed a new object to the view and run it.
When I press submit, it does not return what's in the `Options` part... ?
my view
[alt text http://www.balexandre.com/temp/2010-10-11_1357.png](http://www.balexandre.com/temp/2010-10-11_1357.png)
filling up the generated form
[alt text http://www.balexandre.com/temp/2010-10-11_1353.png](http://www.balexandre.com/temp/2010-10-11_1353.png)
when I press the `Options` part is not passed to the Model!
[alt text http://www.balexandre.com/temp/2010-10-11_1352.png](http://www.balexandre.com/temp/2010-10-11_1352.png)
---
---
Changing the View loop to allocate the sequential number, we now have
```
<%= Html.TextBox("model.Options[" + i + "].Value", option.Value)%>
```
`model` is the name of our Model variable that we pass to the View
`Options` is the property name that is of type `List`
and then we use the property name


| Understanding Forms in MVC: How can I populate the model from a List<> | CC BY-SA 2.5 | null | 2010-10-11T11:09:12.137 | 2010-10-11T12:50:51.153 | 2010-10-11T12:50:51.153 | 28,004 | 28,004 | [
"asp.net-mvc-2",
"viewmodel"
] |
3,905,871 | 1 | 3,906,633 | null | 1 | 756 | In a matrix control, I group columns by 'Size', and then by 'Color'. The resulting table looks like this:

I need to invert the header rows, so the table looks like this:

The values from the child group should display the corresponding value from the parent group.
| Invert header rows of nested column groups in matrix control | CC BY-SA 2.5 | null | 2010-10-11T11:47:02.310 | 2011-01-24T11:56:15.530 | 2011-01-24T11:56:15.530 | 573,261 | 339,702 | [
"reporting-services",
"ssrs-tablix"
] |
3,905,901 | 1 | 3,909,246 | null | 15 | 37,915 | 
You see 162489 and 162990, How can I merge them ?
| how to merge two changesets only (TFS) | CC BY-SA 2.5 | 0 | 2010-10-11T11:51:01.090 | 2015-01-30T09:01:15.373 | 2020-06-20T09:12:55.060 | -1 | 173,718 | [
".net",
"tfs",
"merge",
"tfs-2005"
] |
3,905,999 | 1 | 3,918,488 | null | 1 | 255 | In my application i have a threaded commenting system which i call status messages. i have a few models as follows
users(id, name......)
status_messages(id, message,......, user_id)
status_replies(id, message,......, status_message_id, user_id)
A user can set status messages and his friends and himself can reply to it. if another user replies i would want to pull out his details also.

| CakePHP: Doing Complex Find | CC BY-SA 2.5 | 0 | 2010-10-11T12:04:14.760 | 2010-10-17T20:55:20.550 | 2010-10-11T12:20:01.847 | 155,196 | 155,196 | [
"cakephp",
"model",
"cakephp-1.3"
] |
3,905,891 | 1 | 3,905,909 | null | 5 | 1,693 | This is driving me crazy, and has been bugging me for weeks, I'm trying to sort it all out today but am having real difficulty, if anyone could help it would be a HUGE benefit to me!
I'm trying to get a website I've developed on one computer, to work on my home computer. The old computer was running ASP.net 3.5.
On my new computer, after installing IIS and ASP.net 3.5:

I get the following error:

Upon checking the application pool, it says it is running ASP.net 2.0:

And there is no option to change it to 3.5:

I've checked regedit for the installed .net versions and 3.5 is listed there as installed. I just can't seem to get my site to run with 3.5, or run at all without any strange IIS error messages.
This thread: [http://forums.asp.net/p/1184937/2018939.aspx](http://forums.asp.net/p/1184937/2018939.aspx) suggests that 2.0 showing is correct, my issue then is why is the site not running?
Here is my web.config file:
```
<?xml version="1.0"?>
<configuration>
<configSections>
<sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
<section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
</sectionGroup>
</sectionGroup>
</sectionGroup>
</configSections>
<appSettings/>
<connectionStrings>
<remove name="LocalSqlServer" />
<add name="LocalSqlServer" connectionString="Server=SERVER1\DEVSERVER; Database=alphaPack; User Id=sa; password=sa"
providerName="System.Data.SqlClient" />
</connectionStrings>
<system.net>
<mailSettings>
<smtp>
<network
host="localhost"
port="25"
userName="sa"
password="sa" />
</smtp>
</mailSettings>
</system.net>
<system.web>
<machineKey validationKey="A03751058172F4F941C2120C891C57DA2170AAD76437D8D0D48FF84BAA1ED4A8EB023F96D2164B29080F7B5FD8F86F7F9398DB841C04034B1A464155DDA72BB6" decryptionKey="B65A7A473D2F7343635B59D3A9475A2BB446B3DC21848FCA26313FA24411F516" validation="SHA1" decryption="AES" />
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
-->
<roleManager enabled="true" />
<compilation debug="true" defaultLanguage="c#">
<assemblies>
<add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
<add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
</assemblies>
</compilation>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Forms" />
<!--
The <customErrors> section enables configuration
of what to do if/when an unhandled error occurs
during the execution of a request. Specifically,
it enables developers to configure html error pages
to be displayed in place of a error stack trace.
<customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>
-->
<customErrors mode="Off"/>
<pages>
<controls>
<add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</controls>
</pages>
<httpHandlers>
<remove verb="*" path="*.asmx"/>
<add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false"/>
</httpHandlers>
<httpModules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</httpModules>
<!-- Profile Fields -->
<profile>
<properties>
<add name="IsSubscribed" type="System.Boolean" defaultValue="false" />
<add name="workNumber" type="System.String" defaultValue="" />
<add name="homeNumber" type="System.String" defaultValue="" />
<add name="mobileNumber" type="System.String" defaultValue="" />
<add name="title" type="System.String" defaultValue="" />
<add name="firstName" type="System.String" defaultValue="" />
<add name="surname" type="System.String" defaultValue="" />
</properties>
</profile>
</system.web>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<providerOption name="CompilerVersion" value="v3.5"/>
<providerOption name="WarnAsError" value="false"/>
</compiler>
</compilers>
</system.codedom>
<!--
The system.webServer section is required for running ASP.NET AJAX under Internet
Information Services 7.0. It is not necessary for previous version of IIS.
-->
<system.webServer>
<validation validateIntegratedModeConfiguration="false"/>
<modules>
<remove name="ScriptModule"/>
<add name="ScriptModule" preCondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</modules>
<handlers>
<remove name="WebServiceHandlerFactory-Integrated"/>
<remove name="ScriptHandlerFactory"/>
<remove name="ScriptHandlerFactoryAppServices"/>
<remove name="ScriptResource"/>
<add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="ScriptResource" preCondition="integratedMode" verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</handlers>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Web.Extensions" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Extensions.Design" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
```
And here is my applicationHost.config:
[http://pastebin.com/m3nYmn4n](http://pastebin.com/m3nYmn4n)
Thank you so much for any help, fat juicy bounty on it's way when I can.
| Need help setting up ASP.net 3.5 (Screenshots) | CC BY-SA 2.5 | null | 2010-10-11T11:49:24.120 | 2010-10-11T12:18:34.457 | 2010-10-11T12:18:34.457 | 356,635 | 356,635 | [
"asp.net",
"iis-7",
"windows-7",
"installation"
] |
3,906,039 | 1 | 3,906,063 | null | 16 | 88,105 | I have a FileUpload Control like this
```
<asp:FileUpload ID="fileuploader" runat="server" />
```
Now I want to apply css only on the Browse button part

How can I do this?
| Applying css on asp.net FileUpload Control's Browse Button only | CC BY-SA 2.5 | 0 | 2010-10-11T12:10:47.573 | 2016-05-26T22:10:12.580 | null | null | 301,459 | [
"c#",
".net",
"asp.net",
"css"
] |
3,906,336 | 1 | null | null | 0 | 428 | does anybody know of any usercontrol that would function well as a textbox for entering email recipients.
The control would appear as a simple textbox. When a user would enter some text a drop down list of matches would be displayed. When he would select an item from the list, this item would be added to the textbox. If the user would then continue adding some new text, new list of matches would be shown, etc.
A visual example of what I'd like:

Does anybody know of any usercontrol that can do this? Any ideas how to implement it?
Thanks,
gregor
| WPF textbox usercontrol containing items, not simple text (for adding email recipients) | CC BY-SA 2.5 | null | 2010-10-11T12:50:33.800 | 2010-10-11T13:20:57.260 | null | null | 300,696 | [
"c#",
"wpf",
"user-controls",
"textbox"
] |
3,906,512 | 1 | null | null | 4 | 2,287 | I'm using wxPython bindings for wxWidgets. Is it possible to create custom-shaped window from PNG image and in count alpha-channel? Take a look at VS2010 splash screen to see what I mean:

Highlighted zones (rounded corner and shadow) are not sharp, they use alpha-channel to look smooth.
: I want not only custom shape, but custom shape
: Seems like there is no way to do this with wx :(
| wxWidgets custom window shape (PNG) | CC BY-SA 2.5 | 0 | 2010-10-11T13:13:17.193 | 2010-11-10T08:53:18.957 | 2010-11-10T08:53:18.957 | 212,110 | 212,110 | [
"wxpython",
"png",
"wxwidgets",
"shaped-window"
] |
3,906,640 | 1 | 3,906,787 | null | 91 | 92,870 | I don't understand why the margins of these divs are overlapping.
```
.alignright {float: right}
#header .social {margin-top: 50px;}
#header .social a {display: inline-block;}
#header .social .fb {width: 64px; height: 1px; padding-top: 60px; overflow: hidden;}
#header .social .twit {width: 64px; height: 1px; padding-top: 60px; overflow: hidden;}
#header .contact {margin: 20px 70px 20px 0; font-size: 14px; font-weight: bold;}
#header .contact span {color: #FFFFFF;}
#header .search {margin: 10px 0 0;}
```
```
<div class="alignright">
<div class="social">
<a href="#" class="twit"></a>
<a href="#" class="fb"></a>
</div><!-- social -->
<div class="contact">
Get in Touch: <span>+44 10012 12345</span>
</div><!-- contact -->
<div class="search">
<form method="post" action="">
<input type="text" value="" name="s" gtbfieldid="28">
</form>
</div><!-- search -->
</div>
```

| Why are my div margins overlapping and how can I fix it? | CC BY-SA 4.0 | 0 | 2010-10-11T13:27:55.530 | 2020-01-27T12:56:35.683 | 2019-08-28T17:47:26.140 | 2,756,409 | 205,024 | [
"html",
"css",
"margins"
] |
3,906,730 | 1 | 3,907,615 | null | 1 | 208 | Can you please tell me How can I get Control back from NSOperationQueue
Following is my real question which I asked earlier:
Hi friends , I made an app which plays the song on clicking on the image of artist.(see image attached). Each artist image is implemented on button and on clicking this button, a function is being called which first downloads and then plays the song. I passed this method(function) in a thread but problem is that every time when I click on the image of artist(button) new threads starts running and then multiple songs gets started playing concurrently. How can I use "NSOperation and NSOperationQueue" so that only one song will run at a time . Please help.

Thanks in advance
Now I am able to play song by adding them in queue but when songs starts playing i m not able to do anything on my Screen until song is finished or I scroll the table.
| How to get Control back from NSOperationQueue | CC BY-SA 2.5 | null | 2010-10-11T13:36:26.897 | 2010-10-11T15:25:23.007 | 2010-10-11T13:48:04.363 | 390,423 | 390,423 | [
"iphone"
] |
3,907,142 | 1 | 6,832,675 | null | 3 | 7,790 | I have a class within a package. And I have another class in another package. I would like to link this second class to first. Since the first is a legacy of the second. I'm not able to make this relationship. We tried, but in neither case are the methods of the second brought the first.
Any help is welcome.
Thanks

Class A

Class B
The ownership of Class A, should be visible within the class B. Where A and B are in different folders. And B, I put an "Instance" of A.
| Inheritance in Enterprise Architect | CC BY-SA 2.5 | 0 | 2010-10-11T14:31:38.783 | 2017-09-25T08:45:46.417 | 2010-10-13T19:58:37.917 | 302,751 | 302,751 | [
"architecture",
"data-modeling"
] |
3,907,141 | 1 | 3,907,201 | null | 0 | 861 | This is weird! I'm not sure why it is doing this but the div `.content-wrap`, or `.main-content` is wrapping elements that are outside of the div.......
Screenshot of it using firebug.

But `.main-content` is isn't suppose to be wrapping the 3 columns...
Heres the HTML of both.
```
<div id="plans-wrap">
<section class="starter">
<img class="icon-1" src="../images/plan-icon.png" width="62" height="73" alt="Plan Icon">
<h2>Starter Plan</h2>
<ul>
<li><span>5GB Disk Space</span></li>
<li><span>Unmetered Bandwidth</span></li>
<li><span>Unlimited Add-on Domains</span></li>
<li><span>Unlimited Subdomains</span></li>
<li><span>Unlimited Email/FTP Accounts</span></li>
<li><span>Unlimited MySQL Databases</span></li>
<li><span>Shell access upon request</span></li>
</ul>
<img src="images/starterplan.png" width="192" height="51" alt="Starter Plan">
</section><!-- //.starter -->
<section class="inter">
<img class="icon-2" src="../images/plan-icon.png" width="62" height="73" alt="Plan Icon">
<h2>Intermediate Plan</h2>
<ul>
<li><span>10GB Disk Space</span></li>
<li><span>Unmetered Bandwidth</span></li>
<li><span>Unlimited Add-on Domains</span></li>
<li><span>Unlimited Subdomains</span></li>
<li><span>Unlimited Email/FTP Accounts</span></li>
<li><span>Unlimited MySQL Databases</span></li>
<li><span>Shell access upon request</span></li>
</ul>
<img src="images/interplan.png" width="192" height="51" alt="Intermeidate Plan">
</section><!-- //.intermediate -->
<section class="advance">
<img class="icon-3" src="../images/plan-icon.png" width="62" height="73" alt="Plan Icon">
<h2>Advance Plan</h2>
<ul>
<li><span>Unmetered Disk Space</span></li>
<li><span>Unmetered Bandwidth</span></li>
<li><span>Unlimited Add-on Domains</span></li>
<li><span>Unlimited Subdomains</span></li>
<li><span>Unlimited Email/FTP Accounts</span></li>
<li><span>Unlimited MySQL Databases</span></li>
<li><span>Shell access upon request</span></li>
</ul>
<img src="images/advplan.png" width="192" height="51" alt="Starter Plan">
</section><!-- //.advance -->
</div><!-- //#plans-wrap -->
<div class="content-wrap">
<aside class="badges">
<img src="images/sidebar-stickers.png" width="150" height="634" alt="Sidebar Stickers">
</aside><!-- //.badges -->
<div class="main-content">
<!-- All Content For Each Page Goes Here -->
<!-- index/home -->
<img src="images/hosting-header.png" width="458" height="179" alt="Hosting Header">
<article>
<h1> Welcome to Elektrik Host! </h1>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut sodales nisi eu sem dapibus imperdiet.
Etiam venenatis elit nec sapien commodo dapibus. Donec vel enim nec augue fringilla pharetra. Pellentesque
sed augue est. Nullam et erat sed leo vestibulum consequat sit amet at ligula.
</p>
</article><!-- //article -->
</div><!-- //.main-content -->
</div><!-- //#content-wrap -->
```
and the CSS:
```
/* -- PRICE PLANS -- */
#plans-wrap { margin: 0 0 0 5px; width: 100%; }
#plans-wrap section { background: #1b1b1b; border-radius: 10px; -webkit-border-radius: 10px; -moz-border-radius: 10px; float: left; margin: 19px 10px 0 0; }
#plans-wrap section img.icon-1, #plans-wrap section img.icon-2, #plans-wrap section img.icon-3 { float: right; }
#plans-wrap section h2 { background: url(../images/plan-header-bg.png) repeat-x; display: block; border-radius: 10px 10px 0 0; -moz-border-radius: 10px 10px 0 0; -webkit-border-radius: 10px 10px 0 0; font-size: 15px; padding: 18px 18px 32px 6px; width: 188px; }
#plans-wrap section h2:before { content: "» "; }
#plans-wrap ul { padding: 0px 23px 23px 23px ; }
#plans-wrap ul li { color: #b60000; font-size: 12px; margin: 9px 0 0 0; }
#plans-wrap ul li span { color: #b6b6b6; }
/* -- CONTENT WRAP -- */
#content-wrap { margin: 12px auto; width: auto; }
#content-wrap .badges { float: right;}
```
How can I fix this?
| Div is wrapping everything in the content and out of it | CC BY-SA 2.5 | null | 2010-10-11T14:31:28.707 | 2010-10-11T17:23:11.903 | null | null | 363,551 | [
"html",
"css"
] |
3,907,355 | 1 | 3,907,444 | null | 2 | 1,446 | I want to be able to support iOS 3.x users.
When I try to set the Base SDK in Project Info, the only SDK that appears is iOS 4.1 and iOS 3.2.
How can I add additional SDK's so I can support older users when my app hits the App Store?
| How can I set my Base SDK? | CC BY-SA 2.5 | null | 2010-10-11T14:55:10.193 | 2010-10-11T15:13:42.643 | null | null | 19,875 | [
"iphone",
"objective-c",
"xcode",
"ios4",
"app-store"
] |
3,907,367 | 1 | 5,439,258 | null | 3 | 14,059 | I am working with the universal apps. Now i want to create a three table views in my view controller for iPAD. I have three separate view controllers with XIB.So how can i add the other two table view as subview in the main controllers. Please give me some sample applications and links. In my application, i have three view controllers and add a subview as table view(not UITableViewController). On clicks the first table view data, it navigates to the second table and clicks the second table view data, it navigates to the third table view.
```
Hierarchy:
MainViewController:
--SubTableView1
--SubTableView2
```
See the image below,

Please Help me out.
Thanks!!
| How to create multiple table view in a View Controller for iPad? | CC BY-SA 2.5 | 0 | 2010-10-11T14:56:49.643 | 2011-06-27T16:46:31.183 | null | null | 249,916 | [
"ipad",
"uitableview",
"uiviewcontroller"
] |
3,907,494 | 1 | 3,963,718 | null | 1 | 1,998 | Hello i have a dropdown list in edit mode and read only mode. If users upload pictures, i want them to chose a category for the uploaded pics and display it in a gridview as below.(See Picture below).
When i include "SelectedValue='<%# Bind("CategoryID")" in edit and item template mode, i get this error "'PictureReadOnlyCategories' has a SelectedValue which is invalid because it does not exist in the list of items.
Parameter name: value "
When i removed the "SelectedValue='<%# Bind("CategoryID")" from edit and item template, i get the result on the pic below(screenshot). If u can see the pic below the category is not selected, it just display the -- No Category -- even when i chose a category for the pic.
I want when a pic is uploaded and i category chosen, to display on the gridview. The code for the error message is below:
```
<EditItemTemplate>
<asp:DropDownList ID="pictureEditCategories" runat="server"
AppendDataBoundItems="True"
DataSourceID="categoriesDataSource"
DataTextField="Name" DataValueField="CategoryID"
SelectedValue='<%# Bind("CategoryID") %>' ValidationGroup="PictureEdit" >
<asp:ListItem Value="" Text="--No Category -- "/>
</asp:DropDownList>
</EditItemTemplate>
<ItemTemplate>
<asp:DropDownList ID="PictureReadOnlyCategories" runat="server"
AppendDataBoundItems="True" DataSourceID="categoriesDataSource"
DataTextField="Name" DataValueField="CategoryID" Enabled="False"
SelectedValue='<%# Bind("CategoryID") %>' ValidationGroup="PictureEdit"
>
<asp:ListItem Value="">-- No Category --</asp:ListItem>
</asp:DropDownList>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Title" SortExpression="Title">
<EditItemTemplate>
<asp:TextBox ID="TextBox1" runat="server" EnableViewState="False"
Text='<%# Bind("Title") %>'></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server"
ControlToValidate="TextBox1" Display="Dynamic"
ErrorMessage="must enter a title" ValidationGroup="PictureEdit"></asp:RequiredFieldValidator>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="Label1" runat="server" Text='<%# Bind("Title") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Description" SortExpression="Description">
<EditItemTemplate>
<asp:TextBox ID="TextBox2" runat="server" Columns="25" Rows="4"
Text='<%# Bind("Description") %>' TextMode="MultiLine"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server"
ControlToValidate="TextBox2" Display="Dynamic"
ErrorMessage="you must enter a description" ValidationGroup="PictureEdit"></asp:RequiredFieldValidator>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="Label2" runat="server" Text='<%# Bind("Description") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Date Added" SortExpression="UploadedOn">
<EditItemTemplate>
<asp:Label ID="Label4" runat="server" Text='<%# Bind("UploadedOn") %>'></asp:Label>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="Label3" runat="server" Text='<%# Bind("UploadedOn") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:ImageField DataImageUrlField="PictureID"
DataImageUrlFormatString="~/UploadedImages/{0}.jpg" HeaderText="Image"
ReadOnly="True">
<ControlStyle Width="100px" />
</asp:ImageField>
</Columns>
<EditRowStyle BackColor="#2461BF" />
<FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
<RowStyle BackColor="#EFF3FB" />
<SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
<SortedAscendingCellStyle BackColor="#F5F7FB" />
<SortedAscendingHeaderStyle BackColor="#6D95E1" />
<SortedDescendingCellStyle BackColor="#E9EBEF" />
<SortedDescendingHeaderStyle BackColor="#4870BE" />
</asp:GridView>
```
When i remove the SelectedValue='<%# Bind("CategoryID") %>' from the item and edit template, I get the result for the picture below.
Please i will appreciate your help.
Please you can edit the code or explain it to me since im still learning ASP.net

| dropdown list in edit and read-only mode | CC BY-SA 2.5 | null | 2010-10-11T15:11:59.637 | 2010-10-19T14:23:35.290 | null | null | 463,660 | [
"asp.net"
] |
3,908,464 | 1 | 3,908,559 | null | 0 | 345 | I would like to have a similar look and feel to the task-bar buttons WinAmp provides:

| WinAmp-Style task-bar Buttons using VB 2010 | CC BY-SA 3.0 | null | 2010-10-11T17:18:48.713 | 2013-12-24T15:08:54.653 | 2013-12-24T15:08:54.653 | 1,829,219 | 472,523 | [
"vb.net"
] |
3,908,810 | 1 | 3,908,992 | null | 1 | 190 | i wanna create a 2 level status message system. Which is the best way to create a tables ?
Scope:
1. User sets a Status Message
2. Users Reply to the status message
this is a picture showing it

users (id, name .... )
status_messages (id, message, time, user_id)
status_message_replies (id, message, time, status_message_id, user_d)
status_messages (id, pid, message, time, user_id)
where pid = selfId or ParentId of the status.
I wanna know which is the best method to create the system ?
| DB for Commenting System | CC BY-SA 2.5 | 0 | 2010-10-11T18:08:19.560 | 2010-10-11T18:38:05.553 | null | null | 155,196 | [
"mysql",
"database",
"database-design",
"cakephp",
"comments"
] |
3,908,982 | 1 | null | null | 2 | 583 | SQL Server 2008 R2 Dev
Execution in SSMS of:
1)
> use AdventureWorksDW;
GO;
sp_cdc_enable_table
'dbo',
'FactInternetSales',
@role_name=NULL,
@supports_net_changes=0
succeeds.
> sp_cdc_enable_table 'dbo', 'FactInternetSales' --, @role_name=NULL, @supports_net_changes=0 gives error: > Msg 201, Level 16, State 4, Procedure sp_cdc_enable_table, Line 0
Procedure or function 'sp_cdc_enable_table' expects parameter '@role_name', which was not supplied. Intellisense popup on (having mouse cursor on) sp_cdc_enable_table in SSMS shows:
> stored procedure AdventureWorksDW.sys.sp_cdc_enable_table
@source_schema sysname,
@source_name sysname,
@supports_net_changes ,
@role_name sysname,
@index_name sysname =null,
[continuation truncated by vgv8]

Does not " = null" imply default value which is used if parameter is omitted?
Why does not ommission of @index_name sysname give the error?
Collateral questions:
How can I copy the text of popup description into buffer (for further pasting)?
Is not "@role_name bit = null" in popup an error (and should have been "@role_name bit = 0, " instead)?
Update:
I corrected the typo in post.
Really I executed
> sp_cdc_enable_table 'dbo', 'FactInternetSales'--, @role_name=NULL, @supports_net_changes=0
i.e. both variants are execution of the same script
1) uncommented
2) with comments
OK, initially I typed incorrectly the text of popup which I corrected now.
So, the question about error is removed, thanks.
From the context of my successful execution of 1) you are supposed to notice that my questions are about popup (but not how to succeed):
- - - -
Notice that popup also has "@capture_instance = null," which can be completely ommitted but it is not marked this in any way.
I included the screenshot.
Well, it is rather context sensitive help.
Intellisense does not work at all on sys.sp_* and popup is not shown if there is a syntax error - whatever MS pretended to accomplish by such "help" since it is necessary to insert full correct statement in order to escape syntax errors and have context sensitive "help"...
Update5:
Then, what is the sense that parameters with default values cannot be dropped?
| Intellisense and context help for sys stored procedures - bugs or by design? | CC BY-SA 2.5 | null | 2010-10-11T18:36:49.747 | 2010-10-12T04:47:46.637 | 2010-10-12T04:47:46.637 | 200,449 | 200,449 | [
"sql-server",
"tsql",
"stored-procedures",
"intellisense",
"sql-server-2008"
] |
3,909,148 | 1 | 3,920,866 | null | 0 | 445 | Three (out of 8 or so) of the parameters in an object have an underscore at the beginning of their name. The underscores aren't in my json object and I can't decipher why Firebug would add them in. The same properties are listed later in the object but without the underscores. I'm sure it's trivial but I'm curious to know.
Here's a screenshot:

| What do the underscores mean in DOM object detail view? (Firebug) | CC BY-SA 2.5 | null | 2010-10-11T19:04:32.920 | 2010-10-13T04:53:45.330 | 2010-10-11T19:13:32.747 | 139,010 | 272,084 | [
"javascript",
"firebug"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.