Click here to Skip to main content
15,920,708 members
Home / Discussions / C#
   

C#

 
GeneralRe: type casting a string to a type which is getting received in a string Pin
surender.m21-Apr-10 1:47
surender.m21-Apr-10 1:47 
GeneralRe: type casting a string to a type which is getting received in a string Pin
J4amieC21-Apr-10 1:50
J4amieC21-Apr-10 1:50 
AnswerRe: type casting a string to a type which is getting received in a string Pin
Keith Barrow20-Apr-10 23:39
professionalKeith Barrow20-Apr-10 23:39 
AnswerRe: type casting a string to a type which is getting received in a string Pin
surender.m21-Apr-10 3:27
surender.m21-Apr-10 3:27 
GeneralRe: type casting a string to a type which is getting received in a string Pin
dashingsidds21-Apr-10 22:42
dashingsidds21-Apr-10 22:42 
AnswerRe: type casting a string to a type which is getting received in a string Pin
PIEBALDconsult21-Apr-10 3:57
mvePIEBALDconsult21-Apr-10 3:57 
QuestionSending a Custom Ethernet packet Pin
spiritboy20-Apr-10 22:48
spiritboy20-Apr-10 22:48 
QuestionICCompress Pin
TimSWatson20-Apr-10 22:38
TimSWatson20-Apr-10 22:38 
Hi
I am trying to use ICCompress in C# to compress images from a IP camera. Its not going very well im getting this exception:

System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt

The code that causes the exception is,

byte[] outImgData = new byte[outbi.biHeight * outbi.biWidth * (outbi.biBitCount / 8)];

GCHandle pinnedArray = GCHandle.Alloc(outImgData, GCHandleType.Pinned);
IntPtr outImgPtr = pinnedArray.AddrOfPinnedObject();

BitmapData inBmpDat = image.LockBits(
    new Rectangle(
    0, 0, image.Width, image.Height),
    ImageLockMode.ReadOnly, image.PixelFormat);

Avi.ICCompress(compressorHnd,
            Avi.AVICOMPRESSF_KEYFRAMES,
            ref outbi,
            outImgPtr,
            ref bi,
            inBmpDat.Scan0,
            0,
            0,
            frameNum,
            0,
            5000,
            0,
            0);


Im new to importing DLL's so im not to sure if the arguments im using are correct. Can anyone help?

Thanx
QuestionFileSystemWatcher problem when multi-files deletion in watched folder Pin
Rikq20-Apr-10 22:31
Rikq20-Apr-10 22:31 
QuestionHow to search Special Character in sql server 2005? [modified] Pin
Ashwani Dhiman20-Apr-10 22:11
Ashwani Dhiman20-Apr-10 22:11 
AnswerRe: How to search Special Character in sql server 2005? Pin
Ice_Freez0520-Apr-10 22:19
Ice_Freez0520-Apr-10 22:19 
QuestionSave XML Pin
NarVish20-Apr-10 22:04
NarVish20-Apr-10 22:04 
AnswerRe: Save XML Pin
Ice_Freez0520-Apr-10 22:22
Ice_Freez0520-Apr-10 22:22 
GeneralRe: Save XML Pin
NarVish20-Apr-10 23:20
NarVish20-Apr-10 23:20 
AnswerRe: Save XML Pin
surender.m20-Apr-10 23:51
surender.m20-Apr-10 23:51 
GeneralRe: Save XML Pin
NarVish21-Apr-10 0:09
NarVish21-Apr-10 0:09 
GeneralRe: Save XML Pin
surender.m21-Apr-10 0:21
surender.m21-Apr-10 0:21 
GeneralRe: Save XML Pin
NarVish21-Apr-10 0:51
NarVish21-Apr-10 0:51 
Questionfor loop??? Pin
jellybeannn20-Apr-10 21:57
jellybeannn20-Apr-10 21:57 
Questionsearching in datagridview c# Pin
LenaReu20-Apr-10 21:32
LenaReu20-Apr-10 21:32 
AnswerRe: searching in datagridview c# Pin
sanforjackass20-Apr-10 21:47
sanforjackass20-Apr-10 21:47 
QuestionSession Management with C# Pin
softwarejaeger20-Apr-10 21:29
softwarejaeger20-Apr-10 21:29 
QuestionObject reference not set to an instance of an object Pin
Ice_Freez0520-Apr-10 21:22
Ice_Freez0520-Apr-10 21:22 
AnswerRe: Object reference not set to an instance of an object Pin
OriginalGriff20-Apr-10 21:47
mveOriginalGriff20-Apr-10 21:47 
GeneralRe: Object reference not set to an instance of an object Pin
Ice_Freez0520-Apr-10 22:10
Ice_Freez0520-Apr-10 22:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.