Hello everyone,
? ? ?I'm trying to make a dialog that has some text and my own icon at the left side, I'm using radasm 2.1.0.8.? But when I use the 'preview dialog' button, the icon is not there, and my text is not right either.? below is a snapshot of the before and after 'dialog preview'.? What am I doing wrong?? Well, I would show you my snapshot but don't know how to add a .jpg image, maybe someone can tell me how to do this?
Posted on 2005-03-18 11:46:50 by GorillaCoder
Have you tried EasyCode IDE ?  It has a good resource editor and is very visual in use.

It would be perfect for making a simple dialog application or advance.

http://www.elprogramari.com/English/Assembler/AsmEng.htm

.
Posted on 2005-03-19 05:42:52 by Porkster
Allright, I'll give it a try.? Didn't know that existed.
thanks,
Matt
Posted on 2005-03-19 09:46:51 by GorillaCoder
had more problems with easycoder than with radasm, so if anybody knows why an icon would not show up in a dialog using Radasm, please answer.
Matt
Posted on 2005-03-19 16:12:14 by GorillaCoder
Hi Gorilla,

The preview function of RadASM for dialogs was written by me, I did not include all of the functionality of the dialog as I just needed it to test the tab order. I added a few extra things but for the most part it is just a quick fix for something I needed. The icon in an image box cannot be added via the DialogBoxEx resource as far as I know, you need to load and display it programatically. This presents a problem for the previewer since all it does is copy the dialog to memory and execute it. The source code for the dialog preview addin is available, or if it isn't I will send it to you, so you can modify it to suit your needs if you like or as a start for a whole new preview addin.

I suspect that the text not appearing properly is because it incorrectly detected the dialogs base font, perhaps there is a problem there, I will look into it. Note that the preview funciton can only use the font you have selected for the dialog, none that you might add later via the software (WM_SETFONT)
Posted on 2005-03-19 16:42:34 by donkey
Hello Donkey,
    Thanks for your reply.  dialog source code?  Does this mean that I would have to recompile RadAsm itself to get this feature fixed?  Would'nt I be able to load the icon image for the dialog using the LoadImage function?  You can go ahead and send the source code if it will fix those bugs I mentioned.  What would I use to recopile the source?
Posted on 2005-03-20 14:48:24 by GorillaCoder
Hi

You can find an example on how to put icons and bitmaps on dialogs here:

http://radasm.visualassembler.com/Upload/IcoCtl.zip

KetilO
Posted on 2005-03-20 16:32:46 by KetilO
Ketilo,
    I've looked at this code and can't follow whats going on. And also I'm using FASM for windows and not MASM.  Do you have any commented code that does something like this (or anyone else?) ?
Posted on 2005-03-22 15:58:49 by GorillaCoder

Hello Donkey,
    Thanks for your reply.  dialog source code?  Does this mean that I would have to recompile RadAsm itself to get this feature fixed?  Would'nt I be able to load the icon image for the dialog using the LoadImage function?  You can go ahead and send the source code if it will fix those bugs I mentioned.  What would I use to recopile the source?


Hi GorillaCoder,

The source code is written in GoAsm, which is very close to MASM in syntax. It is available at my website under the "Other RadASM Addins" section. You can look at it if you like but I doubt it will address your needs. As Ketil says, if you want to include images you should look at the example he posted, it addresses these issues directly while the preview addin does not.
Posted on 2005-03-27 21:23:46 by donkey
I'll take another look at the example code, this seems to be the best solution.  I'll reconvert the code to fasm format and go from there.  Thanks everyone for your help. :)
Posted on 2005-04-04 04:57:14 by GorillaCoder