xBrowse shows <Binary> Fieldinfo of a Textfield ?

xBrowse shows <Binary> Fieldinfo of a Textfield ?

Postby ukoenig » Tue May 08, 2012 3:58 pm

Hello,

adding a Text, I get a Fieldinfo <Binary> from the 1. Record.
The DBF-structure is ok, but cannot update the field.
The GET shows the defined text.

The 1. Record

Image

The 2. Record

Image

What could be wrong ?

Best Regards
Uwe :?:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: xBrowse shows <Binary> Fieldinfo of a Textfield ?

Postby nageswaragunupudi » Tue May 08, 2012 6:14 pm

1. What are the exact contents of the field?
2. FWH Version?
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10290
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: xBrowse shows <Binary> Fieldinfo of a Textfield ?

Postby ukoenig » Tue May 08, 2012 6:40 pm

Mr. Rao,

FWH 12.3 xHarbour

opend with a external viewer

MTITLE = C 40

Image

Maybe it happens the first time, after creating a new DBF ( if not exists ) from a Metro-panel-preview.
Closing and reopen, I could change the field and adding new templates.

Image

Best Regards
Uwe :lol:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: xBrowse shows <Binary> Fieldinfo of a Textfield ?

Postby nageswaragunupudi » Tue May 08, 2012 7:24 pm

If xbrowse finds some binary characters then it shows <binary>, unless it is not a valid picture.

I can test if there is any bug in this identification, if I can have the DBF containing the problem text.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10290
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: xBrowse shows <Binary> Fieldinfo of a Textfield ?

Postby ukoenig » Tue May 08, 2012 8:17 pm

Mr. Rao,

another test with some changes filling the 1 record with the vars from the INI-file
after the DBF is created ( still the same result ) all other fields are working fine.
Fieldname MTITLE ( Panel-title )

Image

The Download of the DBF

http://www.pflegeplus.com/fw_downloads/Binary.zip

Creating the new TEMPLATE-dbf and uses the INI to fill the 1. record :

[Windows]
Style=2
1.Color=16443068
2.Color=10899511
GradPos=0.2
Graddirect=.T.
Brush=BluStone.Bmp
Image=Fantasy2.Jpg
[Panel]
Text=Test Title // shows <binary> in xbrowse
Color=65535
Button=120
Caption=TFont():New("@Batang",,-24,.F.,.T.,,,,.T. )
Body=TFont():New("@Gulim",,-16,.F.,.T.,,,,.F. )
Title=TFont():New("Arial",,-24,.F.,.F. ,,,,.F.)


Code: Select all  Expand view

STATIC FUNCTION NEW_DBF()
LOCAL DBFARRAY := {}

AADD(DBFARRAY, { "PROJECT",     "C", 3, 0 })

AADD(DBFARRAY, { "MSTYLE",          "N", 1, 0 })
AADD(DBFARRAY, { "MCOLORF",     "N", 8, 0 })
AADD(DBFARRAY, { "MCOLORB",     "N", 8, 0 })
AADD(DBFARRAY, { "MGRADP",              "N", 5, 2 })
AADD(DBFARRAY, { "MGRADD",              "L", 1, 0 })
AADD(DBFARRAY, { "MBRUSH",          "C", 50, 0 })
AADD(DBFARRAY, { "MIMAGE",          "C", 50, 0 })
AADD(DBFARRAY, { "MTITLE",          "C", 40, 0 })
AADD(DBFARRAY, { "MBTNSIZE",        "N", 3, 0 })
AADD(DBFARRAY, { "MTFONT",          "C", 50, 0 })
AADD(DBFARRAY, { "MTCOLOR",     "N", 8, 0 })
AADD(DBFARRAY, { "CFONT",           "C", 50, 0 })
AADD(DBFARRAY, { "BFONT",           "C", 50, 0 })

// Creates the SAME Var-name and adds a Value to the vars like : COLORF_1, COLORF_2 ......
// this way < 494 > Fields are created
I := 1
FOR I := 1 TO 30 // 30 Buttons created
    xxx := "_" + ALLTRIM(STR(I))
    AADD(DBFARRAY, { "COLORF" + xxx,    "N", 8, 0 })
    AADD(DBFARRAY, { "COLORB" + xxx,    "N", 8, 0 })
    AADD(DBFARRAY, { "CAPTION" + xxx,   "C", 50, 0 })
    AADD(DBFARRAY, { "CAPTCOL" + xxx,   "C", 20, 0 })
    AADD(DBFARRAY, { "ALIGN" + xxx,     "C", 12, 0 })
    AADD(DBFARRAY, { "GROUP" + xxx,     "N", 2, 0 })
    AADD(DBFARRAY, { "BITMAP" + xxx,            "C", 30, 0 })
    AADD(DBFARRAY, { "BMPAL" + xxx,         "C", 12, 0 })
    AADD(DBFARRAY, { "SIZEW" + xxx,     "N", 4, 0 })
    AADD(DBFARRAY, { "SIZEH" + xxx,     "N", 4, 0 })
    AADD(DBFARRAY, { "BODYTXT" + xxx,   "C", 50, 0 })
    AADD(DBFARRAY, { "TXTALGN" + xxx,   "C", 12, 0 })
    AADD(DBFARRAY, { "BACKGRD" + xxx,   "C", 20, 0 })
    AADD(DBFARRAY, { "LARGE" + xxx,     "C", 5, 0 })
    AADD(DBFARRAY, { "MENU" + xxx,      "C", 4, 0 })
    AADD(DBFARRAY, { "ACTION" + xxx,        "C", 6, 0 })
NEXT

cDbfName := c_Path + "\TEMPLATES.DBF"

DELETE FILE &cDbfName

IF LEN(DBFARRAY) == 0
    MsgInfo( "DBF Structure-Error", "New Structure" )
    RETURN NIL
ENDIF

DBCREATE( cDbfName, DBFARRAY )

IF File( cDbfName )
    MsgInfo( "New DBF created ! ( " + ALLTRIM(STR(LEN(DBFARRAY))) + " Fields )", "New Structure" )
ELSE
    MsgAlert( "New Project-File not created !","Project-File")
ENDIF

DBSELECTAREA( 1 )
NET_USE (c_Path + "\TEMPLATES.DBF", 3,5,.T.)  

// Appends 10 Records
// the 1. record is filled with vars from INI-file

I := 1
FOR I := 1 TO 10
    xxx := LTRIM(STR(I))
    NET_APPEND ( 3, 3 )
    IF NET_RLOCK( 5, 5 )
        IF I = 1
            (1)->MSTYLE := nMStyle
            (1)->MCOLORF := nMColorF
            (1)->MCOLORB := nMColorB
            (1)->MGRADP := nMGradpos
            (1)->MGRADD := lMDirect
            (1)->MBRUSH := cMBrush
            (1)->MIMAGE := cMImage
            (1)->MTITLE := cPText // the <binary> Text !!!
            (1)->MBTNSIZE := nPButton
            (1)->MTFONT := cPTFont
            (1)->MTCOLOR := nMTColor
            (1)->CFONT := cPCFont
            (1)->BFONT := cPBFont
        ENDIF
        IF I < 10
            (1)->PROJECT := " " + xxx
        ELSE
            (1)->PROJECT := xxx
        ENDIF
        COMMIT
        NET_ULOCK()
    ENDIF
NEXT
NET_CLOSE ( 3,5,.T.)

RETURN NIL
 


I can save and restore Metro-styles to / from a DBF
There is still my font-problem. to create a font from a DBF-field
The preview of the first record shows, that the Panel-title is ok no < binary>

Image

Best Regards
Uwe :lol:
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 32 guests