i have some excell data. also excel column i created programmaticaly in sql tablr my excel column on the other hand; some column's name is "mydetail" if converting to to upper MYDETAİL. i must this ToUpper() event : MYDETAIL not MYDETAİL
...
Hey there - simple query:
var q = (from SomeObject o in container
where
o.SomeInt > 8
&& o.SomeString != null //Null Ref here
select o;
I always get a null reference exception.
If I use String.IsNullOrEmpty(o.SomeString) the query takes about 100 times as long, as if I use && o.SomeString != "" (which is way faster, but o...
Is it possible to use pure Encrypting and Decrypting keys instead of private and public keys? As I know in .Net asymmetric RSA implementation private key RSAParameters parameters = (new RSACryptoServiceProvider()).ExportParameters(true) is a superset of public key. And using private key we can both encrypt and decrypt our data. But I nee...
Hi everyone,
I'm using Entity framework in web application. ObjectContext is created per request (using HttpContext), hereby code:
string ocKey = "ocm_" + HttpContext.Current.GetHashCode().ToString();
if (!HttpContext.Current.Items.Contains(ocKey))
{
HttpContext.Current.Items.Add(ocKey, new ElevationEntityModel(EFConnectionString))...
WPF and Silverlight have a data binding model whereby I can provide a Binding with a Path which comprises a dot-notation of property accessors down from a DataContext to a specific value inside a complex object graph (eg. MyDataContext.RootProperty.SubProperty.Thing.Value)
I have a (non-UI) requirement to accept such a path expressed a...
Psuedo code for mapping configuration (as below) is not possible since the lambda only lets us access Type IDataReader, wheras when actually mapping, AutoMapper will reach into each "cell" of each IDataRecord while IDataReader.Read() == true:
var mappingConfig = Mapper.CreateMap<IDataReader, IEnumerable<MyDTO>>();
mappingConfig.ForMembe...
HI=i,
I need advice on how i should go about improving my c # skills. I want to improve my skills in general c#,ADO,linq and windows form applications.
...
I have a view that allows the user to make a selection from an IEnumerable.
The way I'm doing it now is to give each checkbox the id of the item and work with the form collection at the controller's side.
I seem to remember there to be a better way but can't remember how anymore.
Are there any better practices?
...
I'm writing an IEnumerator<T> class to iterate over a COM collection I'm wrappering. I've noticed that IEnumerator<T> extends IDisposable, so I'm required to implement the Dispose method.
However, I can't think of anything I would put there, as I only have a reference to the collection (which I wouldn't want being disposed at the end...
i try to create table from excel rows. however; excel columns :
column1 has max 200 character row
column2 has max 300 character row
column3 has max 500 character row
So i need to create sql
create MyTable column3 nvarchar(500) according to Excel Max Character.
...
Hi All.
I've a general question - Lets say I've an SQL Server 2008 DB , and it has some nullable columns. Some of these are null and some are not.
Next, I query the DB for a DataRow in C#.
What value would these null fields have in the DataRow object?
I'm seeing that they have C# "null" values, but someone here said that DbNull != C#...
Hi,
I have the following scenario in Silverlight 4:
I have a notifications service
Snippet
[InheritedExport]
public interface INotificationsService : IObservable<ReceivedNotification>
{
void IssueNotifications(IEnumerable<ClientIssuedNotification> notifications);
}
and and implementation of this service
Snippet
[PartCreationP...
To integrate with the current system for continuous integration, we want to use NUnit for testing (non UI) Silverlight code. Doing this means executing Silverlight code using the runtime of the full .NET framework which usually works just fine as long as not actually using Silverlight specific classes such as the visual elements or Depen...
We generate xml schema for our web services.
Amongst other details these schema contain the defintion of the complex types consumers of our services pass in.
Those complex types can change if our third party suppliers decide they want to add more details but as can be imagined that's something that shouldn't happen on the whim of a d...
When registering .NET assemblies for COM Interop, I do two things, currently in this order:
regasm /tlb:MyDll.tlb Mydll.dll
gacutil /i Mydll.dll
I use regasm to register the type library for COM and gacutil to install the assembly into the GAC. Does it matter which order I do these two actions? Also, as I make updates to my dll, do...
I have a ToolStrip. In my ToolStrip I have a ToolStripDropDownButton. My ToolStripDropDownButton has a DropDown of type ToolStripDropDown that contains a ToolStripControlHost which contains a Label. I have assigned a ContextMenuStrip to my Label. When I show the DropDown and right-click on the label, the ContextMenuStrip displays cor...
Hi
I have a Nant build script which referrences 30 other build scripts.
Each build script referrences a visual studio solution using MSBuild.
Each solution has 3 to 5 projects in.
Some projects are Class Librarys and some are Web Apllications.
The projects reference other projects both in their solution and out of their solution, so...
How can I sort DESC and ASC in a generic list? With LINQ and without LINQ ? I'm using vs 2008.
class Program
{
static void Main(string[] args)
{
List<int> li = new List<int>();
li.Add(456);
li.Add(123);
li.Add(12345667);
li.Add(0);
li.Add(1);
...
Please suggest ways to deliver Windows application (.NET) to Mac OS X. Mono isn't an option, I'm looking for a solution that requires no code changes. I'm considering VirtualBox virtualization (http://www.virtualbox.org). Any other suitable options?
Thanks!
...
Is there any easy way to query a stored procedure (Oracle - PL/SQL) for what parameters it expects?
I know that I can query USER_SOURCE to get the whole procedure but I'd then have to parse the whole procedure, and if the parameter is of type [table].[column]%TYPE I'd then have to query the table schema as well.
Either using just sql o...