Click here to Skip to main content
15,883,896 members
Home / Discussions / C#
   

C#

 
GeneralRe: string.writeline format Pin
George_George27-Jul-08 16:45
George_George27-Jul-08 16:45 
QuestionToolBox Icon - VS2008 Pin
DaveyM6927-Jul-08 3:52
professionalDaveyM6927-Jul-08 3:52 
GeneralRe: ToolBox Icon - VS2008 Pin
DaveyM6928-Jul-08 0:21
professionalDaveyM6928-Jul-08 0:21 
Questionaccessing hardware information Pin
Seyyed Hossein Hasan Pour27-Jul-08 2:18
Seyyed Hossein Hasan Pour27-Jul-08 2:18 
AnswerRe: accessing hardware information Pin
half-life27-Jul-08 5:58
half-life27-Jul-08 5:58 
QuestionConvert Mp3 to Wave Files Pin
SHINOJK27-Jul-08 1:25
SHINOJK27-Jul-08 1:25 
AnswerRe: Convert Mp3 to Wave Files Pin
Ian Uy27-Jul-08 3:21
Ian Uy27-Jul-08 3:21 
QuestionInitializing Byte Array, IndexOutOfRange Exception Pin
Ian Uy27-Jul-08 0:05
Ian Uy27-Jul-08 0:05 
Good Day,

I'm working with the AES Decryptor (using RijndaelManaged), but when I try to initialize a byte[] array to store my ciphertext data, it throws an IndexOutOfRange exception.

using (FileStream Ciphertext = new FileStream(_InputPath, FileMode.Open, FileAccess.Read, FileShare.None)) //For Plaintext Stream
{
    using (FileStream PlainText = new FileStream(_OutputPath, FileMode.Create, FileAccess.Write, FileShare.None)) //For Ciphertext Stream
    {
        using (CryptoStream CStreamWriter = new CryptoStream(PlainText, Decryptor, CryptoStreamMode.Write)) //For CryptoStream Writer
        {
            byte[] CTextData = new byte[Ciphertext.Length]; //EXCEPTION THROWN HERE


The exact error message is: "Index was outside the bounds of the array."


The weird thing is, this only happens for file > 200MB. But for a 150mb file, I have no problem.

Please advice thanks!

It is said that the most complex structures built by mankind are software systems. This is not generally appreciated because most people cannot see them. Maybe that's a good thing because if we saw them as buildings, we'd deem many of them unsafe.

AnswerRe: Initializing Byte Array, IndexOutOfRange Exception Pin
Guffa27-Jul-08 2:54
Guffa27-Jul-08 2:54 
Questionredirecting page to another page Pin
scottichrosaviakosmos26-Jul-08 23:57
scottichrosaviakosmos26-Jul-08 23:57 
QuestionA generic error occurred in GDI+ [modified] Pin
Rob Manderson26-Jul-08 23:41
protectorRob Manderson26-Jul-08 23:41 
AnswerRe: A generic error occurred in GDI+ Pin
Luc Pattyn27-Jul-08 1:08
sitebuilderLuc Pattyn27-Jul-08 1:08 
GeneralRe: A generic error occurred in GDI+ Pin
Rob Manderson27-Jul-08 8:08
protectorRob Manderson27-Jul-08 8:08 
GeneralRe: A generic error occurred in GDI+ Pin
Luc Pattyn27-Jul-08 8:18
sitebuilderLuc Pattyn27-Jul-08 8:18 
QuestionC# code for optimal path, given adjacency matrix/cost values? Pin
sherifffruitfly26-Jul-08 18:51
sherifffruitfly26-Jul-08 18:51 
AnswerRe: C# code for optimal path, given adjacency matrix/cost values? Pin
Paul Conrad26-Jul-08 19:41
professionalPaul Conrad26-Jul-08 19:41 
AnswerRe: C# code for optimal path, given adjacency matrix/cost values? Pin
Robert.C.Cartaino27-Jul-08 6:14
Robert.C.Cartaino27-Jul-08 6:14 
QuestionDays until next birthday Pin
DFlat4Now26-Jul-08 16:59
DFlat4Now26-Jul-08 16:59 
AnswerRe: Days until next birthday Pin
Reza Raad26-Jul-08 17:36
Reza Raad26-Jul-08 17:36 
GeneralRe: Days until next birthday Pin
DFlat4Now26-Jul-08 18:31
DFlat4Now26-Jul-08 18:31 
QuestionRe: Days until next birthday Pin
DFlat4Now26-Jul-08 18:55
DFlat4Now26-Jul-08 18:55 
AnswerRe: Days until next birthday Pin
Paul Conrad26-Jul-08 19:52
professionalPaul Conrad26-Jul-08 19:52 
AnswerRe: Days until next birthday Pin
Reza Raad26-Jul-08 21:43
Reza Raad26-Jul-08 21:43 
AnswerRe: Days until next birthday Pin
Guffa27-Jul-08 2:59
Guffa27-Jul-08 2:59 
QuestionExe Control DLL Pin
nedracix26-Jul-08 16:20
nedracix26-Jul-08 16:20 

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.