.RC file problems

All announcements, questions and issues related to the Resource Builder
Post Reply
NSanderson
Posts: 15
Joined: Tue Nov 25, 2008 4:27 pm

.RC file problems

Post by NSanderson »

Hi,

The latest version of resource builder seems to be unable to open version of resource script (.RC) files that had previously worked.

Instead of opening the file now, we get an error 11 code returned (empty filename) claiming that an empty <> sequence was encountered.

The < or > symbol do not appear in the file (.rc is text file so can easily be checked) so why would this problem start to happen?

Many thanks,

Neil Sanderson
NSanderson
Posts: 15
Joined: Tue Nov 25, 2008 4:27 pm

Post by NSanderson »

Please note that you can import the resource information from the COM DLL that contains the .RC file either by the File->Import... or the File-Open (type of file set to applications, dynamic link libraries)

Version of Resource Builder is 3.0.0.19.

Thanks,

Neil.
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Hi,

Please send us sample RC file that reproduces this problem.
Best regards,
Igor Siticov.
NSanderson
Posts: 15
Joined: Tue Nov 25, 2008 4:27 pm

.RC file problems

Post by NSanderson »

Hi Igor,

this is the text version of the file. Used in Visual C++ 6.0.

Thanks,

Neil


//Microsoft Developer Studio generated resource script.
//
#include "resource.h"

#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "winres.h"

/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS

/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources

#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32

#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//

1 TEXTINCLUDE DISCARDABLE
BEGIN
"resource.h\0"
END

2 TEXTINCLUDE DISCARDABLE
BEGIN
"#include ""winres.h""\r\n"
"\0"
END

3 TEXTINCLUDE DISCARDABLE
BEGIN
"1 TYPELIB ""NxTillCmpt.tlb""\r\n"
"\0"
END

#endif // APSTUDIO_INVOKED


#ifndef _MAC
/////////////////////////////////////////////////////////////////////////////
//
// Version
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 6,3,0,0
PRODUCTVERSION 6,3,0,0
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x2L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "CompanyName", "Next InStore Systems\0"
VALUE "FileDescription", "NxTillCmpt Module\0"
VALUE "FileVersion", "6, 3, 0, 0\0"
VALUE "InternalName", "NXTILLCMPT\0"
VALUE "LegalCopyright", "Copyright 2001\0"
VALUE "OriginalFilename", "NXTILLCMPT.DLL\0"
VALUE "ProductName", "NxTillCmpt Module\0"
VALUE "ProductVersion", "6, 3, 0, 0\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x409, 1200
END
END

#endif // !_MAC


/////////////////////////////////////////////////////////////////////////////
//
// REGISTRY
//

IDR_NXTILL REGISTRY DISCARDABLE "NxTill.rgs"
IDR_NXTILLTXNITEM REGISTRY DISCARDABLE "NxTillTxnItem.rgs"
IDR_NXSALESCAT REGISTRY DISCARDABLE "NxSalesCat.rgs"
IDR_NXRETURNCAT REGISTRY DISCARDABLE "NxReturnCat.rgs"
IDR_NXINCOMECAT REGISTRY DISCARDABLE "NxIncomeCat.rgs"
IDR_NXPROMOTION REGISTRY DISCARDABLE "NxPromotion.rgs"
IDR_NXTXNREASON REGISTRY DISCARDABLE "NxTxnReason.rgs"
IDR_NXCASHADVCAT REGISTRY DISCARDABLE "NxCashAdvCat.rgs"
IDR_TXNGIFTCARDSCAT REGISTRY DISCARDABLE "NxTxnGiftCardsCat.rgs"
IDR_UNVERIFIEDRETSCAT REGISTRY DISCARDABLE "NxUnverifiedReturnsCat.rgs"

/////////////////////////////////////////////////////////////////////////////
//
// String Table
//

STRINGTABLE DISCARDABLE
BEGIN
IDS_PROJNAME "NxTillCmpt"
END

STRINGTABLE DISCARDABLE
BEGIN
IDS_STORE_RETAIL_ORDER "COLLECT FROM STORE (Retail Order)"
IDS_ORDER_NO "ORDER NO"
IDS_VAT "VAT"
IDS_STORE_DIRECTORY_ORDER "COLLECT FROM STORE (Directory Order)"
IDS_HOME_DIRECTORY_ORDER "DELIVER TO HOME (Directory Order)"
IDS_WITHIN_WORKING_DAYS "WITHIN %d WORKING DAYS"
IDS_SUB_TOTAL "SUB TOTAL"
IDS_TOTAL_VAT "TOTAL VAT"
IDS_FLIGHT_NUMBER "FLIGHT NUMBER"
IDS_REFUND_EXCHANGE_VOUCH "BRANCH REFUND/EXCHANGE VOUCHER"
IDS_DIRECTORY_RETURN_VCHR "DIRECTORY RETURN VOUCHER"
IDS_CUSTOMER_REF_NO_IS "| Your Customer Reference Number is: |"
END

