如何调用一个函数/异步程序在Delphi(无组件) [英] How to call a function/procedure asynchronously in Delphi (Without components)

查看:141
本文介绍了如何调用一个函数/异步程序在Delphi(无组件)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想异步运行在Delphi函数或过程,但不使用的组件,有没有办法用delphi核心功能做呢?

I am trying to run a function or procedure in Delphi asynchronously, but without using a component, is there a way to do it with delphi core functions?

推荐答案

您可能还需要在一个线程中执行你的程序。然后用OnTerminate事件得到的结果。是的,在.NET和C#这几天我们某种被宠坏的容易和方便的形式asynchronioulsly执行的方法,但这是它适用于德尔福的方式。

You may also want to execute your procedure on a thread. Use then the OnTerminate event to get the result. Yes, in these days of .NET and C# we are some kind of spoiled with the easy and convenient form of executing methods asynchronioulsly, but that's the way it works on Delphi.

这篇关于如何调用一个函数/异步程序在Delphi(无组件)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