Delphi thick client to web application - delphi

I am currently using Delphi 5 and planning to migrate application to latest version(XE3) or to other technology. Main purpose of migration is dont want thick client. In currrent scenario application(exe) gets downloaded to the users local folder and then it runs rom local. Main purpose is dont want to download the application to users machine. .
Wanted to stick with Delphi if that downloading limitation resolved. Is there web solution? or way to access the application from common point without downloading to users machine.
Thanks for the help and suggestions.
Note: There are lots of users who uses these application.

Depending on the type of application you could add web layer around the core functionality of your application.
If you create something like a SOAP or REST interface, you can write a web client in any language that suits. Could be Delphi, or some more web-oriented language like PHP or ASP.Net.
By having a web interface your users can access from any platform.
On the other hand, if your current application is not layered properly, and you've got a lot of code mixed between the GUI and your model, this could be difficult. It would mean rewriting a lot of code, or just accept the fact that your users need Windows, and an .exe file.
At least by using Delphi, your users don't need to download a huge framework that requires administrator privileges to install.
Anyway, you should provide some more information about what you already have, and what type of application it is, how complicated it is, etc.

If you are planning a move to Java Enterprise Edition (Java EE), accessing existing Delphi logic can be achieved using two communication models, using existing commercial and open source solutions:
for synchronous (request/response) style communication between Delphi and Java, there are lightweight web frameworks for Delphi (I wrote this one recently) and open source JSON/XML libraries which can be used for data exchange. This allows the Java application server to access Delphi logic over HTTP
for asynchronous communication, I wrote (commercial) message broker client libraries for Delphi and Free Pascal, they can be used with the Java Message Service (JMS) servers in the JBoss and the GlassFish application server - JBoss and GlassFish already include a messaging solution (HornetQ and Open MQ), as a mandatory part of the full Java EE profile
I also have written some step by step tutorials for JBoss and GlassFish Delphi integration:
Delphi Integration with JBoss Application Server 5
Delphi Integration with the GlassFish v3 Application Server Part 1 - Sending Messages
Delphi Integration with the GlassFish v3 Application Server Part 2 - Receiving Messages

Related

Does ASP. NET core still requires hosting with. NET support

I plan to develop website in ASP. NET core. In past i wrote few ASP. NET website but as far as i remember it requures to buy special hosting which needs to have. NET installed. I would like to know whether nowdays is it enough to have cheap hosting without. NET support to pubslih my ASP. NET core website or i still need to buy hosting which has. NET support?
ASP.NET Core can be published to either use an installed .NET Core runtime or self-contained, in which the required parts of the framework are actually published along with the app. In .NET Core 3.0, you can actually publish a .NET Core app as an entirely self-contained single executable file.
In either to publish self-contained (whether in a single executable or not), though, you must target a particular runtime environment when you publish (i.e. Win x64, Linux x64, etc.) You can then only put the app in that actual environment, i.e. if you publish for Windows, you can't deploy that to a Linux box. However, you could simply re-publish for Linux instead.
If you target an installed runtime, similar to how .NET Framework works, then you can publish once and deploy anywhere, assuming the destination has the .NET Core runtime installed.
Long and short, you are not locked into any one particular way of deploying. If you want a framework installation, you can do that. If you want self-contained, you can do that as well.
That said, you should still avoid shared hosting. They usually do not support .NET Core at all or don't keep up with deploying new versions. Additionally, deploying self-contained is generally going to be disallowed to prevent users uploading rogue things. You can get a VPS all to yourself for like $5/mo, so there's really no value proposition to shared hosting nowadays, anyhow.

Convert .doc/.docx file to .htm in server, but no Microsoft Office Installed in server

Need to convert .doc/.docx file to .htm file to display on webpage in my MVC web application. This is working in my local system. There is no Microsoft Office Installed in the server and its restricted to install this in the server.
Is there a round-about solution for this? Can I convert .doc file to .htm file without having MS Office installed.
Any suggestions.. Really stuck with this for the past 4 days.. Cant find any solutions.
Thanks
Yes, you can. Take a look at the third-party components (for example, Aspose).
Also you may consider using the Open XML SDK. See Welcome to the Open XML SDK 2.5 for Office for more information. But it doesn't support binary files such doc etc.
Be aware, Microsoft does not currently recommend, and does not support, Automation of Microsoft Office applications from any unattended, non-interactive client application or component (including ASP, ASP.NET, DCOM, and NT Services), because Office may exhibit unstable behavior and/or deadlock when Office is run in this environment.
If you are building a solution that runs in a server-side context, you should try to use components that have been made safe for unattended execution. Or, you should try to find alternatives that allow at least part of the code to run client-side. If you use an Office application from a server-side solution, the application will lack many of the necessary capabilities to run successfully. Additionally, you will be taking risks with the stability of your overall solution.
You can read more about this in the Considerations for server-side Automation of Office article.

