comp.os.mswindows.programmer.win32
  Home FAQ Contact Sign in
comp.os.mswindows.programmer.win32 only
 
Advanced search
May 2007
motuwethfrsasuw
 123456 18
78910111213 19
14151617181920 20
21222324252627 21
28293031    22
2007
 Jan   Feb   Mar   Apr 
 May   Jun   Jul   Aug 
 Sep   Oct   Nov   Dec 
2008 2007    
total
comp.os ... win32 Profile…
RELATED GROUPS

POPULAR GROUPS

more...

 Up
  Listbox - After Double Click, LB_GETCURSEL returns -1.         


Author: Larry Lindstrom
Date: May 1, 2007 13:54

Hi Folks:

Developing on XP Media, VC6, Win32, no MFC.

The LBN_DBLCLK trap for a single selection listbox sends
LB_GETCURSEL to determine the item that was double clicked.

The value returned from SendMessage is -1.

--------------------

switch (HIWORD (wparam))
{
case LBN_DBLCLK:

selected_item_index = SendMessage(listbox_handle,
LB_GETCURSEL, 0, 0);

--------------------

I've double checked. The listbox handle is correct.

This code was copied from another dialog with a listbox that
receives the correct item index in response to a double click.
Show full article (1.12Kb)
2 Comments
  Re: portable executable with visual studio 2005 ?         


Author: tom87.21
Date: May 1, 2007 02:40

On 22 avr, 17:18, David Lowndes wrote:
>>i made a quite big project with visual studio (C language)
>>but if i bring the executable file that vstudio create to another windows xp
>>platform it doesn't start and an error message tell me to reinstall it..
>>so how can i create a portable .exe?
>>The project uses winsock (ws2_32.dll) and only standard dll filled in by
>>visual studio
>
> It's likely that your application uses the 'C' run-time library (a
> DLL) and it's this that's needed to be installed on the other
> computer. You should have the required redistributable as part of the
> VS installation.
>
> If you don't have any requirement to use the DLL version of the
> run-time you could change your project's settings to use the static
> link library and that...
Show full article (1.21Kb)
no comments