STRINGTABLE DISCARDABLE
BEGIN
IDS_PLEASE_KEEP_THIS_SAFE "Please keep this safe."
IDS_CALL "CALL"
IDS_YOU_CAN_SHOP "| You can shop with the Directory |"
IDS_STRAIGHT_AWAY "| straight away: |"
IDS_WWW_NEXT_CO_UK "| Online www.next.co.uk |"
IDS_FULL_TERMS_CONDITIONS "| For full terms and conditions, please |"
IDS_SEE_COPY_DIRECTORY "| see your copy of the Directory |"
IDS_ADVISED_NEXT "| You will be advised of your NEXT |"
IDS_CUSTOMER_REF_IN_DAYS "| Customer Reference Number in %2d days |"
IDS_PLEASE_CALL "Please call "
IDS_PLACE_ORDER_MEANTIME "| To place an order in the meantime |"
IDS_TOTAL "TOTAL"
IDS_ACCOUNT_NO "Account No:"
END

#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////



#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
1 TYPELIB "NxTillCmpt.tlb"

/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Thanks for the file. Could you please post resource.h also?
Best regards,
Igor Siticov.
NSanderson
Posts: 15
Joined: Tue Nov 25, 2008 4:27 pm

.RC file problems

Post by NSanderson »

Hi Igor,

This is the resource.h file contents:

//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Used by NxTillCmpt.rc
//
#define IDS_PROJNAME 100
#define IDR_NXTILL 101
#define IDR_NXTILLTXN 102
#define IDR_NXTILLTXNITEM 103
#define IDR_NXSALESCAT 104
#define IDR_NXRETURNCAT 105
#define IDR_NXINCOMECAT 106
#define IDR_NXPROMOTION 107
#define IDR_NXTXNREASON 108
#define IDR_NXCASHADVCAT 109
#define IDR_TXNGIFTCARDSCAT 110
#define IDR_UNVERIFIEDRETSCAT 111
#define IDS_STORE_RETAIL_ORDER 116
#define IDS_ORDER_NO 117
#define IDS_VAT 118
#define IDS_STORE_DIRECTORY_ORDER 119
#define IDS_HOME_DIRECTORY_ORDER 120
#define IDS_WITHIN_WORKING_DAYS 121
#define IDS_SUB_TOTAL 122
#define IDS_TOTAL_VAT 123
#define IDS_FLIGHT_NUMBER 124
#define IDS_REFUND_EXCHANGE_VOUCH 125
#define IDS_DIRECTORY_RETURN_VCHR 126
#define IDS_CUSTOMER_REF_NO_IS 127
#define IDS_PLEASE_KEEP_THIS_SAFE 128
#define IDS_CALL 129
#define IDS_YOU_CAN_SHOP 130
#define IDS_STRAIGHT_AWAY 131
#define IDS_WWW_NEXT_CO_UK 132
#define IDS_FULL_TERMS_CONDITIONS 133
#define IDS_SEE_COPY_DIRECTORY 134
#define IDS_ADVISED_NEXT 135
#define IDS_CUSTOMER_REF_IN_DAYS 136
#define IDS_PLEASE_CALL 137
#define IDS_PLACE_ORDER_MEANTIME 138
#define IDS_TOTAL 139
#define IDS_ACCOUNT_NO 140

// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 201
#define _APS_NEXT_COMMAND_VALUE 32768
#define _APS_NEXT_CONTROL_VALUE 201
#define _APS_NEXT_SYMED_VALUE 112
#endif
#endif
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Thanks!

Unfortunately, we're still unable to reproduce the problem. The file opens just fine on our side, BUT we had to remove reference to RGS files and TypeLib. May be you can send the whole set to us by email (support at sicomponents dot com)? Then we will try to reproduce on the similar set as yours.
Best regards,
Igor Siticov.
NSanderson
Posts: 15
Joined: Tue Nov 25, 2008 4:27 pm

.RC file problems

Post by NSanderson »

Hi Igor,

I've made sure that all the include paths are defined in the Compiler Include Directories and removed any references in the Always Include File as I was trying to use this to get round a missing .h file include.

I now get the following error message.

"Error message: File D:\ccm\nectar-nsanderson\nectar\components\nxtillcmpt\NxTillCmpt.rc. Line 10 : 72. Cannot open file "winres.h" (System error code 103). Be sure you have configured Include Paths in Options!"

However, WINRES.H is in the first directory listed in the Include Directories list at "C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE" (I've included the quotes to get round the names with spaces problem)

Why does Resource Builder not see this directory?

If I add "C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\winres.h" back into the Always Include File list, I get the Errorcode 11 Empty Filename error.

Any ideas please?
NSanderson
Posts: 15
Joined: Tue Nov 25, 2008 4:27 pm

.RC file problems

Post by NSanderson »

Hi again Igor,

I've just tried adding C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE into the include paths WITHOUT double quotes.

I now get an error reported:
Error message: File dlgs.h. Line 243 : 1. Cannot open tagCRGB file

I've looked in the dlgs.h file (which WinRes.h includes) and the tagCRGB refers to a type definition.

This is the code in the Microsoft dlgs.h file:

//
// Typedef Declarations.
//
typedef struct tagCRGB
{
BYTE bRed;
BYTE bGreen;
BYTE bBlue;
BYTE bExtra;
} CRGB; /* RGB Color */

Is Resource Builder failing to interpret the typedef statement or am I missing something in the include paths, etc?

Thanks,

Neil.
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

Yes, RB unable to compile typedefs. I can suppose that just by deactivating #include WinRes.h the problem will go away. It includes all defines already defined internally by compiler. You can surround it by #ifdef APSTUDIO_INVOKED/#endif if you wish.
Best regards,
Igor Siticov.
NSanderson
Posts: 15
Joined: Tue Nov 25, 2008 4:27 pm

.RC file problems

Post by NSanderson »

Cheers Igor! That works fine.
Post Reply