I have an app that i am developing, it access a website via HttpWebRequest
and HttpWebResponse classes (eg http://thaynann.com/images/) and at the
moment i am able to save all the image files from this page (by grabbing
their URLs and calling WebClient.DownloadData() and save them to my PC), wat
i need to do is to be able to have the applicaiton automatically move to the
next page of images (the issue is that the next page doesnt appear to have
its own URL, it stays at http://thaynann.com/images) and grab the new page of
images and repeat the process to save them.
I have tried lookin at the request and responses that are being used (via
TcpTrace.exe), but i havent had any exp in JavaScript and minimal in HTML
itself, so i get quite lost looking through lines and lines of it
If anyone can help with my problem, that would be much appreciated.
PS, the website isnt real: just used as example
thaynann, 6 1880
Hi,
Most probably the url for the next page is in either a hidden tag, or
embedded in the href of a link , you don't need to use tcptrace, just
analize the page you get,
A tip, using IE get two consecutives pages, save them both ( just the html )
and using diff.exe you may be able to see the parameters being passed.
cheers,
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Thaynann" <Th******@discussions.microsoft.com> wrote in message
news:BC**********************************@microsof t.com... I have an app that i am developing, it access a website via HttpWebRequest and HttpWebResponse classes (eg http://thaynann.com/images/) and at the moment i am able to save all the image files from this page (by grabbing their URLs and calling WebClient.DownloadData() and save them to my PC), wat i need to do is to be able to have the applicaiton automatically move to the next page of images (the issue is that the next page doesnt appear to have its own URL, it stays at http://thaynann.com/images) and grab the new page of images and repeat the process to save them.
I have tried lookin at the request and responses that are being used (via TcpTrace.exe), but i havent had any exp in JavaScript and minimal in HTML itself, so i get quite lost looking through lines and lines of it
If anyone can help with my problem, that would be much appreciated.
PS, the website isnt real: just used as example
thaynann,
Thanx for the reply,
I did wat u suggested and saved 2 consecutve pages through IE, the only
problem i had was, when i saved the html docs (of page 1 and 2), i re-opened
them, and both were of page 1 again, so that leads me to belive that changin
pages would probably be controlled by a JavaScript method somewhere in the
HTML code, i did find a method, (that also appears on the status bar when
then change page button is mouseover (ie...javascript ::ChengePage(3,
Document.DocboxListForm) ), this method is the exact same for all pages, the
3 value does not change, nor does the document one), im not sure if posting
this will be any further help, but it cant hurt to try.
Thanx for your help so far Ignacio.
thaynann
"Ignacio Machin ( .NET/ C# MVP )" wrote: Hi,
Most probably the url for the next page is in either a hidden tag, or embedded in the href of a link , you don't need to use tcptrace, just analize the page you get, A tip, using IE get two consecutives pages, save them both ( just the html ) and using diff.exe you may be able to see the parameters being passed.
cheers,
-- Ignacio Machin, ignacio.machin AT dot.state.fl.us Florida Department Of Transportation "Thaynann" <Th******@discussions.microsoft.com> wrote in message news:BC**********************************@microsof t.com...I have an app that i am developing, it access a website via HttpWebRequest and HttpWebResponse classes (eg http://thaynann.com/images/) and at the moment i am able to save all the image files from this page (by grabbing their URLs and calling WebClient.DownloadData() and save them to my PC), wat i need to do is to be able to have the applicaiton automatically move to the next page of images (the issue is that the next page doesnt appear to have its own URL, it stays at http://thaynann.com/images) and grab the new page of images and repeat the process to save them.
I have tried lookin at the request and responses that are being used (via TcpTrace.exe), but i havent had any exp in JavaScript and minimal in HTML itself, so i get quite lost looking through lines and lines of it
If anyone can help with my problem, that would be much appreciated.
PS, the website isnt real: just used as example
thaynann,
not having much experience in programming with web ascepts....does it matter
that the we files are .CGI files...ie http://thaynann.com/DocList.cgi
"Ignacio Machin ( .NET/ C# MVP )" wrote: Hi,
Most probably the url for the next page is in either a hidden tag, or embedded in the href of a link , you don't need to use tcptrace, just analize the page you get, A tip, using IE get two consecutives pages, save them both ( just the html ) and using diff.exe you may be able to see the parameters being passed.
cheers,
-- Ignacio Machin, ignacio.machin AT dot.state.fl.us Florida Department Of Transportation "Thaynann" <Th******@discussions.microsoft.com> wrote in message news:BC**********************************@microsof t.com...I have an app that i am developing, it access a website via HttpWebRequest and HttpWebResponse classes (eg http://thaynann.com/images/) and at the moment i am able to save all the image files from this page (by grabbing their URLs and calling WebClient.DownloadData() and save them to my PC), wat i need to do is to be able to have the applicaiton automatically move to the next page of images (the issue is that the next page doesnt appear to have its own URL, it stays at http://thaynann.com/images) and grab the new page of images and repeat the process to save them.
I have tried lookin at the request and responses that are being used (via TcpTrace.exe), but i havent had any exp in JavaScript and minimal in HTML itself, so i get quite lost looking through lines and lines of it
If anyone can help with my problem, that would be much appreciated.
PS, the website isnt real: just used as example
thaynann,
Hi,
It does depend of how they did it.
without seen the code of the page (and even so) you can only guess, maybe
the keep in session a "current page" number, then in the html you have a
"back" and "next" which depending of which one is used post the correct
page.
what does the ChangePage method does?
cheers,
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Thaynann" <Th******@discussions.microsoft.com> wrote in message
news:92**********************************@microsof t.com... Thanx for the reply,
I did wat u suggested and saved 2 consecutve pages through IE, the only problem i had was, when i saved the html docs (of page 1 and 2), i re-opened them, and both were of page 1 again, so that leads me to belive that changin pages would probably be controlled by a JavaScript method somewhere in the HTML code, i did find a method, (that also appears on the status bar when then change page button is mouseover (ie...javascript::ChengePage(3, Document.DocboxListForm) ), this method is the exact same for all pages, the 3 value does not change, nor does the document one), im not sure if posting this will be any further help, but it cant hurt to try.
Thanx for your help so far Ignacio.
thaynann
"Ignacio Machin ( .NET/ C# MVP )" wrote:
Hi,
Most probably the url for the next page is in either a hidden tag, or embedded in the href of a link , you don't need to use tcptrace, just analize the page you get, A tip, using IE get two consecutives pages, save them both ( just the html ) and using diff.exe you may be able to see the parameters being passed.
cheers,
-- Ignacio Machin, ignacio.machin AT dot.state.fl.us Florida Department Of Transportation "Thaynann" <Th******@discussions.microsoft.com> wrote in message news:BC**********************************@microsof t.com... >I have an app that i am developing, it access a website via >HttpWebRequest > and HttpWebResponse classes (eg http://thaynann.com/images/) and at the > moment i am able to save all the image files from this page (by > grabbing > their URLs and calling WebClient.DownloadData() and save them to my > PC), > wat > i need to do is to be able to have the applicaiton automatically move > to > the > next page of images (the issue is that the next page doesnt appear to > have > its own URL, it stays at http://thaynann.com/images) and grab the new > page > of > images and repeat the process to save them. > > I have tried lookin at the request and responses that are being used > (via > TcpTrace.exe), but i havent had any exp in JavaScript and minimal in > HTML > itself, so i get quite lost looking through lines and lines of it > > If anyone can help with my problem, that would be much appreciated. > > PS, the website isnt real: just used as example > > thaynann,
Firstly, sorry it took so long for me to reple to this, been off work for a bit
here is teh code for ChangePage() (i didnt write this, i just pulled it out
of files when i ran TcpTrace, it was written by the company who made my fax
machine)
function ChengePage(kind,win) //kind =3, win = document.DoxboxListForm
{
var i;var workInt;var offset;var totalDoc;var BlockSize;var newOffset;
for (i = 0; i < win.length; i++)
{
if(win.elements[i].name == "resultRowBlockSize")
BlockSize = win.elements[i].value;
if(win.elements[i].name == "totalCount")
totalDoc = win.elements[i].value;
if(win.elements[i].name == "offset")
offset = win.elements[i].value;
}
switch( kind )
{
case 1:
newOffset = 0;break;
case 2:
workInt = (offset - 0) - BlockSize;
if( workInt < 0 ) newOffset = 0;
else newOffset = workInt;break;
case 3:
workInt = (offset - 0) + (BlockSize -0);
if( totalDoc < workInt )
{
for( i=1; ;i++ )
{
workInt = 0;
workInt = (offset - 0) - (BlockSize * i);
if( totalDoc > workInt )
newOffset = workInt;break;
}
}
if( totalDoc == workInt ) newOffset = totalDoc - BlockSize;
else newOffset = workInt;break;
case 4:
for( i=1; ;i++)
{
workInt = 0;
workInt = (offset - 0) + (BlockSize * i);
if( totalDoc == workInt )
newOffset = totalDoc - BlockSize;break;
else if( totalDoc < workInt )
newOffset = workInt - BlockSize;break;
else;
}break;
default:
alert(" ***** parameter err ***** ");break;
}
for (i = 0; i < win.length; i++)
{
if (win.elements[i].type == "hidden")
if(win.elements[i].name == "offset")
win.elements[i].value = newOffset;
}
DocumentBoxFormSubmit( 3, win );
}
"Ignacio Machin ( .NET/ C# MVP )" wrote: Hi,
It does depend of how they did it.
without seen the code of the page (and even so) you can only guess, maybe the keep in session a "current page" number, then in the html you have a "back" and "next" which depending of which one is used post the correct page.
what does the ChangePage method does?
cheers,
-- Ignacio Machin, ignacio.machin AT dot.state.fl.us Florida Department Of Transportation
"Thaynann" <Th******@discussions.microsoft.com> wrote in message news:92**********************************@microsof t.com... Thanx for the reply,
I did wat u suggested and saved 2 consecutve pages through IE, the only problem i had was, when i saved the html docs (of page 1 and 2), i re-opened them, and both were of page 1 again, so that leads me to belive that changin pages would probably be controlled by a JavaScript method somewhere in the HTML code, i did find a method, (that also appears on the status bar when then change page button is mouseover (ie...javascript::ChengePage(3, Document.DocboxListForm) ), this method is the exact same for all pages, the 3 value does not change, nor does the document one), im not sure if posting this will be any further help, but it cant hurt to try.
Thanx for your help so far Ignacio.
thaynann
"Ignacio Machin ( .NET/ C# MVP )" wrote:
Hi,
Most probably the url for the next page is in either a hidden tag, or embedded in the href of a link , you don't need to use tcptrace, just analize the page you get, A tip, using IE get two consecutives pages, save them both ( just the html ) and using diff.exe you may be able to see the parameters being passed.
cheers,
-- Ignacio Machin, ignacio.machin AT dot.state.fl.us Florida Department Of Transportation "Thaynann" <Th******@discussions.microsoft.com> wrote in message news:BC**********************************@microsof t.com... >I have an app that i am developing, it access a website via >HttpWebRequest > and HttpWebResponse classes (eg http://thaynann.com/images/) and at the > moment i am able to save all the image files from this page (by > grabbing > their URLs and calling WebClient.DownloadData() and save them to my > PC), > wat > i need to do is to be able to have the applicaiton automatically move > to > the > next page of images (the issue is that the next page doesnt appear to > have > its own URL, it stays at http://thaynann.com/images) and grab the new > page > of > images and repeat the process to save them. > > I have tried lookin at the request and responses that are being used > (via > TcpTrace.exe), but i havent had any exp in JavaScript and minimal in > HTML > itself, so i get quite lost looking through lines and lines of it > > If anyone can help with my problem, that would be much appreciated. > > PS, the website isnt real: just used as example > > thaynann,
Hi,
Where is the code for the function DocumentBoxFormSubmit ?
I think that the key here is a <input type=hidden name=offset> , the
function you shown seems to calculate if you need to move to another page,
if so it update the offset indicator and call later this other
DocumentBoxFormSubmit function, what I have no idea what it does :)
put an alert before submit the page and see the value of offset
cheers,
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Thaynann" <Th******@discussions.microsoft.com> wrote in message
news:99**********************************@microsof t.com... Firstly, sorry it took so long for me to reple to this, been off work for a bit
here is teh code for ChangePage() (i didnt write this, i just pulled it out of files when i ran TcpTrace, it was written by the company who made my fax machine)
function ChengePage(kind,win) //kind =3, win = document.DoxboxListForm { var i;var workInt;var offset;var totalDoc;var BlockSize;var newOffset;
for (i = 0; i < win.length; i++) { if(win.elements[i].name == "resultRowBlockSize") BlockSize = win.elements[i].value; if(win.elements[i].name == "totalCount") totalDoc = win.elements[i].value; if(win.elements[i].name == "offset") offset = win.elements[i].value; } switch( kind ) { case 1: newOffset = 0;break; case 2: workInt = (offset - 0) - BlockSize; if( workInt < 0 ) newOffset = 0; else newOffset = workInt;break; case 3: workInt = (offset - 0) + (BlockSize -0); if( totalDoc < workInt ) { for( i=1; ;i++ ) { workInt = 0; workInt = (offset - 0) - (BlockSize * i); if( totalDoc > workInt ) newOffset = workInt;break; } } if( totalDoc == workInt ) newOffset = totalDoc - BlockSize; else newOffset = workInt;break; case 4: for( i=1; ;i++) { workInt = 0; workInt = (offset - 0) + (BlockSize * i); if( totalDoc == workInt ) newOffset = totalDoc - BlockSize;break; else if( totalDoc < workInt ) newOffset = workInt - BlockSize;break; else; }break; default: alert(" ***** parameter err ***** ");break; } for (i = 0; i < win.length; i++) { if (win.elements[i].type == "hidden") if(win.elements[i].name == "offset") win.elements[i].value = newOffset; } DocumentBoxFormSubmit( 3, win ); }
"Ignacio Machin ( .NET/ C# MVP )" wrote:
Hi,
It does depend of how they did it.
without seen the code of the page (and even so) you can only guess, maybe the keep in session a "current page" number, then in the html you have a "back" and "next" which depending of which one is used post the correct page.
what does the ChangePage method does?
cheers,
-- Ignacio Machin, ignacio.machin AT dot.state.fl.us Florida Department Of Transportation
"Thaynann" <Th******@discussions.microsoft.com> wrote in message news:92**********************************@microsof t.com... > Thanx for the reply, > > I did wat u suggested and saved 2 consecutve pages through IE, the only > problem i had was, when i saved the html docs (of page 1 and 2), i > re-opened > them, and both were of page 1 again, so that leads me to belive that > changin > pages would probably be controlled by a JavaScript method somewhere in > the > HTML code, i did find a method, (that also appears on the status bar > when > then change page button is mouseover (ie...javascript::ChengePage(3, > Document.DocboxListForm) ), this method is the exact same for all > pages, > the > 3 value does not change, nor does the document one), im not sure if > posting > this will be any further help, but it cant hurt to try. > > Thanx for your help so far Ignacio. > > thaynann > > "Ignacio Machin ( .NET/ C# MVP )" wrote: > >> Hi, >> >> Most probably the url for the next page is in either a hidden tag, or >> embedded in the href of a link , you don't need to use tcptrace, just >> analize the page you get, >> A tip, using IE get two consecutives pages, save them both ( just the >> html ) >> and using diff.exe you may be able to see the parameters being passed. >> >> >> cheers, >> >> -- >> Ignacio Machin, >> ignacio.machin AT dot.state.fl.us >> Florida Department Of Transportation >> >> >> >> "Thaynann" <Th******@discussions.microsoft.com> wrote in message >> news:BC**********************************@microsof t.com... >> >I have an app that i am developing, it access a website via >> >HttpWebRequest >> > and HttpWebResponse classes (eg http://thaynann.com/images/) and at >> > the >> > moment i am able to save all the image files from this page (by >> > grabbing >> > their URLs and calling WebClient.DownloadData() and save them to my >> > PC), >> > wat >> > i need to do is to be able to have the applicaiton automatically >> > move >> > to >> > the >> > next page of images (the issue is that the next page doesnt appear >> > to >> > have >> > its own URL, it stays at http://thaynann.com/images) and grab the >> > new >> > page >> > of >> > images and repeat the process to save them. >> > >> > I have tried lookin at the request and responses that are being used >> > (via >> > TcpTrace.exe), but i havent had any exp in JavaScript and minimal in >> > HTML >> > itself, so i get quite lost looking through lines and lines of it >> > >> > If anyone can help with my problem, that would be much appreciated. >> > >> > PS, the website isnt real: just used as example >> > >> > thaynann, >> >> >> This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: François de Dardel |
last post by:
I have a complete Intranet site with about 140 pages using Verdana as
the basic font.
How do I place a table (12 columns) with Arial instead of Verdana, only
for that table. I have defined a style...
|
by: Frostillicus |
last post by:
Hi,
I've written some javascript to randomly choose a classical music composer's
picture and sample audio and display it on my home page
(http://marc.fearby.com/), and this works fine in Mozilla...
|
by: Stefan Finzel |
last post by:
Hi,
is there a way to change the display property on Windows Mobile 2003 SE
Mobile/Pocket Internet Explorer? See following example.
Please note: visibilty property has the same problem.
Is...
|
by: qwerty |
last post by:
I´m new to ASP.Net. My workmate has some experience with it.
He claimed that in ASP.Net working with frames is much simpler than it
was ASP. I asked explanation but he couldn't give me such. (a...
|
by: Joe |
last post by:
Hi,
I have a website with a mix of static (.html) and dynamic pages (.aspx)
pages. I was wondering to change extension .html to .aspx , only to
accommodate future needs of making static pages...
|
by: Steve |
last post by:
I am new to this newsgroup & to .NET in general. I have been playing around
with Visual Studio .NET, building and rendering web pages using VB "code
behind" files. My problem / question is;
How...
|
by: Fokke Nauta |
last post by:
Hi all,
I am searching for a script that can change 2 pages in a frame when clicking
on 1 link.
Example: I have a frameset with 3 pages (content, banner and main).
In the content I want to...
|
by: Martin Slater |
last post by:
Hi all,
I'm using a webbrowser control within an application for the UI and want
to hide the flicker and redraw when changing pages. Ideally I want to
render the new page to a seperate...
|
by: richard |
last post by:
I have <div id=box1 style="display:block"as the initial setting.
I need to change the "display:block" to "display:none" then back to
"display:block" as a means of clearing anything that might be...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
| |