scottelane
asked on
Hiding 'importing' message when loading an image
Hi there,
I have a linked image on a form, and its 'picture' property changes according to what record is selected on a subform of that form. It's a plain image control, not an OLE object.
I have managed to get this working, however when the appropriate linked image is loaded, a dialog box appears for a split second that says ie. "Importing c:\directory\image.png" with a status bar below. It's very annoying because I want the image to appear without this status bar box flickering on top of the interface.
Does anyone have any idea how to get around this without using OLE objects? Is it possible to disable this dialog box?
Thanks in advance
Scott
I have a linked image on a form, and its 'picture' property changes according to what record is selected on a subform of that form. It's a plain image control, not an OLE object.
I have managed to get this working, however when the appropriate linked image is loaded, a dialog box appears for a split second that says ie. "Importing c:\directory\image.png" with a status bar below. It's very annoying because I want the image to appear without this status bar box flickering on top of the interface.
Does anyone have any idea how to get around this without using OLE objects? Is it possible to disable this dialog box?
Thanks in advance
Scott
how do you load your picture ?
i have a similar app. without any problem.
**********
Private Sub Form_Current()
BildAnz.Picture = [BildQuellPfad] & [BildDatei]
End Sub
**********
BildAnz = picture-control
[BildQuellPfad],[BildDatei ] = record-values for path & filename
Regards, Franz
i have a similar app. without any problem.
**********
Private Sub Form_Current()
BildAnz.Picture = [BildQuellPfad] & [BildDatei]
End Sub
**********
BildAnz = picture-control
[BildQuellPfad],[BildDatei
Regards, Franz
ASKER
In the subform I go:
-------------
Private Sub txtName_GotFocus()
On Error GoTo Err_Screenshot
'update screenshot
Parent.imgScreenshot.Pictu re = GetScreenshot(Me.GameId)
Err_Screenshot:
Exit Sub
End Sub
-------------
(GetScreenshot finds the screenshot path for the selected 'GameId')
When I lose focus, I set Parent.imgScreenshot.Pictu re = ""
Unfortunately turning off warnings didn't work 1William, but thanks anyway.
-------------
Private Sub txtName_GotFocus()
On Error GoTo Err_Screenshot
'update screenshot
Parent.imgScreenshot.Pictu
Err_Screenshot:
Exit Sub
End Sub
-------------
(GetScreenshot finds the screenshot path for the selected 'GameId')
When I lose focus, I set Parent.imgScreenshot.Pictu
Unfortunately turning off warnings didn't work 1William, but thanks anyway.
ASKER
In the subform I go:
-------------
Private Sub txtName_GotFocus()
On Error GoTo Err_Screenshot
'update screenshot
Parent.imgScreenshot.Pictu re = GetScreenshot(Me.GameId)
Err_Screenshot:
Exit Sub
End Sub
-------------
(GetScreenshot finds the screenshot path for the selected 'GameId')
When I lose focus, I set Parent.imgScreenshot.Pictu re = ""
Unfortunately turning off warnings didn't work 1William, but thanks anyway.
-------------
Private Sub txtName_GotFocus()
On Error GoTo Err_Screenshot
'update screenshot
Parent.imgScreenshot.Pictu
Err_Screenshot:
Exit Sub
End Sub
-------------
(GetScreenshot finds the screenshot path for the selected 'GameId')
When I lose focus, I set Parent.imgScreenshot.Pictu
Unfortunately turning off warnings didn't work 1William, but thanks anyway.
ASKER
I have found a part solution. When I link to a .bmp, there is no import dialog, however when I link to a .png, it appears. It's unfeasible for me to change the image formats, however there still could be a way to hide the dialog box.
Is there some sort of image control that can natively loads .png files?
Cheers
Is there some sort of image control that can natively loads .png files?
Cheers
Sorry it did not work, worth a shot though. Good luck
If you need only screenshots, I recommend to use irfanview-software. It is small, fast, free and has command-line options (and can handle most formats !!)
i do screenshots of any access-screen with a macro, I can start fom the menu:
the macro only calls the function ScreenToJpg () :
***************
Public Function ScreenToJpg() As Variant
Dim x As Variant
x = Shell("command.com /c d:\work\irftest_acccapt.ba t", vbHide)
End Function
****************
the batchfile:
****************
c:\Programme\irfanview\i_v iew32.exe /silent /capture=2 /convert=d:\work\acc.jpg
****************
of corse you can do that in one step also.
you have to modify that for your formats and path.
download from: www.irfanview.com and read the file about the commandline options. ! important: you can combine the commandline options, so there is very little, you cannot do.
Regards, Franz
PS: If you use for commercial, please register. Irfan has done a realy good job.
i do screenshots of any access-screen with a macro, I can start fom the menu:
the macro only calls the function ScreenToJpg () :
***************
Public Function ScreenToJpg() As Variant
Dim x As Variant
x = Shell("command.com /c d:\work\irftest_acccapt.ba
End Function
****************
the batchfile:
****************
c:\Programme\irfanview\i_v
****************
of corse you can do that in one step also.
you have to modify that for your formats and path.
download from: www.irfanview.com and read the file about the commandline options. ! important: you can combine the commandline options, so there is very little, you cannot do.
Regards, Franz
PS: If you use for commercial, please register. Irfan has done a realy good job.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks RobaJob you are brilliant :) It works perfectly. I thought that it may not have been possible to disable stuff like that, but from now on I'll know that the settings for similar things could be in the registry.
Thanks everyone else for your help too!
Scott
Thanks everyone else for your help too!
Scott
scott, if ur there,
I am using Windows XP.. I changed the HKEY_LOCAL_MACHINE\softwar e\microsof t\Shared Tools\Graphics Filters\PNG\Import\Options to No as well and the Importing Dialog still appears. Apparently, Windows XP ignore your Registry setting on this. Shane alos tried this on his XP machine and it didnt work for him either.
Any ideas?
M
I am using Windows XP.. I changed the HKEY_LOCAL_MACHINE\softwar
Any ideas?
M
docmd.setwarnings false
then after the image load code
docmd.setwarnings true