Jump to content

Need help to use GUI edit to redo a func from line 1 to n


Recommended Posts

I have a stupid question, but I try to find it on internet and this forum and got nothing.

This is my example:

I have 10 link:

  • abc.com/mylink/link-1.html
  • abc.com/mylink/link-2.html
  • abc.com/mylink/link-3.html
  • abc.com/mylink/link-4.html
  • ...... to 10
I coded a func to replace abc.com/mylink/link-1.html to 123.com/news/link-1/

I want to code AutoIt redo my func from 1 to 10. But in fact, it's not 10 link, and not like this example. Now I want to use a GUI edit and everytime I coppy n links to it, It'll do the func from first link to n link. And I dont know how to do it ;)

So thank you for helping me and sorry for my bad English!

Link to comment
Share on other sites

Hello Thatgood,

create a GUI with an edit control, and a button,

In the button action add the following or something similar:

$a_data = StringSplit(GUICtrlRead($Edit1), @CRLF, 1)

After this you'll have an array containing the contents of your edit control ($Edit1). Each Array Element is a line of the edit control..

Regards,Hannes[spoiler]If you can't convince them, confuse them![/spoiler]
Link to comment
Share on other sites

Thank you hannes08, I can do it now!

@ searchresult: I dont post my code because I's not error, I just dont know how to do. Now I can do it, if have any other question or my code doesnt work I will post it up!

Thank Autoitscript.com!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...