🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

SB_GETTEXT for foreign process

#7900
From: Sam
Date: Tue, 14 Dec 2004 11:15
12 lines
1781 bytes
I need to get the text that contains a statusbar from a foreign process. I need the part 2 of this stausbar, so I have used SB_GETTEXT API for this, but the text is not returned in the buffer. It's strange because the call to SB_GETTEXTLENGTH is okey and it returns the number of bytes for the string required.
I have used too the WM_GETTEXT but it gets only the first part of a statusbar and not the others. Does any one have a solution ?

char sValue[255]={0};
const int _PART2_=1;

    int Len = LOWORD(SendMessage(m_hwndItStatusBar, SB_GETTEXTLENGTH, _PART2_, 0));
    if (Len > 0){
           SendMessage(m_hwndItStatusBar, SB_GETTEXT, _PART2_, (LPARAM)(LPSTR)sValue);
           MemoTest->Text= "The string cpntains <" +IntToStr(Len) + "> characters, the value is <"+ (AnsiString)sValue + ">\r\n";
     }
Technical Details
Message-ID: <41becb6c$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!proxad.net!fr.ip.ndsoftware.net!feeder.enertel.nl!nntpfeed-01.ops.asmr-01.energis-idc.net!216.196.110.149.MISMATCH!border2.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,82208ca2ffb49e6b,start
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Sam" <samir.kneife@laposte.net>
Sender: "Sam" <samir.kneife@laposte.net>
Reply-To: "Sam" <samir.kneife@laposte.net>
Subject: SB_GETTEXT for foreign process
Newsgroups: borland.public.cppbuilder.nativeapi
X-User-Info: 62.56.189.71     
X-Forwarded-For: 10.1.1.22
NNTP-Posting-Host: 207.105.83.66
Message-ID: <41becb6c$1@newsgroups.borland.com>
Date: 14 Dec 2004 03:15:56 -0800
X-Trace: newsgroups.borland.com 1103022956 207.105.83.66 (14 Dec 2004 03:15:56 -0800)
Lines: 12
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!proxad.net!fr.ip.ndsoftware.net!feeder.enertel.nl!nntpfeed-01.ops.asmr-01.energis-idc.net!216.196.110.149.MISMATCH!border2.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail