flat assembler
Message board for the users of flat assembler.

Index > Windows > who knows how to create a resource file and how to compile i

Author
Thread Post new topic Reply to topic
andre



Joined: 27 Sep 2009
Posts: 2
andre 27 Sep 2009, 05:43
it?
Post 27 Sep 2009, 05:43
View user's profile Send private message Send e-mail ICQ Number Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20446
Location: In your JS exploiting you and your system
revolution 27 Sep 2009, 08:59
Have a look in the examples folder of the fasm download zip file. In the DIALOG.ASM example is a resource section:
Code:
...
section '.rsrc' resource data readable

  directory RT_DIALOG,dialogs

  resource dialogs,\
     37,LANG_ENGLISH+SUBLANG_DEFAULT,demonstration

  dialog demonstration,'Create message box',70,70,190,175,WS_CAPTION+WS_POPUP+WS_SYSMENU+DS_MODALFRAME
    dialogitem 'STATIC','&Caption:',-1,10,10,70,8,WS_VISIBLE
    dialogitem 'EDIT','',ID_CAPTION,10,20,170,13,WS_VISIBLE+WS_BORDER+WS_TABSTOP
    dialogitem 'STATIC','&Message:',-1,10,40,70,8,WS_VISIBLE
    dialogitem 'EDIT','',ID_MESSAGE,10,50,170,13,WS_VISIBLE+WS_BORDER+WS_TABSTOP+ES_AUTOHSCROLL
    dialogitem 'BUTTON','&Icon',-1,10,70,80,70,WS_VISIBLE+BS_GROUPBOX
    dialogitem 'BUTTON','&Error',ID_ICONERROR,20,82,60,13,WS_VISIBLE+BS_AUTORADIOBUTTON+WS_TABSTOP+WS_GROUP
    dialogitem 'BUTTON','I&nformation',ID_ICONINFORMATION,20,95,60,13,WS_VISIBLE+BS_AUTORADIOBUTTON
    dialogitem 'BUTTON','&Question',ID_ICONQUESTION,20,108,60,13,WS_VISIBLE+BS_AUTORADIOBUTTON
    dialogitem 'BUTTON','&Warning',ID_ICONWARNING,20,121,60,13,WS_VISIBLE+BS_AUTORADIOBUTTON
    dialogitem 'BUTTON','&Style',-1,100,70,80,70,WS_VISIBLE+BS_GROUPBOX
    dialogitem 'BUTTON','&Top most',ID_TOPMOST,110,82,60,13,WS_VISIBLE+WS_TABSTOP+BS_AUTOCHECKBOX
    dialogitem 'BUTTON','OK',IDOK,85,150,45,15,WS_VISIBLE+WS_TABSTOP+BS_DEFPUSHBUTTON
    dialogitem 'BUTTON','C&ancel',IDCANCEL,135,150,45,15,WS_VISIBLE+WS_TABSTOP+BS_PUSHBUTTON
  enddialog    
Post 27 Sep 2009, 08:59
View user's profile Send private message Visit poster's website Reply with quote
andre



Joined: 27 Sep 2009
Posts: 2
andre 27 Sep 2009, 14:12
It means that you create a dialogue menu in a code and not in a separate standalone file. And what about icons and bitmaps?
Post 27 Sep 2009, 14:12
View user's profile Send private message Send e-mail ICQ Number Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20446
Location: In your JS exploiting you and your system
revolution 27 Sep 2009, 14:19
Have a look at the fasmw source FASMW.ASM for an example of some more resource types.
Post 27 Sep 2009, 14:19
View user's profile Send private message Visit poster's website Reply with quote
shoorick



Joined: 25 Feb 2005
Posts: 1614
Location: Ukraine
shoorick 28 Sep 2009, 05:27
you can create dialogs with ResEdit and convert then rc into fasm format with dlg2fasm converter

you can use WinAsm Studio IDE embedded rc editor with fasm add-in and same converter

you may use any rc editor with later conversion rc->res and including resources as shown here:
Code:
section '.rsrc' resource from 'dialog.res' data readable    
Post 28 Sep 2009, 05:27
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.