Click here to Skip to main content
15,899,126 members
Home / Discussions / Managed C++/CLI
   

Managed C++/CLI

 
GeneralRe: NullReferenceException in MC++ Pin
Anonymous10-May-05 10:05
Anonymous10-May-05 10:05 
GeneralExcellent Question Pin
ursus zeta10-May-05 10:33
ursus zeta10-May-05 10:33 
GeneralRe: Excellent Question Pin
Gurminder_G10-May-05 11:14
sussGurminder_G10-May-05 11:14 
GeneralRe: Excellent Question Pin
ursus zeta12-May-05 9:30
ursus zeta12-May-05 9:30 
GeneralToolboxItem attribute problem Pin
tomand9-May-05 0:17
tomand9-May-05 0:17 
Generalmanaged c++ Pin
_tasleem8-May-05 9:47
_tasleem8-May-05 9:47 
GeneralRe: managed c++ Pin
Christian Graus8-May-05 14:11
protectorChristian Graus8-May-05 14:11 
Generalmystring object help Pin
user3166-May-05 19:24
user3166-May-05 19:24 
I was trying to write the string object and ran into trouble. I'm getting run-time error. The run time error says: blah blah... the memory could not be "read".
I'm using MinGW g++ to compile this program. The program is actually much much longer but i deleted everything that used to be there so it is easier to figure it out.

The run-time error occurs inside of the c_str() function.
But it happens before leaving the substr() function (which calls the c_str() function)

The c_str() function works without generating runtime errors sometimes.

here is the output of my program:
in c_str(): string=this, was, a, test
before new char[18]
after new char[18]
after data is copied.
out c_str()
from main(): this, was, a, test
in substr:
new char[8]
after new char[8]
leaving substr
in c_str(): string=this, wa
before new char[8]
after new char[

and then the runtime error occurs.
So, basically, I get runtime error on the line of code that says:
tmpStr = new char[size]; (inside of c_str()), but why would new char[8] cause a runtime error?
It makes no sense to me everything looks correct to me its driving me insane.
Please help.
GeneralRe: mystring object help Pin
user3166-May-05 19:36
user3166-May-05 19:36 
GeneralPassword Code Pin
Derdog1016-May-05 16:37
Derdog1016-May-05 16:37 
GeneralRe: Password Code Pin
Christian Graus8-May-05 14:13
protectorChristian Graus8-May-05 14:13 
GeneralProtect a file by group Pin
sloaken6-May-05 15:37
sloaken6-May-05 15:37 
GeneralIs there a way to print a String using mc++ Pin
Lagwagon565-May-05 7:25
Lagwagon565-May-05 7:25 
GeneralRe: Is there a way to print a String using mc++ Pin
Christian Graus8-May-05 14:14
protectorChristian Graus8-May-05 14:14 
GeneralC++ Problem Pin
Dohan CRPathirana4-May-05 21:38
sussDohan CRPathirana4-May-05 21:38 
GeneralRe: C++ Problem Pin
ushani5-May-05 18:24
ushani5-May-05 18:24 
GeneralInterop::Excel Pin
Delver4-May-05 9:24
Delver4-May-05 9:24 
GeneralCalling an excutable from C++ Pin
HTisGood1-May-05 0:02
sussHTisGood1-May-05 0:02 
GeneralProcess Pin
ursus zeta1-May-05 10:50
ursus zeta1-May-05 10:50 
QuestionHow Do you pass a variable between forms? Pin
Lagwagon5629-Apr-05 7:03
Lagwagon5629-Apr-05 7:03 
AnswerRe: How Do you pass a variable between forms? Pin
Christian Graus1-May-05 11:24
protectorChristian Graus1-May-05 11:24 
GeneralRe: How Do you pass a variable between forms? Pin
Lagwagon565-May-05 7:24
Lagwagon565-May-05 7:24 
Generalcode for controling web came Pin
Randil28-Apr-05 20:09
Randil28-Apr-05 20:09 
QuestionUsing PlaySound() in VC++ .net managed? Pin
ScottLeff26-Apr-05 12:23
ScottLeff26-Apr-05 12:23 
AnswerReally Dumb Suggestion Pin
ursus zeta28-Apr-05 11:11
ursus zeta28-Apr-05 11:11 

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.