Noutați

5 Of The Top Reasons Why You Should Use APIs

An Application Programmable Interface or API allows two applications to interact with each other using the API as a bridge or intermediary. If you are not familiar with how to integrate an API then you may be spending a lot of time unnecessarily writing a lot of code from scratch. In other words you may be working too hard! Are you wasting time by writing a lot of code from scratch? This is the main reason you need to start considering integrating APIs into your software. So, we will talk about how to avoid reinventing the wheel every time you design an application. It’s not just the time expended coding things that could have been handled by the API; writing lots of additional code also means you open yourself up to the possibility that you inadvertently introduce errors – bugs – or unintended behavior. Your new code doesn’t benefit from the ‘wisdom of crowds’ which APIs can bring. A professional API from a specialist source often has many thousands of users/consumers who have used the API before and that means any problems and kinks have probably been caught and rectified before you even begin. Letting someone else do the work is always the hard work is always the smart choice, isn’t it? Is it hard to use an API? When I got my first programming internship 4 years ago, in my first whole month, I spent my time integrating different APIs into the web app. I found integrating hard, but after integrating one API, it all become so easy and fun. All I had to do was pay attention to the documentation of the APIs. Using RAD Studio Delphi we also get some additional help to supercharge our skills. RAD Studio has tools such as the REST Debugger and the marvelously powerful REST components do all the hard work for us and help promulgate low code from us and maximum power from our apps. By the end of this tutorial, you will learn how to employ these kinds of useful yet easy to use tools to easily and quickly integrate one of the market-leading APIs into your cross-platform Delphi application. This is the best-kept secret about Delphi that users of other computer languages often overlook – the “RAD” in RAD Studio stands for “rapid application development” and it’s not some kind of tricksy marketing trope; RAD Studio brings your apps from ideas into reality as fast as possible with that legendary rock-solid Delphi application stability means they keep on working too long after many competing technologies have fallen out of fashion or simply become obsolete due to their reliance on runtime support which atrophies over time. What does this article teach me about using APIs in my desktop and mobile apps? I hope that this tutorial will help you start your API Integrator career. We will cover: Explore various APIs and see what they can do for our desktop and mobile applications Look and at how to integrate APIs for use in our own apps Code a demo cross-platform app using Delphi that integrates API The only thing you need is a copy of RAD Studio and basic knowledge of the Delphi programming language! Are you using automation to connect to an API? We have dozens of tutorials on building a […]

Read More

What Is It Like To Be A Developer Stephane Jordi?

Hello. This article is part of a series where we speak with professional software developers, ask them what it’s like to write code for a living, and perhaps gain a few insights into the software development industry along the way. Our guest today is a Delphi and C++ Builder developer who has an amazingly impressive set of pictures of him smiling nonchalantly on the slopes of some absolutely stunning volcanoes at various locations dotted around the world. Stephane Jordi, also known as Steve, is a Swiss geophysicist who made the move from computer geek to computing applied to real-life needs. He specialized in monitoring solutions, first for volcanic activities, then for nuclear power plant seismic surveillance, and enjoys porting all tools to most known platforms. Hi Steve thanks so much for taking the time out to speak with us today – I think you just came off a long flight? Yes after this I am off to bed. I woke up 26 hours ago and am jetlagged 🙂 Which Embarcadero product(s) do you use a) the most b) regularly? I would say Delphi for my current cross-platform developments and C++Builder for scientific software. Since I’m involved in data acquisition, I need very low level access to digital boards and things like that. C++ is more inclined to do so as it is compatible with a very wide 3rd party tools environment. How and/or why did you become a developer? A little bit by chance. Back in 1980 (started very early), I bought a handheld calculator in New York and discovered overnight on the flight back to Switzerland that it was programmable. I had no clue what that meant. The idea that you could let it record and play back sequences of instructions was like magic. It was an HP-33C with 49 lines (keystrokes) that could be recorded. Then my High School was offering optional classes like cooking, theatre and also computing. That world was still very closed and not accessible. Believe it or not, but I came to software development using punch cards doing Fortran IV on big mainframes. I got hooked. Steve has incredible photos which look like they were designed to be desktop wallpapers Do you think you will ever stop being a developer? If so, what would be next? No. Impossible. Once you get this into your DNA, you just want more. I love everything that comes with development: understand a problem or a need, break it into small pieces, imagine what and how they would perform operations, write the code, swear a lot, and eventually see that it works. The road from complexity to delivery is marvelous. What made you start using Delphi/C++ Builder? I was hired for summer job by a company that had only TurboC v2 at the time. That’s how I discovered the C language and the Borland product line, from Prolog to C and Pascal. Then Delphi was released and I really did enjoy the RAD aspect of it. I did know Pascal so it was an easy jump. Then I used all flavors of Turbo C/C++, Borland C++ and then C++Builder which was a natural evolution to follow Delphi. I used Turbo C++ 3 to write my first volcano monitoring software in… Guatemala. I designed the full GUI framework under DOS […]

