A question on how to use ResEd.

Started by hutch--, October 12, 2009, 01:35:41 PM

Previous topic - Next topic

hutch--

I have just downloaded Resed version 2205 and created a very simple dioalog with two buttons and a group box. I checked the output RC file and it looks fine but when I try to re-open the file with ResEd I get a long list of errors with message boxes.

This is the file output that it appears to be having problems with.


#define IDD_DLG1 1000
#define IDC_BTN1 1001
#define IDC_BTN2 1002
#define  Group Box  1003
#define IDR_VERSION1 1

IDD_DLG1 DIALOGEX 10,10,315,165
CAPTION "Resed Dialog Box"
FONT 10,"MS Sans Serif",700,0,0
STYLE WS_VISIBLE|WS_OVERLAPPEDWINDOW
BEGIN
  CONTROL "IDC_BTN",IDC_BTN1,"Button",WS_CHILDWINDOW|WS_VISIBLE|WS_TABSTOP,267,9,39,12
  CONTROL "IDC_BTN",IDC_BTN2,"Button",WS_CHILDWINDOW|WS_VISIBLE|WS_TABSTOP,267,24,39,12
  CONTROL " Group Box ", Group Box ,"Button",WS_CHILDWINDOW|WS_VISIBLE|BS_GROUPBOX,9,3,249,150
END


When I try to re-open this file I get read errors on the form of the data in the file.
1003 #define
Unknown Resource. Not supported by ResEd.

Line 5 = #define IDR_VERSION1 1
Internal data not supported by ResEd.
Convert this kind of data to files ?

Have I botched something or failed to set something up properly ?
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

rags

Hutch, from what I can tell it's choking on the

#define  Group Box  1003

I think it's the space between group and box that throws things off,
and also causes the version info problems.

I made a similar dialog changed the group box name to "Group Box",
and the darn thing choked.

When I changed the name to "IDC_GRP", all is fine.

Just my ywo cents.
God made Man, but the monkey applied the glue -DEVO

hutch--

Thanks Mike, I will give it a blast. Resed has turned into a nice tool to use so I would like to get it right. I think from memory with the properties box on the right side that I changed the wrong thing instead of the groupbox so this is probably where the mistake occurred.

About 5 minutes later : Yes, that solved the problem, I had messed soomething up in the properties box as I am not used to that style of interface. I have been using oldies for years and they don't do it.

Now i wonder if we could ask Ketil about making the process of handling user mistakes like that a little simpler to use. I have used oldies in the past that would spit the dummy on an incorrect line but load the rest so the error could be fixed from within the editor rather than having to manually fix the RC script.
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

hutch--

Now my next question, I cannot find a combination that will load a file from the command line. I have tried the local file in the current directory RSRC.RC, the full path drv:\dirs\RSRC.RC but it always says it cannot load the file. When it starts I can open the RSRC.RC file from the menu like normal. Does anyone know how to make this work ?
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

akane

Make sure the path is quoted, if contains spaces:
resed "c:\long path name\tar get.rc"
resed c:\shortpathname\target.rc


The path can be quoted even if there are no spaces, as the registry settings go:
HKEY_CURRENT_USER\Software\Classes\.rc
@=rcfile
HKEY_CURRENT_USER\Software\Classes\rcfile\shell\Open\Command
@="D:\ResEd\ResEd 2205.exe" "%1"

hutch--

I know all of this stuff but I still get an error message when starting the resource editor. I have tried it directly from the command line with full paths fully quoted but still get the error message. Interestingly enough it starts in the right directory so you just select "Open" and the file you want is there.
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

KetilO

Hi hutch

I have tested on XP and Vista and it works as it should.
I have no idea why it does not work for you.

Are you using version 2.2.0.5?
What OS are you using?

Version 2.2.0.5b is on its way. It will validate resource id names.

KetilO

hutch--

Ok, I have worked it out, with 2 different command lines in CMD.EXE,


H:\000>h:\resed2205\resed.exe rsrc.rc    ; fails when called from another directory.

H:\000>cd h:\resed2205

H:\resed2205>resed h:\000\rsrc.rc      ; works when called from its own directory.

Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

KetilO

Thancs hutch

This should fix it.

KetilO

hutch--

Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php