Quantcast
Browsing all 1710 articles
Browse latest View live

Attempted to read or write protected memory in Office.Interop.Excel

Hi all,I have a problem creating an Excel file from C# Code with Microsoft.office.interop.excel.dll.The Code where the Exception occurs is:workbook.SaveAs(filename, missing, missing, missing, missing,...

View Article


Can we deploy IWSHRUNTIMELIBRARY with our project?

I have used the IWSHRUNTIME.dll library in my project. My question is how can we deploy the IWSHRUNTIME.dll library with our project and also is it safe to use this library?

View Article


Odd construct in IL (private & virtual method)?

I was looking at some IL recently, and noticed a number of odd signatures.  There is a "My" namespace, which suggests that the source language might have been VB.NET.  However, I have worked...

View Article

Increasing the HEAP size in .NET Framework

Is there a configuration parameter to increase the heap size, especially for 64-bit OS? Or how do I go beyond the default heap size?Thanks,SPSP

View Article

WMIProvider (LocalSystemHost:CLR) not running under System context

Hi,I am trying to develop a managed WMI provider in .NET 4.0 that runs under the Local System account on Windows XP/7 machines.  I start my class definition with the following code: [assembly:...

View Article


Global data getting reset when running under IIS?

We have a scenario using IIS with an ASP.NET web service written in VB.NET. When a call to the web service is made, the web service calls a native dll (written in C, compiled using VS2010) using...

View Article

Assembly Version redirect doesn't work with a configSource in

Hi,    We have built a framework for our Company. It includes about 40 assemblies (about 7 services).We have just delivered a new version (v1.2) of this framework.  Each team using our framework must...

View Article

Framework 4.5 64 bit speed issue

Hi All I have been investigating a strange problem for a couple of days, and it has come to this: I have a simple WinForms applications with a lot of controls, and a lot of them nested in multi layer...

View Article


IO.Directory.Delete - Read-only "Access Denied"

I'm in the middle of a major project converting a VB6 application to .NET and have a requirement to delete a folder and its contents, in this case a complete user profile folder from C:\Documents and...

View Article


CSC Compile timeouts

I have recently moved my solutions from VS2010 to VS2013. When I test otherwise unmodified code on a Windows 2003 Server I start to get errors of this kind:'Error occurred while compiling the script:...

View Article

C++ DLL to GET data from a C# dll

I have a C++ DLL that has data types of char *, std::string and C++ structures that need to bee assigned by data retrieved via a Web Service C# DLL. First can anyone point me to a simple but yet...

View Article

Performance counters: sum of all managed heaps is greather then private bytes

I have the following issue with my process. Why can private bytes value be less than managed heaps? Feel free to consider scenarios with any complexity of inter-process interaction. This reproduces for...

View Article

Object^* should I pin_ptr it or not ?

Hi,I would to know if this code is safe or if I need to pin_ptr my Object^* parameter before using it.ref struct A { System::String ^s; }; void test2(A ^* po) { (*po)->s = "test2"; // is it safe ? }...

View Article


is it safe to cast interior_ptr and interior_ptr to interior_ptr ?

Is that code safe ? (GetInterior_ptr)using namespace System;ref struct A { String ^s; Object ^o;};interior_ptr<Int32> GetInterior_ptr(A ^a) { interior_ptr<String^> ip = &a->s; return...

View Article

Convert in c# a function with structure containing a pointer

How can I convert in C# the C function DRV_DioReadBitcontaining the structure PT_DioReadBit:FEXPORT LRESULT FTYPE DRV_DioReadBit(LONG_PTR DriverHandle,                     LPT_DioReadBit lpDioReadBit);...

View Article


FIPS validated cryptographic algorithms

I have enabled the FIPS algorithm policy on our windows server2008 machine. Now, any page that has a viewstate is abending with the following error:  This implementation is not part of the Windows...

View Article

Image may be NSFW.
Clik here to view.

X509Certificate2.PrivateKey fails even if HasPrivateKey == true

Hi,I am trying to exercise the methods and properties of X509Certificate2 class as I wish to convert an application from .Net Framework 1.1 with its many P/Invoke and CAPICOM calls to a pure .Net app...

View Article


SetupDiGetDeviceRegistryProperty

I have a C# application using P/Invoke to call several SetupApi.dll methods.  I'm not getting an error when I call SetupDiGetDeviceRegistryProperty(), but I'm not getting the desired result either.At...

View Article

which is better?

String o = null; if (o != null) { } if (o is Object) { } Which is better o != null  or  o is Object

View Article

COM interop assemblies and PrimaryInteropAssemblyCodeBase

We have a pretty big issue with registering 32-bit and 64-bit primary interop assemblies and maintaining IntelliSense support. We ship both 32-bit and 64-bit COM in-proc servers and register the...

View Article
Browsing all 1710 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>