Click here to Skip to main content
15,887,267 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Sending mails in VB without Warning(pls help) Pin
Dave Kreskowiak9-Dec-04 1:11
mveDave Kreskowiak9-Dec-04 1:11 
GeneralRe: Sending mails in VB without Warning(pls help) Pin
Boominathan9-Dec-04 18:04
Boominathan9-Dec-04 18:04 
GeneralRe: Sending mails in VB without Warning(pls help) Pin
Dave Kreskowiak10-Dec-04 3:10
mveDave Kreskowiak10-Dec-04 3:10 
GeneralSuspend flexgrid layout while populating data. Pin
mystiqu8-Dec-04 22:54
mystiqu8-Dec-04 22:54 
GeneralRe: Suspend flexgrid layout while populating data. Pin
Jim Matthews9-Dec-04 3:26
Jim Matthews9-Dec-04 3:26 
GeneralSearching text using .net Regular Expression Pin
bahruddina8-Dec-04 22:48
bahruddina8-Dec-04 22:48 
GeneralRe: Searching text using .net Regular Expression Pin
Mekong River8-Dec-04 23:04
Mekong River8-Dec-04 23:04 
GeneralRe: Searching text using .net Regular Expression Pin
Florent Geffroy8-Dec-04 23:29
Florent Geffroy8-Dec-04 23:29 
Hi !

You must use the System.Text.RegularExpressions.Regex class for this.

For string starting with NA, the pattern will be "^NA", ending with NA is "NA$", and containing NA is just "NA". Here's a small sample console application I've made :

Imports System.text.RegularExpressions

Module RegExpTest

    Sub Main()

        Dim Start As String = "NAZERTYUIOP"
        Dim [End] As String = "AZERTYUIOPNA"
        Dim Inside As String = "AZERTNAUIOP"

        Dim rStart As New Regex("^NA")
        Dim rEnd As New Regex("NA$")
        Dim rInside As New Regex("NA")

        Console.WriteLine(rStart.Match(Start).Success)
        Console.WriteLine(rEnd.Match([End]).Success)
        Console.WriteLine(rInside.Match(Inside).Success)

        Console.WriteLine(rEnd.Match(Start).Success)
        Console.WriteLine(rStart.Match([End]).Success)

        Console.ReadLine()

    End Sub

End Module

GeneralRe: Searching text using .net Regular Expression Pin
bahruddina9-Dec-04 0:28
bahruddina9-Dec-04 0:28 
GeneralRe: Searching text using .net Regular Expression Pin
Florent Geffroy9-Dec-04 0:42
Florent Geffroy9-Dec-04 0:42 
GeneralRe: Searching text using .net Regular Expression Pin
bahruddina10-Dec-04 1:09
bahruddina10-Dec-04 1:09 
GeneralWith ... End With block & performance Pin
Florent Geffroy8-Dec-04 22:19
Florent Geffroy8-Dec-04 22:19 
GeneralRe: With ... End With block & performance Pin
Dave Kreskowiak9-Dec-04 1:07
mveDave Kreskowiak9-Dec-04 1:07 
GeneralRe: With ... End With block & performance Pin
Florent Geffroy9-Dec-04 1:19
Florent Geffroy9-Dec-04 1:19 
Generalmultiforms and objects Pin
Nadroj8-Dec-04 20:35
Nadroj8-Dec-04 20:35 
GeneralRe: multiforms and objects Pin
Nadroj8-Dec-04 20:46
Nadroj8-Dec-04 20:46 
Generalhelp please Pin
Member 15740198-Dec-04 19:57
Member 15740198-Dec-04 19:57 
GeneralRe: help please Pin
Dave Kreskowiak9-Dec-04 1:01
mveDave Kreskowiak9-Dec-04 1:01 
GeneralRotating pictures Pin
Don128-Dec-04 18:14
Don128-Dec-04 18:14 
GeneralRe: Rotating pictures Pin
Mekong River8-Dec-04 23:09
Mekong River8-Dec-04 23:09 
GeneralDeployment Pin
nitin_ion8-Dec-04 17:21
nitin_ion8-Dec-04 17:21 
GeneralRe: Deployment Pin
Mekong River8-Dec-04 23:13
Mekong River8-Dec-04 23:13 
GeneralData from two tables Pin
Chaos Machine8-Dec-04 16:22
Chaos Machine8-Dec-04 16:22 
GeneralRe: Data from two tables Pin
J4amieC9-Dec-04 2:52
J4amieC9-Dec-04 2:52 
GeneralRe: Data from two tables Pin
Chaos Machine9-Dec-04 10:52
Chaos Machine9-Dec-04 10:52 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.