Noutați

[Webinar] Deciphering the Enigma of Project Upgrades

Embarcadero’s users understand the scalability and stability of C++ and Delphi programming, and depend on the decades of innovation those languages bring to development. Ninety of the Fortune 100 and an active community of more than three million users worldwide have relied on Embarcadero’s award-winning products over the past 30 years. Icons by Icons8.com. © 2020 EMBARCADERO INC. ALL RIGHTS RESERVED

Read More

Add The Powerful Angular Web Framework To Your Delphi Apps

Angular is an extremely popular and powerful web application design framework. It’s a development platform for creating highly efficient and sophisticated single-page apps. Angular is built on TypeScript which is a strongly-typed super-set of JavaScript. The TypeScript framework shares a parentage with Delphi since the project is headed by Microsoft’s Anders Hejlsberg who we all know better as the original creator of Delphi. Anders is still very active in the TypeScript project. TypeScript was designed to overcome some of the shortcomings of JavaScript and in particular to try and use the lessons learned with Delphi’s superb type system to help prevent very common and subtle errors which crop up frequently in JavaScript when developers accidentally misuse an object. What sort of features does Angular include? It’s a component-based framework for building scalable web applications. TypeScript has a collection of well-integrated libraries that cover a wide variety of features, including routing, forms management, client-server communication, and more TypeScript has a suite of developer tools to help you develop, build, test, and update your code With Angular, you’re taking advantage of a platform that can scale from single-developer projects to enterprise-level applications. Angular is designed to make updating as easy as possible, so you can take advantage of the latest developments with a minimum of effort. Best of all, the Angular ecosystem consists of a diverse group of over 1.7 million developers, library authors, and content creators. What can we do with Angular and Delphi? Of course many things we can do using Delphi, one of them is by serving Angular application using it, so let’s create simple web application using Angular. Here are the steps: Running Angular with Delphi Run application and point your browser to http://localhost:8080/index.html , you should see something like the image below: Easy isn’t it ? Please check updated code here https://github.com/checkdigits/horse-API-Demo

Read More

Visualize Our Astounding Planet’s Journey Around The Sun

No matter how big, successful or important we may, or may not, become in our lives we are all just tiny ants in a vast Cosmos. It’s humbling and useful to remember when you’re having a bad Monday or a terrific Tuesday that we’re each just one of 7.5 billion people hurtling around the Sun. That circuit of the Sun, of course, has fascinated humankind for thousands of years, provoking ancient British Iron Age people to build Stonehenge and Egyptian pharaohs to worship it as the deity Ra. In the English language we even have a day of the week named after it. Our whole wide world in the palm of your hand So with this solar preoccupation it’s perhaps no surprise that there is a striking mobile app from Belgian developer MICRI Consult based in Oostende which helps us to visualize the Earth, its position in space relative to the Sun and how the shadow of night glides across our globe’s surface. It’s at once both a terrific teaching aid for children and adults alike, a useful reference for the physics and astronomical data involved and a beguilingly addictive game too. That’s a pretty clever trick to pull off in a mobile app! How is this native Android app produced? Written in the richly powerful cross-platform FireMonkey FMX framework using RAD Studio Delphi, the Earth Positions app really helps us picture anything we could ever want or need to know about the relationship between the Sun and our blue planet home. Learning is made more fun through clever use of educational games and smooth, rich video animations to engage little learners and the bigger ones too! Great stuff by MICRI Consult What does the Earth Positions app do? The app has three main feature animations The Geographical game, where you have to guess a location on a 3D-earth, which rotates and tumbles to display that location in the middle. This game contains 4 levels (beginner, skillful, advanced and expert), 5 continents (Africa, America, Asia, Europe and Oceania) and 5 groups (capitals, large cities, airports, towns and other). Users can get up to 3 hints and depending on the level, you may have to choose between 3, 6, 9 or 12 possibilities. It contains more than 3000 locations, of which 243 capitals and 108 large cities. Day and night, showing the shape of the night over the earth for any given date and time. It also shows the time at different earth positions and the city lights of the capitals and large cities at night. At the start, the animation shows the current day, but you can select any date to observe how shape of the night changes during the seasons, e.g. March 21, June 21, September 21 and December 21. The earth orbiting around the sun, showing the actual date for each position, the seasons and the special orbit positions of the earth. You can also select any date to indicate it on the orbit. Google Play Earth Positions Screenshot Gallery Do you want to produce a beautiful app with high-performance, native power – RAD Studio can help you do it. Why not download a trial today?

