Checkbox text disappears Harbour/MSVC

Checkbox text disappears Harbour/MSVC

Postby TimStone » Thu Feb 19, 2015 4:37 pm

I have this problem consistently on a program build using Harbour, FWH, and MSVC 2013 ( or even previous versions ).

The checkbox displays normally, but when I click on a checkbox, the text ( in this case Receipts ) disappears.

I suspect I should be using a different control than BS_AUTOCHECKBOX ... but don't know what it would be. Does anyone have a suggestion ?

From the .prg file:
Code: Select all  Expand view

  REDEFINE CHECKBOX aRpt[1] ID 2037 HELPID 128 ;
      MESSAGE "Daily Totals, and itemized list, for all work completed today" ;
      OF oFld:aDialogs[ 1 ]
 


From the .rc file:
Code: Select all  Expand view

 CONTROL "Receipts", 2037, "Button", BS_AUTOCHECKBOX|WS_TABSTOP, 10, 10, 75, 10
 


Thanks.
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Checkbox text disappears Harbour/MSVC

Postby Enrico Maria Giordano » Thu Feb 19, 2015 6:25 pm

Tim,

TimStone wrote:
Code: Select all  Expand view
CONTROL "Receipts", 2037, "Button", BS_AUTOCHECKBOX|WS_TABSTOP, 10, 10, 75, 10 


This is what I use:

Code: Select all  Expand view
CONTROL "Convenzione:", 102, "BUTTON", BS_AUTOCHECKBOX | BS_LEFTTEXT | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 70, 10, 50, 12


EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Checkbox text disappears Harbour/MSVC

Postby TimStone » Thu Feb 19, 2015 7:08 pm

No, it's the same behavior

Remember, I'm using Microsoft Visual Studio ( VC+ ) and Harbour
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Checkbox text disappears Harbour/MSVC

Postby Antonio Linares » Fri Feb 20, 2015 4:48 am

Tim,

In Fivedit preferences, general, there is a checkbox working fine defined this way:

Code: Select all  Expand view
AUTOCHECKBOX    "Duplicates on functions panel", 110, 16, 58, 109, 8, 0, WS_EX_LEFT


https://bitbucket.org/fivetech/fivewin-contributions/downloads/fivedit.zip
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Checkbox text disappears Harbour/MSVC

Postby Enrico Maria Giordano » Fri Feb 20, 2015 10:00 am

Antonio,

WS_EX_LEFT is 0 so I wonder if it can make any differences...

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Checkbox text disappears Harbour/MSVC

Postby TimStone » Fri Feb 20, 2015 4:54 pm

Using that format in the RC results in the same problem.

When a page of checkboxes appears, the prompts are all there. Check on the checkbox, and the text ( prompt ) goes away.

Remember ... this is FWH with Harbour ( no problem using an older xHarbour.com build ) with MSVC. The problem has been there for a long time and I've mentioned it before.
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Checkbox text disappears Harbour/MSVC

Postby Enrico Maria Giordano » Fri Feb 20, 2015 6:05 pm

Tim,

the problem surely comes from FWH, not from [x]Harbour nor from the C compiler.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Checkbox text disappears Harbour/MSVC

Postby Antonio Linares » Fri Feb 20, 2015 6:49 pm

Tim,

Does this happen only with a checkbox on a folder page ?

Does this also happen with a checkbox on a dialogbox (no folder) ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Checkbox text disappears Harbour/MSVC

Postby Rick Lipkin » Fri Feb 20, 2015 7:11 pm

Tim

I had the same problem with radio buttons and the fix was to add the Group Attribute to the control ..

Rick Lipkin
Code: Select all  Expand view

CHECKBOX "Receipts", 2037, 10, 10, 75, 10, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP
 


Image
User avatar
Rick Lipkin
 
Posts: 2665
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Re: Checkbox text disappears Harbour/MSVC

Postby TimStone » Fri Feb 20, 2015 8:02 pm

Rick: Group doesn't help, and I also tried changing CONTROL to CHECKBOX, as in your example, but it doesn't recognize that.

Antonio: It is on both folders, and dialog, pages. Also, if I check one box, but then go back and check a different one, then the text comes back on the original. So, when a box is checked, then the prompt does not show. If focus goes elsewhere, then it restores the text by the now unchecked box.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Checkbox text disappears Harbour/MSVC

Postby Enrico Maria Giordano » Fri Feb 20, 2015 8:38 pm

Tim,

at this point, we absolutely need a sample showing the problem.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Checkbox text disappears Harbour/MSVC

Postby TimStone » Fri Feb 20, 2015 8:43 pm

Actually, at this point I'm going to revise the .rc file.

I've just looked at the MSDN formatting, which is what Antonio used in the editor. For too long I've carried over the old Borland Resource Editor file with some modifications.

Once I do that I will come back here and we can revisit the issue.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Checkbox text disappears Harbour/MSVC

Postby Antonio Linares » Sat Feb 21, 2015 7:45 am

Tim,

I have started with this simple example and build it using FWH\samples\buildh32.bat that uses MS Visual C

Code: Select all  Expand view
#include "FiveWin.ch"

function Main()

   local oDlg, lValue := .T.

   DEFINE DIALOG oDlg

   @ 2, 2 CHECKBOX lValue PROMPT "Checkbox" OF oDlg SIZE 80, 20

   ACTIVATE DIALOG oDlg CENTERED

return nil


Here it is working fine. Could you build it there also and confirm me that it works fine for you ? thanks

Next step: we will use a RC file to define the dialog.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Checkbox text disappears Harbour/MSVC

Postby TimStone » Sat Feb 21, 2015 7:35 pm

Antonio,

OK ... I added it as a function within the application, and it has the same behavior as I see with the .RC

It shows checked, but click on it and it disappears.

If I add two more checkboxes, the one that is clicked ( checked or unchecked ) does not show the text, but the others do. If I click on a different one, then it loses the text, and the previous one regains it.

I should add that I also see this with Radio buttons. I read Rick's note, but grouping didn't seem to help here.

Tim

Built with Microsoft Visual Studio 2013 ( not a build.bat file ), FWH ( current release ) and Harbour ( current FW release ).
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Checkbox text disappears Harbour/MSVC

Postby Antonio Linares » Sun Feb 22, 2015 7:32 am

Tim,

Are you using themes in your app resources ?

1 24 "WindowsXP.Manifest"
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Next

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 52 guests