Print Thread
Page 1 of 2 1 2
Console App in Kylix
#6125 02/27/04 07:06 PM
Joined: Feb 2004
Posts: 7
G
Garby Offline OP
Member
OP Offline
Member
G
Joined: Feb 2004
Posts: 7
Hi there,

i want to develop a console application in Kylix 3. Whenever i want to run the executable file in a console there appears this exception: undefined symbol: initPAnsiStrings.
This is only if i include the units Oracle, OracleDate aso.

If i run the program in the IDE it works fine.

Is there no possibility to run your Components in a console program or is the problem on my linux system?

thanks Garby

Re: Console App in Kylix
#6126 02/27/04 08:28 PM
Joined: Aug 1999
Posts: 22,208
Member
Offline
Member
Joined: Aug 1999
Posts: 22,208
I performed a little Google search, and found the following page with possible solutions:

http://forums.belution.com/en/kylix/000/000/25s.shtml

I hope this helps.


Marco Kalter
Allround Automations
Re: Console App in Kylix
#6127 03/01/04 01:44 PM
Joined: Feb 2004
Posts: 7
G
Garby Offline OP
Member
OP Offline
Member
G
Joined: Feb 2004
Posts: 7
Ok, the Connection works in the IDE.
If i want to run the ConsoleProgram in a Terminal Window, the exception "could not locate oci dll" appears. In the console i get this message: cannot connect to X server.

The ORACLE_HOME and ORACLE_OWNER Variables were set. ORACLE_HOME/bin is added to the PATH Variable.

Thanks for helping.

Garby

Re: Console App in Kylix
#6128 03/01/04 06:42 PM
Joined: Sep 2001
Posts: 22
L
ltd Offline
Member
Offline
Member
L
Joined: Sep 2001
Posts: 22
I had to add the Oracle library path to the
LD_LIBRARY_PATH= Variable to get console applications to work with oracle.

Lars

Re: Console App in Kylix
#6129 03/01/04 07:12 PM
Joined: Feb 2004
Posts: 7
G
Garby Offline OP
Member
OP Offline
Member
G
Joined: Feb 2004
Posts: 7
This dosen

Re: Console App in Kylix
#6130 03/01/04 07:56 PM
Joined: Sep 2001
Posts: 22
L
ltd Offline
Member
Offline
Member
L
Joined: Sep 2001
Posts: 22
I have checked my variables again and the only additional thing is that i have the /home/oracle/lib in the path also.

By the way i think that you made only a typing error with "LD_LIBRARY_PATCH" there is an extra "C" in what you posted here.

Yes Kylix needs some Patches but it is still a "PATH". wink

Lars

Re: Console App in Kylix
#6131 03/02/04 01:18 PM
Joined: Feb 2004
Posts: 7
G
Garby Offline OP
Member
OP Offline
Member
G
Joined: Feb 2004
Posts: 7
It works now in the Terminal Window, but in the console appears the message cannot connect to X server.

In the uses section there are 3 units: SysUtils, Oracle, OracleData;

any Ideas?

thanks
Garby

Re: Console App in Kylix
#6132 03/02/04 10:49 PM
Joined: Aug 1999
Posts: 22,208
Member
Offline
Member
Joined: Aug 1999
Posts: 22,208
Is the DISPLAY environment variable set correctly?


Marco Kalter
Allround Automations
Re: Console App in Kylix
#6133 03/03/04 11:50 AM
Joined: Feb 2004
Posts: 7
G
Garby Offline OP
Member
OP Offline
Member
G
Joined: Feb 2004
Posts: 7
The DISPLAY Variable is set to ":0"

thanks
Garby

Re: Console App in Kylix
#6134 03/05/04 05:40 PM
Joined: Feb 2004
Posts: 7
G
Garby Offline OP
Member
OP Offline
Member
G
Joined: Feb 2004
Posts: 7
Ok all works fine now (even in the console) except one thing.
The console program runs only when a X Server is started. Is this the standard behavior or is somthing wrong with my system?

thanks
Garby

Re: Console App in Kylix
#6135 03/05/04 10:23 PM
Joined: Aug 1999
Posts: 22,208
Member
Offline
Member
Joined: Aug 1999
Posts: 22,208
I'm not sure if this is standard behavior.

To remove all dependencies with X, you would need to recompile the Direct Oracle Access package with the NONVISUAL compiler directive set. This requires the sourcecode though.


Marco Kalter
Allround Automations
Re: Console App in Kylix
#6136 03/10/04 02:17 PM
Joined: Feb 2004
Posts: 7
G
Garby Offline OP
Member
OP Offline
Member
G
Joined: Feb 2004
Posts: 7
Hi,
it is not possible for me to compile the Package.
there are too many ErrorMessages.

I am Using DOA 4.0.3.0

Garby

Re: Console App in Kylix
#6137 03/10/04 09:47 PM
Joined: Aug 1999
Posts: 22,208
Member
Offline
Member
Joined: Aug 1999
Posts: 22,208
Such as?


Marco Kalter
Allround Automations
Re: Console App in Kylix
#6138 03/18/04 04:18 AM
Joined: Mar 2004
Posts: 6
J
Member
Offline
Member
J
Joined: Mar 2004
Posts: 6
Hi,

The errors I received when trying to recompile using the NONVISUAL conditional define were:-
- [Error] OracleNavigator.pas(577): Incompatible types: 'OracleVisual.TMsgDlgBtn' and 'QDialogs.TMsgDlgBtn'
- [Error] OracleNavigator.pas(625): Duplicate case label

Thanks

Jeff

Re: Console App in Kylix
#6139 03/18/04 04:23 AM
Joined: Mar 2004
Posts: 6
J
Member
Offline
Member
J
Joined: Mar 2004
Posts: 6
I am using DOA 4.0.0.0

Jeff

Re: Console App in Kylix
#6140 03/18/04 06:28 AM
Joined: Mar 2004
Posts: 6
J
Member
Offline
Member
J
Joined: Mar 2004
Posts: 6
I have just downloaded v4.0.3 and I get the same errors as above when compiling with Kylix3.

Jeff

Re: Console App in Kylix
#6141 03/18/04 10:58 PM
Joined: Aug 1999
Posts: 22,208
Member
Offline
Member
Joined: Aug 1999
Posts: 22,208
OracleNavigator.pas should not be compiled. It is not referenced in any of the other Direct Oracle Access unit, and should not be referenced in your application either.

I just noticed that you tried to compile the Direct Oracle Access package. You should not do so. The package should stay as it is, NONVISUAL should be defined in your project, and the Direct Oracle Access source files should be included in the search path of the project.


Marco Kalter
Allround Automations
Re: Console App in Kylix
#6142 03/22/04 03:37 AM
Joined: Mar 2004
Posts: 6
J
Member
Offline
Member
J
Joined: Mar 2004
Posts: 6
You're dead right, I was trying to recompile the Direct Oracle Access package. It all makes sense now.

I have now put NONVISUAL as a conditional define in my project and included the oracle source dir in my search path and everything works fine now.

Thanks

Jeff

Page 1 of 2 1 2

Moderated by  support 

Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.4
(Release build 20200307)
Responsive Width:

PHP: 7.1.33 Page Time: 0.034s Queries: 14 (0.011s) Memory: 2.5932 MB (Peak: 3.0395 MB) Data Comp: Off Server Time: 2024-05-03 22:43:03 UTC
Valid HTML 5 and Valid CSS