cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
danho13
Level 4

ScrollabeText control not displaying RTF file

Hi All,

I've been struggling with this issue on and off for a little over a week now and have tried every solution I could find both on these forums and on other sites.

The problem I'm having is with a ScrollableText control on a custom dialog. Since I was seemingly blocked from adding the ScrollableText control to a newly created custom dialog, I copied the control from the sdLicense (RTF) dialog and pasted it onto my new dialog.

I then created a very small, very simple RTF file in WordPad and added it to the support files, as per the help/documentation. I then browsed to the source location for the file on the dev machine and added the RTF file as the source of the ScrollableText control. At this point, the control shows the text formatted properly.

I built the installer and ran it and when I got to the dialog the ScrollableText control displayed \License.rtf rather than the text.

This has been particularly vexing as it is very important I be able to display the EULA to the folks installing the software.

I will note that I am using an InstallScript MSI project.

Any help on overcoming this issue would be much appreciated.

Regards,

Daniel
Labels (1)
0 Kudos
(2) Replies
danho13
Level 4

It appears that, maybe, the support files I am using to populate this dialog are not being copied to the "supportdir" location by the time I am wanting to show the dialog (right after welcome, from the "ask dest path" dialog).

It seems likely that is the reason why it is simply showing the file name.

Can someone confirm when the "support" files are supposed to be copied and why they aren't copied by the time OnFirstUIBefore is fired?.

Thanks,

Daniel
0 Kudos
hidenori
Level 17

You need to write code to set the multi-line edit field. The following sample code reads License.rtf located in the support folder and set the contents to the control, SD_MULTEDIT_FIELD1. You may want to add the code to the DLG_INIT event of your custom dialog that displays the Scrollable Text control.

list = ListCreate( STRINGLIST );
if(!ListReadFromFile( list, SUPPORTDIR^"License.rtf" )) then
CtrlSetMLEText( szDlg, SD_MULTEDIT_FIELD1, list );
endif;
ListDestroy( list );
0 Kudos