×
The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.
Hi Mike
You can use embedded SQL to calculate the formula quite simply. You can
find an example of how to do this at:
http://www.astradyne-uk.com/code/index.php?id=4c8ad8fbd1
All the best
Jonathan
-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[
mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of eftimios pantzopoulos
Sent: 03 May 2007 11:24
To: midrange-l@xxxxxxxxxxxx
Subject: Executing a dynamic formula
I was wondering if anyone has solved this type of problem:
I work for a large leasing company and the business has been asking about
the possibility of creating functions and running them dynamically. In other
words, a user would be able to create a string in a reference table such as
result = (amount/term)* interest rate and then have that formula run, with
values substituted at execution time.
They may then decide to tweak the formula next month to result =
(amount/term)* interest rate + 100.00 so tht it runs without any coding
changes. In other words, a dynamic EVAL.
I think I could do it with QSHELL by placing the formula in a QSHELL script
dynaically and then executing the script to derive the result but it's not
very elegant.
I've heard that VB has a function which accepts the formula as a string and
returns a result, but I haven't been able to find it.
Thanks,
Mike Pantzopoulos
As an Amazon Associate we earn from qualifying purchases.