Writing message to corp or fleet chat.

I love the feature to warp to safety on a hostile in local chat.  I am sure today alone it has saved me some ships. Oh life in low sec is hard.  Now, I would like the ability to write a warning into corp or fleet chat when these hostiles show up in system.  Is there a way to do that?

Thank you!

It is not yet as simple as it should be. The main problem is setting the input focus to the input box in the chat window as it is not yet present in the interface. I will add it to the Interface in the next release.

In the current version I set the input focus by clicking 10px above the bottom of the chat window. The follwing code does this and also contains the complete method to send a string to the corp chat:

MotionResult MouseClickWithRegionSubstituted(      IUIElement destination,      RectInt region,      MouseButtonIdEnum mouseButton)    =>      Sanderling.MotionExecute(new MotionParam()      {          MouseListWaypoint = new[]{ new MotionParamMouseRegion()          {              UIElement = destination,              RegionReplacement = region,          }},          MouseButton = new[]{mouseButton},      });  MotionResult MouseClickOffsetFromBottomMiddle(     IUIElement destination,     Vektor2DInt offset,     MouseButtonIdEnum mouseButton)    =>     MouseClickWithRegionSubstituted(destination,         RectInt.FromCenterAndSize(new Vektor2DInt(0, destination.Region.Size().B / 2) + offset, new Vektor2DInt(8, 8)),         mouseButton);  void ChatCorpSend(string text) {     var windowChatCorp = Sanderling.MemoryMeasurementParsed?.Value?.WindowChatChannel?.FirstOrDefault(c => c?.Caption?.RegexMatchSuccessIgnoreCase("corp") ?? false);     MouseClickOffsetFromBottomMiddle(windowChatCorp, new Vektor2DInt(0, -10), MouseButtonIdEnum.Left);     Sanderling.TextEntry(text);     Sanderling.KeyboardPress(VirtualKeyCode.RETURN); }

With version 16.02.04, writing a message to chat has become way easier, now you can use this code:

void ChatSendMessage(WindowChatChannel windowChat, string messageText)
     if(null == windowChat) return;


void ChatCorpSendMessage(string messageText) => ChatSendMessage(
        Sanderling.MemoryMeasurementParsed?.Value?.WindowChatChannel?.FirstOrDefault(c => c?.Caption?.RegexMatchSuccessIgnoreCase("corp") ?? false),
1 Like