-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bin2Text: Forms with ole controls conversion error #95
Comments
@KestasL Hi, thanks for pointing this out. I will have to look into this - I never used something else then 1252, so all the code page commands are a odd to me. |
@KestasL Some questions please check foxbin2prg, line 1 and 2:
, the file should have a total of 33386 lines
Is this a typo? My guess is you mean 17356.
I see the SCAN .. at line 17459 See https://github.com/fdbozzo/foxbin2prg/blob/master/foxbin2prg.prg But this just a version problem, the issue will be the same. I guess the problem will raise for a vcx as well. I need you testing the problem. I have problems doing this, since it is bound to some ActiveX - and to your codepage. Please report if the problem exists in the vc2 file. |
Hello, same problem with vcx files too. I made the OLE field to be in binary format, and now on mine system everything fine. |
@KestasL Ah, ok for the line numbers and the VCX's. The solution is as you wrote, I just need to learn something about NOCPTRANS to place it optimal. (This is, I have no idea if it must be like
, or if
will be enough (without the code near LINE 17477, because it is just calling it over and over for the same field)) So, would you mind to try it like the code in the second snippet, and without the other NOCPTRANS? Only SCX. |
@KestasL could you please test the foxbin2prg.prg from https://github.com/lscheffler/foxbin2prg ? It should run with vcx and scx. The file is version '1.19.79' on top. Thank you. Update: |
I checked, yes, everything seems to be fine now. |
Fine! |
Hello, |
Thank you! |
Fixed version is available at https://github.com/lscheffler/foxbin2prg, no Thor update provided. |
Lutz, thank you so much for keeping this fixed and up to date. We use it every day to update our code in BitBucket and our whole CI system. It's so amazing that we can use this tool to keep our efforts in FoxPro alive. |
ℹ Computer information
Convert form to sc2 has bug.
If file collation different then 1252 ( in main case 1257) the ole value data is converted with errors and we
can't convert back to scx, sct format.
I solve the issue with modification to ole fields in data tables does not converted:
`
LINE 17365
With This As c_conversor_scx_a_prg Of 'FOXBIN2PRG.PRG'
Use (.c_InputFile) Shared Again Noupdate Alias _TABLAORIG
* [Kestutis Laurinavicius] prevent change ole codepage
SET NOCPTRANS TO ole
Select _TABLAORIG.*,Recno() regnum From _TABLAORIG Into Cursor TABLABIN Readwrite
Use In (Select("_TABLAORIG"))
`
`
LINE 17477
Scan Rest While Upper( TABLABIN.PLATFORM ) = "WINDOWS" And Lower( Alltrim( Getwordnum( TABLABIN.Parent, 1, '.' ) ) ) == Lower(lcObjName)
lnObjCount = lnObjCount + 1
loRegObj = Null
SET NOCPTRANS TO ole
Scatter Memo Name loRegObj
`
I'm not Visual FoxPro expert, so you can come up with more elegant solution.
The text was updated successfully, but these errors were encountered: