FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin para Harbour/xHarbour ResEdit y Borland 7.4
Posts: 607
Joined: Mon Mar 04, 2013 04:32 PM
ResEdit y Borland 7.4
Posted: Fri May 15, 2020 09:06 PM

Hola amigos:

El titulo es un poco raro, verdad?, pues que no me funciona ResEdit con mi version que he actualizado hace pocos dias de Borland 7.4 , al abrir el .rc me sale el error, en una linea determinada.
Se esperaba cadena de texto. Si borro esta linea me aparece en otra y no hay manera de abrirlo.

Que he hecho despues de volverme loco unas cuantas horas, he caido que habia actualizado Borland 7.0 a 7.4, he vuelto a la version antigua y voila... Todo perfecto.

¿Alquien de vosotros utiliza con exito el Editor ResEdit con Borland 7.4?
¿Se requiere algun tipo de ajuste para que funcione?.

En fin, espero vuestra amable respuesta.

Saludos.

Jose.

Fwh 24.07 64 bits + Harbour 64 bits 3.2dev(r2407221137) + MSVC64
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
Re: ResEdit y Borland 7.4
Posted: Fri May 15, 2020 09:54 PM

Here is my Resource Script Template for Resedit

include <windows.h>

include <commctrl.h>

//#include "resource.h"

ifndef WC_STATIC

define WC_STATIC L"Static"

endif

ifndef MONTHCAL_CLASS

define MONTHCAL_CLASS "SysMonthCal32"

endif

ifndef DATETIMEPICK_CLASS

define DATETIMEPICK_CLASS "SysDateTimePick32"

endif

%RESOURCES%

This template works for me ...

Rick Lipkin

Posts: 607
Joined: Mon Mar 04, 2013 04:32 PM
Re: ResEdit y Borland 7.4
Posted: Sat May 16, 2020 08:14 AM
Hi Rick

Thanks for your interest

Here is mine,
Code (fw): Select all Collapse
#include <winresrc.h>
#include <windows.h>
#include <commctrl.h>

#ifndef WC_TABCONTROL
#define WC_TABCONTROL   "SysTabControl32"
#endif

#ifndef MONTHCAL_CLASS
#define MONTHCAL_CLASS  "SysMonthCal32"
#endif

#ifndef DATETIMEPICK_CLASS
#define DATETIMEPICK_CLASS "SysDateTimePick32"
#endif

#ifndef VOS__WINDOWS32 
#define VOS__WINDOWS32          0x00000004L
#endif

#ifndef VFT_APP
#define VFT_APP                 0x00000001L
#endif

#ifndef VFT2_UNKNOWN
#define VFT2_UNKNOWN            0x00000000L
#endif

#ifdef __FLAT__
1 24 "C:\FWH\SAMPLES\WINXP\WindowsXP.Manifest"
#endif

#ifdef __64__
1 24 "C:\FWH\SAMPLES\WINXP\WindowsXP.Manifest64"
#endif

#include "resource.h"



it works ok in Borland 7.0 and fails in Borland 7.4

and the resource.h
is

Code (fw): Select all Collapse
#ifndef IDC_STATIC
#define IDC_STATIC (-1)
#endif


We are still investigating, I do not think it is the version of Borland 7.4 that I have ...

Jose
Fwh 24.07 64 bits + Harbour 64 bits 3.2dev(r2407221137) + MSVC64
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
Re: ResEdit y Borland 7.4
Posted: Sat May 16, 2020 02:15 PM
Jose

Here is my Borland 7.4 Bcc32c.cfg file


-I"c:\borland\bcc74\include";"c:\borland\bcc74\include\dinkumware64";"c:\borland\bcc74\include\windows\crtl";"c:\borland\bcc74\include\windows\rtl";"c:\borland\bcc74\include\windows\vcl";"c:\borland\bcc74\\include\windows\sdk"
-I"c:\borland\bcc74\include\windows";"c:\borland\bcc74\include\windows\vcl";"c:\borland\bcc74\include\windows\rtl";"c:\borland\bcc74\include\windows\sdk";"c:\borland\bcc74\include\dinkumware64";"c:\borland\bcc74\include\windows\crtl"
-L"c:\borland\bcc74\lib\win32c\release";"c:\borland\bcc74\lib\win32c\release\psdk"

Your Borland path may not be the same



ps ... I usually compile the WindowsXP manifest separate in it's own xplook.rc file which gets compiled in to the .exe

XPlook.rc ..

// Add this to your resources RC file

#ifdef __FLAT__
1 24 ".\WindowsXP.Manifest"
#endif



