please help me.
Hi Guys,
I'm trying to see if a given series of nines or tens are in a grid of lines, say, 9 x 9, but they won't line up. I'm sure there's a way to do it with what I have so far, and i can't figure it out. I'm using VBA for this.
I have a major problem. I need to figure out a way to reverse the order of a list of 1,2,3,4,5,6,7,8,9 numbers. The numbers are in a column of numbers in an excel spreadsheet.
Hi,
I have a list of 10 strings and I have to check each string for each word whether it contains the right ending word or not. For example, one of the string could be "the stars" and I have to check whether it contains the ending word "stars".
In the first place, I don't know if the word that I need to check it contains at least one vowel.
You are actually better off writing a method in C#, which calls your VB code, and you can do all the filtering in C#. If you want to stick with VBA, you can use the InStr function to get the last word in the string, then either use multiple loops or RegEx, like this:
A couple of notes before we start: First, you need to check for both 'e' and 'i' endings. Second, you can use a character set to help you match multiple characters like this:
if (string.EndsWith("$i")) {
But if you're just doing a simple one word ending check, you don't need to worry about the character set. Third, you can use a RegEx if you want to match more than one character. Fourth, as you mention, this isn't ideal, but you can use an alternation like this:
if (Regex.IsMatch(mystring, @"i|e")) {... }
Fifth, if this is one line in your sheet or workbook, you can use a For Each loop, like this:
I have a string of text that contains a date in this format yyyy-mm-dd hh:mm:ss. What I need is a way to get the parts after the time into a variable.
I need to run some tests
Related links:
Comments