Read More

Perform Ultra-Fast Time Series Analysis To Empower Your Apps

Analyzing time series can be a heavy burden for your apps. The calculations involved can vary from reasonably simple to mind-numbingly complex and doing it the wrong way can bring even a desktop machine to its knees. We’re going to show you five different ways to perform high-performance analysis on a time series to truly add enterprise-grade power to your apps in a scalable, responsive way. What is Time Series Analysis? Time Series is an ordered sequence of data points which spread over a period of time. Thus it is a sequence of discrete-time data. The Time Series Data is monitored over constant temporal intervals. This data can be in any measurable and quantifiable parameter related to the field of business, science, finance, etc (for example: Heights of ocean tides, counts of sunspots, the daily closing value of the Dow Jones Industrial Average, etc.). Time Series Analysis refers to identification of the common patterns displayed by the data over a period of time. For these tasks, experts employ specific methods to study the data’s characteristics and extract meaningful statistics that eventually aid in forecasting. Time Series Analysis is beneficial and commonly used for Economic Forecasting, Yield Projection, Inventory Studies, Census Analysis, Sales Forecasting, Stock Market Analysis, Budgetary Analysis, etc. Why use Python for Time Series Analysis? Python is a general-purpose interpreted programming language (unlike R or Matlab). Easy to learn and use primarily because it focuses on readability. It is a popular language in general, consistently appearing in the top 10 programming languages in surveys on StackOverflow (for example, the 2015 survey results). Python is a dynamic language and very suited to interactive development and quick prototyping with the power to support the development of large applications. Python is also widely used for Machine Learning and Data Science because of the excellent library support (in this post, you will learn how to implement Machine Learning for Time Series tasks). It means that you can perform your research and development (figuring out what models to use) in the same programming language that you use in productions, greatly simplifying the transition from development to production. Read more here, for Why use Python for Scientific Computing: Delphi adds Powerful GUI Features and Functionalities to Python In this tutorial, we’ll build Windows Apps with extensive Time Series Analysis capabilities by integrating Python’s Computer Vision libraries with Embarcadero’s Delphi, using Python4Delphi (P4D). P4D empowers Python users with Delphi’s award-winning VCL functionalities for Windows which enables us to build native Windows apps 5x faster. This integration enables us to create a modern GUI with Windows 10 looks and responsive controls for our Python Computer Vision applications. Python4Delphi also comes with an extensive range of demos, use cases, and tutorials. We’re going to cover the following… How to use PyDSE, statsmodels, sktime, Nitime, and tslearn Python libraries to perform Time Series Analysis All of them would be integrated with Python4Delphi to create Windows Apps with Time Series Analysis capabilities. What do I need to perform time series analysis? Before we begin to work, download and install the latest Python for your platform. Follow the Python4Delphi installation instructions mentioned here. Alternatively, you can check out the easy instructions found in the Getting Started With Python4Delphi video by Jim McKeeth. Time to get Started! First, open and run our […]

Read More

How To Use A REST AI API The Really Difficult Way

