Комментарии: Функция парсинга данных по тегам https://programistik.top/parsim-dannye-s-sajtov/ Блог начинающего специалиста Fri, 27 Mar 2015 15:49:16 +0000 hourly 1 Автор: Андрей https://programistik.top/parsim-dannye-s-sajtov/#comment-14335 Fri, 27 Mar 2015 15:49:16 +0000 https://programistik.top/?p=83#comment-14335 Не подскажите как фиксировать любое вхождение по маске?
Задача: вытащить из кода все данные в теге ****

]]>
Автор: Евгений https://programistik.top/parsim-dannye-s-sajtov/#comment-12195 Wed, 18 Feb 2015 07:42:48 +0000 https://programistik.top/?p=83#comment-12195 В ответ на Sleytor.

Public Class Form1
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Dim Result As String
Dim url As String = "/search?c[section]=people&c[bday]=10&c[bmonth]=3"
Dim m As Integer
Result = Pars(url, ("[bday]="), ("&c"))
m = Val(url.Last)
MsgBox(Result & " " & MonthName(m)) 'Результат
End Sub
Public Function Pars(ByRef strSource As String, ByRef strStart As String, ByRef strEnd As String) As String
Dim iPos As Integer, iEnd As Integer
Dim strResult As String
iPos = strSource.IndexOf(strStart, 0)
iEnd = strSource.IndexOf(strEnd, iPos + strStart.Length)
If iPos -1 AndAlso iEnd -1 Then
strResult = strSource.Substring(iPos + strStart.Length, iEnd - (iPos + strStart.Length))
End If
Return strResult
End Function
End Class

]]>
Автор: Sleytor https://programistik.top/parsim-dannye-s-sajtov/#comment-11928 Sun, 15 Feb 2015 15:21:20 +0000 https://programistik.top/?p=83#comment-11928 А как выдернуть "10 марта" отсюда: "/search?c[section]=people&c[bday]=10&c[bmonth]=3"

]]>
Автор: Евгений https://programistik.top/parsim-dannye-s-sajtov/#comment-4449 Wed, 20 Nov 2013 18:19:47 +0000 https://programistik.top/?p=83#comment-4449 В ответ на Egor.

Ссылку в студию. Посмотрю, как времечко будет.

]]>
Автор: Egor https://programistik.top/parsim-dannye-s-sajtov/#comment-4448 Wed, 20 Nov 2013 06:45:17 +0000 https://programistik.top/?p=83#comment-4448 Удалось на 80% поскольку криво делают страницы вебмастера.
Может быть Вы свой вариант предложите?

]]>
Автор: Евгений https://programistik.top/parsim-dannye-s-sajtov/#comment-4445 Sun, 17 Nov 2013 09:01:01 +0000 https://programistik.top/?p=83#comment-4445 В ответ на Egor.

На форуме не удалось решить проблему?

]]>
Автор: Egor https://programistik.top/parsim-dannye-s-sajtov/#comment-4442 Sat, 16 Nov 2013 09:15:43 +0000 https://programistik.top/?p=83#comment-4442 Заголовок вытаскивать легко.
Лучше покажите, как вытащить несколько анкоров, чтоб перечисление анкоров было через запятую, они будут для одного URL.
 

]]>