For example, download the attached links and save these pictures to the C: directory.
Thanks!
Here is a very simple script that I believe will do what you want
Names Default To Here( 1 ); // Create a list of all of the images imgList = {"http://data2.readoor.cn/files/3211195850f6ae/pdf/9213745e4f7c7b/3/859de8ee2b9187a0e73d764fd53466e4.jpg", "http://data2.readoor.cn/files/3211195850f6ae/pdf/9213745e4f7c7b/3/.........", "http://data2.readoor.cn/files/3211195850f6ae/pdf/9213745e4f7c7b/3/........."}; // Read in and write each of the images For( i = 1, i <= N Items( imgList ), i++, img = Open( imgList[i], jpg ); img << Save Image( "C:\image" || Char( i ) || ".jpg", jpg ); );
The Open() and Save Image() functions are Documented with examples in the Scripting Index.
I used to write it this way, but it didn't work.
request = New HTTP Request( Url("http://data2.readoor.cn/files/3211195850f6ae/pdf/2977675e4e6cb5/3/f0df50279eeaa6465bfaf4e93525e81a.jpg",jpg), Method( "GET" ), ); img = request << Send; img << SaveImage( "C:/1.jpg", jpg );
dt=Current Data Table(); imgList = Column( "url" ) << get values; For( i = 1, i <= N Row(dt), i++, img = Open( imgList[i], jpg ); img << Save Image( "C:\image" || Char( i ) || ".jpg", jpg ); );