>> all good except the date is not formatting as @D6
you're not calling format on that line, so no reason to expect it would be formatted...
>> p_web.Formatvalue(bed2:Inspectiondate,'@d6') but that drops it completely ??
bed2:Inspectiondate is blank there, so one would expect that to be blank.
have you tried;
loc:filename = p_web.RenameFile('Bedroom2Picture',p_web.GSV('pro:propertyname') & '.' & p_web.GSV('Cab:CabinID')&'.' & format(p_web.GSV('Bed2:InspectionDate'),'@d6') & '.png')
(ie - what Jane said...)
I think you will find that works. [except that...]
Also I recommend you use '@D012' not @d6.
@d6 suffers from 2 problems - firstly it contains the / character, which will cause pain to you later on because / is not a character allowed in URL's. So at the very least use '@D06-'. D12 would be better because it has no separators, and sorts y/m/d which means the files will appear in date order when sorted by name.
cheers
Bruce