Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can reports become images to be made into wallpaper or desktop image? 5

Status
Not open for further replies.

Docpro777

Programmer
Jul 1, 2003
105
US
I realize this is probably not possible, but:

Can reports be made images to be made into wallpaper or a desktop (backround) image.

(I currently generate images in the main foxpro window via report writer)

Thanks in advance,

Phil

Philip M. Traynor, DPM
 
Brian,

I finally figured out James Kahn's dll and it truly is great.

Apparent Advantages I see are:
1) It gives directory option as to where to save the bmp (vs. default mypictures)
2) It snaps a (developer/user) controlled dimension of the screen.
3) It bypasses MSPaint altogether.
4) It seems to be able to work in a seemless non-shaky fast manner.

I'll work more with the dll and keep you posted.


Philip M. Traynor, DPM
 
We can only Bask in James' Reflected Glory [blush]

His dll would help to solve several questions that have been asked on TT in the past.

I've sent James an e-mail requesting he post a TT FAQ or to allow me to.

Brian
 
Brian (and all), this works spectacularly for me now: Here is my COMPLETE working prototype in just a few lines of code using James dll and your wallpaper resources:

_screen.WindowState= 2
_screen.backcolor=rgb(255,255,255) &&or whatever
report format 'reports\visit\schedmo' for visit.dos=date() && or whatever report you'd want on the desktop

Set DEFAULT TO (SUBSTR(SYS(16,1),AT(":",SYS(16,1)) - 1, RAT("\", SYS(16,1)) - (AT(":",SYS(16,1)) - 1))) &&this line may be redundant
Declare Integer formtobmpA IN "PCT_DLL.dll" string bmpfilename,integer nX,integer nY,integer nX2,integer nY2
retVal = formtobmpA("c:\schedule.bmp",10,50,1200,900) && Save screen to file c:\screen.bmp
lcBMPFile = "C:\schedule.bmp"
DECLARE INTEGER SystemParametersInfo IN user32 INTEGER uiAction, INTEGER uiParam, STRING @pvParam, INTEGER fWinIni
= SystemParametersInfo (20, 5, @lcBMPFile , 3)

Philip M. Traynor, DPM
 
DocPro777

If you want to simply convert .bmp to .jpg, try topng.exe, 230KB, a freeware command line image converter which converts to and from a number of different image formats.

Run it through ShellExecute() with final parameter of 0 to run hidden, with :-

topng mybitmap.bmp jpg

and you end up with

mybitmap.jpg


FAQ184-2483 - the answer to getting answered.​
Chris [pc2]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top