Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > microsoft.public.excel.programming > #108858

Re: MID and FIND function in vba

From GS <gs@v.invalid>
Newsgroups microsoft.public.excel.programming
Subject Re: MID and FIND function in vba
Date 2016-06-04 03:18 -0400
Organization A noiseless patient Spider
Message-ID <nitvcj$8b6$1@dont-email.me> (permalink)
References <dc48a761-16d6-4294-ab8f-0a7c927ea178@googlegroups.com>

Show all headers | View raw


Just a hint...

Dim vData, n&, k&

'Load the state - city list into vData,
'Then split each element using the " - " as delimeter
'  and dump the 2nd element into colD...

k = 2 '//1st row of data
With Sheets("Sheet1")
  For n = 1 to UBound(vData)
    .Cells(k, 4) = Split(vData(n, 1), " - ")(1): k = k + 1
  Next 'n
End With

-- 
Garry

Free usenet access at http://www.eternal-september.org
Classic VB Users Regroup!
  comp.lang.basic.visual.misc
  microsoft.public.vb.general.discussion

---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus

Back to microsoft.public.excel.programming | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

MID and FIND function in vba "L. Howard" <lhkittle@comcast.net> - 2016-06-03 17:16 -0700
  Re: MID and FIND function in vba GS <gs@v.invalid> - 2016-06-04 03:18 -0400
    Re: MID and FIND function in vba GS <gs@v.invalid> - 2016-06-04 07:29 -0400
      Re: MID and FIND function in vba GS <gs@v.invalid> - 2016-06-04 07:40 -0400
        Re: MID and FIND function in vba "L. Howard" <lhkittle@comcast.net> - 2016-06-04 14:47 -0700
          Re: MID and FIND function in vba GS <gs@v.invalid> - 2016-06-04 17:56 -0400
            Re: MID and FIND function in vba "L. Howard" <lhkittle@comcast.net> - 2016-06-04 20:18 -0700
              Re: MID and FIND function in vba GS <gs@v.invalid> - 2016-06-05 04:20 -0400
                Re: MID and FIND function in vba "L. Howard" <lhkittle@comcast.net> - 2016-06-05 02:07 -0700
                Re: MID and FIND function in vba GS <gs@v.invalid> - 2016-06-05 07:08 -0400
  Re: MID and FIND function in vba Claus Busch <claus_busch@t-online.de> - 2016-06-04 09:22 +0200
  Re: MID and FIND function in vba GS <gs@v.invalid> - 2016-06-04 03:22 -0400
    Re: MID and FIND function in vba "L. Howard" <lhkittle@comcast.net> - 2016-06-04 02:57 -0700
      Re: MID and FIND function in vba Claus Busch <claus_busch@t-online.de> - 2016-06-04 12:25 +0200
        Re: MID and FIND function in vba "L. Howard" <lhkittle@comcast.net> - 2016-06-04 03:55 -0700
          Re: MID and FIND function in vba Claus Busch <claus_busch@t-online.de> - 2016-06-04 13:16 +0200
            Re: MID and FIND function in vba Claus Busch <claus_busch@t-online.de> - 2016-06-04 13:22 +0200
            Re: MID and FIND function in vba "L. Howard" <lhkittle@comcast.net> - 2016-06-04 14:38 -0700

csiph-web