Read More

Redesigned High DPI and Themed Design-Time Editors

The new update of TMS FNC Core v2.7.0.0 and TMS FNC UI Pack v3.6.0.0, has updated modern design-time editors. And the implementation of an editor for the TTMSFNCBitmapContainer component. High DPI As Delphi 11 Alexandria has the possibility to handle high DPI in design-time as well, the editors are now updated with high DPI aware controls. This is the beginning of the implementation of different components to support high DPI. Adapt to your Theme No more full white screens popping up when working in Dark mode. The editors now change according to the IDE. It matches the style to the Dark or Light theme. Available in Visual Studio Code Until now there was no design time implementation for the FNC controls in TMS WEB Core for VSC. With the new release this is now enabled and they adapt to the Dark or Light theme of your VSC. TMSFNCBitmapContainer Editor Implements a more fluent design to work with the different bitmaps in the collection. This editor gives the ability to add multiple existing files or a new item. And enables you to change the image and the name of each bitmap.

Read More

TMS WEB Core for Visual Studio Code v1.9 available

The highlights of this new release are: Support for creating Miletus cross-platform desktop applications targeting macOS ARM Now you can create a desktop application supporting the new Apple M1 hardware in addition to the Intel Apple devices we already supported. Support for creating Miletus cross-platform desktop applications targeting Raspberry Pi An entirely new territory opens up to not only create apps running on the Raspberry Pi directly but also with having the components to directly communicate with the hardware extensions connected to the Raspberry Pi over i²c, SPI, UART or GDPIO! Discover in this video what the Miletus Raspberry Pi target can bring you. Other than these two highlights, the new version v1.9 includes all TMS WEB Core latest framework enhancements for creating classic web client applications and PWA’s (installable progressive web applications).  Discover TMS WEB Core for Visual Studio Code now. Note that in addition to the wide range of components already included in the TMS WEB Core framework, the TMS FNC product family now also fully supports TMS WEB Core for Visual Studio Code! You can download the trial versions of FNC components and install these in the IDE and discover the full potential TMS WEB Core brings!

Read More

What Are The Mistakes We Made In Creating Delphi Objects?

