Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 288
  • Last Modified:

Getting a Windows (Delphi) program to run on a website...

Hi, I've written a stock analysis software and instead of selling individual copies outright (as most people do), I would like to have it 'pay-per-use' over a website. It's a Windows program written in Delphi, that basically runs one big 'batch job' on the data of 3500 stocks and spits out recommendations. Ideally I'd like to have my software sitting on a server somewhere, the customer comes to my website, makes a small payment of a few dollars to Paypal (or some other payment processor), then gets access to my program over the web so he can run his one-time batch job analysis. Then when he's done, he logs out (or his allotted time expires and he gets logged out). And that's it.

So basically my first hurdle is - how can I run my Delphi program through a website? Maybe it's not even possible? Then once I can solve that, would look for a way to handle the "pay-per-use" side of it.

Thanks!
    Shawn

0
shawn226
Asked:
shawn226
  • 6
  • 3
  • 2
  • +3
1 Solution
 
ThommyCommented:
I suggest using a web service to make your application accessible over the internet.

Building a Web Service from Scratch with Delphi
http://www.devarticles.com/c/a/Delphi-Kylix/Building-a-Web-Service-from-Scratch-with-Delphi/

You can either implement your functionality directly into the web service server application or make a call to your Windows program...
0
 
shawn226Author Commented:
Thanks Thommy, but I haven't a clue on how to do this or where to start. Briefly looking at that link and I was totally lost.
   Do I just basically take my existing Delphi program and add a few commands to it? Or do I have to totally write my program over again in a different programming language?

Shawn
0
 
jimyXCommented:
>   "how can I run my Delphi program through a website?"
Here comes the wonderful world of the Intraweb:
http://www.atozed.com/intraweb/index.en.aspx

For simple example:
http://www.swissdelphicenter.ch/en/showarticle.php?id=6

And you can find many examples & demos on the web about working with IntraWeb.
This link will get you started:
http://delphi.about.com/od/intraweb/IntraWeb_RAD_Web_Delphi_development.htm

And let's not forget Dr.bob's:
http://www.drbob42.com/examines/examin48.htm
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
ThommyCommented:
There is no getting around to familiarize with web development, if you want to make your application available over the internet!!!

You do not have to use a different programming language, but you have to rewrite your program as a web application, which meets the demands of the internet.

jimyX has provided a good collection of links for starting your career as a Delphi web developer...
0
 
Geert GOracle dbaCommented:
i would consider what your app actually does first,
before even thinking about the web

from what you say: a stock analysis program

from what i know about something like that:
1: start program
2: get access to the database
3: get the data
4: run tool for analysis
5: create report

now let's get into detail about each item
1:
you control when you start this program
you will have to automate each step if you want this done over the web
probably also provide 24/7 support as the web is wordwide

2:
99% of your customers will not want something from on the web have access to the database
especially if they don't know what it's gonna do
which databases will you support ?
oracle, interbase, firebird, dbase, paradox, mssql, banyan vines, teradata, msaccess, ... etc

3:
again 99% will not trust anything from the web
> alternative: upload all the data into your site
> this means that you will have to provide the necessary space to store their data
> i hope you are very succesfull, and that you provide enough space for at least 10 customers a day
> also keep in mind that once they paid, they will want you to maintain a history for them to access every 6 or 12 months

4:
you control this too, the more customers you have, the more processor power you'll need :)

5:
pdf reports or even html reports are easy to make

i believe your most crucial point:
getting to the data
* having people trust you and let you in
or
* having them upload the data to you

if you can get them to upload the data, you wouldn't need to change your app at all
just build a framework around it to get the data and deliver the report back out
if i were you, i would try to get this to work first
0
 
Ephraim WangoyaCommented:
Nice one Geert

On top of that you can always change bits of your applications to DLL's so you dont have to write a whole new application for the WEB, just use existing (already tested) code via the DLLs
0
 
Geert GOracle dbaCommented:
Nice one ?
just pointing out some possible problems
like clients having a few TerraByte of data to analyse
0
 
Ephraim WangoyaCommented:
So I agree with you
0
 
shawn226Author Commented:
Thanks everybody for the replies. Looks like I have quite the magical journey ahead of me  ;-)

But doing some googling I found this link:

http://www.delphipages.com/forum/showthread.php?t=191067

