Page 1 of 2

ResEdit y Borland 7.4

PostPosted: Fri May 15, 2020 9:06 pm
by jvtecheto
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.

Re: ResEdit y Borland 7.4

PostPosted: Fri May 15, 2020 9:54 pm
by Rick Lipkin
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

Re: ResEdit y Borland 7.4

PostPosted: Sat May 16, 2020 8:14 am
by jvtecheto
Hi Rick

Thanks for your interest

Here is mine,
Code: Select all  Expand view


#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: Select all  Expand view

#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

Re: ResEdit y Borland 7.4

PostPosted: Sat May 16, 2020 2:15 pm
by Rick Lipkin
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

Re: ResEdit y Borland 7.4

PostPosted: Sun May 17, 2020 10:47 am
by jvtecheto
Dear Rick

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

Code: Select all  Expand view

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

Re: ResEdit y Borland 7.4

PostPosted: Sun May 17, 2020 10:59 am
by jvtecheto
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

Re: ResEdit y Borland 7.4

PostPosted: Sun May 17, 2020 2:29 pm
by Enrico Maria Giordano
jvtecheto wrote:I only have

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


You don't need the other folders.

EMG

Re: ResEdit y Borland 7.4

PostPosted: Mon May 18, 2020 1:02 pm
by Rick Lipkin
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

Re: ResEdit y Borland 7.4

PostPosted: Mon May 18, 2020 6:18 pm
by carlos vargas
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%

Re: ResEdit y Borland 7.4

PostPosted: Mon May 18, 2020 6:37 pm
by carlos vargas
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

Re: ResEdit y Borland 7.4

PostPosted: Tue May 19, 2020 3:53 pm
by jvtecheto
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.

Re: ResEdit y Borland 7.4

PostPosted: Tue May 19, 2020 4:35 pm
by carlos vargas
parece que el problema esta en la constante WC_STATIC, buscando en mis rc no encuentro una sola mension. por ello no tengo problemas.

Re: ResEdit y Borland 7.4

PostPosted: Tue May 19, 2020 7:19 pm
by jvtecheto
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.

Re: ResEdit y Borland 7.4

PostPosted: Tue May 19, 2020 8:28 pm
by jvtecheto
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

Re: ResEdit y Borland 7.4

PostPosted: Tue May 19, 2020 8:56 pm
by carlos vargas
simplemente, pon en la plantilla
Code: Select all  Expand view

#ifndef WC_STATIC
#define WC_STATIC  "Static"
#endif
 


ya lo probe aca, sin problemas.

Image