Practically every developer, even a newcomer in programming, can create and destroy objects correctly. A classic construction that is used in the majority of programs looks the following way: MyObject:= TMyClass.Create(); try {some code…} finally MyObject.Free; end; MyObject:= TMyClass.Create(); try   {some code…} finally   MyObject.Free; end; Yet, some time ago, there were a lot of discussions where to place object creation: before an exception handler or within the try-finally-end construction. Of course, now, it is not difficult to find an answer to this question. An example of well-written code can be found on many online resources, such as StackOverflow, in books and in official documentation. But do you really understand why it is so and what can happen if you use the wrong variant? It is possible that you will have to answer this question during a technical interview. If you do not know the correct answer, just keep reading this article! What is the best way to debug a Delphi code problem? You can get debug messages in various ways, but one of the most convenient is to use the CodeSite logging system. You can install the ‘lite’ version from GetIt Package Manager using this link: https://getitnow.embarcadero.com/?q=codesite&product=rad-studio&sub=all&sortby=date&categories=-1 What is the wrong way to use an object? As an example, let’s create a class. TMyClass = class private function getSelfPointer: Pointer; public constructor Create(beRaized: Boolean = False); procedure Free; overload; end; implementation {$R *.dfm} { TMyClass } constructor TMyClass.Create(beRaized: Boolean); begin if beRaized then raise Exception.Create(‘Error Message’); end; procedure TMyClass.Free; begin // inherited; CodeSite.Send( ‘Destroy object’); {$IFNDEF AUTOREFCOUNT} if Self nil then begin CodeSite.Send( ‘ Destroyed object address:’, IntToHex(Integer(Pointer(self)))); Destroy; end; {$ENDIF} end; function TMyClass.getSelfPointer: Pointer; begin Result := Pointer(Self); end; 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 TMyClass = class private   function getSelfPointer: Pointer; public   constructor Create(beRaized: Boolean = False);   procedure Free; overload; end;   implementation   {$R *.dfm}   { TMyClass } constructor TMyClass.Create(beRaized: Boolean); begin   if beRaized then     raise Exception.Create(‘Error Message’); end;   procedure TMyClass.Free; begin   // inherited;   CodeSite.Send( ‘Destroy object’); {$IFNDEF AUTOREFCOUNT}   if Self > nil then   begin     CodeSite.Send( ‘ Destroyed object address:’, IntToHex(Integer(Pointer(self))));     Destroy;   end; {$ENDIF} end;     function TMyClass.getSelfPointer: Pointer; begin   Result := Pointer(Self); end; In our class we will redefine the Free method only for having a look at the address of the object that we want to destroy. We will copy the code that will destroy the object from the Free method of the TObject class. The only unique method will be getSelfPointer that returns the Pointer to the Object.The class constructor as a parameter will have a logical meaning. If it equals True, an exception will be generated and an object won’t be created.Now, let’s take two global variables of the TMyClass type. var fMain: TfMain; MyObject, MyObject2: TMyClass; var   fMain: TfMain;     MyObject,   MyObject2: TMyClass; How do we get an error in a Delphi constructor? Then let’s place two buttons on the form and define click handlers for them. procedure TfMain.Button1Click(Sender: TObject); begin MyObject:= TMyClass.Create(); try CodeSite.Send(‘Actual MyObject address: ‘, IntToHex(Integer(MyObject.getSelfPointer ), 8)); finally MyObject.Free; end; MyObject2:= TMyClass.Create(); try CodeSite.Send(‘MyObject2 was created. Actual MyObject2 address: ‘, IntToHex(Integer(MyObject2.getSelfPointer ), 8)); // […]

Read More

Boosting UI Components With Frameworks That Speed Development

