🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #4552

Re: Sending a character string as a message ?

#4552
From: Ed Mulroy
Date: Sun, 08 Jan 2006 14:46
19 lines
1882 bytes
The base way that a string of characters is handled in C and C++ is to 
provide a pointer to the beginning of the string.  The way that memory is 
handled under Win32 is such that a memory address in one program is not a 
valid pointer to the same thing in another program.  Therefore you cannot 
just pass a pointer to the string between programs in the way you do it 
between functions in the same program.  However Windows provides a way to 
get around that limitation.  Look at the help for the message WM_COPYDATA. 
For larger amounts of data look at memory mapped files.

.  Ed

> David wrote in message
> news:43c115e7@newsgroups.borland.com...
>
> This may sound like a dumb question but is it possible to send a string of 
> characters from one app to another using the windows API ??
>
> Currently I am using files to do this but a more direct way would be 
> better.
Technical Details
Message-ID: <43c1257f$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news3.google.com!news2.volia.net!solnet.ch!solnet.ch!news-out.usenet.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
References: <43c115e7@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,f0b09784cee63bed
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Ed Mulroy" <dont_email_me@bitbuc.ket>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <43c115e7@newsgroups.borland.com>
Subject: Re: Sending a character string as a message ?
Date: Sun, 8 Jan 2006 09:46:04 -0500
Lines: 21
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2670
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 69.134.170.196
Message-ID: <43c1257f$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1136731519 69.134.170.196 (8 Jan 2006 06:45:19 -0700)
X-Authenticated-User: edmulroy
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news3.google.com!news2.volia.net!solnet.ch!solnet.ch!news-out.usenet.com!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail