Base64 encode and decode can only work with container content, it basically creates a textual representation of whatever is in the container.
The BaseElements plugin has a wider implementation of the Base64 encoding/decoding that you can use.
are you trying to CREATE the 1x1 graphic in that color? or do you already have the graphics and can import? the color can _fill_ the container if the field is larger than 1x1. I do this all the time with color "swatches".
Tell us more?
I did do a completely bonkers things earlier this year and create a table with a record for every single RGB value, as the B64 string for every single pixel image has a common start and end with just a bit in the middle that is unique.
As a 16m record file its the slowest and clunkiest method I can think of, but proved that it works...
Yes, you can do this, and without a plug-in (but using Base64Decode, not Base64Encode). Take the Exelisys' progress bar sample for BMP and modify it for the dimensions you need.
Thanks everyone. The progress bar example was very helpful and I was able to get what I needed to work.
I am trying to clear out some of the unnecessary code from this custom function but I keep breaking it. Can someone please tell me how I can remove the progress and the foreground options?
Using foreground_color only
Let ( [
_base = "Qk06AAAAAAAAADYAAAAoAAAAAQAAAAEAAAABABgAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAA" ;
_padding = "AA=="
Base64Decode ( _base & foreground_color & _padding ; "1px.bmp" )
Thanks very much user19752.
I have been using this technique for quite some time and it's always worked great. However, now I want to create a PDF the container field comes out empty, despite showing in Preview mode..
This also happens with the solution provided in this thread.
Does anybody have any experience with this?
A long time ago (in a not so distant galaxy), I created 1x1 px/PT color swatches with a graphic program (FireWorks, I believe). These were imported (a folder of graphics) into a container (many records) & then used wherever needed. Because graphics can fill a space (even from a single 1x1 px/PT), they were light weight storage & "expandable".
-- sent from myPhone --
how are you creating the pdf?
what are you storing?
how are you trying to view it, export it?
Creating PDF - going to Preview Mode, then Save as PDF button
What am I storing - not sure what you're asking here
Trying to view with Acrobat Reader
And what are you doing with Base 64?
That is what this thread is about and current can't see a connection.