UI components are central to any front-end project. They are the medium for effective interaction between your customer base and your app. In addition to making your app’s functionality accessible, a good UI increases user engagement. Simply put, UI components are the key to meeting your users’ expectations. Because UI is so important, your front-end developers always need to approach UI design in a way that improves user experience. One of the best practices is to make sure you are consistent when you choose UI interface elements. This is especially true when it comes to your input controls and navigation elements. By standardizing them, you make things easier for your users — a consistent UI reduces your user’s learning curve. This is because they don’t have to spend too much time learning how to navigate your site. This, in turn, results in happy and satisfied customers who are more engaged with your app. In essence, consistent UI design eliminates confusion. That is because users usually assume that the basic, universal rules that apply outside of your app or website also apply to your website. For example, when users see the grey button beside a pop-up, they automatically assume clicking it will close that pop-up. Since there are many components involved in web app development, the best way to design consistent and quick UI components and speed up the development is to use frameworks that support a component-based approach. Frameworks like Angular, React, and Vue. Unfortunately, these frameworks don’t have built-in components, so developers either have to build them from scratch or get them from the community. This is where a tool like Sencha ExtWebComponents comes in handy. What is Sencha ExtWebComponents? Sencha ExtWebComponents is an efficient framework-agnostic UI component tool. It helps front-end developers develop web applications faster. Sencha ExtWebComponents has over 115 pre-built UI components so that you don’t have to start from scratch. From charts (bar, line, area, column, etc.) as well as grids, trees, forms, and layouts, it has everything a front-end developer needs to build an interactive web app. In addition, all of the components work together seamlessly in any application. Using Sencha ExtWebComponents also reduces dependencies and ongoing maintenance. Finally, it comes with great tutorials, docs, and examples to help you get started quickly. Which Frameworks does ExtWebComponents Support? Sencha ExtWebComponents is a versatile tool. It also supports several frameworks. This means you can add both modern and classic Angular, React, and Vue components to your existing apps. Similarly, you can build a create-react-app or ExtAngular App from scratch with modern or classic components. You can also use Modern ExtWebComponents or Classic ExtWebComponents in your existing JavaScript apps. How do Sencha ExtWebComponents UI components work? Here are some of the UI components most commonly used in apps and websites: Grid Grids are great when you want to show a large amount of tabular data on the client-side of your web app. Sencha ExtWebComponents offers various Grids Th3se include the basic grid, locking grid, and grouped grid. It also comes with add-ons, like filtering, the row expander, and summary rows. Finally, you can sort your grids by ascending or descending order. The Grid component in Sencha ExtWebComponents helps organizations handle thousands of records efficiently. Below is an example of a Basic Grid created with Sencha ExtWebComponents: […]

Read More

Developer and Development News – Sunday, November 14, 2021

I’ve built a C++Builder app that pulls development related news and posts from more than 50 developer focused RSS news feeds. From time to time, I’ll highlight some of the articles that piqued my interest. Beautiful C++: 30 Core Guidelines for Writing Clean, Safe, and Fast Code–Kate GregoryIncludes explanations of 30 guidelines along with plenty of examples, the occasional diagram, and stories that put them into context. Bjarne Stroustrup and Herb Sutter, who edit the ISO C++ Core Guidelines GitHub site , reviewed the book, and gave helpful comments on the text, and wrote a foreword and an afterword. All Hail Bug Reports: How We Reduced the Analysis Time of the User’s Project From 80 to 4 HoursBug reports are great If a bug report is adequately handled from both sides, it means that both the user and the software developer are interested in solving the problem. If both sides achieve the desired result, it’s a win-win situation. Podcasts for New Software DevelopersIf you want to be a good software developer you have to be constantly learning. One of the best ways to learn is through listening to good podcasts. This post contains a list of some of the best podcasts new software developers can learn from. Fuzz in Your Language, Fuzzer, or ArchitectureThe developers at ForAllSecure have compiled a catalog of fuzz targets intended for Mayhem that’s written and compiled using several different languages (and architectures) like C/C++, Python, Go, Rust, Java, and many others! Top 11 Time Wastes as a DevOps EngineerIn a world where everything is changing rapidly, productivity and speed through efficient time management is probably what every company is looking for today. This article lists the known time losses that every DevOps engineer should avoid in order to free up time and spend it more effectively. AMD reveals 50 security flaws in its EPYC processors and its Windows 10 graphics driver; Intel discloses 25 vulnerabilities in its products including CPUsAMD has revealed 50 new CVE-listed bugs this week, 23 of them rated of “high” concern, meaning they’re rated at between 7.0 and 8.9 on the Common Vulnerability Scoring System. Intel has also revealed product vulnerabilities – 25 of them. Chipzilla issues its own IDs for flaws, and groups multiple CVEs beneath them. 11 Tutorials For Working With Ethereum From DelphiThis blog post looks at some of the most popular and effective tutorials that can help you adapt to a quick hands-on for working with Ethereum from Delphi.

Read More

5 Reasons Why It’s Great to be a Delphi Developer in 2021-2022