REST AI APIs are really easy to use with RAD Studio Look, we have been spoiling you a little too much on this site. We keep showing you how few lines of code it is to call APIs on public REST servers. We showed you comparison tests which proved that the skilled Delphi developers in the test were nearly 7 times faster than some competing technologies. We’ve published a total smorgasbord of articles about how totally easy it is to use RAD Studio Delphi to perform artificial intelligence, machine learning and deep learning along with some nifty demonstrations integrating image processing in your apps. We really mean it when we say RAD Studio Delphi makes difficult tasks easier. We know though, you might not believe us. So here’s how to include artificial intelligence into your apps by using a REST API the really difficult way. What can be done with DenseCap Artificial Intelligence? DenseCap detects objects in an image. It creates a JSON object containing coordinates of detected objects and readable captions for them. In the left side of title picture, you see the image processed. The middle part shows starting lines of the JSON object text representation. The DenseCap page contains the product description. The mathematical background is described in this PDF document. For demo purposes, we chose the simplest – draw the found objects on initial image. You see it in the right part of title picture. An important practical usage – process a large image library and store extracted data in DB. This DB can be used to search images or fragments by caption texts. How do I use the DenseCap AI API in my applications? A DenseCap wrapper is available as a C# Nuget package. Available also C# source and JavaScript source in GitHub, but they are a bit obsolete. The DenseCap C# Nuget package does not expose COM interface. Therefore, we should create a wrapper DLL in Visual Studio. C# usage for two tasks, image file and image UR, proposed by DenseCap developers, is following: Our aim is a CLR C++ exporting two functions: __declspec(dllexport) BSTR Densecap_ProcessFile(BSTR key, BSTR filename); __declspec(dllexport) BSTR Densecap_ProcessUrl(BSTR key, BSTR url); __declspec(dllexport) BSTR Densecap_ProcessFile(BSTR key, BSTR filename); __declspec(dllexport) BSTR Densecap_ProcessUrl(BSTR key, BSTR url); These functions return strings – JSON object textual representations. For further processing in Delphi, these strings can be converted in JSON again. Unfortunately, currently Visual Studio CLR C++ does not support Nuget import. So, two wrappers required, C# importing Nuget and CLR C++ exporting desired functions. A complete solution available at the following link: https://github.com/checkdigits/Embarcadero_DenseCap2 All binaries required for Delphi are placed in the “Release: folder.. To work with Delphi, you do not need Visual Studio, simply download files from this folder. And now, you can skip chapters about Visual Studio, and go directly to the Delphi part. C# wrapper – project DeepAICsWrapper Right click on the project, select “Manage Nuget Packages”: Type DeepAI. Press Install. Selected package appears together with packages it depends on. Press OK. Create two static functions, for file and URL. Build the project. C++ CLR wrapper – project DeepAIClrWrapper Add a new C++ project – CLR Class Library. Right click References, add a reference to the recently created DeepAICsWrapper Required functions are in DeepAIClrWrapper.h, leaving cpp empty. Build the project. Using the […]

Read More

Rapidly Build A Visually Stunning Login For Your Javascript Dashboards

