NO

Author Topic: Whats wrong with my resources  (Read 3257 times)

hatred

  • Guest
Whats wrong with my resources
« on: December 10, 2014, 10:19:08 AM »
When compile resource.rc & resource.h print this error

#1 resource.h
Code: [Select]
#define IDM_MAIN 100
#define IDM_TRAY 101
// blah-blah-blah

Code: [Select]
POLINK: fatal error: Invalid machine type in object 'E:\projects\c\dogcode\src\resource.h'.
#2 resource.rc
Code: [Select]
#58 CONTROL         "", IDC_TREEVIEW, WC_TREEVIEW, WS_TABSTOP | WS_BORDER | TVS_TRACKSELECT | TVS_INFOTIP | TVS_NOSCROLL | TVS_FULLROWSELECT | TVS_SHOWSELALWAYS, 12, 12, 170, 280, WS_EX_LEFT
#59 CONTROL         "", IDC_LISTVIEW, WC_LISTVIEW, WS_TABSTOP | WS_BORDER | LVS_ALIGNLEFT | LVS_SHOWSELALWAYS | LVS_NOSORTHEADER | LVS_REPORT, 194, 12, 420, 280, WS_EX_LEFT

Code: [Select]
PORC: E:\projects\c\dogcode\src\resource.rc(58): error: String literal expected (found: L"STRING").
PORC: E:\projects\c\dogcode\src\resource.rc(59): error: String literal expected (found: L"STRING").

So what is this??????????

x64 project, UNICODE defined
« Last Edit: December 10, 2014, 12:02:12 PM by hatred »

Offline TimoVJL

  • Global Moderator
  • Member
  • *****
  • Posts: 2107
Re: Whats wrong with my resources
« Reply #1 on: December 10, 2014, 12:08:04 PM »
Code: [Select]
PORC: E:\projects\c\dogcode\src\resource.rc(58): error: String literal expected (found: L"STRING").Remove that L from string ( L"STRING" -> "STRING" ).
May the source be with you

hatred

  • Guest
Re: Whats wrong with my resources
« Reply #2 on: December 10, 2014, 01:25:33 PM »
Problem is that: VS compile this project with no-error, Pelles C gets error when find Unicode strings, and UNICODE define is NOT worked for his resouce compiler

Offline frankie

  • Global Moderator
  • Member
  • *****
  • Posts: 2113
Re: Whats wrong with my resources
« Reply #3 on: December 11, 2014, 10:32:10 AM »
In resources the strings are always unicode, but PellesC porc doesn't recognize the L prefix for unicode.
Can be a minor bug.
"It is better to be hated for what you are than to be loved for what you are not." - Andre Gide