Delphi is one of the programming world’s legendary languages, a cornerstone of the history of software development. New languages have come to the fore as new platforms and frameworks have emerged, but Delphi has stood its ground as development trends came and went because of its reliability and efficacy as a development path.  What’s more, over time Delphi has not only not faded into the annals of history, it has evolved and expanded its capabilities, features and libraries on pace with the growing sophistication and needs of contemporary software solutions. Delphi has remained highly relevant throughout the 26 years since its inception, and today offers a unique and highly attractive proposition that combines multi-platform native capability, low-code high-productivity development, and integration with other languages (with C++ through C++Builder, with Python through Python4Delphi). And with Microsoft’s return to native as the preferred option for Windows app development, there are many reasons why it’s great to be a Delphi developer in 2021-2022. Here are the five most important reasons: 1. Delphi is The Best Available Framework for Native Windows Development As Embarcadero Product Manager Marco Cantu points out in his recent blog post, native Windows development is poised to return to the forefront after Microsoft’s decision to move away from UWP. Microsoft’s recent official deprecation of UWP, which originally replaced .NET alongside the release of Windows 8, indicates that native is once again the focus for application development. And it just so happens that Delphi and RAD Studio are positioned as the best available frameworks for native Windows development. For more information read Marco Cantu’s detailed blog post on this important decision from Microsoft. 2. Delphi Has a Big Community of Fans and Highly Loyal Following  Millions of developers around the world were introduced to programming through Delphi and Object Pascal, and many remain deeply loyal to it. There are also large local and international online communities for Delphi developers and fans. Every year Delphi developers get together for the annual online conference DelphiCon, to discuss the latest in, on and around Delphi. DelphiCon 2021 is scheduled to take place November 16th to 18th. Themes include blockchain, artificial intelligence, tools and APIs, low-code, VCL, components, libraries, and developer productivity. DelphiCon 2021 is open and registration is free. Sign up here: DelphiCon2021 3. Delphi is Super-Easy to Learn And Use Delphi is known as a very easy language to learn and use. Developers new to Delphi also have access to extensive free learning resources, including free courses and content on LearnDelphi.org, and on the Embarcadero Channel on YouTube. LearnDelphi.org Embarcadero YouTube Channel 4. The Full-Featured Delphi Community Edition is Available For Free Not only is Delphi super-easy to learn, developers new to Delphi can download the full-featured Community Edition to work with Delphi completely free forever. They can move to a paid version only after crossing a set revenue threshold. Delphi Community Edition is a full-featured IDE for building iOS, Android, Windows and macOS apps from a single Delphi codebase.Delphi Community Edition includes a code editor, powerful debugging tools, built-in access to popular local databases with live data at design time, Bluetooth capabilities, and a visual UI designer with support for pixel perfect, platform-specific styling. Delphi Community Edition is ideal for learners, independent developers and small teams looking to get started with development, […]

Read More

6 Ways To Improve Your C++ (And Neural Network!) Knowledge

