Differences in ItemTemplates

Hi,

The following displays an image correctly in a TWebContinuosScroll.ItemTemplate but does not in a TWebDBResponsiveGrid.Options.ItemTemplate.

image

Thanks,

Ken

Do you implement OnItemGetFieldValue to feed the data of the image in the same way as for the TWebContinuousScrollControl?
This event OnItemGetFieldValue should return the base64 image data.

No and I don't do that in the TWebContinuousScroll. It works without it

I'm sorry, but it is not clear to me from your description how you bind the DB to the TWebContinuosScroll control then.

In the TWebContinuousScroll I load it in the OnFetchNextPage event this is actually calling PHP which is returning a json array from a MySQL database. This displays images perfectly with no additional handling needed in the TMS Web program. The images are converted to base 64 by the PHP.

In a TWebResponsiveGrid I I use LoadFromJson which loads the same PHP. This also displays the images correctly

In TWebDBResponsiveGrid I use a TWebHttpRequest to load the same PHP and then use:

TWebClientDataSet.Rows:=TJSArray(TJSJSON.ParseObject(AResponse));
WebClientDataSet1.Open;

This does not display the images. I hope this makes things clearer.

I have managed to get it to work in a TWebDBResponsiveGrid by setting the field in the TWebClientDataSet to a TStringField. I previously had it set as a TBlobField. Apologies if I have wasted your time.