I need to deploy source ASP.NET MVC code on Azure websites, and for it to run

This may be a terribly simple question, but....
I am using MVC3, Razor, C#, ASP.NET4.5/SQL Server 2008 and deploying to Azure Websites & SQL Azure.
I need to copy all of my source code, without compilation, from my web application ie model source, class libraries and views. All additional projects such as Entity Framework DAL projects will remain as a DLL. However I do not wish to have a web application DLL since I need to edit C# code in situ, and have the site run using this code, no doubt using the JIT compiler.
The main reason is because I am doing some integration work and the 3rd party site sends a return url back, and "Localhost" is not very accessible to the outside world, so wish to use my Azure website instead.
So can I copy my web application code as source, and if so is it a matter of copying all the C# files up and removing the web application DLL?
Thanks in advance.
EDIT
Further thoughts. Azure Websites provides a container for the Worker process to operate which hosts the Application DLL which is P-Code which is then dynamically compiled to native code. So I am not sure if one can start with a source C# file like one can with a Razor View.
EDIT2
Or do I need to make the changes on my Local machine and keep republishing to Azure Websites to test the integration? A little long winded...
MVC Sites must be Web Applications, they cannot be on the fly compiled. Sorry, there is no way around this. You must compile your code into a DLL for it to run if you want to use MVC.
The reasons for this are many, but a big one is that the "on the fly" compilation model used by ASP.NET Web Site projects does not use namespaces, and namespaces are very important to the operation of MVC.
Another issue is that MVC depends heavily on static assembly references, which is also not the case in Web Site projects.
In general, ASP.NET Web Site projects are poorly supported, have a lot of issues that make them unsuitable for larger projects, and even more unsuitable for use with more advanced frameworks.

ServiceStack WSDL error. Endpoint is not compatible with Windows Store apps. Skipping...

Working on a Windows 8 (metro style) application, and want to reference a service hosted by ServiceStack from it. Since I cannot use the C# client objects provided by ServiceStack (can't reference the DLL from a Windows 8 project) I figured I'd have to fall back to adding a service reference using svcutil or from within VS 2012. When I do this, I get the following error:
Warning 5 Custom tool warning: Endpoint 'WSHttpBinding_ISyncReply' at address 'http://localhost/ServiceStackRD/soap12' is not compatible with Windows Store apps. Skipping... C:\Development\GridPresenter\GridPresenter\Service References\ServiceReference2\Reference.svcmap 1 1 GridPresenter
Does anybody know what makes an endpoint "not compatible with Windows Store apps?" If so, how do I tell ServiceStack to modify the endpoint definition to make it play nice with Windows 8 apps? Thank you.
SOAP and WSDLs are an ugly solution on any new platform, you have to get too many moving parts right for it to work properly.
The path of least resistance would be to use a C# HTTP Client that supports a Windows 8 Metro app and just parse the JSON returned from ServiceStack's JSON services. Here's an example of parsing GitHub's 3rd party API using these WebRequest extensions in ServiceStack.Text.
The community has yet to contribute a Windows 8/Metro App build of ServiceStack.Text so you will likely have to use another JSON serializer that does support it.

What is the "current" Delphi web app framework?

