Jump to content

ChrisChuah

Members
  • Content Count

    121
  • Joined

  • Last visited

Everything posted by ChrisChuah

  1. HI By right, the delphi 64 bits applications that uses Oracle DBExpress should use the dbxora.dll and midas.dll. However, when i deployed using those dll, my application would not be able to connect to the oracle database. Instead i have to add the dbexpora.dll which is 32bit dll that I have been using in Delphi 6. Once i added that dbexpora.dll file into my application folder, my application is able to connect to the Oracle database. Anyone has any idea why the dbexpora.dll is still being used? Maybe next time i should ditch DBExpress and move on to other drivers instead. sigh regards chris
  2. Hi Is there a way to use Indy TCP Client to have a synchronous method whereby IdTCPClient1.Connect; IdTCPClient1.Send(); IdTCPClient1.Disconnect rather than to wait for OnConnect event to send the message and followed by Disconnect as I would need to put the buffer on queue so that it will be written to the socket onConnect event The reason for doing this is that i need to send multiple message to different TCP servers and they will accept one command and need to disconnect after sending. What would be the best way to implement this? please advise regards chris
  3. ChrisChuah

    Any delphi components for VNC or RemoteDesktop?

    Thank you. I managed to connect to the 64 bit dll file although the Delphi IDE registered the 32 bit dll as activeX component. until now, i am still learning how to go about doing things in delphi regards chris
  4. ChrisChuah

    Any delphi components for VNC or RemoteDesktop?

    Delphi can compile app into 64bit isnt it? If so, can my Delphi 64bit app run the 32bit dll or does it require the 64bit dll?
  5. ChrisChuah

    Any delphi components for VNC or RemoteDesktop?

    hi Also the activeX comes in 32 bit and 64 bit version when i do a regsvr32 vnc.dll and regsvr32 vnc64.dll, Delphi only shows the 32 bit activeX when importing. how can delphi able to use the 64bit dll? please advise
  6. ChrisChuah

    Any delphi components for VNC or RemoteDesktop?

    Hi Last time, since Delphi 6, i managed to download an VNCX.dll from internet and i was able to embed it into my Delphi 6 application. Now, i tried to import this same component into Delphi 11, Delphi 11 managed to convert into the TLB files and was able to compile it and add to the Palette. When i create a new Windows VCL app and add that VNC ActiveX component into the form, Delphi 11 will crash. Is there a way to find out why Delphi 11 crashed? regards chris
  7. ChrisChuah

    Indy TIdTCPClient connect, send and disconnect

    Hi Remy The data sent to 2 ports are different. The server was designed in such a way that Port1 is sending Command and Control data while Port2 is used for sending and receiving Configuration data. That was how the server was implemented long time ago. Since both ports will be getting data from the server at any 1 time so i cant just use 1 client to send and receive from 2 different ports at the same time isnt it? Am i able to use 1 idTCPClient port to connect to 2 ports? once connected, both ports can receive data at the same time? please advise regards chris
  8. ChrisChuah

    TWebBrowser Edge Engine Unavailable

    Hi Thank you. Will try it use it on Linux. Regards chris
  9. ChrisChuah

    Indy TIdTCPClient connect, send and disconnect

    Hi Remy Now i m having another problem In my app, i have 2 idTCPClient sockets that connect to 2 different ports of same server application. When one of the port or idTCPClient (Client A) disconnect, it should disconnect the other idTCPClient (Client B) as there may be some issues with the server app. When reconnecting the idTCPClient B to the server, whenever i try to use ClientB.IOHandler.Read, it will give me an exception like this ----- <07/11/2023 10:02:31> IP to Connect to CM: 172.20.11.9:16194 <07/11/2023 10:02:31> Connecting..CM User TCP: 172.20.11.9:16197 Own IP: 172.20.13.201 <07/11/2023 10:02:36> Error in Thread Run. Type: EIdConnClosedGracefully Msg: Connection Closed Gracefully. ----- When disconnecting idTCPClient B, should i release the IOHandler? If not how can i handle this exception as I am using a IdThreadComponent to read the IdTCPClient B socket for messages regards chris
  10. ChrisChuah

    TWebBrowser Edge Engine Unavailable

    Hi Has anyone tried out this CEF4Delphi https://github.com/salvadordf/CEF4Delphi It seems it can embed chromium based browser into Delphi App and support for Linux Please advise regards chris
  11. ChrisChuah

    TWebBrowser Edge Engine Unavailable

    Hi I have another question. For Windows x86 and x64, we will need to copy the webview2load.dll to the app directory. How about linux? what are the files that i need to copy or attach to my app directory? The windows webview2load.dll is found in C:\Program Files (x86)\Embarcadero\Studio\22.0\Redist\win64 for 64bit deployment and C:\Program Files (x86)\Embarcadero\Studio\22.0\Redist\win32 for 32bit deployment. Do i attached the entire C:\Program Files (x86)\Embarcadero\Studio\22.0\Redist\linux64 directory files when i deploy for linux when using TWebBrowser in Linux? please advise regards chris
  12. ChrisChuah

    TWebBrowser Edge Engine Unavailable

    hi i managed to find it. must download the EdgeView2 SDK from Getit. From there get the webview2load.dll and copy it to my app directory. thanks chris
  13. ChrisChuah

    TWebBrowser Edge Engine Unavailable

    hi, i am using the Twebbrowser component to load a page which i can see it from microsoft edge and chrome but it was not able to be displayed on the TWebbrowser. Any ideas on how to debug it. i think its still using IE but i am trying to use EdgeIfAvailable but Edge engine is not found if i set the EdgeOnly option where can i find the webview2loader.dll? i downloaded the Evergreen standalone as well as the Fixed version. Expanded the Fixed version but cant find this file regards chris
  14. ChrisChuah

    TWebBrowser Edge Engine Unavailable

    hi I am also having this error whereby Microsoft Edge WebView2 Runtime is installed as shown in Programs and Features but Delphi 11.1 will show an exception as shown in the pic please advise regards chris
  15. ChrisChuah

    Any delphi components for VNC or RemoteDesktop?

    so meaning there is no component that i can use readily to plug into a Delphi form so that i can connect to a VNC server isnt it? still have to do more work on it. oh mine.. then will need more time to research on these few github sources
  16. The TControlSizer made by http://www.simes.clara.co.uk/delphi/ctrlsize.htm no longer exists. Is there a replacement for it to work on Delphi 11? Its still working under Delphi 6 but somehow due to it using windows messages lparams, it is currently not working now regards chris === From the Delphi Groups ====== Here are a few URLs you may want to check out: TStretchHandle http://www.torry.ru/index.htm, at the Authors's page under S for Scott, Anthony. TControlSizer http://community.borland.com/homepages/dsp/index.htm http://www.simes.clara.co.uk/delphi/ctrlsize.htm DDH by Marco Cantu has an example, download DDh3Code.zip from http://www.marcocantu.com/ddh/default.htm Part II, Chapter 8 "Advanced Window Components", DdhSizer.pas. And how to use it ..\SizeComp\SizeDemo.dpr. TSizeControl http://rpi.net.au/~ajohnson/delphi/ -- Peter Below (TeamB) Use the newsgroup archives : http://www.mers.com/searchsite.html http://www.tamaracka.com/search.htm http://groups.google.com http://www.prolix.be
  17. ChrisChuah

    Any delphi components for VNC or RemoteDesktop?

    Hi What is the difference between https://github.com/teppicom/RealThinClient-SDK and https://github.com/CloudDelphi/RTC-Portal-VCL? Actually i need a VNC client component to connect to the VNC Server which is running on Ubuntu 22. Somehow the VNC Server on Ubuntu 22 is different from VNC Server on Ubuntu 20 regards chris
  18. ChrisChuah

    FMX TWebBrowser

    Hi I have a local web page which i will use the FMX.TWebBrowser for Linux to call e.g. File:///home/chris/webpage.html In this web page, there is a java script that will read the xml in that /home/chris directory However, the web browser is unable to read the xml due to CORS Is there a way to allow the FMX.TWebBrowser to enable the javascript to read the local xml file or how to disable the CORS? regards chris
  19. Hi Currently i running Delphi 11.1 in Windows 10 VM. The VM is running on MacOS Monterey 12.6.3 With Delphi 11.1, i am still able to compile MacOS app to run on Monterey. However, if i were to upgrade my MacOS to Ventura, Will my Delphi 11.1 able to compile MacOS app for Ventura? I dont want to face the fact that after i upgraded my MacOS from Monterey to Ventura and Delphi 11.1 cannot compile for MacOS, iOS and Android via PAServer. regards chris
  20. ChrisChuah

    Delphi 11.1 compiled under MacOS Ventura

    Hi So sorry to cause so much of confusion. Currently, i am running MacOS Monterey with XCode 14.2, PAServer 13.1.11 Actually, if i were to upgrade the MacOS from Monetery to Ventura, while keeping the PAServer for Delphi 11.1 at 13.1.11 and XCode 14.2, would there be any problem to compile and run a FMX application for MacOS? Previously i had a problems after upgrading the XCode or MacOS, Delphi would not be able to compile and run the fmx application for iOS or MacOS. I am now stuck with Delphi 11.1 as the company may not want to continue with using Delphi further due to not able to find programmers with such skills locally. Everyone is onto newer programming languages such as javascript, Ruby, Rust, C sharp etc. So sorry to say (what i feel) that delphi is really on a decline whereby the number of components released in 2008 and now, its not easy to find a suitable component for delphi. Hence maybe i am stuck in the middle whereby i may need to re-write some of my apps into other programming languages such as Java or ReactJS regards chris
  21. ChrisChuah

    Delphi 11.1 compiled under MacOS Ventura

    does it mean that my Windows 10 VM with Delphi 11.1 will not be able to compile iOS and MacOS app on my Macbook running on MacOS Ventura? regards chris
  22. Hi I have a component like this TMyComponentEvent = procedure (Sender : TObject ; aData : string) of object; TMyComponent = class(TComponent) private FClient : TidTCPClient; FProcessList : TmyStringList; FReadThreadComponent : TidThreadComponent; FProcessThreadComponent : TidThreadComponent; FOnMyEvent : TMyComponentEvent; procedure DoMyEvent(aData : string); dynamic; ... ... procedure ReadThreadComponentRun(Sender : TidThreadComponent) procedure ProcessThreadComponentRun(Sender : TidThreadComponent) .. .. published property OnMyEvent : TMyComponentEvent read FOnMyEvent write FOnMyEvent; end; procedure register; begin RegisterComponents('MyComponents', [TMyComponent]); end; // cc : the UI screen will have this component and will have a set of code // cc : to implement on this event procedure TMyComponent.DoMyEvent(aData : string); begin if assigned(FOnMyEvent) then FOnMyEvent(self, aData); end; // cc : assume that the TidTCPCLient is connected to the server // cc : so the FReadThreadComponent will always get the data from TidTCPClient procedure TMyComponent.ReadThreadComponentRun(Sender :TidThreadComponent) var l_readBytes : TIdBytes; l_processdata : string; begin FClient.IOhandler.ReadBytes(l_ReadBytes, -1, false); if length(l_readBytes) = 0 then exit; {There are some headers to remove from the l_readBytes l_processData := ProcessidBytes(l_readBytes); FProcessList.add(l_processData); end; // cc : this is another idThreadComponent that will take the first item from the myStringList // cc : and process it procedure TMyComponent.ProcessThreadComponentRun(Sender : TidThreadComponent); var l_data : string; begin // cc : take the first item from the MyStringList l_data := FProcessList.getFirstData; if (l_data[1] = '1') then DoMyEvent(l_data); end; In the main form TMainForm.MyComponentMyEvent(Sender : TObject; aData : string) begin TThread.Synchronize (nil, procedure begin // update the FMX Form UI button, grid etc. end); end; Now, the question is, if i DO NOT use the TThread.Synchronize, there will be problem updating the UI grid etc. What is the difference if i use the TThread. Synchronize and TThread.Queue Somehow, if i use the Synchronize function, it is slower in updating the UI than TThread.Queue. How can i make the UI updating more responsive? Am i doing it correctly or can anyone advise? Also there is some hanging issue whereby the function using the TThread.Queue can be called by Clipboard event. Maybe i will need to capture that event screen again
  23. ChrisChuah

    Delphi 11.1 with TidThreadComponent and TThread.Synchronize

    I agree with you. It is really a headache when dealing with Thread and synchronisation. In Indy TCP component, i need to use the Thread component to read the TCP socket constantly for data. When there is data, need to append to a buffer or memstream as network data does not come in nice chunk of data with start and end. Then we need to process that memstream for the appropriate data and remove the part of the data process from the memstream and add to another queue or List. Then we need to create another thread to process this List to send out events. Need to create the thread so that it will hog up the first thread that read data from the TCP component. In this processing thread, need to fire event based on the message. In this event, if there is a need to update the Main form UI, we need to use the TThread.Synchronize or TThread.Queue. If I were to update the data in memory, then i would not need to use TThread isnt it? <== Am i on the correct path? So, if i update the data in memory and i use the timer to refresh the Main form UI, Do i still need to use TThread.Synchronize or TThread.Queue? But using System.TTimer to refresh the data would have a lower priority in refreshing as if there are lots of data coming in on the TCPClient, the updates would use up the CPU and the timer will be set back to later time when the CPU is less busy isnt it? Please advise
  24. ChrisChuah

    Delphi 11.1 with TidThreadComponent and TThread.Synchronize

    Hi remy Ignore my last statement on the TThread.Queue can be called by Clipboard event. I am still trying to figure out why my application UI can hang or irresponsive when there is a large amount of data is received from the TidTCPClient. The TidThreadComponent will be busy processing and send out events to the MyEvent function as shown below TMainForm.MyComponentMyEvent(Sender : TObject; aData : string) begin TThread.Synchronize (nil, procedure begin // update the FMX Form UI button, grid etc. end); end; My app is then reported by windows task manager that it is not responding. How can i check where the problem lies? Is it at the TThread.Synchronized in the MyComponentMyEvent? I cannot click on any part of the application UI anymore. This is an FMX application running in Windows 32 bit. Would I not face any of this hanging issue if i change to a VCL application instead of FMX? Please advise regards Chris
  25. Hi Currently i need to go back to maintain my source code written 10 years ago. when i tried to run IdHTTP.Head function, sometimes it would hang there and this caused my thread to hang there. What can i solve this "hanging" problem? Where can i download the latest Indy 9 (9.0.50) or Can i download Indy 10 to work with Delphi 6? please help regards chris
×