1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

VBからslackにメッセージ

Last updated at Posted at 2019-02-26

エクセルのVBからSLACKにメッセージ出せないか探して出せた
最初メールだけかと思ってたらいけた
参考:https://became-free.com/vbdotnet-slack-api/
上記参考からslackのページが日本語化進んでて助かる
VB側は
Sub test1()

TargetURL = "https://hooks.slack.com/services/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"
Set httpReq = CreateObject("WinHttp.WinHttpRequest.5.1")
httpReq.Open "POST", TargetURL, False
httpReq.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
httpReq.send ("payload={""text"":""hoge\nエクセルVBからメッセージ""}")

End Sub
こんな感じ

powershell でも同じことできた さらにフックする条件付けて

1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?