Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Builder 6 texteditor error

Status
Not open for further replies.

vsy

Programmer
Apr 21, 2008
2
US
//"error message"
[Linker Error] Unresolved external '__fastcall TForm1::HelpAboutExecute(System::TObject *)
' referenced from C:\PROGRAM FILES\BORLAND\CBUILDER6\PROJECTS\TEXTEDITOR\UNIT1.OBJ


//"Unit1.cpp code"




//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop

#include "Unit1.h"
#include "About.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------

void __fastcall TForm1::FileNewExecute(TObject *Sender)
{
RichEdit1->Clear();
FileName = "untitled.txt";
StatusBar1->Panels->Items[0]->Text = FileName;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FileOpen1Accept(TObject *Sender)
{
RichEdit1->Lines->LoadFromFile (FileOpen1->Dialog->FileName);
FileName = FileOpen1->Dialog->FileName;
StatusBar1->Panels->Items[0]->Text = FileName;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FileSaveExecute(TObject *Sender)
{
if (FileName == "untitled.txt")
FileSaveAs1->Execute();
else
RichEdit1->Lines->SaveToFile(FileName);
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FileSaveAs1BeforeExecute(TObject *Sender)
{
FileSaveAs1->Dialog->InitialDir = ExtractFilePath (FileName);
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FileSaveAs1Accept(TObject *Sender)
{
FileName = FileSaveAs1->Dialog->FileName;
RichEdit1->Lines->SaveToFile(FileName);
StatusBar1->Panels->Items[0]->Text = FileName;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::HelpContents1Execute(TObject *Sender)
{
const static int HELP_TAB = 15;
const static int CONTENTS_ACTIVE = -3;
Application->HelpCommand(HELP_TAB, CONTENTS_ACTIVE);
}
//---------------------------------------------------------------------------
void __fastcall TForm1::HelpIndexExecute(TObject *Sender)
{
const static int HELP_TAB = 15;
const static int INDEX_ACTIVE = -2;
Application->HelpCommand(HELP_TAB, INDEX_ACTIVE);
}

void __fastcall TForm1::FormCreate(TObject *Sender)
{
Application->HelpFile = ExtractFilePath(Application->ExeName) + "TextEditor.hlp"
;FileName = "untitled.txt";
StatusBar1->Panels->Items[0]->Text = FileName;
RichEdit1->Clear();
}
//---------------------------------------------------------------------------


//"About.cpp code"



//---------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop

#include "About.h"
//---------------------------------------------------------------------
#pragma resource "*.dfm"
TAboutBox *AboutBox;
//---------------------------------------------------------------------
__fastcall TAboutBox::TAboutBox(TComponent* AOwner)
: TForm(AOwner)
{
}
//---------------------------------------------------------------------
void __fastcall TAboutBox::FormCreate(TObject *Sender)
{
AboutBox->ShowModal();
}
//---------------------------------------------------------------------------


 
My suggestion would be to check your Unit1.h file and see if your TForm1 class declaration has that method declared in it. I sometimes forget to implement a method that I've declared in a class, and that is the error I get when I do.
 
Thanks for the reply I'll check.
This texteditor in the help-using builder files.
I'm use to turbo C++ which I took in high school.
(not the qbasic print, none working iostream free version
bordland offers now)

By the way you know where I can find turbo c++ with a working cin and cout? (so I can compare the two while I learn builder)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top