I'm looking at Delphi web server apps, and the first thing I notice when I go into the New Items dialog is that there are several different frameworks.
WebBroker looks the nicest from a conceptual standpoint, but in the documentation it looks like its DB and session-management code is tied to the BDE, which makes it somewhat less than useful today.
WebSnap looks very similar, but the documentation says it's deprecated and IW ("VCL for the Web") should be used instead.
So I look at IW, and I can't make heads or tails of how it's supposed to work. The sample code is full of stuff that looks like it belongs in a desktop app, like clicking a button to fire an event handler to change the caption of a form element. (Wouldn't that have to be done client-side in JavaScript if we're creating a webpage?)
So what's the current standard framework for building a web server in Delphi?
While there are several commercial options available for writing web apps with Delphi, in my opinion Delphi no longer ships with a modern web development solution included as part of the package.
If I had to give an answer to your question though I would say that the current out of the box Delphi web framework is WebBroker. WebBroker is the only web framework included with Delphi that isn't deprecated or restricted in its functionality.
WebBroker was introduced perhaps as far back as Delphi 4. It's a good honest work horse but it hasn't really been improved much since it was first introduced. It leaves you to do most of the heavy lifting but it also doesn't get in your way. WebSnap and IntraWeb were built using WebBroker as their foundation which gives you idea of the level of services it provides.
A full version of IntraWeb has been bundled with Delphi Enterprise for many years but as of Delphi XE it now has several limitations (no SSL, no ISAPI deployment, 20 minute idle timeout) that will very likely mean you'll need to buy a license from AtoZed to use it seriously.
The version of IntraWeb bundled with Delphi Pro has always been far too limited to be considered anything other than an evaluation version.
Old question but still deserves an up-to-date answer.
Current 'settled in' solutions are:
IntraWeb:
https://www.atozed.com/intraweb/
uniGUI:
http://unigui.com/
Introduction
uniGUI Web Application Framework extends Web application development experience to a new dimension. uniGUI enables Delphi developers to create, design and debug web applications in IDE using a unique set of visual components. Each component is designed to provide same functionality of its counterpart visual component in Delphi VCL. This provides a very comfortable development environment very close to native VCL application development with an easy learning curve. uniGUI Web applications can be deployed to a server using one of the available deployment options such as Windows Service, Standalone Server or ISAPI Module.
Product Highlights:
Based on industry's most advanced JavaScript library Sencha Ext JS.
Includes OEM license for Sencha Ext JS. (Please see licensing for details).
A unique platform to create stateful web applications.
Complete IDE support for creating projects, designing forms, frames and handling data modules.
Advanced support for scripting client side JavaScript events.
Library core is fully optimized to achieve highest level of scalability.
Including advanced Stress Test Tool utility.
Comes with various deployment options: ISAPI Module, Standalone Server and Windows Service.
Supported Delphi versions: Turbo Delphi Pro, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi XE, XE2, XE3, XE4, X5, XE6, XE7, XE8, Delphi 10 Seattle, 10.1 Berlin, 10.2.3 Tokyo and 10.3.3 Rio (Win32 & Win64 platforms). (Linux support is in the roadmap)
C++ Builder supported.
Supported Browsers: IE 9+, Microsoft Edge, FireFox, Chrome, Safari and Opera
New state-of-the-art uniGUI HyperServer technology.
TMS WebCore:
https://www.tmssoftware.com/site/tmswebcore.asp
RADical Web
Modern SPA web application model
Pure HTML5/CSS3/Javascript based applications
Standard component framework for common UI controls and access to browser features
Debugging in Pascal code via the browser
Backed by a solid & proven Delphi Pascal to Javascript compiler that was years in development
Reuse skills and components Component based RAD development integrated
in the Delphi IDE A truly revolutionary & innovative TMS FNC component
framework that is now also web enabled, allowing to create UI controls
that can be used on VCL, FMX, LCL and WEB! Open to consume other
existing Javascript frameworks & libraries Open to use HTML/CSS for
design Open to use other jQuery controls or even other Javascript
frameworks Offers Pascal class wrappers for jQuery controls from the
jQWidgets library Easy interfacing to REST cloud services including to
TMS XData for database
Easy Deployment Application consists of HTML & Javascript files only
that can be easily deployed on any light or heavyweight webservers Use
any existing load-balancing software and/or techniques for highest
performance Small and convenient debug webserver is included for fast
RAD development
http://docwiki.embarcadero.com/RADStudio/en/DataSnap_Overview_and_Architecture
DataSnap has been there for a long time, and the latest releases is DCOM-free. You can utilize it to build up server side piece (S in both C/S and B/S). Its current role is almost like WCF in .NET world.
Then if you are building a web site front end, you can use IW. But DataSnap makes it even possible to build up front end using PHP or other web technologies.
https://github.com/relativ/pascalweb
PascalWeb use pascalscript compiler , you can create web app, like php or python

Resources