Hey everyone I'm new to the programming world and unfortunately I have come across a big problem that I will hope I can get some help with. I have a program that was apparently created using delphi 3 and then finished using delphi 4 with some additional parts added later. I have found copies of amost every version of delphi ever made and installed them on my pc and attempted to compile this program in question. Unfortuantely I have yet to get it to compile without a few thousand error messages and I am st uck between a rock and a hard place. I know very little of Delphi programming, let alone programming itself. I have to get this program to compile so I can make some changes to the program. By trade I am a PLC programmer and I program in ladder logic, so I understand generally how I can make things work. I don't have much experience with structured text programming or C or C+ which makes this all the more complicated for me. I have gone through quite a few tutorials various websites and forums had up to teach yourself how to navigate through the Delphi interface as well as how the basics of a program are created. I have created some simple windows based programs already using the tutorials, and generaly understand the structure of a program made with delphi. I know the program I need to compile works because it is running even right now on a server, I just need to make some changes. I was told it is not easy to just make a program compile without finding out why it wont compile let alone if there was any 3rd party modules or database tools used to build it. So I came to the Delphi guru forum looking for help. If there is anyone out there that can possibly even point me in the right direction I would be greatly appreciative. I already know I have bit off far more than I can chew, but I would like to know if there is some way I can do this. I will be posting some of the error messages in a little while. In the mean time is there anyone out there that could possibly lend a hand?
![]() |
0 |
![]() |
Chris Osmond wrote: > Hey everyone I'm new to the programming world and unfortunately I have come across a big problem > that I will hope I can get some help with. I have a program that was apparently created using > delphi 3 and then finished using delphi 4 with some additional parts added later. I have found > copies of amost every version of delphi ever made and installed them on my pc and attempted to > compile this program in question. Unfortuantely I have yet to get it to compile without a few > thousand error messages and I am st uck between a rock and a hard place. I know very little of > Delphi programming, let alone programming itself. I have to get this program to compile so I can > make some changes to the program. > > By trade I am a PLC programmer and I program in ladder logic, so I understand generally how I can > make things work. I don't have much experience with structured text programming or C or C+ which > makes this all the more complicated for me. I have gone through quite a few tutorials various > websites and forums had up to teach yourself how to navigate through the Delphi interface as well > as how the basics of a program are created. I have created some simple windows based programs > already using the tutorials, and generaly understand the structure of a program made with delphi. > > I know the program I need to compile works because it is running even right now on a server, I > just need to make some changes. I was told it is not easy to just make a program compile without > finding out why it wont compile let alone if there was any 3rd party modules or database tools > used to build it. So I came to the Delphi guru forum looking for help. If there is anyone out > there that can possibly even point me in the right direction I would be greatly appreciative. > > I already know I have bit off far more than I can chew, but I would like to know if there is some > way I can do this. I will be posting some of the error messages in a little while. In the mean > time is there anyone out there that could possibly lend a hand? Chris, If you are looking for somebody to work with you through the process a better forum could be embarcadero.public.jobs.hiring (or just write me an email, see my signature). If you are looking for answers to specific questions, e.g what the error messages may mean, then look at some more appropriate newsgroup like f.i. embarcadero.public.delphi.general. Cheers Tom -- Tom Brunberg firstname.surname@welho.com
![]() |
0 |
![]() |
Chris Osmond wrote: > I have found copies of amost every version of delphi ever made and > installed them on my pc and attempted to compile this program in > question. Hmmm... They must have cost quite a lot of money, right? Such dedication. -- Rudy Velthuis "Once you've written TBicycle, you never forget how." -- Oliver Townshend in b.p.d.n-t.
![]() |
0 |
![]() |
Rudy Velthuis (TeamB) wrote: > Chris Osmond wrote: > > > I have found copies of amost every version of delphi ever made and > > installed them on my pc and attempted to compile this program in > > question. > > Hmmm... They must have cost quite a lot of money, right? Such > dedication. I don't know how much they cost Chris, but D1, D2, D3, D4, D5, D6, D7, D2004, D2005, D2010, DXE and DXE2 have cost me a chunk of change over the years. (To say nothing of TP1 through BP7, most of them, and Turbo Prolog.) I suspect it's third party stuff that't tripping Chris up. Chris, could you present Uses clauses of the units in this app? If they're very lengthy, you could strip out the ones you're absolutely certain are native Delphi units. John
![]() |
0 |
![]() |
> {quote:title=Rudy Velthuis (TeamB) wrote:}{quote} > Chris Osmond wrote: > > > I have found copies of amost every version of delphi ever made and > > installed them on my pc and attempted to compile this program in > > question. > > Hmmm... They must have cost quite a lot of money, right? Such > dedication. > > -- > Rudy Velthuis > > "Once you've written TBicycle, you never forget how." > -- Oliver Townshend in b.p.d.n-t. To be honest, all the copies other than my Delphi 7 that I own, were downloaded cracked versions I found through torrents to try to compile the program. Seing as none of them worked without an abundance of errors I am back to trying to tinker with my Delphi 7. The new Embarcadero looked very easy to navigate with colored phrases and automatic fill words, but still has so many errors on compile of this program. If one of the other versions of delphi worked to compile my program, I would go buy a copy so I can use it for further fixing of the program. I am currently using my Delphi 7 to make some SCATA windows based programs for communication from a PC to a PLC via Ethernet on our network.
![]() |
0 |
![]() |
> {quote:title=John Treder wrote:}{quote} > Rudy Velthuis (TeamB) wrote: > > > Chris Osmond wrote: > > > > > I have found copies of amost every version of delphi ever made and > > > installed them on my pc and attempted to compile this program in > > > question. > > > > Hmmm... They must have cost quite a lot of money, right? Such > > dedication. > > I don't know how much they cost Chris, but D1, D2, D3, D4, D5, D6, D7, > D2004, D2005, D2010, DXE and DXE2 have cost me a chunk of change over > the years. (To say nothing of TP1 through BP7, most of them, and Turbo > Prolog.) > > I suspect it's third party stuff that't tripping Chris up. > Chris, could you present Uses clauses of the units in this app? If > they're very lengthy, you could strip out the ones you're absolutely > certain are native Delphi units. > > John Hey John, I apologise for asking a newbie question but could you explain what you would like me to present? Chris
![]() |
0 |
![]() |
Chris Osmond wrote: > Hey John, > > I apologise for asking a newbie question but could you explain what > you would like me to present? > > Chris At the top of each unit in your project, there's a "Uses" clause, something like this: {code} unit DlgEditJob; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, ActnList, ToolWin, Menus, ActnPopup, ActnMan, ActnCtrls, ActnMenus, PlatformDefaultStyleActnCtrls, StdCtrls, ExtCtrls, Generics.Collections, ActiveX, VirtualTrees, GlobalDefs, JobTask, DlgAddToEditJob; {code} And there may be another one at the begining of the "Implementation" section. Those are lists of everything Delphi uses to compile your project. Most of the stuff in those clauses is internal Delphi code. In the example above, that I cut and pasted from one of my projects, "VirtualTrees" is a third-party unit, and "GlobalDefs, JobTask, DlgAddToEditJob" are units that I wrote myself. If you post the Uses clauses from your main form, we (folks in the newsgroup) can see if there's anything there that isn't part of Delphi, and we may have a clue as to why you're having a problem compiling the project. Do put the "{code}" line above and below what you copy from the project; it will make it easier to read. JOhn
![]() |
0 |
![]() |
> {quote:title=John Treder wrote:}{quote} > Chris Osmond wrote: > > > Hey John, > > > > I apologise for asking a newbie question but could you explain what > > you would like me to present? > > > > Chris > > At the top of each unit in your project, there's a "Uses" clause, > something like this: > > {code} > unit DlgEditJob; > > interface > > uses > Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, > Forms, > Dialogs, ActnList, ToolWin, Menus, ActnPopup, ActnMan, ActnCtrls, > ActnMenus, > PlatformDefaultStyleActnCtrls, StdCtrls, ExtCtrls, > Generics.Collections, > ActiveX, VirtualTrees, GlobalDefs, JobTask, DlgAddToEditJob; > {code} > > And there may be another one at the begining of the "Implementation" > section. > Those are lists of everything Delphi uses to compile your project. > > Most of the stuff in those clauses is internal Delphi code. In the > example above, that I cut and pasted from one of my projects, > "VirtualTrees" is a third-party unit, and "GlobalDefs, JobTask, > DlgAddToEditJob" are units that I wrote myself. > > If you post the Uses clauses from your main form, we (folks in the > newsgroup) can see if there's anything there that isn't part of Delphi, > and we may have a clue as to why you're having a problem compiling the > project. > Do put the "{code}" line above and below what you copy from the > project; it will make it easier to read. > > JOhn Hey John, this is from the start of the program: {code} program XXXXXXXXXX; uses Windows, SysUtils, Classes, Forms, ActiveDS in 'ActiveDS.pas', ADS in 'ADS.pas', AccCtrl in 'AccCtrl.pas', AclApi in 'AclApi.pas', IntShCut in 'IntShCut.pas', Res in 'Res.pas', FormWelcome in 'FormWelcome.pas' {WelcomeForm}, FormAgreement in 'FormAgreement.pas' {AgreementForm}, FormSetupType in 'FormSetupType.pas' {SetupTypeForm}, FormSerial in 'FormSerial.pas' {SerialForm}, FormDestination in 'FormDestination.pas' {DestinationForm}, FormConnection in 'FormConnection.pas' {ConnectionForm}, FormSettings in 'FormSettings.pas' {SettingsForm}, FormUsers in 'FormUsers.pas' {UsersForm}, FormIIS in 'FormIIS.pas' {IISForm}, FormWSIdentity in 'FormWSIdentity.pas' {WSIdentityForm}, FormProgramFolder in 'FormProgramFolder.pas' {ProgramFolderForm}, FormStartInstallation in 'FormStartInstallation.pas' {StartInstallationForm}, FormInfo in 'FormInfo.pas' {InfoForm}, FormInstallComplete in 'FormInstallComplete.pas' {InstallCompleteForm}, FormEmptyAction in 'FormEmptyAction.pas' {EmptyActionForm}, FormUpgradeList in 'FormUpgradeList.pas' {UpgradeListForm}, FormPassword in 'FormPassword.pas' {PasswordForm}, FormStartUpgrade in 'FormStartUpgrade.pas' {StartUpgradeForm}, FormUpgradeComplete in 'FormUpgradeComplete.pas' {UpgradeCompleteForm}, FormUninstallList in 'FormUninstallList.pas' {UninstallListForm}, FormStartUninstall in 'FormStartUninstall.pas' {StartUninstallForm}, FormUninstallComplete in 'FormUninstallComplete.pas' {UninstallCompleteForm}, FormBackupList in 'FormBackupList.pas' {BackupListForm}, FormBackupDestination in 'FormBackupDestination.pas' {BackupDestinationForm}, FormStartBackup in 'FormStartBackup.pas' {StartBackupForm}, FormBackupComplete in 'FormBackupComplete.pas' {BackupCompleteForm}, FormRestoreFile in 'FormRestoreFile.pas' {RestoreFileForm}, FormRestoreInstallation in 'FormRestoreInstallation.pas' {RestoreInstallationForm}, FormStartRestore in 'FormStartRestore.pas' {StartRestoreForm}, FormRestoreComplete in 'FormRestoreComplete.pas' {RestoreCompleteForm}, FormProjectName in 'FormProjectName.pas' {ProjectNameForm}, Installer in 'Installer.pas', SQLConst in 'SQLConst.pas', CabIntf in 'CabIntf.pas', CabSTComps in 'CabSTComps.pas', CabSTConsts in 'CabSTConsts.pas', FileTracker in 'FileTracker.pas', DataStor in '..\common\DataStor.pas', Blowfish in '..\common\Blowfish.pas', FileCnf in '..\common\FileCnf.pas', FileBackup in 'FileBackup.pas', AppConst in '..\common\AppConst.pas', InstList in 'InstList.pas', ResStream in 'ResStream.pas', WizardStack in 'WizardStack.pas'; {$R *.RES} {$R DATA.RES} {code} const waWelcomeForm = 0; waAgreementForm = 1; waSetupTypeForm = 2; --------------------- I know the guy who wrote this code wrote the majority of the units himself, and I know there may have been some 3rd party stuff included in here. Let me know what you can see. This program is XXXXX because I would prefer not to spread this very hard earned code around the net for free. A lot of money was put into this program, and I would prefer not to waste it. Specific code I will have to pm probably, but the main form is just a break down of where things are referencing from right? The fatal error when compiling is below: [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas'
![]() |
0 |
![]() |
On Thu, 29 Sep 2011 09:39:50 -0700, Chris Osmond <> wrote: >[Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas' This says the failure is coming from Installer.pas. Fatal errors are very often missing units--can you do the same thing you just did except for Installer.Pas?
![]() |
0 |
![]() |
Chris Osmond wrote: > [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas' There must be other errors reported before this. You should either post what those erros were here, or read the following: https://forums.embarcadero.com/thread.jspa?threadID=24120 First, make sure get a copy of ever file vefore deleting all *.dcu files, then try to 'Build All'.
![]() |
0 |
![]() |
Chris Osmond wrote: > I know the guy who wrote this code wrote the majority of the units himself, > and I know there may have been some 3rd party stuff included in here. Let me > know what you can see. Ok, Chris, you've provided a way start searching. > > This program is XXXXX because I would prefer not to spread this very hard > earned code around the net for free. A lot of money was put into this > program, and I would prefer not to waste it. That's fine. > > Specific code I will have to pm probably, but the main form is just a break > down of where things are referencing from right? Yes, what you posted was what's called the "project file". Its name on your hard drive is "XXXXX.dpr". > > The fatal error when compiling is below: > > [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit > 'Installer.pas' So the first question is, do you have the file "Installer.pas" in the directory where "XXXXX.dpr" lives? There will be many of these questions. In the end, you'll have to find all the *.pas files in the list you posted. And that will be enough to cause another cascade of problems, BTW! This isn't really the right newsgroup to use for your problem. It would be better - that is, you'll find more people who can help - if you post this message (with a short explanatory note) in the embarcadero.public.delphi.ide newsgroup. I expect the other responses here will also give you something to work with. John
![]() |
0 |
![]() |
Adem Meda wrote: > Chris Osmond wrote: > > > [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit > > 'Installer.pas' > > There must be other errors reported before this. > > You should either post what those erros were here, or read the following: > > https://forums.embarcadero.com/thread.jspa?threadID=24120 > > First, make sure get a copy of ever file vefore deleting all *.dcu files, > then try to 'Build All'. A good way to "delete" the files is to rename them to something like TheFile.Xdcu . John
![]() |
0 |
![]() |
> {quote:title=Adem Meda wrote:}{quote} > Chris Osmond wrote: > > > [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas' > > There must be other errors reported before this. > > You should either post what those erros were here, or read the following: > > https://forums.embarcadero.com/thread.jspa?threadID=24120 > > First, make sure get a copy of ever file vefore deleting all *.dcu files, then try to 'Build All'. Here are all the errors just on installer.pas that I get: {code} [Warning] Installer.pas(28): Unit 'FileCtrl' is specific to a platform [Warning] Installer.pas(131): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(298): Symbol 'AllocateHWnd' is deprecated [Warning] Installer.pas(304): Symbol 'DeallocateHWnd' is deprecated [Error] Installer.pas(701): Undeclared identifier: 'VarArrayLowBound' [Error] Installer.pas(701): Undeclared identifier: 'VarArrayHighBound' [Warning] Installer.pas(995): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1005): Symbol 'RaiseLastWin32Error' is deprecated [Warning] Installer.pas(1019): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1027): Symbol 'RaiseLastWin32Error' is deprecated [Warning] Installer.pas(1030): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1050): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1053): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1055): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1063): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1068): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1074): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1107): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1115): Symbol 'RaiseLastWin32Error' is deprecated [Warning] Installer.pas(1118): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1126): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1132): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1158): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1161): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1163): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1186): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1188): Symbol 'RaiseLastWin32Error' is deprecated [Warning] Installer.pas(1191): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1212): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1215): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1222): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1320): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(1480): Symbol 'RaiseLastWin32Error' is deprecated [Warning] Installer.pas(1485): Symbol 'Win32Check' is specific to a platform [Warning] Installer.pas(1563): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(1564): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(1606): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(1738): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(1742): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(2015): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(2016): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(2221): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(2351): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(2574): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Warning] Installer.pas(2578): Symbol 'ExcludeTrailingBackslash' is specific to a platform [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas' {code} -------------------------- This is the interface and implementation: {code} unit Installer; interface uses Res; procedure Install(const SerialNumber, ProjectName, CompanyName, EmailAddress, SMTPServer, AdminLogin, AdminPassword, StaffLogin, StaffPassword, CustomerLogin, CustomerPassword, SQLServerName, Password, DomainName, MainPath, WebSitePath, ProgramFolder, BackupFileName: string; TCPPort, Network: Integer; WebSiteIdentities: TWebSiteIdentities; var InstallationStatus: TInstallationStatus; var RebootRequired: Boolean); procedure Upgrade(ID: Integer; const Password: string; InRestore: Boolean; var InstallationStatus: TInstallationStatus; var RebootRequired: Boolean); procedure Backup(ID: Integer; const Password, BackupPath: string; var InstallationStatus: TInstallationStatus); procedure Restore(ID: Integer; const Password, BackupFileName: string; var InstallationStatus: TInstallationStatus; var RebootRequired: Boolean); procedure Uninstall(ID: Integer; const Password: string; var InstallationStatus: TInstallationStatus; var RebootRequired: Boolean); procedure ReadConfigFile(const ConfigFileName: string; var SQLServerName: string; var Network, SetupInProgress: Integer; const DefaultSQLServerName: string; DefaultNetwork, DefaultSetupInProgress: Integer); procedure ReleaseQueryEndSession; implementation uses Windows, Messages, SysUtils, Classes, Forms, Registry, FileCtrl, ADODB, ActiveDS, ADS, ActiveX, WinSvc, FormInfo, SQLConst, CabSTComps, FileTracker, AclApi, AccCtrl, FileCnf, AppConst, ComObj, Blowfish, FileBackup, ResStream; {code}
![]() |
0 |
![]() |
Chris Osmond wrote: > Here are all the errors just on installer.pas that I get: > > [Warning] Installer.pas(28): Unit 'FileCtrl' is specific to a platform > [Warning] Installer.pas(131): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(298): Symbol 'AllocateHWnd' is deprecated > [Warning] Installer.pas(304): Symbol 'DeallocateHWnd' is deprecated These are easy. Just add the following lines at the top of Installer.pas {$WARN SYMBOL_PLATFORM OFF} {$WARN SYMBOL_LIBRARY OFF} {$WARN SYMBOL_DEPRECATED OFF} {$WARN UNIT_DEPRECATED OFF} {$WARN UNIT_LIBRARY OFF} {$WARN UNIT_PLATFORM OFF} Then, when you have time, with cursor on '$WARN' press F1 to see what it means. > [Error] Installer.pas(701): Undeclared identifier: 'VarArrayLowBound' > [Error] Installer.pas(701): Undeclared identifier: 'VarArrayHighBound' Easy. It needs the 'Variants' unit added to the 'Uses' clause. See below. > [Warning] Installer.pas(995): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1005): Symbol 'RaiseLastWin32Error' is deprecated > [Warning] Installer.pas(1019): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1027): Symbol 'RaiseLastWin32Error' is deprecated > [Warning] Installer.pas(1030): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1050): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1053): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1055): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1063): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1068): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1074): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1107): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1115): Symbol 'RaiseLastWin32Error' is deprecated > [Warning] Installer.pas(1118): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1126): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1132): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1158): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1161): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1163): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1186): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1188): Symbol 'RaiseLastWin32Error' is deprecated > [Warning] Installer.pas(1191): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1212): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1215): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1222): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1320): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(1480): Symbol 'RaiseLastWin32Error' is deprecated > [Warning] Installer.pas(1485): Symbol 'Win32Check' is specific to a platform > [Warning] Installer.pas(1563): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(1564): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(1606): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(1738): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(1742): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(2015): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(2016): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(2221): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(2351): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(2574): Symbol 'ExcludeTrailingBackslash' is specific to a platform > [Warning] Installer.pas(2578): Symbol 'ExcludeTrailingBackslash' is specific to a platform These are not important --they are just warnings. All these will vanish when you add the '$WARN' stuff anyway. > [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas' > implementation > > uses Windows, Messages, SysUtils, Classes, Forms, Registry, FileCtrl, ADODB, > ActiveDS, ADS, ActiveX, WinSvc, FormInfo, SQLConst, CabSTComps, FileTracker, > AclApi, AccCtrl, FileCnf, AppConst, ComObj, Blowfish, FileBackup, ResStream;> > {code} Add 'Variants' to the 'Uses' clause to that the above becomes this: Uses Windows, Messages, SysUtils, Classes, Forms, {...} FileBackup, ResStream, *Variants*; Then try to compile.
![]() |
0 |
![]() |
> {quote:title=Adem Meda wrote:}{quote} > Chris Osmond wrote: > > > Here are all the errors just on installer.pas that I get: > > > > [Warning] Installer.pas(28): Unit 'FileCtrl' is specific to a platform > > [Warning] Installer.pas(131): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(298): Symbol 'AllocateHWnd' is deprecated > > [Warning] Installer.pas(304): Symbol 'DeallocateHWnd' is deprecated > > These are easy. Just add the following lines at the top of Installer.pas > > {$WARN SYMBOL_PLATFORM OFF} > {$WARN SYMBOL_LIBRARY OFF} > {$WARN SYMBOL_DEPRECATED OFF} > {$WARN UNIT_DEPRECATED OFF} > {$WARN UNIT_LIBRARY OFF} > {$WARN UNIT_PLATFORM OFF} > > Then, when you have time, with cursor on '$WARN' press F1 to see what it means. > > > [Error] Installer.pas(701): Undeclared identifier: 'VarArrayLowBound' > > [Error] Installer.pas(701): Undeclared identifier: 'VarArrayHighBound' > > Easy. It needs the 'Variants' unit added to the 'Uses' clause. > > See below. > > > [Warning] Installer.pas(995): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1005): Symbol 'RaiseLastWin32Error' is deprecated > > [Warning] Installer.pas(1019): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1027): Symbol 'RaiseLastWin32Error' is deprecated > > [Warning] Installer.pas(1030): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1050): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1053): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1055): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1063): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1068): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1074): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1107): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1115): Symbol 'RaiseLastWin32Error' is deprecated > > [Warning] Installer.pas(1118): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1126): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1132): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1158): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1161): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1163): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1186): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1188): Symbol 'RaiseLastWin32Error' is deprecated > > [Warning] Installer.pas(1191): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1212): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1215): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1222): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1320): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(1480): Symbol 'RaiseLastWin32Error' is deprecated > > [Warning] Installer.pas(1485): Symbol 'Win32Check' is specific to a platform > > [Warning] Installer.pas(1563): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(1564): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(1606): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(1738): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(1742): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(2015): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(2016): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(2221): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(2351): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(2574): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > [Warning] Installer.pas(2578): Symbol 'ExcludeTrailingBackslash' is specific to a platform > > These are not important --they are just warnings. > > All these will vanish when you add the '$WARN' stuff anyway. > > > [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas' > > > implementation > > > > uses Windows, Messages, SysUtils, Classes, Forms, Registry, FileCtrl, ADODB, > > ActiveDS, ADS, ActiveX, WinSvc, FormInfo, SQLConst, CabSTComps, FileTracker, > > AclApi, AccCtrl, FileCnf, AppConst, ComObj, Blowfish, FileBackup, ResStream;> > > {code} > > Add 'Variants' to the 'Uses' clause to that the above becomes this: > > Uses > Windows, > Messages, > SysUtils, > Classes, > Forms, > {...} > FileBackup, > ResStream, > *Variants*; > > Then try to compile. Thank you for your help, my warning and error is now a file not found 'Data.Res' The code is here from the XXXXXXX.dpr file: {code} {$R *RES} {$R DATA.RES} const waWelcomeForm = 0; waAgreementForm = 1; {code} Error is below: [Warning] XXXXXXX.dpr(61): File not found: 'DATA.RES' [Error] File not found: 'DATA.RES' I am assuming I now need to build a DATA unit?
![]() |
0 |
![]() |
> [Warning] XXXXXXX.dpr(61): File not found: 'DATA.RES' > > [Error] File not found: 'DATA.RES' > > I am assuming I now need to build a DATA unit? No. 'DATA.RES' isn't a unit file, it is a resource file. Try to locace a 'DATA.RES' file lurking in one of the (sub-)directories and if so, put it in the project folder. If not, see if there's a 'DATA.RC' file in that folder and then Google for compiling resource files --you'll have to do this yourself as I don't remeber the steps off hand. This one might help: http://stackoverflow.com/questions/992921/how-to-compile-res-file-from-commandline-delphi-7 See, especially, comment #4 there. But, before doing that, try commenting that line out and compile. Though you'll probably have to do the above eventually, tt might not be such a show stopper for initial compile. To comment it out do this (put a dot after the curly bracket) {.$R DATA.RES}
![]() |
0 |
![]() |
On Fri, 30 Sep 2011 07:53:10 -0700, Chris Osmond <> wrote: >> {quote:title=Adem Meda wrote:}{quote} >> Chris Osmond wrote: >> >> > [Fatal Error] FormInstallComplete.pas(33): Could not compile used unit 'Installer.pas' >> >> There must be other errors reported before this. >> >> You should either post what those erros were here, or read the following: >> >> https://forums.embarcadero.com/thread.jspa?threadID=24120 >> >> First, make sure get a copy of ever file vefore deleting all *.dcu files, then try to 'Build All'. > >Here are all the errors just on installer.pas that I get: > >{code} Ah, now we are getting somewhere. >[Warning] Installer.pas(28): Unit 'FileCtrl' is specific to a platform >[Warning] Installer.pas(131): Symbol 'ExcludeTrailingBackslash' is specific to a platform Most of these are utterly harmless and can be easily disabled in the options. They're only meaningful if you're trying to write code that can run on Kylix also. Turn off the platform specific warnings in the compiler and your error list will get *MUCH* smaller. >[Warning] Installer.pas(298): Symbol 'AllocateHWnd' is deprecated >[Warning] Installer.pas(304): Symbol 'DeallocateHWnd' is deprecated I'm not sure on these. >[Error] Installer.pas(701): Undeclared identifier: 'VarArrayLowBound' >[Error] Installer.pas(701): Undeclared identifier: 'VarArrayHighBound' Here's why it failed. >{code} > >uses Res; .... >implementation > >uses Windows, Messages, SysUtils, Classes, Forms, Registry, FileCtrl, ADODB, > ActiveDS, ADS, ActiveX, WinSvc, FormInfo, SQLConst, CabSTComps, FileTracker, > AclApi, AccCtrl, FileCnf, AppConst, ComObj, Blowfish, FileBackup, ResStream; > >{code} These were the lines we were asking for. I would have thought Variants would have to be in here to get it to compile. I never did much of anything with variants, though.
![]() |
0 |
![]() |
> {quote:title=Adem Meda wrote:}{quote} > > [Warning] XXXXXXX.dpr(61): File not found: 'DATA.RES' > > > > [Error] File not found: 'DATA.RES' > > > > I am assuming I now need to build a DATA unit? > > No. 'DATA.RES' isn't a unit file, it is a resource file. > > Try to locace a 'DATA.RES' file lurking in one of the (sub-)directories and if so, put it in the project folder. > > If not, see if there's a 'DATA.RC' file in that folder and then Google for compiling resource files --you'll have to do this yourself as I don't remeber the steps off hand. > > This one might help: http://stackoverflow.com/questions/992921/how-to-compile-res-file-from-commandline-delphi-7 > > See, especially, comment #4 there. > > But, before doing that, try commenting that line out and compile. > > Though you'll probably have to do the above eventually, tt might not be such a show stopper for initial compile. > > To comment it out do this (put a dot after the curly bracket) > > {.$R DATA.RES} If I use the {.$R DATA.RES} in the code I get an error windows that comes up and tells me: Unable to create process: The requested operation requires elevation I have a data.rc file in the installer folder. Comment #4 in that link says I can possibly just include a .rc file into the command line, tried that {$R DATA.RC} and it lets me know this: [Error] RLINK32: Unsupported 16bit resource in file "C:\Users\chris\XXXXXXX\XXXXXXXXX\installer\data.rc" This data.rc file only has 3 lines in it: {code} Z_SITE RCDATA site.dat Z_DATA RCDATA data.dat R_LICENSE RCDATA license.dat {code}
![]() |
0 |
![]() |
Chris Osmond wrote: > If I use the {.$R DATA.RES} in the code I get an error windows that comes up and tells me: > > Unable to create process: The requested operation requires elevation I have no idea why it says that. But, ignore that --you have bigger problems, see below: > I have a data.rc file in the installer folder. Comment #4 in that link says I can possibly just include a .rc file into the command line, tried that {$R DATA.RC} and it lets me know this: > > [Error] RLINK32: Unsupported 16bit resource in file "C:\Users\chris\XXXXXXX\XXXXXXXXX\installer\data.rc" > > This data.rc file only has 3 lines in it: > > Z_SITE RCDATA site.dat > Z_DATA RCDATA data.dat > R_LICENSE RCDATA license.dat Hmm... It seems these *.dat files have some binaries in them and they appear to be 16-bit. You have to deal with that problem: i.e. find the sources for those files and generate 32-bit versions of them --that I can't help you with, simply because I don't know what those files contain, nor what tool was used to generate them. Wait a minute: Perhaps you have *.rc files for those *.dat files somewhere; if so, you might try compiling them into *.res files first (use #4 method) and then change their extensions to *.dat afterwards.
![]() |
0 |
![]() |
> {quote:title=Adem Meda wrote:}{quote} > Chris Osmond wrote: > > > If I use the {.$R DATA.RES} in the code I get an error windows that comes up and tells me: > > > > Unable to create process: The requested operation requires elevation > > I have no idea why it says that. But, ignore that --you have bigger problems, see below: > > > I have a data.rc file in the installer folder. Comment #4 in that link says I can possibly just include a .rc file into the command line, tried that {$R DATA.RC} and it lets me know this: > > > > [Error] RLINK32: Unsupported 16bit resource in file "C:\Users\chris\XXXXXXX\XXXXXXXXX\installer\data.rc" > > > > This data.rc file only has 3 lines in it: > > > > Z_SITE RCDATA site.dat > > Z_DATA RCDATA data.dat > > R_LICENSE RCDATA license.dat > > Hmm... It seems these *.dat files have some binaries in them and they appear to be 16-bit. > > You have to deal with that problem: i.e. find the sources for those files and generate 32-bit versions of them --that I can't help you with, simply because I don't know what those files contain, nor what tool was used to generate them. > > Wait a minute: Perhaps you have *.rc files for those *.dat files somewhere; if so, you might try compiling them into *.res files first (use #4 method) and then change their extensions to *.dat afterwards. I may have found something. I searched for site.dat, and data.dat and license.dat and found they were all text in a dos .cmd file. I crossed my fingers that my pc wouldn't start to smoke or suddenly flash me a blue screen and executed it, and I suddenly see a DATA.res file created in the directory. I guess I needed to run a dos prompt to generate the data.res file? Regardless, I now have only a few warnings but now I am back to only the "requires elevation" window that comes up. I think it has to do with my Windows 7 install, and me possibly not having admin rights to execute the compiled program?
![]() |
0 |
![]() |
Chris Osmond wrote: > I guess I needed to run a dos prompt to generate the data.res file? Where's the original developer of that app? Dead? Did s/he not leave any documentation; or, can't you reach him/her? > Regardless, I now have only a few warnings but now I am back to only the "requires elevation" window that comes up. I think it has to do with my Windows 7 install, and me possibly not having admin rights to execute the compiled program? Yes, in Win7 you need Admin rights to install a program. Anyway, it seems you're mostly set to go. Good luck.
![]() |
0 |
![]() |
On Fri, 30 Sep 2011 11:38:49 -0700, Chris Osmond <> wrote: >If I use the {.$R DATA.RES} in the code I get an error windows that comes up and tells me: > >Unable to create process: The requested operation requires elevation It sounds like you're operating out of Program Files.
![]() |
0 |
![]() |
On Fri, 30 Sep 2011 12:20:16 -0700, Chris Osmond <> wrote: >Regardless, I now have only a few warnings but now I am back to only the "requires elevation" window that comes up. I think it has to do with my Windows 7 install, and me possibly not having admin rights to execute the compiled program? If that error is coming from the program and not the compiler then your program is probably breaking the rules of Win 7 and trying to write to something in Program Files--perhaps a config file??
![]() |
0 |
![]() |
> {quote:title=Adem Meda wrote:}{quote} > Chris Osmond wrote: > > > I guess I needed to run a dos prompt to generate the data.res file? > > Where's the original developer of that app? > > Dead? > > Did s/he not leave any documentation; or, can't you reach him/her? > > > Regardless, I now have only a few warnings but now I am back to only the "requires elevation" window that comes up. I think it has to do with my Windows 7 install, and me possibly not having admin rights to execute the compiled program? > > Yes, in Win7 you need Admin rights to install a program. > > Anyway, it seems you're mostly set to go. > > Good luck. Well I gained my admin rights, now I am in 'ResStream.pas' and I have an error that says Undeclared identifier: 'SResNotFound' The code is: {code} begin raise EResNotFound.CreateFmt (SResNotFound, [Name]); end; {code} The interface for the unit ResStream is: Windows, SysUtils, Classes; and implementation is: uses Blowfish, Consts; By the way, now I have tons of warnings for Unsafe type 'PChar' and 'Pointer' etc. A code to silence those warnings would be what? or are there some internal settings in delphi I can just switch off the warnings.
![]() |
0 |
![]() |
> {quote:title=Loren Pechtel wrote:}{quote} > On Fri, 30 Sep 2011 11:38:49 -0700, Chris Osmond <> wrote: > > >If I use the {.$R DATA.RES} in the code I get an error windows that comes up and tells me: > > > >Unable to create process: The requested operation requires elevation > > It sounds like you're operating out of Program Files. I am trying to run it from program files yes. So many file permissions with Windows 7... sigh... Now that I have this new problem with SResNotFound being undeclared I am stuck again
![]() |
0 |
![]() |
Chris Osmond wrote: > > {quote:title=Adem Meda wrote:}{quote} > > Chris Osmond wrote: > > > > > I guess I needed to run a dos prompt to generate the data.res file? > > > > Where's the original developer of that app? > > > > Dead? > > > > Did s/he not leave any documentation; or, can't you reach him/her? > > > > > *Regardless*, I now have only a few warnings but now I am back to only the "requires elevation" window that comes up. I think it has to do with my Windows 7 install, and me possibly not having admin rights to execute the compiled program?
![]() |
0 |
![]() |
Chris Osmond wrote: > Well I gained my admin rights, now I am in 'ResStream.pas' and I have an > error that says Undeclared identifier: 'SResNotFound' > > The code is: > > {code} > > begin > raise EResNotFound.CreateFmt (SResNotFound, [Name]); > end; > > {code} > Adem has been remarkably more helpful than I'd be likely to be! Your problem here is that a variable "Name", which should be a .res file, isn't found where the code went looking for it. Just above the code you quoted, there's certainly a line that says or ends with "except". Before that one there's a line that says "try". The problem is somewhere between the "try" and the "except". John
![]() |
0 |
![]() |
> {quote:title=John Treder wrote:}{quote} > Chris Osmond wrote: > > > Well I gained my admin rights, now I am in 'ResStream.pas' and I have an > > error that says Undeclared identifier: 'SResNotFound' > > > > The code is: > > > > {code} > > > > begin > > raise EResNotFound.CreateFmt (SResNotFound, [Name]); > > end; > > > > {code} > > > > Adem has been remarkably more helpful than I'd be likely to be! > Your problem here is that a variable "Name", which should be a .res file, isn't > found where the code went looking for it. > Just above the code you quoted, there's certainly a line that says or ends with > "except". Before that one there's a line that says "try". > The problem is somewhere between the "try" and the "except". > > John The section of code above it says it is a procedure and 'Name' is in one of the parts in brackets: {code} procedure TEncodedResourceStream.Initialize(Instance: THandle; Name, ResType: PChar; const Key: array of Byte); procedure Error; begin raise EResNotFound.CreateFmt(SResNotFound, [Name]); end; {code} And before that there there are two constructors, one for a TEncodedResourceStream.Create and a TEncodedResourceStream.CreateFromID, I couldnt find try, or exept
![]() |
0 |
![]() |
Chris Osmond wrote: > > {quote:title=John Treder wrote:}{quote} > > Chris Osmond wrote: > > > > > Well I gained my admin rights, now I am in 'ResStream.pas' and I have an > > > error that says Undeclared identifier: 'SResNotFound' > > > > > > The code is: > > > > > > {code} > > > > > > begin > > > raise EResNotFound.CreateFmt (SResNotFound, [Name]); > > > end; > > > > > > {code} > > > > > > > Adem has been remarkably more helpful than I'd be likely to be! > > Your problem here is that a variable "Name", which should be a .res file, > > isn't found where the code went looking for it. > > Just above the code you quoted, there's certainly a line that says or ends > > with "except". Before that one there's a line that says "try". > > The problem is somewhere between the "try" and the "except". > > > > John > > The section of code above it says it is a procedure and 'Name' is in one of > the parts in brackets: > > {code} > > procedure TEncodedResourceStream.Initialize(Instance: THandle; Name, ResType: > PChar; const Key: array of Byte); > > procedure Error; > begin > raise EResNotFound.CreateFmt(SResNotFound, [Name]); > end; > > {code} > > And before that there there are two constructors, one for a > TEncodedResourceStream.Create and a TEncodedResourceStream.CreateFromID, I > couldnt find try, or exept Ok, I'm sorry, I didn't see the whole picture. The "procedure Error;" is a local procedure visible only within the Initialize procedure. Within that procedure, below the Error procedure, there will be some code that tests the "Name" argument for validity. If that code finds a problem it will call Error, which does nothing but raise the exception. So I sent you on a wild goose chase. EResNotFound is an exception class declared in the Classes unit. SResNotFound is a string constant in the unit RTLConsts in Delphi XE. I'm not sure where it is in your version of Delphi, but it's somewhere in a Delphi unit, I'm sure. I don't have earlier versions of Delphi installed. You can search for the text "SResNotFound" in files in your Delphi source directory, than add that unit to the uses clause. John
![]() |
0 |
![]() |
> > > > {code} > > > > procedure TEncodedResourceStream.Initialize(Instance: THandle; Name, ResType: > > PChar; const Key: array of Byte); > > > > procedure Error; > > begin > > raise EResNotFound.CreateFmt(SResNotFound, [Name]); > > end; > > > > {code} > > > > And before that there there are two constructors, one for a > > TEncodedResourceStream.Create and a TEncodedResourceStream.CreateFromID, I > > couldnt find try, or exept > > Ok, I'm sorry, I didn't see the whole picture. > The "procedure Error;" is a local procedure visible only within the Initialize > procedure. > Within that procedure, below the Error procedure, there will be some code that > tests the "Name" argument for validity. If that code finds a problem it will > call Error, which does nothing but raise the exception. > > So I sent you on a wild goose chase. > EResNotFound is an exception class declared in the Classes unit. > SResNotFound is a string constant in the unit RTLConsts in Delphi XE. I'm not > sure where it is in your version of Delphi, but it's somewhere in a Delphi > unit, I'm sure. I don't have earlier versions of Delphi installed. > You can search for the text "SResNotFound" in files in your Delphi source > directory, than add that unit to the uses clause. > > John I found 'SResNotFound' in the delphi 7 source directory under 'richedit_DRC.rc' It is listed 4 times in the file: {code} #define RTLConsts_SResNotFound 65413 RTLConsts_SReadOnlyProperty "Property is read-only" /* ID:RTLConsts_SResNotFound Orig:"Resource %s not found" Status:2 Created:36987.3973918519 Modified:36987.3973918519 PrevOrig: PrevCurr: Comment: */ RTLConsts_SResNotFound "Resource %s not found" /* ID:RTLConsts_SSeekNotImplemented Orig:"%s.Seek not implemented" Status:0 Created:36987.3973918519 Modified:36987.3973918519 PrevOrig: PrevCurr: Comment: */ // ID:Consts_SResNotFound Orig:"Resource %s not found" Status:3 Created:36361.6641203704 Modified:36987.3973900463 PrevOrig: PrevCurr: Comment: // Consts_SResNotFound "Resource %s not found" {code} File Located in C:\Program Files\Borland\Delphi7\Demos\Richedit\Enu I am supposed to add this file to my units clause?
![]() |
0 |
![]() |
Chris Osmond wrote: > > > > > > {code} > > > > > > procedure TEncodedResourceStream.Initialize(Instance: THandle; Name, > > > ResType: PChar; const Key: array of Byte); > > > > > > procedure Error; > > > begin > > > raise EResNotFound.CreateFmt(SResNotFound, [Name]); > > > end; > > > > > > {code} > > > > > > And before that there there are two constructors, one for a > > > TEncodedResourceStream.Create and a TEncodedResourceStream.CreateFromID, I > > > couldnt find try, or exept > > > > Ok, I'm sorry, I didn't see the whole picture. > > The "procedure Error;" is a local procedure visible only within the > > Initialize procedure. > > Within that procedure, below the Error procedure, there will be some code > > that tests the "Name" argument for validity. If that code finds a problem > > it will call Error, which does nothing but raise the exception. > > > > So I sent you on a wild goose chase. > > EResNotFound is an exception class declared in the Classes unit. > > SResNotFound is a string constant in the unit RTLConsts in Delphi XE. I'm > > not sure where it is in your version of Delphi, but it's somewhere in a > > Delphi unit, I'm sure. I don't have earlier versions of Delphi installed. > > You can search for the text "SResNotFound" in files in your Delphi source > > directory, than add that unit to the uses clause. > > > > John > > I found 'SResNotFound' in the delphi 7 source directory under > 'richedit_DRC.rc' > > It is listed 4 times in the file: > {code} > > #define RTLConsts_SResNotFound 65413 > > RTLConsts_SReadOnlyProperty "Property is read-only" > /* ID:RTLConsts_SResNotFound Orig:"Resource %s not found" Status:2 > Created:36987.3973918519 Modified:36987.3973918519 PrevOrig: PrevCurr: > Comment: */ > > RTLConsts_SResNotFound "Resource %s not found" > /* ID:RTLConsts_SSeekNotImplemented Orig:"%s.Seek not implemented" Status:0 > Created:36987.3973918519 Modified:36987.3973918519 PrevOrig: PrevCurr: > Comment: */ > > // ID:Consts_SResNotFound Orig:"Resource %s not found" Status:3 > Created:36361.6641203704 Modified:36987.3973900463 PrevOrig: PrevCurr: > Comment: > > // Consts_SResNotFound "Resource %s not found" > > {code} > > File Located in C:\Program Files\Borland\Delphi7\Demos\Richedit\Enu > > I am supposed to add this file to my units clause? I'm sort of feeling my way along here, and I might again suggest something wrong. First, try putting "Richedit" in the uses clause and see what happens. If the compiler barfs on that, try to figure out how to add the path to "Richedit.pas", which I'm pretty sure you have, to the compiler paths. My thinking is below. The file "richedit_DRC.rc" is a resource file. The clue I'm looking at is "File Located in C:\Program Files\Borland\Delphi7\Demos\Richedit\Enu". In that directory, there's probably a "Richedit.pas" file. If so, what you need to do is add "C:\Program Files\Borland\Delphi7\Demos\Richedit" to the compiler search path in the Project>Options menu. ** I do hope someone will jump in and correct me here! ** I honestly don't remember what the exact place in D7 that you put the paths where the compiler was supposed to look for source files. I do know that it has changed at least once over the years. John
![]() |
0 |
![]() |
Chris Osmond wrote: > > > > > > {code} > > > > > > procedure TEncodedResourceStream.Initialize(Instance: THandle; > > > Name, ResType: PChar; const Key: array of Byte); > > > > > > procedure Error; > > > begin > > > raise EResNotFound.CreateFmt(SResNotFound, [Name]); > > > end; > > > > > > {code} > > > > > EResNotFound is an exception class declared in the Classes unit. > > SResNotFound is a string constant in the unit RTLConsts in Delphi > > XE. I'm not sure where it is in your version of Delphi, but it's > > somewhere in a Delphi unit, I'm sure. I don't have earlier > > versions of Delphi installed. You can search for the text > > "SResNotFound" in files in your Delphi source directory, than add > > that unit to the uses clause. > I found 'SResNotFound' in the delphi 7 source directory under > 'richedit_DRC.rc' No, that is not the correct one. The SResNotFound identifier is a resource string constant, that is: it is declared in a Delphi unit (a pas file) in a section starting with resourcestring Since Delphi 6 most of the constants the RTL units use are in the RTLConsts unit, in older versions there was a unit named consts.pas that contained the constants used by RTL and VCL (there were a few other units with "consts" in the name, dbconsts.pas, for example, if memory serves). So, if you are moving to a post-D6 version you need to add RTLConsts to the Uses clause of the unit in question. -- Peter Below (TeamB) Don't be a vampire (http://slash7.com/pages/vampires), use the newsgroup archives : http://codenewsfast.com http://groups.google.com
![]() |
0 |
![]() |
Peter Below wrote: > Chris Osmond wrote: > > > > > > > > > {code} > > > > > > > > procedure TEncodedResourceStream.Initialize(Instance: THandle; > > > > Name, ResType: PChar; const Key: array of Byte); > > > > > > > > procedure Error; > > > > begin > > > > raise EResNotFound.CreateFmt(SResNotFound, [Name]); > > > > end; > > > > > > > > {code} > > > > > > > EResNotFound is an exception class declared in the Classes unit. > > > SResNotFound is a string constant in the unit RTLConsts in Delphi > > > XE. I'm not sure where it is in your version of Delphi, but it's > > > somewhere in a Delphi unit, I'm sure. I don't have earlier > > > versions of Delphi installed. You can search for the text > > > "SResNotFound" in files in your Delphi source directory, than add > > > that unit to the uses clause. > > > I found 'SResNotFound' in the delphi 7 source directory under > > 'richedit_DRC.rc' > > No, that is not the correct one. The SResNotFound identifier is a > resource string constant, that is: it is declared in a Delphi unit (a > pas file) in a section starting with > > resourcestring > > Since Delphi 6 most of the constants the RTL units use are in the > RTLConsts unit, in older versions there was a unit named consts.pas > that contained the constants used by RTL and VCL (there were a few > other units with "consts" in the name, dbconsts.pas, for example, if > memory serves). > > So, if you are moving to a post-D6 version you need to add RTLConsts to > the Uses clause of the unit in question. Thanks for jumping in, Peter. I wasn't sure when RTLConsts appeared. John
![]() |
0 |
![]() |
Chris Osmond wrote: > > {quote:title=Rudy Velthuis (TeamB) wrote:}{quote} > > Chris Osmond wrote: > > > > > I have found copies of amost every version of delphi ever made and > > > installed them on my pc and attempted to compile this program in > > > question. > > > > Hmmm... They must have cost quite a lot of money, right? Such > > dedication. > > To be honest, all the copies other than my Delphi 7 that I own, were > downloaded cracked versions I found through torrents to try to > compile the program. Well, good that you're honest, but you are aware of the fact that you are posting to the Embarcadero forums, right? Piracy is illegal and Embarcadero don't take this very lightly. IOW, you are not licensed to use any other than the version you own. If it compiles with a newer version, you'll have to buy that. -- Rudy Velthuis "The problem with people who have no vices is that generally you can be pretty sure they're going to have some pretty annoying virtues." -- Elizabeth Taylor
![]() |
0 |
![]() |
> No, that is not the correct one. The SResNotFound identifier is a > resource string constant, that is: it is declared in a Delphi unit (a > pas file) in a section starting with > > resourcestring > > Since Delphi 6 most of the constants the RTL units use are in the > RTLConsts unit, in older versions there was a unit named consts.pas > that contained the constants used by RTL and VCL (there were a few > other units with "consts" in the name, dbconsts.pas, for example, if > memory serves). > > So, if you are moving to a post-D6 version you need to add RTLConsts to > the Uses clause of the unit in question. > > > Ok, so I put in RTLConsts into the Uses clause in two areas and it does not bring up that error it seemed, and went onto a new error in in a .pas file called FileTracker with the error: Undeclared identifier: 'SCannotCreateDir' Again I am assuming another unit that is improperly referenced from the Delphi 3,4 that it was built on running on Delphi 7? By the way, are there a few settings I can "check off" that will turn off this giant list of warnings I get? Also I can not thank you guys and girls enough for the help I have been receiving on this issue. I actually like using Delphi and making little windows programs. Its not only fun, but I wish I could find a good book somewhere to teach myself some of the more advanced parts I can possibly use for my machines I create. Chris > -- > Peter Below (TeamB) > Don't be a vampire (http://slash7.com/pages/vampires), > use the newsgroup archives : > http://codenewsfast.com > http://groups.google.com
![]() |
0 |
![]() |
Chris Osmond wrote: > By the way, are there a few settings I can "check off" that will turn off this giant list of warnings I get? Load your project. From the Menu Select Project > Options Click on the "Compiler Messages" tab Uncheck the following ... Platform Symbol Platform Unit Unsafe Type Unsafe Code Unsafe Typecast (the first 2 are near the top of the list, the other 3 at the bottom). It's worth checking the "default" box if you're using D7, as you'll never want these warnings. Click "OK" to save it. Should be a lot better after that. ... Joe Member of the UK Developers Group
![]() |
0 |
![]() |
> > Well, good that you're honest, but you are aware of the fact that you > are posting to the Embarcadero forums, right? Piracy is illegal and > Embarcadero don't take this very lightly. > > IOW, you are not licensed to use any other than the version you own. If > it compiles with a newer version, you'll have to buy that. > -- > Rudy Velthuis Hey Rudy I own Delphi 7 and am fully aware of the piracy laws. If I knew that it would compile with a new version, it would be purchased just like I bought 7. But to find out if it will work, wouldn't I need to test it? If there were trial versions of each version I would have gone that route. Chris
![]() |
0 |
![]() |
Chris Osmond wrote: > Also I can not thank you guys and girls enough for the help I have > been receiving on this issue. I actually like using Delphi and making > little windows programs. Welcome to the club! > I wish I could find a > good book somewhere to teach myself some of the more advanced parts I > can possibly use for my machines I create. Marco Cantu's books are on-line. I learned a lot from them when they were "real books", a good number of years ago. :-) John
![]() |
0 |
![]() |
Chris Osmond wrote: > Ok, so I put in RTLConsts into the Uses clause in two areas and it > does not bring up that error it seemed, and went onto a new error in > in a .pas file called FileTracker with the error: Undeclared > identifier: 'SCannotCreateDir' Use the Find in Files function from the IDE Search menu. Copy the identifier not found to the "text to find" control, check "Whole words only" under Options, leave "Case sensitive" unchecked, select "search in directories" in the "Where" group. Click the Browse button and navigate to the Source folder under the Delphi7 root (on my system that happens to be C:\Borland\Delphi7\Source, but it will be somewhere under Program files if you accepted the standard folder names in the installer). Check the "include subdirectories" box. Click OK and pour a coffee. Add milk and sugar as necessary, stirr well, take a sip. The search should be done by now and the result pane (docked to the editor bottom by default) will show you that the identifier is declared in the SysConsts unit. So that is the one to add to the Uses clause in FileTracker.pas. > Also I can not thank you guys and girls enough for the help I have > been receiving on this issue. I actually like using Delphi and making > little windows programs. Its not only fun, but I wish I could find a > good book somewhere to teach myself some of the more advanced parts I > can possibly use for my machines I create. http://www.marcocantu.com/md7/ would be good. It is out of print but you may be able to find a used copy somewhere. Amazon lists 4 offers at the moment. -- Peter Below (TeamB) Don't be a vampire (http://slash7.com/pages/vampires), use the newsgroup archives : http://codenewsfast.com http://groups.google.com
![]() |
0 |
![]() |
Chris Osmond wrote: > > > > Well, good that you're honest, but you are aware of the fact that > > you are posting to the Embarcadero forums, right? Piracy is illegal > > and Embarcadero don't take this very lightly. > > > > IOW, you are not licensed to use any other than the version you > > own. If it compiles with a newer version, you'll have to buy that. > Hey Rudy > > I own Delphi 7 and am fully aware of the piracy laws. If I knew that > it would compile with a new version, it would be purchased just like > I bought 7. But to find out if it will work, wouldn't I need to test > it? If there were trial versions of each version I would have gone > that route. There are still trial versions of the last 4 or 5 versions. You could have gone that route. You could have, well, asked here. -- Rudy Velthuis "Look at you in war. There has never been a just one, never an honorable one, on the part of the instigator of the war." -- Mark Twain
![]() |
0 |
![]() |