[Gambas-user] Size of a picture

Christopher Brian Jack brian at ...1334...
Thu Oct 19 19:48:08 CEST 2006


On Thu, 19 Oct 2006, rolf wrote:

> Hi everybody,
>
> I would like to store a picture in a postgresql database. So every non char
> (i.e. A-Z, a-z, 0-9...) have to be quoted as octal numbers with two leading
> backslashes. Because the Replace function only works with strings I have to
> loop through the picture data and do the substitution by myself.
>
> To do so, I need the number of bytes the picture has. How can I get this
> value?

If you are getting the picture from a file you can get the length from the
file on disk.

.=================================================.
|  Christopher BRIAN Jack aka "Gau of the Veldt"  |
+================================================='
| oevna at ...1544...
`=================================================-
Hi Spambots, my email address is sputnik at ...1334...
Hi Humans, my email address uses rot13 cipher





More information about the User mailing list