I declare the TFileStream as such

__fastcall TFileStream(const AnsiString filename, mode);

and include the following: #include <vcl.h>

But i get the error "E2293 ) expected"

What am I doing wrong? Can someone give me a hint or possible solution.

P.S. I have tried searching on google with possible keywords but have had no luck.

Thank you for your time...Really appreciate your help.

Recommended Answers

All 5 Replies

What am I doing wrong?

Not reading this and this as requested, and assuming we are psychic.

what does this error mean that i get with the TFileStream declaration


E2293 ) expected

It means the people that designed the compiler assigned the value E2293 to the error. And unless you miscopied the error, it is ") expected".
So look above whatever line is wrong for a missing )

But the error relates to this declaration:

__fastcall TFileStream(const AnsiString fileOutput.txt, fmOpenWrite);

there is nothing wrong with this declaration

Errors are reported where they are noticed, not where they occur.

If the current error message on the current line doesn't make sense, then you need to start looking back through the code to see where it all started to go wrong.

Eg.

int a
int b;

could well report "unexpected int on line 2", but the real problem is a missing ; on line 1.
You have to consider this kind of error in your case.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.