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 Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Modifying cell content in Grid

Status
Not open for further replies.

beedubau

Programmer
Jan 7, 2003
97
AU

On a hand coded form I have a grid with picture details produced from a table with filesize in bytes.

I wish to display this in my grid in the in the more normal form of nnn Kb.

Code:
        THISFORM.grid1.ADDOBJECT('Column6','Column')
        WITH THISFORM.grid1.Column6
            .CONTROLSOURCE = 'PICTURES.FSIZE'
            .Header1.CAPTION = 'FileSize'

How do I do that?

Can I add a ' Kb' after the value in the field?

Thanks

Bryan
 
Yes if you make this column character, e.g.

this.column1.ControlSource = [transform(MyTable.mySize) + " Kb."] - column will be read-only.

BTW, I have a nice form for selecting files with icons, etc.
 
Thanks Ilyad,

I used
Code:
.ControlSource = [transform(INT(PICTURES.fSize/1024)) + " Kb"]

Your form sounds interesting - is it available?

Regards

Bryan
 
I posted a form's code in another forum, but this form is based on Frank Deitrich's IconBuddy class to get program associated icons. If I would be able to contact Frank (my attempt to send him private e-mail faled so far) I'll ask him to post the latest version including two simple forms.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top