Solved

I need a vbscript that will take the info in the clipboard and format it then put it back into the clipboard

Posted on 2015-01-20
5
55 Views
Last Modified: 2015-03-25
i need a vbscipt that will look at the below data in the clipboard

BBBBBBLINE1BBBBBBB
BBBBBBLINE2BBBBBBB
BBBBBBLINE3BBBBBBB
BBBBBBLINE4BBBBBBB

and put the 5 characters starting at character 8 and put it in the clipboard with vbcrlf after each line

result
LINE1 & VBCRLF
LINE2& VBCRLF
LINE3& VBCRLF
LINE3& VBCRLF
i cannot install any additional programs.
0
Comment
Question by:rjef
  • 3
  • 2
5 Comments
 
LVL 6

Accepted Solution

by:
oferam earned 500 total points
ID: 40559788
Attached a script that does what you are after.

Notice that in your input example LINE1 starts at position 5 and not 8.
ClipboardExample.vbs
0
 

Author Comment

by:rjef
ID: 40559842
it didn't work
0
 
LVL 6

Expert Comment

by:oferam
ID: 40559855
What happened?

what did you get? VBScript might not be allowed to run.

You can uncommnet the msgbox lines and see where you "get".
0
 

Author Comment

by:rjef
ID: 40559867
it worked if i say allow.  how do i turn that off?
1 then allow then 4 then 3 then 5
0
 

Author Closing Comment

by:rjef
ID: 40687118
thanks
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Introduction During my participation as a VBScript contributor at Experts Exchange, one of the most common questions I come across is this: "I have a script that runs against only one computer. How can I make it run against a list of computers in …
Active Directory replication delay is the cause to many problems.  Here is a super easy script to force Active Directory replication to all sites with by using an elevated PowerShell command prompt, and a tool to verify your changes.
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now