VBA to replace text + Multiple Tabsheets

Status
Not open for further replies.

billtadz

New Member
Joined
Nov 20, 2020
Messages
29
Office Version
  1. 2016
Platform
  1. Windows
Hi, I have a notepad that contains data - either a bunch of router and switch configurations.
I want to extract a string from this notepad and replace the templates (with configurations) in multiple tab sheets.

For example:

In notepad:

vlan 10
name Data_161.229.58.0

hostname XXX-YYY-ZZZ

interface GigabitEthernet1/0/47
description XXX-YY_MM_YY-ZZZ Gi0/1
no switchport
ip address 10.31.1.34 255.255.255.252


network 10.30.96.32 0.0.0.7 area 1.1.11.1
network 10.31.1.32 0.0.0.3 area 1.1.11.1


snmp-server location [LOC]XXX YYY ZZZ|[ESS]NA|[EOL]311222


one of the tab sheets

vlan 10
name Data_161.229.58.0

sysname XXX-YYY-ZZZ

interface Vlanif947
description XXX-YY_MM_YY-ZZZ G0/0/2
ip address 10.31.1.34 255.255.255.252


area 1.1.11.1
authentication-mode md5 1 cipher branch0$pf
stub no-summary
network 10.30.96.32 0.0.0.7
network 10.31.1.32 0.0.0.3
network 10.31.1.40 0.0.0.3

snmp-agent sys-info location [LOC]XXX YYY ZZZ|[ESS]NA|[EOL]311222

Is this doable with VBA, to simply replace the blue with reds.
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
or I can also copy the notepad texts in available tab sheets.
 
Upvote 0
up for this thread.

Removing the notepad here now. Any advice yet on how to solve this?
 
Upvote 0
Duplicate VBA for Multiple Tab Sheets

Please do not post the same question multiple times. All clarifications, follow-ups, and bumps should be posted back to the original thread.
Per forum rules, posts of a duplicate nature will be locked or deleted (rule 12 here: Forum Rules).
 
Upvote 0
Status
Not open for further replies.

Forum statistics

Threads
1,214,653
Messages
6,120,748
Members
448,989
Latest member
mariah3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top