Can not get "ReplaceStr" proc address

Examples step by step how to make your own automated strategy or user indicator
Message
Author
numbercruncher
Posts: 2
Joined: Sun Aug 09, 2009 4:08 pm

Can not get "ReplaceStr" proc address

#1 Postby numbercruncher » Sun Aug 09, 2009 4:19 pm

Congratulations on an awesome application.

I am trying to create an MA indicator using C++.
It compiles ok. I've dropped the dll in the indicators directory but it is not available to FT.
The LOGS directory has a file - ForexTester.log and I see this line in it -
.2009.08.09 22:01:30 (TDllIndicator.create) Can not load indicator MyMA.dll, have error: Can not get "ReplaceStr" proc address

Looks like I've missed something out. Any help or ideas greatly appreciated.

User avatar
Terranin
Site Admin
Posts: 833
Joined: Sat Oct 21, 2006 4:39 pm

Re: Can not get "ReplaceStr" proc address

#2 Postby Terranin » Sun Aug 09, 2009 10:35 pm

numbercruncher wrote:Congratulations on an awesome application.

I am trying to create an MA indicator using C++.
It compiles ok. I've dropped the dll in the indicators directory but it is not available to FT.
The LOGS directory has a file - ForexTester.log and I see this line in it -
.2009.08.09 22:01:30 (TDllIndicator.create) Can not load indicator MyMA.dll, have error: Can not get "ReplaceStr" proc address

Looks like I've missed something out. Any help or ideas greatly appreciated.


You should make some procedures visible for Forex Tester defining them in EXPORTS section including ReplaceStr procedure. For C++ (I think you use this language) you need to attach a file like this to a project (this is for strategy) see lesson 1:

LIBRARY DemoStrategy

EXPORTS InitStrategy
DoneStrategy
ResetStrategy
GetSingleTick
ReplaceStr
IntrfProcsRec
Hasta la vista
Mike

numbercruncher
Posts: 2
Joined: Sun Aug 09, 2009 4:08 pm

#3 Postby numbercruncher » Mon Aug 10, 2009 3:54 pm

OK, now it works - my def file was a bit thin.

Great now I'm converting indicators - this is really cool.

Thank you very much for taking the time and making the effort to write this and make it available. This could change lives.

:D

b4gt
Posts: 23
Joined: Mon Jul 12, 2010 12:41 pm

#4 Postby b4gt » Mon Jul 12, 2010 12:58 pm

Forgive me for resurrecting this post but I have the same problem trying to install an indicator that I made. Following the example in the Ishimoku.def file my def file contains

Code: Select all

LIBRARY ROUNDNR

EXPORTS Init
   Calculate
   ReplaceStr
   IntrfProcsRec


The only functions I have in my cpp file so far are Init and Calculate.
When I try to install that .dll file I get the same message as numbercruncher

I have disabled the incremental linking and I have added the .def file in Project->Properties->Configuration Properties->Linker->Input->Module Definition File

I am using Forex Tester 2.5 and the project is made with Microsoft Visual C++ 2010 Express. Any help please?

b4gt
Posts: 23
Joined: Mon Jul 12, 2010 12:41 pm

#5 Postby b4gt » Mon Jul 12, 2010 2:03 pm

Nevermind. For some PEBCAC reason the .def file that should be edited was not the same that I edited. So no game. Everything works fine now


Return to “Programming lessons”

Who is online

Users browsing this forum: No registered users and 18 guests