Rick Lipkin
Posts: 607
Joined: Mon Mar 04, 2013 04:32 PM
Re: ResEdit y Borland 7.4
Posted: Sun May 17, 2020 10:47 AM
Dear Rick

In my Borland 7.4 version 32 bits downloaded from friend Mel's website
folders do not exist.

Code (fw): Select all Collapse
c:\borland\bcc74\include\windows\rtl";"c:\borland\bcc74\include\windows\vcl


I only have

c:\bcc7\include\Windows\sdk, c:\bcc7\include\Windows\crtl

That is why it gives me an error when opening an .rc file, very strange not ?

however it compiles perfectly without any errors.

don't know, I'm confused, thanks for your help

Jose
Fwh 24.07 64 bits + Harbour 64 bits 3.2dev(r2407221137) + MSVC64
Posts: 607
Joined: Mon Mar 04, 2013 04:32 PM
Re: ResEdit y Borland 7.4
Posted: Sun May 17, 2020 10:59 AM

a rick thing if you use xplook.rc as you join two .rc files to final exe ?

In case the problem is that, it surprises me, but ...

Thanks

Jose

Fwh 24.07 64 bits + Harbour 64 bits 3.2dev(r2407221137) + MSVC64
Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Re: ResEdit y Borland 7.4
Posted: Sun May 17, 2020 02:29 PM
jvtecheto wrote:I only have

c:\bcc7\include\Windows\sdk, c:\bcc7\include\Windows\crtl


You don't need the other folders.

EMG
Posts: 2706
Joined: Fri Oct 07, 2005 01:50 PM
Re: ResEdit y Borland 7.4
Posted: Mon May 18, 2020 01:02 PM
Jose

.rc files are nothing more than text files .. Many years ago I decided to work only with .rc files to build my forms. I came up with a windows batch file to combine all ..rc files into a single monolithic .rc which I then compile into .res.

This is a variant if the rc2dll32.dll.bat file :


@Echo Off

DEL LeaveW32.RC
DEL LeaveW32.RES

COPY *.RC LeaveW32.RC

C:\BORLAND\BCC74\BIN\brcc32 -iC:\BORLAND\BCC74\include -v -iC:\BORLAND\BCC74\include\dinkumware -iC:\BORLAND\BCC74\include\windows\sdk LeaveW32.Rc >Rick.Txt

del *.iL?
del *.map
del *.obj
del *.~rc
del *.rws
:del *.res
del *.tds
echo done!




In case something happens during the .rc compile .. I send the output >Rick.txt. When this batch file is complete two files are created