The login functionality of an application is the first thing most people see when they go to use a product. It is the most essential, inevitable, and foundational part of any software system out there. A developer who is working on an application often looks for quick and easy ways in which they can build the login part of an application, and focus most of the energy on implementing the actual business logic. In this blog post, we’ll see a quick overview of how we can rapidly build a login system for your JavaScript dashboards using Sencha Ext JS. For a more in-depth version of this guide see the documentation. How can I generate an app using Sencha CMD? Sencha allows you to generate an application boilerplate using the Sencha CMD. Run the following command in your terminal or CLI to generate a LoginApp boilerplate code. sencha -sdk /path/to/ExtSDK generate app LoginApp ./LoginApp Once you have generated the app, navigate to {appRoot}/app.js and remove the mainView config from the application config. We are doing this because we want to perform some validations and evaluations before deciding the initial view when the application loads. For example, there is no need to instantiate the Main view if the user is logged out of the system. At this point, when we have removed the mainView config, the browser shows a blank page upon refreshing the page. This is because the app does not know which view to instantiate yet. We handle this by adding plugins: ‘viewport’ line to {appRoot}/app/view/main/Main.js file. How can I create the login view components? After handling all the configurations and setup prerequisites, navigate to app/view folder inside the LoginApp folder and create a new directory called login. Inside this new directory, create two files Login.js and LoginController.js. Your directory structure should look somewhat like this now. How to generate the login window in my application? To create the login window, open the {appRoot}/app/view/login/Login.js file and define the Login class as follows. Ext.define(‘LoginApp.view.login.Login’, { extend: ‘Ext.window.Window’, xtype: ‘login’ }); In the above code, we essentially extended the Ext.window.Window class to create our own Login class to be further in the application. Let’s add some basic dependencies and properties that our Login class should rely on. requires: [ ‘LoginApp.view.login.LoginController’, ‘Ext.form.Panel’ ], controller: ‘login’, bodyPadding: 10, title: ‘Login Window’, closable: false, autoShow: true Now comes the actual UI part. We need to create a form containing at least three entities in total; username text field, password text field, and login button itself. items: { xtype: ‘form’, reference: ‘form’, items: [{ xtype: ‘textfield’, name: ‘username’, fieldLabel: ‘Username’, allowBlank: false }, { xtype: ‘textfield’, name: ‘password’, inputType: ‘password’, fieldLabel: ‘Password’, allowBlank: false }, { xtype: ‘displayfield’, hideEmptyLabel: false, value: ‘Enter any non-blank password’ }], buttons: [{ text: ‘Login’, formBind: true, listeners: { click: ‘onLoginClick’ } }] } All in all, the final code for in Login.js file should look like below. Ext.define(‘LoginApp.view.login.Login’, { extend: ‘Ext.window.Window’, xtype: ‘login’, requires: [ ‘LoginApp.view.login.LoginController’, ‘Ext.form.Panel’ ], controller: ‘login’, bodyPadding: 10, title: ‘Login Window’, closable: false, autoShow: true, items: { xtype: ‘form’, reference: ‘form’, items: [{ xtype: ‘textfield’, name: ‘username’, fieldLabel: ‘Username’, allowBlank: false }, { xtype: ‘textfield’, name: ‘password’, inputType: ‘password’, fieldLabel: ‘Password’, allowBlank: false }, { xtype: ‘displayfield’, hideEmptyLabel: false, value: ‘Enter any non-blank password’ }], buttons: [{ […]

Read More

The Future of Startups Demands Massive Productivity

Productivity means that you achieve as much as possible within a given time frame. It is a top priority for startups. You don’t want to see your software developers getting involved with time-consuming designing and coding to get the job done. Your team needs a massive productivity boost to solidify the future of your startup. But how can you enhance it? In this post, you will find all the details. Why do startups demand productivity? The start-ups around the world are obsessed with boosting productivity. But why do they need it? Here are the reasons: Desire for Growth Like every startup owner, you want your business to grow. And to achieve growth, your team needs to be very productive. It will enable you to deliver the best software service for your customers timely. It will help you to earn trust and draw the attention of large clients, which leads to the massive growth of your business. That’s why startups around the world demand massive productivity. Save Time and Money Every start-up wants to reduce overhead costs while maximizing profit. To achieve it, your business needs to be very productive. You don’t want your team to spend days on a task that can be completed within a few hours with an alternate framework. You want them to utilize the right tool to get the job done quickly and efficiently. It can save you a lot of time and money. How can Delphi provide a massive productivity boost? Delphi enables your team to develop software significantly faster than the other popular frameworks, including WPF.NET and Electron. A group of developers participated in a benchmarking test where they used all of these frameworks to build a clone of the Windows 10 calculator. The results were pretty interesting. Three Delphi developers managed to build the calculator in an average of 4.66 hours using RAD Studio. Also, there was one Delphi developer who re-used Delphi calculator code he had written to produce other Windows desktop versions of the calculator in the same productivity time trial and, using a readily-available 3rd party library, he went on to create an Electron calculator in just 7 minutes and then a progressive web app (PWA) in around the same time. It demonstrates the impressive code-reusability of Delphi. On the other hand, 16 developers completed the calculator using WPF.NET with a mean average time of 53 hours. To design the same thing, eight Electron developers took a mean average of 47 hours.  The test proves that Delphi is significantly superior to its competitor in terms of boosting the productivity of the development teams. Also, Delphi makes it very easy for you to create an appealing user interface visually. It provides you with the What-You-See-Is-What-You-Get (WYSIWYG) design experience. You can place components onto the Graphical User Interface (GUI) by simply performing the drag-and-drop functionality. You can resize them without touching a code. Also, the codes are significantly short. As a result, Delphi can boost productivity 5 times higher than both WPF and Electron. Should you really use Delphi? Delphi can boost the productivity of your software development team massively. It is faster, lighter, and more powerful than both WPF.NET and Electron. So, you should seriously consider using Delphi. It can meet the future demand of massive productivity of your startup effectively.

Read More

RAD Server CRUD Procedures – Part 3

In this RAD Server CRUD Procedures – Part 3 post we will show how to implement a FireMonkey (FMX) Client to call the RAD Server CRUD procedures and interact with the Employee Table. In the part 2 post, we discussed modifying the default generated CRUD procedure implementations from the RAD Server Package Wizard, to show one possible way to implement Get, GetItem, Post, Put and Delete. In the part 1 post, we discussed the the default generated CRUD procedure implementations from the RAD Server Package Wizard. The Embarcadero RAD Server (also known as EMS – Enterprise Mobility Server) uses the industry standards of REST, and to transfer data to and from the RAD Server REST Service, JSON – JavaScript Object Notation, is typically used as the transfer encoding. Due to the Embarcadero RAD Server supporting industry standard REST and JSON, we will use Delphi’s, C++ Builder and/or RAD Studio’s REST Client Library components (TRESTClient, TRESTRequest, and TRESTResponse ) to implement our EMS REST Client. And recall from Post 2, we used the System.JSON Classes (TJSONArray and TJSONObject) on the back-end RAD Server to implement our CRUD procedures. Employees REST Client For our main REST Client UI form, we have all of the ten (10) columns (fields) from our Employee Table, mostly as TEdit controls for First Name, Last Name, etc., and TSpinBox for the Employee Number, Department Number, and Salary, and one TDateEdit for the HireDate: The bottom panel has 10 TButtons. These buttons will perform the following functions from our RAD Server CRUD procedures:READ: performs the REST HTTP GET, to return all records from the Employee table.PREV: Displays the previous record.NEXT: Displays the next record.FIRST: Displays the first record.LAST: Displays the last record.CREATE: Starts the create mode, to allow the user to use the form to enter a new record.COMMIT: The commit button gets enabled by the CREATE button, and this COMMIT button makes the REST HTTP POST call to the RAD Server to INSERT a new record into the Employee table.EDIT: Starts the Edit mode for the UI form, similar to how Create enter a create mode, allow the user to edit a record.UPDATE: The update button gets enabled by the EDIT button, and after we have made edits to the record, this Update button makes the REST HTTP PUT call to the RAD Server to UPDATE this existing record in the Employee table.DELETE: This Delete button, let’s us delete the current EMP_NO from the Employee table, by making the REST HTTP DELETE call to the RAD Server to DELETE this EMP_NO from the Employee table. With the COMMIT and UPDATE buttons, we do perform their REST calls, and then we perform another GET (READ) call, to get all of the records again. This was just done just for simplicity reasons. This REST Client application also uses the REST Client Library components; RESTClient, RESTRequest and RESTResponse: The Embarcadero REST Client Library is a framework for accessing REST-based web services, like the Embarcadero RAD (EMS) Server. The library is available for all platforms that are supported by Delphi and/or C++ Builder The REST Client Library framework focuses on JSON as the representation format. Let’s now take a look at the implementation code for this Employees REST Client. READ (GET) The source code for the READ (Get) button is this: […]

Read More

Understanding the Colonial Pipeline Ransomware Attack

Published June 17, 2021 WRITTEN BY ED TITTEL. Ed Tittel is a long-time IT industry writer and consultant who specializes in matters of networking, security, and Web technologies. For a copy of his resume, a list of publications, his personal blog, and more, please visit www.edtittel.com or follow @EdTittel On or about May 7, 2021, Colonial Pipeline had to shut its pipelines down because of a ransomware attack. Colonial is a major fuel pipeline operator in the southern and eastern US. Its pipelines stretch from Texas to New Jersey, and reach into Louisiana, Mississippi, Alabama, Georgia, both Carolinas, Tennessee, Virginia, Maryland and Pennsylvania. After a week of downtime that saw gas shortages in many of the more eastern states just mentioned, the company announced on May 12 it was restarting pipeline operations. By May 15, those operations had more or less returned to normal. One burning question remains: What happened? Understanding The Colonial Pipeline Ransomware Attack A Word from Joseph Blount, Colonial Pipeline’s CEO In an interview with the Wall Street Journal, Blount recounted he authorized a ransom payment of $4.4 million. He did so because company executives, in the words of the WSJ story, “were unsure how badly the cyberattack had breached its systems or how long it would take to bring the pipeline back.” According to the WSJ, “Colonial Pipeline provides roughly 45% of the fuel for the East Coast…” Essentially Colonial Pipeline chose to disregard long-standing advice from the FBI and other law enforcement agencies not to pay ransom demands in such situations. Blount demurred and is quoted as saying he authorized payment because “…it was the right thing to do for the country.” More About the Attack Security experts are in agreement with US government officials who attribute the attack to a criminal gang based in eastern Europe named DarkSide. This shadowy organization builds malware to attack systems for extortion, and shares the proceeds obtained from its ransomware with affiliates who actually foist the attacks that see its ransomware take over business and government systems all over the world. As reported in the WSJ story, Colonial worked with experts who had prior experience dealing with the organization behind the attack. That said, the company declined to share details on the negotiations involved in making the payment, or how much of its losses might (or might not) be covered by its cyber insurance coverage. Once the attackers received payment, they provided a decryption tool to unlock affected systems. To underscore law enforcement advice, Colonial also disclosed that the decryption key did not provide everything needed to restore its systems to normal operation. According to CNN, and contrary to many other reports, the sponsoring Darkside organization is not “believed to be state-backed.” Instead Lior Div, CEO of cybersecurity firm Cybereason, describes DarkSide as a “private group that was established in 2020.” That said, consensus is emerging that DarkSide operates in Russia for two compelling reasons. According to CNN, “its online communications are in Russian, and it preys on non-Russian speaking countries.” Div is further quoted as saying “Russian law enforcement typically leaves groups operating within the county alone, if their targets are elsewhere.” DarkSide runs what CNN and other call a “ransomware-as-service” business. That it, it builds tools that it makes available to other criminals, who then use […]

Read More

Build A Modern, Scalable AI Chatbot Into Your Apps in Under 5 Minutes!

User interaction now has a new set of tools: Chatbots and they have many advantages. Chatbots have become almost ubiquitous in recent times. Not only that but many of the bots have added power by the inclusion of basic artificial intelligence and machine-learning to make them much smarter and with that added smarts they can become much more useful than a simple “hi how are you” interaction, often carrying out tasks such as automated order tracking, support inquiries and appointment management. Chatbots have come a long way from the days of Joseph Weizenbaum’s Eliza. Is it hard to add a chatbot to my app? No! Things have come along in leaps and bounds in recent years. Modern chatbots are easier to install, often distributed across robust, scalable cloud platforms, and are extremely portable across different operating systems and device targets. Despite this the time involved in implementing them in your code is extremely fast. What makes up a modern chatbot? The construction of a chatbot basically goes through two major challenges: Natural Language Processing (NLP) and natural language understanding (NLU). In this article we’re going to meet those challenges in an easy to understand and rapid-to-implement way using Wit.ai as the foundation for our AI Chatbot. Wit.ai is an open NLP engine for developers. It allows you to build human-like conversational applications. Wit.ai provides an easy interface and API allowing our apps to understand human conversation from interactions, parsing the message into data we can then act on. Wit.ai is one of the most powerful APIs used to understand natural language and it’s free. Wit.ai works with NLP and NLU. NLU is the process of understanding what a sentence means. This kind of extracted meanings are called “intents”. A typical intent might be that the user wants to view a weather forecast or they want to see or hear a collection of tasks on a todo list. What does natural language processing (NLP) actually do? NLP breaks a sentence into pieces called entities. They are variables that contain details of the user’s task. For example, for a weather forecast, you should be able to identify which place the user wants the forecast for. Wit.ai offers an API that takes text or voice input and returns intents and entities. When NLP is combined with NLU – the input from the user – your application may take actions or even interact with and ask the user new questions. How do I create an AI chatbot in my application? Go to https://wit.ai/ create an account and a new app. You should see something like the following screen: In the “Utterance” section, you can enter a message that a user would type. Wit.ai may not understand the intent and the entities at first, you need to train it. Choose the intent and highlight the entity manually, as my example: Then click on the button to train your bot. Also, check  ‘See how it works’ to get more information and, the API documentation here. Add some more Utterances to train your bot, until, at least, it can get the intents and entities automatically. Now, we are ready to implement AI on a chatbot application. How do I implement Wit.ai in my own chatbot application? First, you will need a chatbot application. This post will not […]

Read More