Is there any way of how to identify which buttons has been created by code and then to remove thm by code before procceeding in recreating some new ones by code too.
You are the developper, so I expect you knowing wich button you want to remove and replace by another one.
There is no difference between a Button added in the Designer or in the code.
What is the purpose of removing Buttons and generate new ones ?
You could 'play' with the Visible property to hide and show them or change their text or images.
For layouts for different screen sizes and resolutions you could use AutoScale in the DesignerScripts or the
AutoScale module or use %x and %y values.
Be aware that a 10'' screen has a surface 8 times bigger than a 3.5'' screen.
And a 10'' screen has a surface double of a 7'' screen.
So a layout designed for a 3.5'' screen and streched for a 10'' screen will look awfull.
A layout designed for a tablet may look too small on a phone.
- AutoScale in the DesignerScripts allows scaling only views added in the Designer and based on the standard screen size (320 / 480 / 160).
- The AutoScale module allows to scale Views added in the code.
Did you read chapter
8.10 AutoScale in the Beginner's Guide.