Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-16 Thread John J Foster via 4D_Tech
Hi Armin,

Thanks I’ll give it a try.

Appreciate,
John…


> On May 16, 2019, at 12:00 PM, 4d_tech-requ...@lists.4d.com wrote:
> 
> John, change the codec and it works
> 
> The component has an error on this line and you have to change the Codec to
> 4pct 
> 
> PICTURE TO BLOB($1;$blob;".4pct")
> 
> Regards Armin

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-15 Thread ADeeg via 4D_Tech
4D Tech mailing list wrote
> Hi All,
> 
> 4D v17R4 Windows and Macintosh Stand alone and 4D Server
> I do not have an old 4D Write plugin only the new 4D Write Pro
> App upgraded from 4D 2012 to 4D V17
> 
> I am working on the final v17 conversion piece migrating older 4D Write
> saved in picture field to 4D Write Pro saved in object field. I am using
> the the code from the component on the blog
> "https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component”.
> 
> However, as I watch the code in the debugger, this is what I see:
> 
> $blob:=_Extract4W7From4DPicture ($1)
> If (BLOB size($blob)=0)
>   GET PICTURE FORMATS($1;$codecIDs)
>   If (Size of array($codecIDs)=1)
>   If ($codecIDs{1}=".pict”)
>   !!! // makes it to here so “knows” it’s a pict.
>   $blob:=_Extract4W7FromMacPicture ($1)
>   !!! // returns an empty blob
>   End if 
>   End if 
> End if 
> 
> Inside this routine "Extract4W7FromMacPicture ($1)” this line executes
> 
> PICTURE TO BLOB($1;$blob;"PICT") 
> 
> Always returns an empty blob even though $1 is a picture with a size like
> 25ko.
> 
> So not sure what;’s going on and why it doesn’t work.
> 
> Does anyone have any experience with converting an older 4D Write saved in
> a picture field into a 4D Write Pro object?
> 
> Appreciate,
> John

John, change the codec and it works

The component has an error on this line and you have to change the Codec to
4pct 

PICTURE TO BLOB($1;$blob;".4pct")

Regards Armin



--
Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-15 Thread John J Foster via 4D_Tech
Hi Tim,

I’m guessing not since I went back on the downed site and relaxed that the 
first download is 64bit and that you have to search and click into another link 
which then opens the ftp download page to find the 32bit versions.

I am presently doing this and will try this again …

BTW, the videos show converting the 4D Write docs to disk. Can I also just add 
a blob field and save them to a blob field if I choose to? {although I’d likely 
send to disk and save the field}.

Thanks,
John...

> You will need to use 32 bit. Are you using 32 bit?
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-15 Thread Timothy Penner via 4D_Tech
You will need to use 32 bit. Are you using 32 bit?

-Tim




-Original Message-
From: John J Foster 
Sent: Wednesday, May 15, 2019 9:00 AM
To: Timothy Penner 
Cc: 4D iNug Technical <4d_tech@lists.4d.com>
Subject: Re: Migrating 4D Write Pictures to 4D Write Pro Objects

Hey Tim,

Thanks helpful!

OK, so I need to get the Write docs into v7 format before migrating to 4D Write 
Pro object format.

Based upon these v16 videos can I migrate from within 4D v17?

Or do I need to convert in an earlier version?

And if I can convert in 4D v17 (windows or Mac) then it appears I would need to 
have 4D Write installed as well. And if so, I cannot find a v17 version of the 
4D Write plugin. Can I use 4D Write 16?

Appreciate,
John...



> On May 15, 2019, at 8:47 AM, Timothy Penner  wrote:
>
> Hi John,
>
> Video Tip: Converting 4D Write documents to 4D Write Pro
> https://kb.4d.com/assetid=77703
>
> Here is the section about converting 4D Write documents stored in Picture 
> fields.
> https://youtu.be/nc6JMNanv58?t=120
>
> Here is the process you need to follow:
> https://youtu.be/nc6JMNanv58?t=163
>
>
> -Tim
>
>
>
>
> 
>
> Timothy Penner
> Senior Technical Services Engineer
>
> 4D Inc
> 95 S. Market Street, Suite #240
> CA 95113 San Jose
> United States
>
> Téléphone : +1-408-557-4600
> Standard :  +1-408-557-4600
> Fax :   +1-408-271-5080
> Email : tpen...@4d.com
> Web :   www.4D.com
>
>
>
>
>
> On 5/15/19, 8:27 AM, "4D_Tech on behalf of John J Foster via 4D_Tech" 
> <4d_tech-boun...@lists.4d.com on behalf of 4d_tech@lists.4d.com> wrote:
>
>Hi All,
>
>There’s an implied assumption that Migrating 4d-write documents stored in 
> picture fields will work using the v17 component. I didn't see any caveats as 
> to preparing 4D Wrote docs in earlier versions.
>
>So, as Randy offered, maybe that’s the correct path. Maybe I should change 
> the docs in 4D v12 from picture fields into blob - either by adding another 
> blob fold to the table or exporting the 4D Write docs to disk.
>
>Is this the best way to approach 4D Write docs?
>
>Have others had a similar experience as Randy?
>
>Thanks for your help,
>John…
>
>
>
>> 4D v17R4 Windows and Macintosh Stand alone and 4D Server I do not
>> have an old 4D Write plugin only the new 4D Write Pro App upgraded
>> from 4D 2012 to 4D V17
>>
>> I am working on the final v17 conversion piece migrating older 4D Write 
>> saved in picture field to 4D Write Pro saved in object field. I am using the 
>> the code from the component on the blog 
>> "https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component”.
>>
>> However, as I watch the code in the debugger, this is what I see:
>>
>> $blob:=_Extract4W7From4DPicture ($1)
>> If (BLOB size($blob)=0)
>> GET PICTURE FORMATS($1;$codecIDs)
>> If (Size of array($codecIDs)=1)
>> If ($codecIDs{1}=".pict”)
>> !!! // makes it to here so “knows” it’s a pict.
>> $blob:=_Extract4W7FromMacPicture ($1) !!! // returns an empty blob
>> End if End if End if
>>
>> Inside this routine "Extract4W7FromMacPicture ($1)” this line
>> executes
>>
>> PICTURE TO BLOB($1;$blob;"PICT")
>>
>> Always returns an empty blob even though $1 is a picture with a size like 
>> 25ko.
>>
>> So not sure what;’s going on and why it doesn’t work.
>>
>> Does anyone have any experience with converting an older 4D Write saved in a 
>> picture field into a 4D Write Pro object?
>>
>> Appreciate,
>> John…
>>
>>
>>
>>
>
>**
>4D Internet Users Group (4D iNUG)
>Archive:  http://lists.4d.com/archives.html
>Options: https://lists.4d.com/mailman/options/4d_tech
>Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
>
> **
>
>

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-15 Thread John J Foster via 4D_Tech
Hey Tim,

Thanks helpful!

OK, so I need to get the Write docs into v7 format before migrating to 4D Write 
Pro object format.

Based upon these v16 videos can I migrate from within 4D v17?

Or do I need to convert in an earlier version?

And if I can convert in 4D v17 (windows or Mac) then it appears I would need to 
have 4D Write installed as well. And if so, I cannot find a v17 version of the 
4D Write plugin. Can I use 4D Write 16?

Appreciate,
John...



> On May 15, 2019, at 8:47 AM, Timothy Penner  wrote:
> 
> Hi John,
> 
> Video Tip: Converting 4D Write documents to 4D Write Pro
> https://kb.4d.com/assetid=77703
> 
> Here is the section about converting 4D Write documents stored in Picture 
> fields.
> https://youtu.be/nc6JMNanv58?t=120
> 
> Here is the process you need to follow:
> https://youtu.be/nc6JMNanv58?t=163
> 
> 
> -Tim
> 
> 
> 
> 
> 
> 
> Timothy Penner
> Senior Technical Services Engineer
> 
> 4D Inc
> 95 S. Market Street, Suite #240
> CA 95113 San Jose
> United States
> 
> Téléphone : +1-408-557-4600
> Standard :  +1-408-557-4600
> Fax :   +1-408-271-5080
> Email : tpen...@4d.com
> Web :   www.4D.com
> 
> 
> 
> 
> 
> On 5/15/19, 8:27 AM, "4D_Tech on behalf of John J Foster via 4D_Tech" 
> <4d_tech-boun...@lists.4d.com on behalf of 4d_tech@lists.4d.com> wrote:
> 
>Hi All,
> 
>There’s an implied assumption that Migrating 4d-write documents stored in 
> picture fields will work using the v17 component. I didn't see any caveats as 
> to preparing 4D Wrote docs in earlier versions.
> 
>So, as Randy offered, maybe that’s the correct path. Maybe I should change 
> the docs in 4D v12 from picture fields into blob - either by adding another 
> blob fold to the table or exporting the 4D Write docs to disk.
> 
>Is this the best way to approach 4D Write docs?
> 
>Have others had a similar experience as Randy?
> 
>Thanks for your help,
>John…
> 
> 
> 
>> 4D v17R4 Windows and Macintosh Stand alone and 4D Server
>> I do not have an old 4D Write plugin only the new 4D Write Pro
>> App upgraded from 4D 2012 to 4D V17
>> 
>> I am working on the final v17 conversion piece migrating older 4D Write 
>> saved in picture field to 4D Write Pro saved in object field. I am using the 
>> the code from the component on the blog 
>> "https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component”.
>> 
>> However, as I watch the code in the debugger, this is what I see:
>> 
>> $blob:=_Extract4W7From4DPicture ($1)
>> If (BLOB size($blob)=0)
>> GET PICTURE FORMATS($1;$codecIDs)
>> If (Size of array($codecIDs)=1)
>> If ($codecIDs{1}=".pict”)
>> !!! // makes it to here so “knows” it’s a pict.
>> $blob:=_Extract4W7FromMacPicture ($1)
>> !!! // returns an empty blob
>> End if
>> End if
>> End if
>> 
>> Inside this routine "Extract4W7FromMacPicture ($1)” this line executes
>> 
>> PICTURE TO BLOB($1;$blob;"PICT")
>> 
>> Always returns an empty blob even though $1 is a picture with a size like 
>> 25ko.
>> 
>> So not sure what;’s going on and why it doesn’t work.
>> 
>> Does anyone have any experience with converting an older 4D Write saved in a 
>> picture field into a 4D Write Pro object?
>> 
>> Appreciate,
>> John…
>> 
>> 
>> 
>> 
> 
>**
>4D Internet Users Group (4D iNUG)
>Archive:  http://lists.4d.com/archives.html
>Options: https://lists.4d.com/mailman/options/4d_tech
>Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
>**
> 
> 

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-15 Thread Timothy Penner via 4D_Tech
Hi John,

Video Tip: Converting 4D Write documents to 4D Write Pro
https://kb.4d.com/assetid=77703

Here is the section about converting 4D Write documents stored in Picture 
fields.
https://youtu.be/nc6JMNanv58?t=120

Here is the process you need to follow:
https://youtu.be/nc6JMNanv58?t=163


-Tim







On 5/15/19, 8:27 AM, "4D_Tech on behalf of John J Foster via 4D_Tech" 
<4d_tech-boun...@lists.4d.com on behalf of 4d_tech@lists.4d.com> wrote:

Hi All,

There’s an implied assumption that Migrating 4d-write documents stored in 
picture fields will work using the v17 component. I didn't see any caveats as 
to preparing 4D Wrote docs in earlier versions.

So, as Randy offered, maybe that’s the correct path. Maybe I should change 
the docs in 4D v12 from picture fields into blob - either by adding another 
blob fold to the table or exporting the 4D Write docs to disk.

Is this the best way to approach 4D Write docs?

Have others had a similar experience as Randy?

Thanks for your help,
John…



> 4D v17R4 Windows and Macintosh Stand alone and 4D Server
> I do not have an old 4D Write plugin only the new 4D Write Pro
> App upgraded from 4D 2012 to 4D V17
>
> I am working on the final v17 conversion piece migrating older 4D Write 
saved in picture field to 4D Write Pro saved in object field. I am using the 
the code from the component on the blog 
"https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component”.
>
> However, as I watch the code in the debugger, this is what I see:
>
> $blob:=_Extract4W7From4DPicture ($1)
> If (BLOB size($blob)=0)
> GET PICTURE FORMATS($1;$codecIDs)
> If (Size of array($codecIDs)=1)
> If ($codecIDs{1}=".pict”)
> !!! // makes it to here so “knows” it’s a pict.
> $blob:=_Extract4W7FromMacPicture ($1)
> !!! // returns an empty blob
> End if
> End if
> End if
>
> Inside this routine "Extract4W7FromMacPicture ($1)” this line executes
>
> PICTURE TO BLOB($1;$blob;"PICT")
>
> Always returns an empty blob even though $1 is a picture with a size like 
25ko.
>
> So not sure what;’s going on and why it doesn’t work.
>
> Does anyone have any experience with converting an older 4D Write saved 
in a picture field into a 4D Write Pro object?
>
> Appreciate,
> John…
>
>
>
>

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-15 Thread John J Foster via 4D_Tech
Hi All,

There’s an implied assumption that Migrating 4d-write documents stored in 
picture fields will work using the v17 component. I didn't see any caveats as 
to preparing 4D Wrote docs in earlier versions.

So, as Randy offered, maybe that’s the correct path. Maybe I should change the 
docs in 4D v12 from picture fields into blob - either by adding another blob 
fold to the table or exporting the 4D Write docs to disk.

Is this the best way to approach 4D Write docs?

Have others had a similar experience as Randy?

Thanks for your help,
John…



> 4D v17R4 Windows and Macintosh Stand alone and 4D Server
> I do not have an old 4D Write plugin only the new 4D Write Pro
> App upgraded from 4D 2012 to 4D V17
> 
> I am working on the final v17 conversion piece migrating older 4D Write saved 
> in picture field to 4D Write Pro saved in object field. I am using the the 
> code from the component on the blog 
> "https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component”.
> 
> However, as I watch the code in the debugger, this is what I see:
> 
> $blob:=_Extract4W7From4DPicture ($1)
> If (BLOB size($blob)=0)
>   GET PICTURE FORMATS($1;$codecIDs)
>   If (Size of array($codecIDs)=1)
>   If ($codecIDs{1}=".pict”)
>   !!! // makes it to here so “knows” it’s a pict.
>   $blob:=_Extract4W7FromMacPicture ($1)
>   !!! // returns an empty blob
>   End if 
>   End if 
> End if 
> 
> Inside this routine "Extract4W7FromMacPicture ($1)” this line executes
> 
> PICTURE TO BLOB($1;$blob;"PICT") 
> 
> Always returns an empty blob even though $1 is a picture with a size like 
> 25ko.
> 
> So not sure what;’s going on and why it doesn’t work.
> 
> Does anyone have any experience with converting an older 4D Write saved in a 
> picture field into a 4D Write Pro object?
> 
> Appreciate,
> John…
> 
> 
> 
> 

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-14 Thread John J Foster via 4D_Tech
Hi Randy,

Thank you!

I only have two versions to work with for the client. 4D v12 and 4D v17. So if 
these routines work in 4D v12 I might just try it there.

I’ll try it again tomorrow with fresh eyes.

Appreciate,
John...

> On May 14, 2019, at 3:29 PM, Randy Jaynes  wrote:
> 
> John,
> 
> Not sure about the component you mention, but you most likely have to run 
> this in a 32bit version of v17 in order for it to work.
> 
> I worked through this by creating a method in my v13 structure doing this:
> 
>   
> //-
> ALL RECORDS([Letter])
> 
> $numRecs:=Records in selection([Letter])
> $numRecsStr:=String($numRecs)
> 
> $wr_letter:=WR New offscreen area 
> $path:=Util_File_getPathName (Structure file)+"Letters"+Folder separator
> If (Test path name($path)#Is a folder)
> CREATE FOLDER($path)
> End if 
> 
> For ($i;1;$numRecs)
>If (Picture size([Letter]WR_Letter_)>0)
> 
> //-
> //- LOAD THE LETTER INTO AN OFFSCREEN AREA 
> -
> 
> //-
> WR PICTURE TO AREA ($wr_letter;[Letter]WR_Letter_)
> 
> 
> //-
> //- SAVE THE AREA TO A DOCUMENT  
> -
> 
> //-
> //must have the .4W7 or the WP IMPORT DOCUMENT command will fail in 
> v16+
>   $fileName:=$path+"Letter_"+String([Letter]Letter_PK)+".4w7"
>   WR SAVE DOCUMENT ($wr_letter;$filename;wr 4D Write document)
>End if 
> 
>NEXT RECORD([Letter])
> End for 
> WR DELETE OFFSCREEN AREA ($wr_letter)
>   
> //-
> 
> The advantage here was that I had 4D Write in v13 exporting to its native 
> .4W7 files, and then 4D Write Pro in v17 was smoothly importing and 
> converting the letters.
> 
> Not sure if that will help any, but this process has worked well for dozens 
> of upgrades for our OEM database.
> 
> Randy
> 
> --
> Randy Jaynes
> Senior Programmer and Customer Support
> 
> http://printpoint.com  • 845.687.3741 • PrintPoint, 
> Inc • 57 Ludlow Lane • Palisades, NY 10964 
> Please send all email contacts to supp...@printpoint.com 
> 
> 
> 
>> On May 14, 2019, at 4:56 PM, John J Foster via 4D_Tech <4d_tech@lists.4d.com 
>> > wrote:
>> 
>> Hi All,
>> 
>> 4D v17R4 Windows and Macintosh Stand alone and 4D Server
>> I do not have an old 4D Write plugin only the new 4D Write Pro
>> App upgraded from 4D 2012 to 4D V17
>> 
>> I am working on the final v17 conversion piece migrating older 4D Write 
>> saved in picture field to 4D Write Pro saved in object field. I am using the 
>> the code from the component on the blog 
>> "https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component
>>  
>> ”.
>> 
>> However, as I watch the code in the debugger, this is what I see:
>> 
>> $blob:=_Extract4W7From4DPicture ($1)
>> If (BLOB size($blob)=0)
>>  GET PICTURE FORMATS($1;$codecIDs)
>>  If (Size of array($codecIDs)=1)
>>  If ($codecIDs{1}=".pict”)
>>  !!! // makes it to here so “knows” it’s a pict.
>>  $blob:=_Extract4W7FromMacPicture ($1)
>>  !!! // returns an empty blob
>>  End if 
>>  End if 
>> End if 
>> 
>> Inside this routine "Extract4W7FromMacPicture ($1)” this line executes
>> 
>> PICTURE TO BLOB($1;$blob;"PICT") 
>> 
>> Always returns an empty blob even though $1 is a picture with a size like 
>> 25ko.
>> 
>> So not sure what;’s going on and why it doesn’t work.
>> 
>> Does anyone have any experience with converting an older 4D Write saved in a 
>> picture field into a 4D Write Pro object?
>> 
>> Appreciate,
>> John…
>> 
>> 
>> 
>> 
>> **
>> 4D Internet Users Group (4D iNUG)
>> Archive:  http://lists.4d.com/archives.html 
>> 
>> Options: https://lists.4d.com/mailman/options/4d_tech 
>> 
>> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com 
>> 
>> **
> 

**
4D Internet Users Group (4D 

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-14 Thread Tim Nevels via 4D_Tech
On May 14, 2019, at 5:29 PM, John J Foster wrote:

> 4D v17R4 Windows and Macintosh Stand alone and 4D Server
> I do not have an old 4D Write plugin only the new 4D Write Pro
> App upgraded from 4D 2012 to 4D V17
> 
> I am working on the final v17 conversion piece migrating older 4D Write saved 
> in picture field to 4D Write Pro saved in object field. I am using the the 
> code from the component on the blog 
> "https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component”.
> 
> However, as I watch the code in the debugger, this is what I see:
> 
> $blob:=_Extract4W7From4DPicture ($1)
> If (BLOB size($blob)=0)
>   GET PICTURE FORMATS($1;$codecIDs)
>   If (Size of array($codecIDs)=1)
>   If ($codecIDs{1}=".pict”)
>   !!! // makes it to here so “knows” it’s a pict.
>   $blob:=_Extract4W7FromMacPicture ($1)
>   !!! // returns an empty blob
>   End if 
>   End if 
> End if 
> 
> Inside this routine "Extract4W7FromMacPicture ($1)” this line executes
> 
> PICTURE TO BLOB($1;$blob;"PICT") 
> 
> Always returns an empty blob even though $1 is a picture with a size like 
> 25ko.
> 
> So not sure what;’s going on and why it doesn’t work.
> 
> Does anyone have any experience with converting an older 4D Write saved in a 
> picture field into a 4D Write Pro object?

If you are trying to convert old PICT formatted imaged in 4D Write areas — 
which it appears you are trying to do — you will need QuickTime installed on 
your machine so that it can read the PICT format and put the picture into the 
BLOB. 

Use PICTURE CODEC LIST to see if your machine has QuickTime installed and thus 
available for use. 

https://doc.4d.com/4Dv17/4D/17.1/PICTURE-CODEC-LIST.301-4179097.en.html

You may also have to reactivate QuickTime support with SET DATABASE 
PARAMETER(QuickTime support;…  to get it working.

https://doc.4d.com/4Dv17/4D/17.1/Pictures.300-4179081.en.html

Tim

*
Tim Nevels
Innovative Solutions
785-749-3444
timnev...@mac.com
*

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-14 Thread Randy Jaynes via 4D_Tech
John,

Not sure about the component you mention, but you most likely have to run this 
in a 32bit version of v17 in order for it to work.

I worked through this by creating a method in my v13 structure doing this:

  
//-
ALL RECORDS([Letter])

$numRecs:=Records in selection([Letter])
$numRecsStr:=String($numRecs)

$wr_letter:=WR New offscreen area 
$path:=Util_File_getPathName (Structure file)+"Letters"+Folder separator
If (Test path name($path)#Is a folder)
CREATE FOLDER($path)
End if 

For ($i;1;$numRecs)
   If (Picture size([Letter]WR_Letter_)>0)

//-
//- LOAD THE LETTER INTO AN OFFSCREEN AREA -

//-
WR PICTURE TO AREA ($wr_letter;[Letter]WR_Letter_)


//-
//- SAVE THE AREA TO A DOCUMENT  
-

//-
//must have the .4W7 or the WP IMPORT DOCUMENT command will fail in v16+
  $fileName:=$path+"Letter_"+String([Letter]Letter_PK)+".4w7"
  WR SAVE DOCUMENT ($wr_letter;$filename;wr 4D Write document)
   End if 

   NEXT RECORD([Letter])
End for 
WR DELETE OFFSCREEN AREA ($wr_letter)
  
//-

The advantage here was that I had 4D Write in v13 exporting to its native .4W7 
files, and then 4D Write Pro in v17 was smoothly importing and converting the 
letters.

Not sure if that will help any, but this process has worked well for dozens of 
upgrades for our OEM database.

Randy

--
Randy Jaynes
Senior Programmer and Customer Support

http://printpoint.com  • 845.687.3741 • PrintPoint, Inc 
• 57 Ludlow Lane • Palisades, NY 10964 
Please send all email contacts to supp...@printpoint.com 



> On May 14, 2019, at 4:56 PM, John J Foster via 4D_Tech <4d_tech@lists.4d.com 
> > wrote:
> 
> Hi All,
> 
> 4D v17R4 Windows and Macintosh Stand alone and 4D Server
> I do not have an old 4D Write plugin only the new 4D Write Pro
> App upgraded from 4D 2012 to 4D V17
> 
> I am working on the final v17 conversion piece migrating older 4D Write saved 
> in picture field to 4D Write Pro saved in object field. I am using the the 
> code from the component on the blog 
> "https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component
>  
> ”.
> 
> However, as I watch the code in the debugger, this is what I see:
> 
> $blob:=_Extract4W7From4DPicture ($1)
> If (BLOB size($blob)=0)
>   GET PICTURE FORMATS($1;$codecIDs)
>   If (Size of array($codecIDs)=1)
>   If ($codecIDs{1}=".pict”)
>   !!! // makes it to here so “knows” it’s a pict.
>   $blob:=_Extract4W7FromMacPicture ($1)
>   !!! // returns an empty blob
>   End if 
>   End if 
> End if 
> 
> Inside this routine "Extract4W7FromMacPicture ($1)” this line executes
> 
> PICTURE TO BLOB($1;$blob;"PICT") 
> 
> Always returns an empty blob even though $1 is a picture with a size like 
> 25ko.
> 
> So not sure what;’s going on and why it doesn’t work.
> 
> Does anyone have any experience with converting an older 4D Write saved in a 
> picture field into a 4D Write Pro object?
> 
> Appreciate,
> John…
> 
> 
> 
> 
> **
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html 
> 
> Options: https://lists.4d.com/mailman/options/4d_tech 
> 
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com 
> 
> **

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Migrating 4D Write Pictures to 4D Write Pro Objects

2019-05-14 Thread John J Foster via 4D_Tech
Hi All,

4D v17R4 Windows and Macintosh Stand alone and 4D Server
I do not have an old 4D Write plugin only the new 4D Write Pro
App upgraded from 4D 2012 to 4D V17

I am working on the final v17 conversion piece migrating older 4D Write saved 
in picture field to 4D Write Pro saved in object field. I am using the the code 
from the component on the blog 
"https://blog.4d.com/migrate-4d-write-documents-stored-in-picture-fields/#component”.

However, as I watch the code in the debugger, this is what I see:

$blob:=_Extract4W7From4DPicture ($1)
If (BLOB size($blob)=0)
GET PICTURE FORMATS($1;$codecIDs)
If (Size of array($codecIDs)=1)
If ($codecIDs{1}=".pict”)
!!! // makes it to here so “knows” it’s a pict.
$blob:=_Extract4W7FromMacPicture ($1)
!!! // returns an empty blob
End if 
End if 
End if 

Inside this routine "Extract4W7FromMacPicture ($1)” this line executes

PICTURE TO BLOB($1;$blob;"PICT") 

Always returns an empty blob even though $1 is a picture with a size like 25ko.

So not sure what;’s going on and why it doesn’t work.

Does anyone have any experience with converting an older 4D Write saved in a 
picture field into a 4D Write Pro object?

Appreciate,
John…




**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**