Hi,
I have ListBox in my WPF project that gets set to a datasource of "MyObjectCollection".
I have managed to get the ListBox to display my collection, and each item to display two string properties from the object. The object also contains an Image, how do i get the image to display in the ListBox?
I am currently using the below code ...
How do you pass a value from your DAL to your sproc so that the ISNULL function will do it's job.
Particularly the DATE value coming from my .NET assembly.
In T-SQL an INSERT STMNT and in the VALUES clause, the line of interest goes like this;
ISNULL(@myparm_forcolumn9, @myparm_forcolumn9)
What value do I pass from .NET to make t...
I am trying to display an amount of colorpicker controls depending on an amount of colors in a xaml resourcedictionary file.
For some reason I can't figure out the right way to do this. When loading it in through a XAMLReader to a ResourcesDictionary Object, I m not sure what is the best way to iterate over it.
I had first tried to han...
I started a new solution (with multiple projects) and am trying to get it to build. Initially I was getting an internal compiler error and thought maybe it had to do with MySql, so I removed all references to MySql. Now I am getting the error "Could not find a 'Sub Main' in ''". I have made sure that all of my projects have a Main sub...
I spent the rest of the evening reading StackOverflow questions and also some blog entries and links about the subject. All of them turned out to be very helpful, but I still feel that they don't really answer my question.
So, I'm developing a simple web application. I'd like to create a reusable data access layer which I can later reus...
I am using TcpClient to listen on a port for requests. When the requests come in from the client I want to know the client ip making the request.
I've tried:
Console.WriteLine(tcpClient.Client.RemoteEndPoint.ToString());
Console.WriteLine(tcpClient.Client.LocalEndPoint.ToString());
var networkStream = tcpClient.GetStream();
var pi = n...
I am working on a .NET project where several versions of the same type of object have been created over the life of the project - most new versions add a field or two. However, now I am looking to mitigate problems for users with an old version.
My goal is that when a user tries to open an old version of the serialized object with the ...
I have created a C#/.Net application using visual studio. I have also created an installer project that puts out two files:
An MSI file
Setup.exe file
In my installer project properties I have setup .Net 3.5 as a prerequisite.
What I would like my installer to do as as follows:
Put out a single file (MSI/exe/whatever) that also i...
Hi there,
Is there a specific version of .Net that I can target that is bundled with all versions of Windows of XP SP2 and higher?
We are trying to create a simple setup stub without having to resort to a low-level C/C++ app... currently something is cooked up in VB6, but there's a fair amount of low-level network code that I would muc...
Hi,
Can I use .net 3.5 binaries for a library with a .net 4.0 application / what are the negatives if any? In other words is there any reason I should take more time out to download source for the library and build it under .net 4.0 (assuming it builds without any problems I guess) as opposed to downloading the .net 3.5 binaries.
I'...
Is it possible for multiple wcf services to implement the same service contract interface?
What I want to do is allow for a test service to be interchangeable for the real service, and to specify which service to be used in the configuration file.
For example:
[ServiceContract]
public interface IUselessService
{
[OperationContra...
i need to get started with accessing a database with c#
please give me the simplest example possible!!
perhaps a mysql database would be the simplest example?
please show me how to connect to a mysql database and get data
...
Short Desc:
I'm curious to see if I can use SQL Analysis services or some other SQL Server service to mine some data for me that will show commonalities between SQL TEXT fields in a dataset.
Long Desc
I am looking at a subset of data that consists of about 10,000 rows of TEXT blobs which are used as a notes column in a issue tracking ...
i am connect to a mysql database using this example:
http://bitdaddys.com/MySQL-ConnectorNet.html
at the top the instruction is to:
Next add reference to: MySql.Data
how do i do that?
...
Since C# uses Garbage Collection. When is it necessary to use .Dispose to free the memory?
I realize there are a few situations so I'll try to list the ones I can think of.
If I close a Form that contains GUI type object, are those objects dereferenced and therefore will be collected?
If I create a local object using new should I .Di...
i apologize in advance for the elementary questions
i am using:
command.CommandText = "select * from some_table;"
to retrieve data
can i do use the same thing to update data?
...
I am using the following code to add a contact, but I get the following unhandled exception:
Google.GData.Client.GDataRequestException: Execution of request failed: http://www.google.com/m8/feeds/contacts/default/full
GDataCredentials myCred = new GDataCredentials("myusername", "mypassword");
RequestSettings myReque...
Is there any method / extension method on IEnumerable that allows me to find the index of of an object instance in it? Like IndexOf() in IList?
indexPosition = myEnumerable.IndexOf() ?
Thanks
...
Sometimes, no "foo" directory is left after running this code:
string folder = Path.Combine(Path.GetTempPath(), "foo");
if (!Directory.Exists(folder))
Directory.CreateDirectory(folder);
Process.Start(@"c:\windows\explorer.exe", folder);
Thread.Sleep(TimeSpan.FromSeconds(5));
Directory.Delete(folder, false);
Directory.CreateDirectory...
I am looking for a reliable hosting company for a ASP.NET/SQLServer application. Any suggestion is appreciated.
My current host has been working fine till recently. It goes down almost once a week now.
...