-
WSSteve05
AskWoody LoungerCool. Thanks, guys.
-
WSSteve05
AskWoody LoungerCool. Thanks, guys.
-
WSSteve05
AskWoody LoungerWhoops! Found that I could return the array by using the Advanced Filter and choosing unique items. But could you write a custom function in VBA or an Array function to return those unique items?
-
WSSteve05
AskWoody LoungerWhoops! Found that I could return the array by using the Advanced Filter and choosing unique items. But could you write a custom function in VBA or an Array function to return those unique items?
-
WSSteve05
AskWoody LoungerThanks, Hans. I’ll take look.
-
WSSteve05
AskWoody LoungerThanks, Hans. I’ll take look.
-
WSSteve05
AskWoody LoungerHi Hans,
Good to hear from you. Eventually I would need to know both. You can get that information from Format Menu/Tabs. Let me explain what I’m trying to do.
We have a Word document that looks like it is in tab-delimited format, but not quite. This file was arranged using tabs, but it didn’t include a tab where a null value occurred, it just moved the tab over to the next column! Hence, if you try to copy/paste and convert text to table and so on, the information doesn’t align properly. Where a null value occurs, the data shifts to the left.
The only solution I have right now is to create a table and place the information in the corresponding columns. I would do this by first building an array that has all the tab stop positions from the very first row, since no null values exist. Then loop through the data and copy information between the tabs and paste in the appropriate cells. I would have the macro compare the current tab stop position to the position that I’m expecting in the array, which would be incremented by the loop. If the current tab position is greater than the tab position in the array, I know I have a null value. I would then move over one cell within the table and increment the array by one. At least, it sounds plausible.
So to take your example, let’s pretend that I’m showing marks on the page, an left tab on the ruler is the first row “L”, a “T” represents a tab, and a “-” represents a space the tab is extending. (There are no spaces) . And the words in parentheses is the information to be copied. The information would like this:
L L L L
-T(store)–T(Name)–T(IG)–T(AW)
-T(18054)-T(Bob)————-T(Y)What you would get is this:
Store Name IG AW
18054 Bob YWhich is incorrect!
I’ve included a sample. If you can figure out a different solution or how to find the actual tab position of the currently selected tab, that would be fantastic!
Thanks,
-
WSSteve05
AskWoody LoungerHi Hans,
Good to hear from you. Eventually I would need to know both. You can get that information from Format Menu/Tabs. Let me explain what I’m trying to do.
We have a Word document that looks like it is in tab-delimited format, but not quite. This file was arranged using tabs, but it didn’t include a tab where a null value occurred, it just moved the tab over to the next column! Hence, if you try to copy/paste and convert text to table and so on, the information doesn’t align properly. Where a null value occurs, the data shifts to the left.
The only solution I have right now is to create a table and place the information in the corresponding columns. I would do this by first building an array that has all the tab stop positions from the very first row, since no null values exist. Then loop through the data and copy information between the tabs and paste in the appropriate cells. I would have the macro compare the current tab stop position to the position that I’m expecting in the array, which would be incremented by the loop. If the current tab position is greater than the tab position in the array, I know I have a null value. I would then move over one cell within the table and increment the array by one. At least, it sounds plausible.
So to take your example, let’s pretend that I’m showing marks on the page, an left tab on the ruler is the first row “L”, a “T” represents a tab, and a “-” represents a space the tab is extending. (There are no spaces) . And the words in parentheses is the information to be copied. The information would like this:
L L L L
-T(store)–T(Name)–T(IG)–T(AW)
-T(18054)-T(Bob)————-T(Y)What you would get is this:
Store Name IG AW
18054 Bob YWhich is incorrect!
I’ve included a sample. If you can figure out a different solution or how to find the actual tab position of the currently selected tab, that would be fantastic!
Thanks,
-
WSSteve05
AskWoody LoungerAndrew,
Your second post gave me hope! However, I noticed that position returned is not the same as the tab position. For instance, it looks like using:
MsgBox PointsToInches(Selection.Information(wdHorizontalPositionRelativeToPage))
Finds the beginning of the selection, whereas I will need to know where the tab is set.
Am I wearing out my welcome?LOL
-
WSSteve05
AskWoody LoungerAndrew,
Your second post gave me hope! However, I noticed that position returned is not the same as the tab position. For instance, it looks like using:
MsgBox PointsToInches(Selection.Information(wdHorizontalPositionRelativeToPage))
Finds the beginning of the selection, whereas I will need to know where the tab is set.
Am I wearing out my welcome?LOL
-
WSSteve05
AskWoody LoungerThanks for your speedy response!
However, while the tab stops may be indexed, I need to know the position of the CURRENTLY selected tab, not the tab in the first position. I want to use this in conjunction with a find/execute method or MoveUntil method.
Thanks in advance for any assistance. And as always, you guys are awesome.
Best regards,
-
WSSteve05
AskWoody LoungerThanks for your speedy response!
However, while the tab stops may be indexed, I need to know the position of the CURRENTLY selected tab, not the tab in the first position. I want to use this in conjunction with a find/execute method or MoveUntil method.
Thanks in advance for any assistance. And as always, you guys are awesome.
Best regards,
-
WSSteve05
AskWoody LoungerCorrect. I won’t talk about VBA or about using the VBA Editor until possibly another class. (Up to the customer.) There is only material in the book to cover recording a macro and creating custom buttons and toolbars, but there are no examples or labs. I’ll probably use some simple print macros and the draft “watermark”. Thanks for the help.
-
WSSteve05
AskWoody LoungerCorrect. I won’t talk about VBA or about using the VBA Editor until possibly another class. (Up to the customer.) There is only material in the book to cover recording a macro and creating custom buttons and toolbars, but there are no examples or labs. I’ll probably use some simple print macros and the draft “watermark”. Thanks for the help.
-
WSSteve05
AskWoody LoungerI like both ideas. Charlotte, thanks for the demo. Very Clever way of not having to recreate common command buttons over and over again. Mark, wonderful idea of using the subform name + number as an easy way to not hard code the names themselves. Brillant. Right now, I think I will try out Mark’s idea and maybe both of your ideas into my own database. Thanks, again.
![]() |
There are isolated problems with current patches, but they are well-known and documented on this site. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
Rufus is available from the MSFT Store
by
PL1
25 minutes ago -
Microsoft : Ending USB-C® Port Confusion
by
Alex5723
2 hours, 34 minutes ago -
KB5061768 update for Intel vPro processor
by
drmark
16 minutes ago -
Outlook 365 classic has exhausted all shared resources
by
drmark
45 minutes ago -
My Simple Word 2010 Macro Is Not Working
by
mbennett555
17 hours, 46 minutes ago -
Office gets current release
by
Susan Bradley
57 minutes ago -
FBI: Still Using One of These Old Routers? It’s Vulnerable to Hackers
by
Alex5723
1 day, 15 hours ago -
Windows AI Local Only no NPU required!
by
RetiredGeek
23 hours, 32 minutes ago -
Stop the OneDrive defaults
by
CWBillow
1 day, 15 hours ago -
Windows 11 Insider Preview build 27868 released to Canary
by
joep517
2 days, 1 hour ago -
X Suspends Encrypted DMs
by
Alex5723
2 days, 3 hours ago -
WSJ : My Robot and Me AI generated movie
by
Alex5723
2 days, 4 hours ago -
Botnet hacks 9,000+ ASUS routers to add persistent SSH backdoor
by
Alex5723
2 days, 4 hours ago -
OpenAI model sabotages shutdown code
by
Cybertooth
2 days, 5 hours ago -
Backup and access old e-mails after company e-mail address is terminated
by
M W Leijendekker
1 day, 17 hours ago -
Enabling Secureboot
by
ITguy
2 days ago -
Windows hosting exposes additional bugs
by
Susan Bradley
2 days, 13 hours ago -
No more rounded corners??
by
CWBillow
2 days, 9 hours ago -
Android 15 and IPV6
by
Win7and10
1 day, 22 hours ago -
KB5058405 might fail to install with recovery error 0xc0000098 in ACPI.sys
by
Susan Bradley
3 days, 1 hour ago -
T-Mobile’s T-Life App has a “Screen Recording Tool” Turned on
by
Alex5723
3 days, 4 hours ago -
Windows 11 Insider Preview Build 26100.4202 (24H2) released to Release Preview
by
joep517
2 days, 23 hours ago -
Windows Update orchestration platform to update all software
by
Alex5723
3 days, 11 hours ago -
May preview updates
by
Susan Bradley
2 days, 23 hours ago -
Microsoft releases KB5061977 Windows 11 24H2, Server 2025 emergency out of band
by
Alex5723
2 days, 14 hours ago -
Just got this pop-up page while browsing
by
Alex5723
3 days, 3 hours ago -
KB5058379 / KB 5061768 Failures
by
crown
3 days, 1 hour ago -
Windows 10 23H2 Good to Update to ?
by
jkitc
2 days, 3 hours ago -
At last – installation of 24H2
by
Botswana12
4 days, 3 hours ago -
MS-DEFCON 4: As good as it gets
by
Susan Bradley
1 hour, 13 minutes ago
Recent blog posts
Key Links
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.