goiletisim 0 Posted October 12, 2022 (edited) Hello Everyone, I want to convert the powerbuilder code to delphi, but I couldn't because my knowledge of Winapi is not good. gole_sbo_application.Desktop.Title = gole_sbo_application.Desktop.Title + "_" +string(GetCurrentProcessId()) SetNull(Is_WindowName) ll_hFrameWindow = FindWindowA('TMFrameClass', as_windowname) ll_Child=GetWindow(ll_hFrameWindow, GW_CHILD) ll_hPBWindow = handle(This) ll_rc = SetParenta(ll_hPBWindow, gl_parent_handle) Thank you for helping Edited October 12, 2022 by goiletisim Share this post Link to post
David Heffernan 2345 Posted October 12, 2022 The Windows API functions have the same name no matter which language you call them from. This just hunts out a window by name and class, finds its first child window, and makes this window be its child. However, your real problem is that, with probability > 0.99, cross-process parenting isn't a viable solution for any problem. You say that your knowledge of winapi is not good. Well, it's going to be impossible to write this program without good knowledge of winapi. If at any point in time, you find yourself not knowing something, you must study until you acquire that knowledge. Or hire somebody that already has the knowledge. Share this post Link to post
Lars Fosdal 1792 Posted October 12, 2022 I'd forgo all PowerBuilder UI related things and focus on the function of the app - what does it need to do. Analyse the code (a "screen" here is a reference to a window or combination of windows/controls) - how do you navigate it - what does each screen do - where does it get its data - how does it treat and display the data - what can you do within that screen You would only need to focus on bringing the content and functionality over, without dwelling too much on the old-school PowerBuilder UI code. It would be more of a rewrite than a migration. Share this post Link to post