Link to home
Start Free TrialLog in
Avatar of CodedK
CodedKFlag for Greece

asked on

Customize net send.

Hi.

When i use net send to create a message there is a title:
"Message from .... to  .... on x/x/xxxx"

Can i remove that ?

Thanks in advance :)
Avatar of heretoread
heretoread

Dont think so, as it would be the server that adds it.
Avatar of CodedK

ASKER

Some time ago i've used a net send wrapper (not NetMessageBufferSend) and i could
send a message using any name i wanted (From value).

Of course at that time i was working with windows 2000. (Is it so different than XP?)

Now i cant find that code since i replace it with NetMessageBufferSend.

I've tried ''NetMessageBufferSend'' and ShellExecute of Net Send ... I cant even change the From value.
Is there a way at least hide the Title ? Or some kind of trick ?
I'm suprised you were able to do that due to the fromname parameter. It has been this way since NT3.5.
Here is MSDN help on that parameter:

fromname
[in] Pointer to a constant string specifying who the message is from. If this parameter is NULL, the message is sent from the local computer name.

Note the last sentance...

There's a demo on how to implement net send at Torry's here http://www.swissdelphicenter.ch/torry/showcode.php?id=617

Regards
Pierre
Avatar of CodedK

ASKER

Hi EddieShipman.

I've tried these 2 ways and i cant replicate this behaviour....
I dont know how this happened but based on that fact i'm asking this question :/
I spend the last 2 hours reading MSDN...
ASKER CERTIFIED SOLUTION
Avatar of Pierre Cornelius
Pierre Cornelius
Flag of South Africa image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
To use the FromName parameter with something other than your registered alias, I believe you need to add an alias first using NetMessageNameAdd.

I have had this working OK on WinXP in an application I wrote for work..
Hmm that also may have been so that messages could be recieved using that alias rather than the computer name.. It has been a while.. :-)
Avatar of CodedK

ASKER

PierreC the wrapper from Borland site can change the from name to anything i like :) !!!!
Thanks !
Is there someway to remove the "Message from .... to  .... on x/x/xxxx" title?
Glad to help.

I don't think you can remove the "Message from .... to  .... on x/x/xxxx" title?
Avatar of CodedK

ASKER

Sorry for not posting.

I found that Process explorer from sysinternals can send
a message to any user and you can change the caption of the message and the title !
OK, I will take alook at the source code and see if I can see how they are doing it.
Oh, I guess they stopped providing source for all their utilities...
Hmmm....
Avatar of CodedK

ASKER

Yes i know. No source.
This example shows at least that it can be done .. :)
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of CodedK

ASKER

:)
Avatar of CodedK

ASKER

Thanks for your time :)