Hello C++ Developers, LearnCPlusPlus.org is packed full of great articles on new modern C++ topics for professionals and beginners. In this article, we point you toward some recent great posts about how to open old project files like *.mak and *.bpr files, how to create a DLL in FMX projects, and 64bits VCL Component. Do you want to set the runtime process priority of your applications in runtime? For the Artificial Intelligence field, we explain the simplest basic activation function that can be used in C++ applications. As you see, again we have a lot of different topics that can be used in Modern C++ applications. If you are new to RAD Studio, we think these posts may help you as much as a rapid introduction to programming in C++ if you’re a beginner, all the way to the most robust, modern, and latest techniques for those more experienced with the language. For those who are perhaps wanting to expand their knowledge with the most up-to-date features, routines, and methodologies this is a great little boost (pun intended) to your C++ knowledge. The new RAD Studio 11, C++ Builder 11, Delphi 11 are released with great new features and according to our tests, the LearnCPlusPlus.org examples are working well with the latest RADS 11. You can see more of our C++ posts on this blog by clicking the following dynamic search link: https://blogs.embarcadero.com/?s=C%2B%2B Here are our selections, How Can We Use C++ Builder in Modern and Professional Ways? These posts are designed to be easy to understand the modern C++. Here are the topics, How To Open Legacy C++ .mak Files With The Latest RAD Studio This Is How To Open C++ Builder .bpr Projects With The Latest RAD Studio How to Create a New Windows FMX DLL In C++ How to Create a New 64bits VCL Component in C++ or Delphi How To Set Runtime Process Priority On Windows In A C++ App What Is An Identity Activation Function in Neural Networks? What Kind of C++ Questions Are We Answering? These are the questions that we answer this week, What is the Project file in C++ Builder? What is .bpr file? Can I open very old C++ builder *.bpr project files with the latest RAD Studio? Is it possible to use forms of .bpr projects with the latest RAD Studio? How can I use forms of the old .bpr project? What is a Project file in C++ Builder? What is a .mak file? Can I open very old C++ builder *.mak project files with the latest RAD Studio? Is it possible to use .mak projects with the latest RAD Studio? How can I use old versions of a .mak project? What is Static Library? What is DLL? How can I create a new DLL Dynamic Library? Can I create a new DLL using with FMX framework? How can I create a function in a Dynamic Library? Where can I find a simple DLL example as a C++ Builder FMX? Can we develop Dynamic Link Libraries in C++ Builder for Windows FireMonkey Applications? Is it possible to use DLLs in multi-device applications? How can I create a new 64bits VCL Component? How can I use the New Component menu? How can I use and fill the New Component Wizard for the 64bits VCL applications? What is a Component in C++? What is an Object in C++? How I can set runtime process priority on my Windows C++ application? Can I change the process […]

Read More

Native Windows is Back to Center Stage

With the downplay of UWP, native development is again the primary Windows development model, after 20 years (given we had .NET in between). Native is what Delphi does at its best, so this is great news for us. Over the last couple of weeks there have been  several announcements from Microsoft that partially reverse past directions in terms of Windows development. In short, Microsoft is downplaying (if not fully deprecating) the Universal Windows Platform model. Here are some relevant links: UWP has been the application development focus for Microsoft since Windows 8 was released, and it was replacing a focus on .NET architecture as the Windows development platform. Now this is a very interesting evolution from the perspective of developers (and development tools vendors like Embarcadero) who have remained focused on the classic native Windows development model, as we are first class citizens again after a very long time. From Native to .NET and UWP For many years, the native development model based on involving the classic Windows API and leveraging the three core Kernel/User/GDI libraries and all of their extensions has been considered an old-style, deprecated approach that would soon be abandoned. This is the classic model used by Delphi and C++Builder (with the VCL library), but also by Visual C++ (with the MFC library). Windows developers were first encouraged to move to .NET (with the idea that the future platform APIs would require .NET and classic applications at some point would stop running on Windows). Over time, it became clear this wasn’t going to be the case. As the .NET-centric focus slowed down, Microsoft started pushing the next idea: the Universal Windows Platform. This was primarily driven by two ideas: one, the ability to run the same application on a desktop PC, but also a Windows phone, a gaming console and a visor technology; two, a more secure platform with limited access to the underlying operating system. At the API level, supporting UWP implied using the WinRT platform APIs, which were different and incompatible with the classic APIs. UWP was slow to catch up. For Delphi and RAD Studio there wasn’t an option, but also migration from Visual C++ and .NET and C# would imply using different runtime libraries and different UI controls — accounting for a large rewrite of an existing application. When Windows 8 first shipped (still allowing classic API applications) there were very few UWP apps available, including from Microsoft. However, some of the new platform features were only available via the WinRT APIs, which is why developers and tools (RAD Studio included) came up with options to call WinRT APIs from within a classic application. RAD Studio Windows notifications support, for example, is implemented with this approach. While Microsoft kept pushing for UWP, indicating classic apps were going to be deprecated, developers didn’t really listen. The next step was promoting the so-called “Desktop Bridge”, that is, the ability for native applications to leverage more of the WinRT APIs and to be “packaged” in a light container for extra security. This last feature was achieved by packaging an application as an APPX and later MSIX. Again, RAD Studio has long offered this support directly in the IDE. Microsoft initially described the bridge as a way to help migrate applications to UWP, which was still the […]

Read More