comp.os.mswindows.programmer.win32
  Home FAQ Contact Sign in
comp.os.mswindows.programmer.win32 only
 
Advanced search
January 2008
motuwethfrsasuw
 123456 1
78910111213 2
14151617181920 3
21222324252627 4
28293031    5
2008
 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
  Advice for Managing Parent Child Relationships in MDI App?         


Author: Larry Lindstrom
Date: Jan 28, 2008 23:36

Hi Folks:

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

I'm doing my first MDI app. Things are going OK, but I've run
into a little problem, and I'm hoping someone can offer some advice.

Is there some Windows supported mechanism to enforce a parent
child relationship between two windows in an MDI frame? I don't
see anything in the MDICREATESTRUCT that looks promising.

The user selects one of the menu items, and the MDI child
pops up. Let's call this Window A.

A button in Window A is hit and this causes another MDI child
to open. Lets call this Window B.

Window B was created by a button in Window A, and I'd like
Window B to behave as Window A's child.

Now the user selects another item from the menu and a new top
level MDI child pops up. This is Window C.

Window C is now on top of the Z order, obscuring Window A
and it's child, Window B. This is proper behavior.
Show full article (1.93Kb)
5 Comments
  Creating multiple processes         


Author: Andrew Falanga
Date: Jan 28, 2008 15:17

Hi,

When I asked about threads a while ago, several here gave me excellent
help (thanks) but I remember being told by these folks to use
_beginthreadex( ) instead of CreateThread (if memory serves, that's
what I was asking about). Is something like this true for
CreateProcess to? I thought I'd ask before writing too much code
using CreateProcess( ). From the "See Also" section in MSDN, it
doesn't look like there's much else to choose from, but I'm not very
familiar with the Windows development environment.

Thanks,
Andy
4 Comments
  Treminal services and mapped serial ports         


Author: pavel.konyukhov
Date: Jan 28, 2008 10:16

Hi!
I have a question about programming MS Terminal Services.
I'm working on the software that uses mapped serial ports from the
terminal.
The software includes the application which starts while the session
is in the logon process (gina asks the credentials).
The problem comes when I try to reconnect to the disconnected session:
new session, which only serves the logon process is created, the
application reads data from the mapped port
and then this session dies, switching to the existing one.
I need the opened ports to be closed.
As I see, I only can get the notification about the logon session
termination by processing the WM_WTSSESSION_CHANGE message.
But the message is sent asynchronously and it is completely impossible
to close the port correctly before the logon session dies.
After that...
Show full article (0.91Kb)
no comments
  DWM composition + get part of desktop area obscured by a window         


Author:
Date: Jan 28, 2008 00:56

Hi,

What I want is to get desktop's bitmap bits obscured by a window in DMW
composition on mode. Is this achievable from the application level?

Before Vista it was practically undoable, the only desperate attempt I
am aware of is Feng Yuan's "WM_PRINT hook"
(http://www.fengyuan.com/article/wmprint.html). But apart from other
flaws it doesn't support layered windows that do paint themselves using
UpdateLayeredWindow() rather than using Windows WM_PAINT paradigm.

Is this task in Windows Vista with DMW composition turned on any easier?
Needless to say the DMW has all the data to perform easily such
operation, but can this data be exported to the application? The point
is to create custom glass effect (on application level) and for this the
application needs to know the background it lays on.

Thanks,

--
Grzegorz Wróbel
677265676F727940346E6575726F6E732E636F6D
8 Comments
  Re: Convert Windows 1252 to UTF-8?         


Author: Ulrich Eckhardt
Date: Jan 28, 2008 00:15

MrDRamos@hotmail.com wrote:
>>>Does anybody know a way to convert Windows code page 1252 to UTF-8 in
>>>C++?
>>
>>>The idea is ... I have an app that reads files off a user's HARD DRIVE
>>>... assume the user is in the US, so the FILE NAMES ARE 1252 encoded ...

Assuming the user uses MS Windows NT, 2k etc the filenames are encoded in
UCS2/UTF-16, available via the wchar_t win32 APIs.
>>>I have to insert it into a database that expects UTF-8.  Does anybody
>>>know a way to convert the Windows 1252 encoding to UTF-8?

MultibyteToWideChar using CP1252 and the the reverse using UTF-8. Note that
this can be made to work according to the user's current settings, so if I
set my codepage to IS08859-15 (not unusual for a German) it would work just
the same for me. Complete Unicode awareness and use of full-Unicode capable
APIs would be a better choice though, maybe even I have some Chinese
letters in my filenames...
> olsize_t USTR_CP1252_To_Utf8(char* dst_str, olsize_t dst_len,
> const char* src_str, olsize_t src_len)
[...conversion function...]
Show full article (1.43Kb)
no comments