Tntman 14 Posted April 2, 2020 (edited) If we talk about windows platform we can embed some resource data ( for example strings ) into our exe. For example we have app "A" and app "B". Lets say that app "A" is our main app. App "B" is secondary app ( .exe - windows compiled ) with some RCDATA strings that are embedded in it. We could load app "B" into app "A" and change resource data in app "B" from app "A" ( this can't be done if app "B" is running, app "B" needs to be closed ). If we talk about windows platform VCL or FMX we could do this with -> https://docs.microsoft.com/en-us/windows/win32/menurc/adding-deleting-and-replacing-resources My question is: What or is there any way to do this multi platform ? ( android,ios,mac,wearables,linux ... ) I suppose that it cannot be done exactly like in windows because some stuff that I mentioned are for windows only.. So what would be the best way to achieve same thing on other platforms ( android,ios,mac,linux,wearables ... ) Also imagine that we have FMX app that is compiled for windows ( we will call it "Win-app" ) and we have other app that is for android and it is built/compiled with delphi FMX ( we will call it "Andro-app" and it will have .apk extension ). Is it possible to load "Andro-app" .apk to "Win-app" and edit embedded resources in "Andro-app" from "Win-app"? <- Is this also possible for other platforms ( Ios,Mac,linux,wearables - make "win-app" that load and edit for example resoruce strings in "ios-app", "mac-app", "linux-app" ...etc... ) I don't need code, I just need someone to point me out and give me directions and I will try to learn on my own since it is so interesting topic. Thank you Edited April 2, 2020 by Tntman Share this post Link to post
vfbb 285 Posted April 2, 2020 What is the real purpose? Are the apps from third parties? Perhaps there is a much simpler solution than changing different platform binaries, explain it better. Share this post Link to post
Tntman 14 Posted April 3, 2020 (edited) I am not sure did you understood my question or maybe i described it poorly so i will try to explain it again.. Here on this link you can see delphi resource hacker. http://www.angusj.com/resourcehacker/ Tool is used to update ( edit ) resource strings in windows executables ( .exe ). I used this tool to edit resources strings in games ( overwriting money value for example ) What i want to ask is it possible to make similar application in delphi fmx for windows that will be capable of updating ( editing ) resources strings in other executables for different platforms ( .apk, Linux executable, mac executables, ios executables... ) Also my other question is where is best place and what is best way to embed/include resource strings that can be updated ( edited ) on other platforms except windows ( android, mac, ios, linux... ). Edited April 3, 2020 by Tntman Share this post Link to post
vfbb 285 Posted April 3, 2020 (edited) You can not change an signed iOS, MacOS or Android app, if the app is not yours. But if you have the source, the app is your, you have many options to save the resources strings, you can save in particular files for it. When we are talking about resources strings for translation, this will allow the store to make smallest packages of your app, because it will not delivery the unnecessary data to the user. For example, a French language will not be included in a user that use English language ... However, this languages files isn’t usually big, and I personally prefer to make a cross platform solution, languages in the source code. Other solution is storing it in a SQLite. Edited April 3, 2020 by vfbb 1 Share this post Link to post
Tntman 14 Posted April 4, 2020 On 4/3/2020 at 1:50 PM, vfbb said: You can not change an signed iOS, MacOS or Android app, if the app is not yours. But if you have the source, the app is your, you have many options to save the resources strings, you can save in particular files for it. When we are talking about resources strings for translation, this will allow the store to make smallest packages of your app, because it will not delivery the unnecessary data to the user. For example, a French language will not be included in a user that use English language ... However, this languages files isn’t usually big, and I personally prefer to make a cross platform solution, languages in the source code. Other solution is storing it in a SQLite. Hmm so basically i added txt file over the IDE ( option resources and images ). I compile app and run on nox, it installed with no problem, after clicking on a button im loading content of txt file that i added in memo and everything works. After that i go to bin directory on my windows machine and edit that txt document inside of an .apk file and upload again to nox, install again and open app in nox it works , it is installed and when i click button it loads txt file with different content and everything works fine so im little bit confused now Share this post Link to post
limelect 48 Posted April 4, 2020 Some clarifications "I go to bin directory on my windows machine and edit that txt document inside of an .apk file and upload again" without any compilations? Edit inside of an .apk? how? you disassemble? Do you know where your resource is in the Apk file? APK is really a ZIP file. Your whole procedure is unclear Share this post Link to post
Tntman 14 Posted April 4, 2020 (edited) 1 hour ago, limelect said: Some clarifications "I go to bin directory on my windows machine and edit that txt document inside of an .apk file and upload again" without any compilations? Edit inside of an .apk? how? you disassemble? Do you know where your resource is in the Apk file? APK is really a ZIP file. Your whole procedure is unclear open in winrar without unziping it so just open. Find text file open it, change data and save text file Edited April 4, 2020 by Tntman Share this post Link to post
limelect 48 Posted April 4, 2020 This will work. However, I do not know what will happen on the market if it is signed and published Share this post Link to post
Tntman 14 Posted April 4, 2020 (edited) 1 hour ago, limelect said: This will work. However, I do not know what will happen on the market if it is signed and published Can you explain me the procedure and why u think that it could not work ? I have never published any app to market i dont even have acc there EDIT: i am talking about android play store, not apple store Edited April 4, 2020 by Tntman Share this post Link to post
limelect 48 Posted April 4, 2020 Android Apple the same. See your Delphi publishing to the market. You can compile for the market. When you compile for Android under configuration there is "Application store". On D10.2.3 See Delphi help 1 Share this post Link to post
Tntman 14 Posted April 4, 2020 1 hour ago, limelect said: Android Apple the same. See your Delphi publishing to the market. You can compile for the market. When you compile for Android under configuration there is "Application store". On D10.2.3 See Delphi help I was thinking that you can just post any .apk to marked ... didnt know that there are some other options for that, i will try to read more about it Share this post Link to post
limelect 48 Posted April 4, 2020 Also of not long ago no 32bits any more. ONLY 64bits. Which means D10.3 Share this post Link to post
vfbb 285 Posted April 4, 2020 It is that I say, you cannot change a signed Android, iOS or macOS app. To the store not. The binary have a checksum that is generated by a key that all apps have, because you don't have the sign key of that app, the changed apk will be invalid. Share this post Link to post
Tntman 14 Posted April 4, 2020 Yes im using 10.3 free version.. Well ok i kinda understand whole concept behind signed apps .. If apps are not signed it could easily be abused Share this post Link to post