... it seems to address exactly what I need in a much much simpler way (making my Delphi app an ActiveX object?). Is this approach okay too? Would this work?

In response to Geert's suggestions, it's best I give a little more detail on my app. The running of it is pretty straightforward and it essentially accepts a few input fields from the user, he then clicks GO and my app reads through flat ascii files (no database) of the daily data of around 3600 stocks (one ascii file per stock). Total size of all data files together would be around 250 - 300 megs. It does its number crunching (around 10 - 12 minutes total) and then presents a list of candidate stocks right on the screen in a TListView box. No pdf output, no pdf printouts, nothing like that. The User can sort and rank the results in the TListView by clicking different columns - if he finds a trade suggestion he likes, he can simply jot it down.
    This all raises another important issue as well - if my app becomes halfway popular, it's possible I could have a lot of customers all arriving at my website wanting to run it simultaneously. Would this cause problems and require a special kind of web server?

Thanks to all
    Shawn
0
 
shawn226Author Commented:
Hi guys... are you still with me? Any thoughts on my last post?

Thanks
   Shawn
0
 
jimyXCommented:
Does your application require interactive communication with database?
When I read your comment (#35185963) I understand that you have database. Even if it's a text file and one-way reading, still it requires retrieving data. Can the ActiveX do that? I do not think so.

> "the customer comes to my website, makes a small payment"

You can have Customers Database and assign user/password to every customer whenever a payment is made. The payee will be extended the right to access your application for a specific period of time, let's say X hours from the time of the first log in, or it can be prorated to a maximum of three sessions every session is a specific period of time, or whatever the package that you offer is. So whenever a customer logs, in the time will be captured and counter will start to determine when the session ends.

You have two options here, use web application (IntraWeb) or web Site (php or similar).
0
 
shawn226Author Commented:
Thanks for the reply JimyX. Yes my app has to read ascii data files, so in that sense, I guess that is the database. And an ocx cannot do this?? I really have no idea how ocx's work, I hardly know what they are.

You say "You have two options here, use web application (IntraWeb) or web Site (php or similar)." How would I accomplish this with the "web site" option? I would have to re-write my whole app in Java or something?

(I realize I've asked kind of a 2-part question: how to make my Windows app run on a website, and also how to set up a pay-per-use system for it. I think in this thread I better just stick to the topic of how to get my app to run over a website. Once I've got that working,then I can worry about how to set up a "pay-per-use" system for it).

Thanks
   Shawn
0
 
Ephraim WangoyaCommented:

I don't know how an ActiveX object helps you in this case. Your processing is done on your server where you have your files so whats the need for ActiveX

All this stuff is going to be done in the code behind. Send the desired information to your dll in the code behind, let it crunch the numbers then spit out XML which you will bind to your datagrid
0
 
sbrvarCommented:
Does your application have a form? Or can it just accept some parameters and run away with it and return a result?

ActiveX could be used, but it would only run on IE browsers, not on others. On top of that, users would have to allow unsigned activex controls to run on their computer (which mostly they don't), so there'd be a lot of issues.

Another option is, if no form is required, CGI (console) program, run on web server.
Yet another, to make regular ISAPI (dll) to run on web server.

You really need to provide us with more information about your Delphi application :)

Take care,
Sabina
0
 
shawn226Author Commented:
Hi Sabina... you wrote:

>Does your application have a form? Or can it just accept some parameters and run away with it and >return a result?


Yes, I do use a GUI form. It's a very simple program - the user enters some parameters in the form, clicks GO and the program then crunches data for 3600 stocks. Then it displays the results back on the form in a TListView box. It does not write to output files.


>ActiveX could be used, but it would only run on IE browsers, not on others. On top of that, users >would have to allow unsigned activex controls to run on their computer (which mostly they don't), >so there'd be a lot of issues.


I guess that wouldn't be very handy then if Firefox users (or others) couldn't use it.


>Another option is, if no form is required, CGI (console) program, run on web server.
>Yet another, to make regular ISAPI (dll) to run on web server.


What is ISAPI?


Thanks
    Shawn

0
 
shawn226Author Commented:
Thanks, this got me on the right track, and I have continued to follow up on how to implement Intraweb via the discussion forum at www.atozed.com.

Thanks
    Shawn
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

  • 6
  • 3
  • 2
  • +3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now