Leavw32.rc ( monolithic file that has all my .rc's copied into one file) and Leavw32.Res

The .res file gets linked into the application... The reason I do it this way is I had a huge .rc file that I kept working with .. adding new forms all the time. Somewhere along the line my single ( working ) .rc got corrupt and I had to try to debug a huge file ..

I decided to build all my single forms into .rc and then copy them all together during the final compile .. I found the above script so much easier to work with as it re-builds the single monolithic .rc file each time I build the project.

Hope that makes sense.

Rick Lipkin
Posts: 1789
Joined: Tue Oct 11, 2005 05:01 PM
Re: ResEdit y Borland 7.4
Posted: Mon May 18, 2020 06:18 PM
este es el que uso actualmente con bcc740. recuerden que se debe hacer un cambio en prsht.h
http://forums.fivetechsupport.com/viewtopic.php?f=3&t=34083&p=201802&hilit=prsht.h#p201802


#include <winresrc.h>
#include <windows.h>
#include <commctrl.h>

#ifndef WC_TABCONTROL
#define WC_TABCONTROL "SysTabControl32"
#endif

#ifndef MONTHCAL_CLASS
#define MONTHCAL_CLASS "SysMonthCal32"
#endif

#ifndef DATETIMEPICK_CLASS
#define DATETIMEPICK_CLASS "SysDateTimePick32"
#endif

#ifndef VOS__WINDOWS32
#define VOS__WINDOWS32 0x00000004L
#endif

#ifndef VFT_APP
#define VFT_APP 0x00000001L
#endif

#ifndef VFT2_UNKNOWN
#define VFT2_UNKNOWN 0x00000000L
#endif

#include "%RESOURCE_HEADER%"

%RESOURCES%
Salu2

Carlos Vargas

Desde Managua, Nicaragua (CA)
Posts: 1789
Joined: Tue Oct 11, 2005 05:01 PM
Re: ResEdit y Borland 7.4
Posted: Mon May 18, 2020 06:37 PM
agregue esto y abrio, es raro por que esta en el commctrl.h, hayq ue revisar por que no lo abrio inicialmente


#ifndef NOSTATIC

#ifdef _WIN32

// Static Class Name
#define WC_STATICA "Static"
#define WC_STATICW L"Static"

#ifdef UNICODE
#define WC_STATIC WC_STATICW
#else
#define WC_STATIC WC_STATICA
#endif

#else
#define WC_STATIC "Static"
#endif

#endif // NOSTATIC
Salu2

Carlos Vargas

Desde Managua, Nicaragua (CA)
Posts: 607
Joined: Mon Mar 04, 2013 04:32 PM
Re: ResEdit y Borland 7.4
Posted: Tue May 19, 2020 03:53 PM

Hola amigos:

Muchas gracias a todos por las ideas que me habeis dado sobre los ficheros .rc, tambien me queda claro que el ResEdit es algo anarquico.
pero al final creo que el problema esta en la version de Borland 7.4 del amigo Mel que por lo menos a mi no me funciona del todo bien con ResEdit.
probare a conseguir otra version mas amigable.

Tambien pondre en practica alguna idea de las expuestas, iniciare un nuevo hilo con estos temas para no hacer este tan largo.

Un abrazo a todos.

Jose.

Fwh 24.07 64 bits + Harbour 64 bits 3.2dev(r2407221137) + MSVC64
Posts: 1789
Joined: Tue Oct 11, 2005 05:01 PM
Re: ResEdit y Borland 7.4
Posted: Tue May 19, 2020 04:35 PM

parece que el problema esta en la constante WC_STATIC, buscando en mis rc no encuentro una sola mension. por ello no tengo problemas.

Salu2

Carlos Vargas

Desde Managua, Nicaragua (CA)
Posts: 607
Joined: Mon Mar 04, 2013 04:32 PM
Re: ResEdit y Borland 7.4
Posted: Tue May 19, 2020 07:19 PM
carlos vargas wrote:parece que el problema esta en la constante WC_STATIC, buscando en mis rc no encuentro una sola mension. por ello no tengo problemas.


Hola Carlos, gracias por tu ayuda.

Es que te explico este fichero .rc yo viene de una DLL creada con Borland Resource Workshop de 16 bits.
Ya borre o modifique todos los controles de Borland , pero lo de esa constante, claro al no utilizar nunca ResEdit no sabia que se arrastraba.
Claro, esa constante significara Workshop Control o algo asi.

Probare a borrarla a ver que hace.

Os mantengo informados.

Saludos.
Fwh 24.07 64 bits + Harbour 64 bits 3.2dev(r2407221137) + MSVC64
Posts: 607
Joined: Mon Mar 04, 2013 04:32 PM
Re: ResEdit y Borland 7.4
Posted: Tue May 19, 2020 08:28 PM
jvtecheto wrote:
carlos vargas wrote:parece que el problema esta en la constante WC_STATIC, buscando en mis rc no encuentro una sola mension. por ello no tengo problemas.


Hola Carlos, gracias por tu ayuda.

Es que te explico este fichero .rc yo viene de una DLL creada con Borland Resource Workshop de 16 bits.
Ya borre o modifique todos los controles de Borland , pero lo de esa constante, claro al no utilizar nunca ResEdit no sabia que se arrastraba.
Claro, esa constante significara Workshop Control o algo asi.

Probare a borrarla a ver que hace.

Os mantengo informados.

Saludos.
Carlos si que existe ese estilo prueba a colocar un picture control en un diálogo para rellenarlo con un bitmap, eso es un Wc_static, no se cual es el problema con Bcc 7.0 funciona de lujo. Pero como cambies a 7.4 utilizando los mismos paths todo, al intentar abrir ya da error. Y si que apunta a wc_static pero no veo el error por ninguna parte. Bueno me quedo con 7.0 por ahora.

Enviado desde mi POCOPHONE F1 mediante Tapatalk
Fwh 24.07 64 bits + Harbour 64 bits 3.2dev(r2407221137) + MSVC64
Posts: 1789
Joined: Tue Oct 11, 2005 05:01 PM
Re: ResEdit y Borland 7.4
Posted: Tue May 19, 2020 08:56 PM
simplemente, pon en la plantilla
Code (fw): Select all Collapse
#ifndef WC_STATIC
#define WC_STATIC  "Static"
#endif


ya lo probe aca, sin problemas.

Salu2

Carlos Vargas

Desde Managua, Nicaragua (CA)