Good Delphi Prism online resources - delphi

A Google search on "delphi prism", "delphi prism resources" or "delphi prism code snippets" reveal almost no good sites at all are there any good programming site(s) with some good amount of code snippets and tutorials on Delphi Prism?
Thanks in advance!

#omair, you have you have basically five ways to obtain information about Delphi Prism
1) The official Info
Prism Wiki
Developing for Mono with Delphi Prism
2) Using the Blogs
Introduction to Language Integrated Query with Delphi Prism: Part 1
Introduction to Language Integrated Query with Delphi Prism, Part 2
Using LINQ to Objetcs in Delphi Prism
Introduction to Delphi Prism (CodeProject)
Delphi Prism and the Cirrus Framework (#jamiei blog)
Dynamically compiling code with Delphi Prism (#jamiei blog)
Dynamically generating code with Delphi Prism (#jamiei blog)
Delphi Prism and the Microsoft Rx Framework (#jamiei blog)
3) as #jamiei suggest Translate the C# or VB .Net Code to Delphi Prism is not difficult, you can use the C# to Oxygene Tool or you can do it manually.
4) the books
Delphi Prism Development Essentials Dr. Bob
Delphi Prism Manual de referecnia (spanish)
Delphi for .NET Developer's Guide (this book is about delphi .Net but is very useful)
.NET 2.0 for Delphi Programmers (very nice book, cover intermediate and advanced topics about .Net under a Delphi Programmer Perspective)
5) Ask in StackOverflow

Agreed, along with the Prism Documentation Wiki it's worth noting that the best resources for .NET code are nearly all composed of C# code snippet sites.
The RemObjects team have built a C# to Oxygene tool and have even integrated it into the IDE so you can copy C# code from sites such as CodeProject and the MSDN documentation and paste it directly as Delphi Prism code into the IDE.

Best place I find is http://prismwiki.codegear.com/en/Main_Page
There's also the various CodeGear and RemObjects newsgroups.

Prism was just a rebranding of the Oxygene compiler. If you search for Oxygene then you are more likely to find resources.

Related

Is it possible to use Delphi XE2 to develop Windows CE Applications?

I have to develop an application to run on Windows CE accessing a remote Firebird database.
I would like to use Delphi to do so.
Is it possible?
Native Delphi only works with x86 compatible processors and Win32/Win64 or MacOS 10 API.
Ken White already pointed to you Delphi Prism, however if you would purchase it, instead of re-marked tool, you'd perhaps purchase the original product, i heard it comes with multiple platforms support instead of one. RemObjects Oxygene is the original product, part of which is re-sold as Prism.
Another option would be using Lazarus (vanilla or CodeTyphon distro). Its LCL library mimics VCL in many respects and FPC compiler mimics Delphi language (and some other Pascal dialects as well).
http://www.pilotlogic.com/codetyphon/help/index.html?cross_build_for_windows_mobile.htm
http://wiki.freepascal.org/Windows_CE_Interface
http://www.lazarus.freepascal.org/index.php?topic=8175.0
No, it isn't. Delphi XE2 does apps for Win32/64, OS X, (and with the help of FreePascal, iOS), but not for CE.
You can probably use Delphi Prism to do so. There is a separate delphi-prism tag for that here at SO.
In fact, you may be able to use the Delphi IDE to build Windows CE applications, using KOL-CE library, after some adaptations.
KOL-CE - Key Objects Library CE is a set of objects to develop powerful (but compact) Windows CE/Pocket PC/Windows Mobile/Win32 GUI applications using Free Pascal Compiler. The library is based on KOL library by Vladimir Kladov (http://kolmck.net).
It targets the Lazarus IDE, but since it is a fork of a Delphi project, you may be able to use it in your Delphi IDE, perhaps after some modifications. And if you are not able (or do not have the time) to do the needed modifications, I'm quite confident that you would be pleased to use the Lazarus IDE and modern object pascal instead of switching to another language.
You need to install the FPC arm-wince cross compiler for Win32 to compile WinCE executables, but you develop your application in Windows, with the IDE.
Note that KOL is a light new set of components, very diverse to the VCL. Very powerful, but only low-level object code can be re-used, since they are not compatible with the VCL (or the Lazarus LVCL).
Using Lazarus and its native LVCL components is also available to Windows CE, is much close to the VCL classes layout, but will produce much bigger executables than KOL-CE.
For the historic perspective: no you can't in Delphi itself as of Delphi 2007.
In Delphi 2005 and Delphi 2006 could do this, targeting the .NET Compact Framework on Windows CE as Delphi contained a Delphi .NET compiler that was more compatible with the Delphi language than the current (but much more evolved) Oxygene .NET/Java platform implementation of the Delphi language.
As of Delphi 2007, the Delphi .NET compiler got retired.
Right now, Oxygene is much better as it supports a broader set of language and platform features than Delphi .NET ever did. It is less compatible with the Delphi language because the platforms it supports warranted for some language deviations that in practice are very useful.
Oxygene ships both separately (with a full feature set) and as Delphi Prism (with only the .NET portion).
For Delphi 2005/2006 you needed the CF Build Helper from Jeremy North and the Class Helpers I wrote (they are included in the CF Build Helper). A nice article on how to use both is at EDN.
Given the hoopla you had to go through back then, it is much wiser to use Oxygene if you want a language very close to the Delphi language.
For a historic overview of Pascal and Delphi like languages, read this article by Jim McKeeth.

SAML in Delphi 2010

I need to implement SAML in web based Delphi 2010 application. Are there any components available in Delphi 2010 to implement?Are there any delphi sample code available?
I could see sample code for .net but not for Delphi Please let me know.
Thank you in advance
I have had a look around the web, as far as I am able to tell, delphi 2010 doesn't have a component for the implementation of SAML.
The most helpful website I have been able to find is this: http://codeverge.com/embarcadero.delphi.non-tech/saml-in-delphi-2010/1087146 (Link leads out of stack overflow) but as far as I can tell delphi has no components for it, Sorry!

Is Delphi Prism a new version of Delphi .net?

First of all (before this question get down voted): I am a developer developing 99,99% of my programs using Delphi targeting Win32 (developing in Delphi 7 still, very slowly migrating to Delphi 2010).
When Delphi 2006 or 2007 (can't remember which version at the moment) came out I bought the RAD Studio edition to be able to start developing .net applications using Delphi.net and VCL.net.
I played around with it for some short time, but in the end, due to work load just kept using Delphi 7 as development platform.
When Delphi 2010 came was released, I decided to give .net a go once more, and (foolishly) bought the Studio License once more thinking the include PRISM was the previous Delphi.net (to be developed in the Delphi IDE).
Now that I have installed PRISM (and the Visual Studio 8 IDE - o horror), I am just wondering whether PRISM is a new version of Delphi.Net or not (probably not). And if I can use some of my Win32 code under Prism.
UPDATE AFTER SOME REPLIES: I keep the question open because you get more answers when a answer has not been selected yet.
I do miss the Delphi IDE though. It's all a mather of taste but having to develop in two different IDE's (where f.i. the keyboard shortcuts are different - and I don't want to give up the Delphi ones, thank you)) is not my idea of spending my development time.
Prism is a replacement for Delphi .Net - it has been developed by RemObjects and its original names were Oxygene and Chrome ( http://www.remobjects.com/ ).
Because it's much more mature than Delphi .Net in the .Net segment it now is included in Delphi RAD Studio instead of Delphi .Net.
You won't be able to use all of your W32 code, but the syntax is very similar and most algorithms will probably work without any change.
See http://prismwiki.codegear.com/en/Win32_Delphi_vs._Delphi_Prism for a detailed comparison of Delphi W32 and Delphi Prism.
No. Delphi.NET was designed specifically to be backwards-compatible with Win32 Delphi code. Prism is not. It was not developed by the Borland/CodeGear team, doesn't include VCL support, and has a handful of minor language differences. It's better to think of it as a new dialect of Object Pascal than as Delphi.NET.
The main difference was that Delphi.Net was mainly a port of the RTL/VCL to .Net, as well as an adaptation of Object Pascal to be a .Net language.
It had to include a full blown IDE with a special Delphi.Net Form Designer.
The goal was to help move a VCL Forms application to .Net with a minimum of changes, or create new application without having to re-learn the IDE and the library.
Delphi Prism is also an adaptation of Object Pascal to the .Net world but with more emphasis on being a fully fledged .Net language (even more so than C#) and much less worries on being compatible with Delphi.
It is just the language, hosted in Visual Studio, and does use whatever designer is provided by the IDE.
So in the end pure Pascal code will be very much similar, and easily ported, but rich GUI applications will need more rewriting/redesigning.
Yes and no.
Oxygene (FKA Delphi Prism) replaces Delphi for .NET, but it is not a new version of it.
They have different design philosophies and are not 100% compatible. As Francois pointed out, Prism does not include the VCL.Net. Instead it focuses completely on supporting the .NET GUI Frameworks: WPF, Silverlight, Prism, WinForms, ASP.NET, etc.
Delphi for .NET was all about migrating and backwards compatibility. Delphi Prism is all about being a full featured .NET development language and "forward compatibility."
You can create you pure business logic as code compatible between Delphi native and Delphi Prism, but all the GUI and IO code (anything that makes use of the VCL or RTL) will be specialized.
Check out the Oxidizer and ShineOn for more help in migrating and code compatibility with Delphi Prism.
No, Prism has been labeled Delphi more to make it more popular, like Delphi PHP.
It's not like Delphi.NET, with a VCL-alike etc, or even a compatible language (it uses method instead of procedure and many other deviations).
So you can see if you like it, but from what I have seen from it, having used Delphi won't be much of an help, and neither do existing codebases.

ASMX in Delphi Studio

I recently bought Bob's book Delphi XML, SOAP & Web Services
in page 85 of this book the (Delphi 2006 8used) comes with several New Item Categories such as
C# Projects
C++ Builder projects
Delphi for .NET Projects
something that you don't have in a fresh installation
I need this ASP.NET Web Service Application that is inside Delphi for .NET Projects, but I can't find how do we get this plugin(?) to install in Delphi so we get all this new projects categories.
Does any of you use this and can tell me what is the Plugin?
image from the book showing what we are after
alt text http://www.balexandre.com/temp/2009-08-31_1322_asmx_in_delphi.png
We tried Delphi prism but it is not that as Prism works in Visual Studio it self and not in Delphi Studio.
We also tried to send an email to Bob Swart but no answer from him :(
We thought and we own RAD Studio 2007 Professional, and that comes with that Delphi for .NET Projects but not the ASP.NET Web Services, so, we are thinking that it only be available for the Enterprise or Architect versions, but I can't find any information regarding where is this (bundle details and what's inside what) :(
Thanks
The Delphi.Net functionality was removed after Delphi 2007, so I am not sure why you do not see the project type. But as Delphi.Net is a pretty dead technology it would probably make sense to look for an alternative for .Net development like Delphi Prism or C#.
Actually, since Delphi 2007, the functionality has been split into three different product, plus a fourth studio product. There's Delphi for WIN32 which includes C++ and Delphi for .NET which includes C# and ASP.NET. And then there's the Developers Studio which combines these development systems into one product. There are also products called Turbo Delphi, Turbo C++, Turbo C# and Turbo Delphi for .NET.
To be honest, Borland/Codegear/Embarcadero is trying to find the most popular combinations of these products making it very unclear for developers to choose the right version. Now we have Delphi Prism for .NET which integrates in Visual Studio, plus Delphi and Delphi for .NET or whatever. Anyway, I stopped upgrading Delphi since I bought Developer Studio 2007 simply because they're making a big mess of their marketing strategy.
Plus, they're becoming too expensive. For .NET development, Visual Studio will provide plenty of options already, especially when designing web applications. I will upgrade once the price becomes reasonable again and their marketing strategy becomes more normalized. I fear it will be a cold day in Hell when that happens.
You're probably using just the WIN32 version, not the Studio version which would combine both. Or you just installed the WIN32 and not the .NET part! Or, with Delphi 2007, you just start the WIN32 identity, not the whole Studio identity. (Delphi will install multiple icons, one for Delphi/WIN32, one for C++, one for C#/.NET and one for the complete studio.)
Just adding that I myself use the RAD Developer Studio 2007 and it does contain the ASP.NET Web Services. Just make sure you've included them during installation!
Got it.... (finally)
The best way to integrate Delphi code in a .NET output (in my case ASP.NET Web Services) is to download Delphi Prism (free trial version for evaluation) and use it.
File > New Website > ASP.NET Web Service > Language: Oxygene > Choose the required Framework
alt text http://www.balexandre.com/temp/2009-09-01_0857.png
This will create a normal ASMX Web Service with the .pas file as the Code Behind :)
Exactly what I'm after!

About Delphi Wings (ORM)

Someone knows if Delphi Wings (The Embarcadero ORM for Delphi) will be available in Delphi 2010? I'm testing some ORMs but I will preffer the Embarcadero one, if it's available shortly.
Regards,
Francis
Wings isn't an officially endorsed Embarcadero ORM that will be part of Delphi. It is a project developed by Paweł Głowacki, who is an Embarcadero employee.
I didn't know that Embarcadero plan something like this. CodeGear and current Delphi already supports ECO. See also embarcadero developer network.
BTS ECO is an excellent framework that should be investigated, I have started using it myself.

Resources