How xbrowse' column show and print jpg ?

How xbrowse' column show and print jpg ?

Postby ShumingWang » Fri Jan 14, 2011 4:02 am

How xbrowse' column show and print jpg ?
I want like this
oCol := obrow:AddCol()
oCol:bStrData := { ||odb2:cjpgfile+".jpg"}
// or oCol:bStrData := { ||fieldget(5)+".jpg"}
oCol:cHeader := "img"

Thanks !
Shuming Wang
http://www.xtech2.top
Mobile:(86)13802729058
Email:100200651@qq.com
QQ:100200651
Weixin: qq100200651
ShumingWang
 
Posts: 465
Joined: Sun Oct 30, 2005 6:37 am
Location: Guangzhou(Canton),China

Re: How xbrowse' column show and print jpg ?

Postby nageswaragunupudi » Fri Jan 14, 2011 5:32 am

Code: Select all  Expand view
oCol := obrow:AddCol()
oCol:bEditValue := { ||odb2:cjpgfile+".jpg"}   
oCol:cHeader := "img"
oCol:cDataType := 'F'   // 'F' indicates File name containing imagedata
oCol:nWidth := <provide enough width here>

oBrw:nRowHeight := <provide enough row height to display image"


#1. Use of bStrData is deprecated and still works (with the same limitations) and retained for backward compatibility. Instead please use bEditValue and cEditPicture.

#2. With the above code, the image is shown resized to fit inside the cell area, keeping the proportions of width and height of the image. If the user resizes the width or row height during runtime, the images are suitably resized by xbrowse to fit the cell.

#3. oBrw:Report() prints the image also. oBrw:ToExcel() exports image also into the cell.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10631
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: How xbrowse' column show and print jpg ?

Postby ShumingWang » Fri Jan 14, 2011 8:56 am

G. N. Rao. ,
TKS!
Shuming Wang
http://www.xtech2.top
Mobile:(86)13802729058
Email:100200651@qq.com
QQ:100200651
Weixin: qq100200651
ShumingWang
 
Posts: 465
Joined: Sun Oct 30, 2005 6:37 am
Location: Guangzhou(Canton),China


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 103 guests