【发布时间】:2015-05-10 03:21:54
【问题描述】:
您好,我有一个很长的 HTML 文档,这只是我感兴趣的部分:
<iframe class="goog-te-menu-frame skiptranslate" src="javascript:void(0)" frameborder="0" style="display: none; visibility: visible;"></iframe><div class="chatbox3"><div class="chatbox2"><div class="chatbox"><div class="logwrapper" style="top: 89px; margin-right: 168px;"><div class="logbox"><div style="position: relative; min-height: 100%;"><div class="logitem"><p class="statuslog">You're now chatting with a random stranger. Say hi!</p></div><div class="logitem"><p class="strangermsg"><strong class="msgsource">Stranger:</strong> <span>hii there</span></p></div><div class="logitem"><p class="strangermsg"><strong class="msgsource">Stranger:</strong> <span>nice to meet you</span></p></div><div class="logitem"><p class="strangermsg"><strong class="msgsource">Stranger:</strong> <span>this is a text</span></p></div><div class="logitem"><p class="youmsg"><strong class="msgsource">You:</strong> <span>this text should not be taken</span></p></div><div class="logitem"><p class="statuslog">Stranger has disconnected.</p></div><div class="logitem"><div class="statuslog">
输出如下:
你现在正在和一个随机的陌生人聊天。打个招呼!
陌生人:你好陌生人:很高兴见到你陌生人:这是一个文本你:这个文本不应该被占用陌生人已断开连接。我想将Stranger发送的所有消息提取成字符串(Visual Basic),并忽略我发送的消息和You are now chatting with a random stranger. Sai hi!和Stranger has disconnected.等系统消息
我不知道应该如何处理这个问题,需要帮助,谢谢。
【问题讨论】:
-
我投票结束这个问题,因为它似乎是家庭作业/没有尝试任何尝试
标签: html vb.net string chat data-extraction