Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Start with no items selected in list box


3 replies to this topic

badejo

badejo
  • Members
  • 12 posts

Posted 14 March 2002 - 17:10

I have a custom dialog with a list box I am calling, and the first item in the list is always selected by default.  I know that there is a was to select the default entry, but I would prefer to leave the list blank so that the user is forced to make a selection instead of just going with the default.

Can anyone think of a way to accomplish this?

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 16 March 2002 - 09:51

Standard or Basic MSI project?

badejo

badejo
  • Members
  • 12 posts

Posted 18 March 2002 - 22:28

It is a Standard project.

The INIT portion of my script is as follows"

case DLG_INIT: // This case will be called initially and should be used to
// initialize any controls in the dialog.

// Initialize the title of the dialog.
if ( szTitle != "" ) then
CtrlSetText( DLG_NAME, TITLE_FIELD, szTitle );  
endif;

// Initialize the description field of the dialog.
if ( szDescription != "" ) then
CtrlSetText( DLG_NAME, DESCRIPTION_FIELD, szDescription );
endif;

   nListResult = (CtrlSetList (DLG_NAME, 1302, nList1));
   if (nListResult = 0) then
     //MessageBox ( "list set successfully", INFORMATION);
   else
     MessageBox ( "CtrlSetList failed.  Installation will abort.", INFORMATION);
     abort;
   endif;

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 18 March 2002 - 23:09

Moved to Developer - Standard Projects