| View previous topic :: View next topic |
| Author |
Message |
caravas General User

Joined: 05 Sep 2011 Posts: 31
|
Posted: Sun Apr 22, 2012 6:51 am Post subject: How to Insert a Picture in a Dialog Box, Not a Link for it |
|
|
Hi folks!
Does anyone know how to insert a picture and not only a link to it, in a dialog box?
When I try to insert a picture as a dialog box background, I can not set off the option selection Link to it. So, if a copy the document to another computer, the dialog box loses all the pictures connections.
Thanks in advance! |
|
| Back to top |
|
 |
caravas General User

Joined: 05 Sep 2011 Posts: 31
|
Posted: Tue Apr 24, 2012 4:50 pm Post subject: |
|
|
Well,
If someone else needs, there's an alternative solution. You may need to create a subfolder to place your pictures and if you want to copy your files to another computer, just copy the subfolder together with your file:
| Code: | Sub LoadBiblio
oDoc = ThisComponent
oDocURL = oDoc.getURL()
If (Not GlobalScope.BasicLibraries.isLibraryLoaded("Tools")) Then
GlobalScope.BasicLibraries.LoadLibrary("Tools")
End If
oUrl = DirectoryNameoutofPath(oDocURL, "/")& "/Files/Picture.bmp"
oDlgEntra = CreateUnoDialog(DialogLibraries.Library1.DlgEntra)
oDlgEntra.setTitle("Informe MatrĂcula e Senha!")
oControlModel = oDlgEntra.GetControl("ImageControl1").GetModel()
oControlModel.ImageURL = oURL
oDlgEntra.Execute()
End Sub
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|