Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Scrape spots and print

Status
Not open for further replies.

StarChip

IS-IT--Management
Jun 24, 2003
3
0
0
US
I have looked for a solution but am having problems getting this to work. I need to take the Name, Address..... info off the screen and send it to a label printer or to at least be able to paste it into the program to print labels.
The problem is the data is not consecutive so I need to scrape different sections and place <cr> into the string to format the data. It would also be nice if it could check if a line is blank before it is added to the label so there are no gaps.
Anyone else tried this??
Thankx in advance.
 
Getting the data is easy, just use the GetString method. If you're unfamiliar with this, check the help files or let me know and I'll go into further detail, but it looks like this in 6.7.

VendorName = Sess0.Screen.GetString(x,y,LengthToGet)

Once you've got the info you're looking for, you can compare it to an empty string to see if it contains data. The Trim function removes both leading and trailing spaces.

If Trim(VendorName) = &quot;&quot; ...

I don't know how you want to send this to the printer. I would suggest you send it to a file, then cut/paste or just open the file in Excel to print.

calculus
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top