#include <MsgBoxConstants.au3> ; to declare the Constants of MsgBox
Local $sRegex = "(?m)\<\s*[iI][mM][gG]\s+(.*?)src="(?<url>.*?)"(.*?)\/>"
Local $sString = "<h1>问题描述</h1>" & @CRLF & _
"<p>安装 VS 2019 (版本:16.0.2)后,发现更新选项中已经没有 “Entity Framework 6.X 工具” 了,打开 .edmx 文件时,呈现的视图是 xml 视图。</p>" & @CRLF & _
"<p> </p>" & @CRLF & _
"<h1>解决方案</h1>" & @CRLF & _
"<h2>1. 安装扩展</h2>" & @CRLF & _
"<p>扩展程序 <a href="https://marketplace.visualstudio.com/items?itemName=ErikEJ.EntityFramework6PowerToolsCommunityEdition" target="_blank">https://marketplace.visualstudio.com/items?itemName=ErikEJ.EntityFramework6PowerToolsCommunityEdition</a> </p>" & @CRLF & _
"<p> </p>" & @CRLF & _
"<h2>2. 重启 VS</h2>" & @CRLF & _
"<p> </p>" & @CRLF & _
"<h1>截图</h1>" & @CRLF & _
"<p><img src="https://img2018.cnblogs.com/blog/148372/201904/148372-20190429174619331-462329749.png" alt="" /></p>" & @CRLF & _
"<p> </p>" & @CRLF & _
"<p><img src="https://img2018.cnblogs.com/blog/148372/201904/148372-20190429174628181-393603022.png" alt="" /></p>" & @CRLF & _
"<p> </p>"
Local $sSubst = "<a href="${url}" target="_blank"><img src="${url}" width="100%" alt="点击看大图" title="点击看大图" /></a>"
Local $sResult = StringRegExpReplace($sString, $sRegex, $sSubst)
MsgBox($MB_SYSTEMMODAL, "Result", $sResult)
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for AutoIt, please visit: https://www.autoitscript.com/autoit3/docs/functions/StringRegExp.htm