You can also replace a background image with an Image Object.
Just add an Image Object on your page and let it handle the background with Image.SetProperties("Image1", {ImageFile=_SourceFolder.."\\AutoPlay\\Images\\Bac kground.png"});
Announcement
Collapse
No announcement yet.
Application restart?
Collapse
X
-
Originally posted by mrdude View PostFor some reason when I switched between pages, not all the pages would have the new background until the page was redrawn, it's not a big deal though as you don't notice it and it's very quick, and it's working fine so......
Leave a comment:
-
-
For some reason when I switched between pages, not all the pages would have the new background until the page was redrawn, it's not a big deal though as you don't notice it and it's very quick, and it's working fine so......
Leave a comment:
-
-
I don't remember having to redraw each time I used to change background but why you reset the background each time you reset the page I not really understanding the point of changing a page can you send your APZ I sure something is a little wrong here.
Leave a comment:
-
-
Originally posted by Ham View PostYou can use the Application.SetPageProperties.
e.g.PHP Code:Application.SetPageProperties("Page1", {ImageFilename=_SourceFolder.."\\AutoPlay\\Images\\Background.png"})
I had to do this though because I have multiple pages:
Code:function backgrounds() -- Display a single-selection file browse dialog result = Dialog.FileBrowse(true, "Load Background File", _SourceFolder .. "\\AutoPlay\\Docs\\Backgrounds\\", "Png File (*.png)|*.png|All Files (*.*)|*.*|", "", "", false, true); result2 = String.Replace(result[1], [[\]], [[\\]], false); -- If CANCEL was not chosen, then let's get the file path if (result[1] ~= "CANCEL") then File.Copy(result2, _SourceFolder .. "\\AutoPlay\\Images\\Background.png", true, true, false, false, nil); tbPageProperties = {}; tbPageProperties.ImageFilename = result2 Application.SetPageProperties("Page1", tbPageProperties); Application.SetPageProperties("Page2", tbPageProperties); Application.SetPageProperties("Page3", tbPageProperties); Page.Redraw(); end end
Code:Application.SetPageProperties("Page1", {ImageFilename=_SourceFolder.."\\AutoPlay\\Images\\Background.png"}) Page.Redraw();
Code:Application.SetPageProperties("Page2", {ImageFilename=_SourceFolder.."\\AutoPlay\\Images\\Background.png"}) Page.Redraw();
Leave a comment:
-
-
You can use the Application.SetPageProperties.
e.g.PHP Code:Application.SetPageProperties("Page1", {ImageFilename=_SourceFolder.."\\AutoPlay\\Images\\Background.png"})
Leave a comment:
-
-
Application restart?
I have set a background image in page properties, then this function to change it:
Code:function backgrounds() -- Display a single-selection file browse dialog result = Dialog.FileBrowse(true, "Load Background File", _SourceFolder .. "\\AutoPlay\\Docs\\Backgrounds\\", "Png File (*.png)|*.png|All Files (*.*)|*.*|", "", "", false, true); result2 = String.Replace(result[1], [[\]], [[\\]], false); -- If CANCEL was not chosen, then let's get the file path if (result[1] ~= "CANCEL") then File.Copy(result2, _SourceFolder .. "\\AutoPlay\\Images\\Background.png", true, true, false, false, nil); end end
Thanks.Tags: None
-
Leave a comment: