Wish Create comment link for changing app's icon.

Theera

Expert
Licensed User
Longtime User
Refer to this I think it is easier for changing app's icon and set it readonly file by using comment link with batch file.
 

Sandman

Expert
Licensed User
Longtime User
Working link:
 

Theera

Expert
Licensed User
Longtime User
Working link:
I think that I can do in B4A,but I can't do in B4i,so I think someone can solved it better.
 

Theera

Expert
Licensed User
Longtime User
The present, I 've used B4A Template Thai edition as attached file. I think it may be easy strategy to change only one clicked.
 

Attachments

  • B4ATemplate.txt
    1.8 KB · Views: 25

aeric

Expert
Licensed User
Longtime User
The present, I 've used B4A Template Thai edition as attached file. I think it may be easy strategy to change only one clicked.
I don't see any comment links inside your file.

I suggest to you to use Conditional Compilation to determine the icon file.
 

Theera

Expert
Licensed User
Longtime User
@echo off
set /p filename=%1
set /p mypath=%2
If exist %mypath%\icon.png (
attrib -r %mypath%\icon.png
del %mypath%\icon.png
)
ren %filename% icon.png
copy icon.png %mypath%\
attrib +r %mypath%\icon.png
I think that I should create bat file before.(myscript.bat, x.png)
B4X:
'Ctrl + click to change icon: ide://run?File=myscript.bat&args=.. \.. \shared+Files\x.png&args=..\object\drawable&FilesSync=True
 
Last edited:

tchart

Well-Known Member
Licensed User
Longtime User
@Theera I have updated b4x_cba to replace icons.

You can use this ide link or make part of your build actions;

B4X:
b4x_cba.exe -action setexeicon -exe C:\Release\application.exe -icon C:\Release\icon.ico

The icon must be in "ico" format.

You should also fully qualify the paths if they are not in the objects folder.

You an download from here;

 

Theera

Expert
Licensed User
Longtime User
@Theera I have updated b4x_cba to replace icons.

You can use this ide link or make part of your build actions;

B4X:
b4x_cba.exe -action setexeicon -exe C:\Release\application.exe -icon C:\Release\icon.ico

The icon must be in "ico" format.

You should also fully qualify the paths if they are not in the objects folder.

You an download from here;

But in B4A uses icon.png, doesn't it?
 

Theera

Expert
Licensed User
Longtime User
You are correct, sorry I thought you were trying to set the icon for the B4J Packager!

Apologies :( I misread the thread.
Your stategy is the great, it is useful for B4J.Thank you for sharing the idea.
 
Top