Jump to content

Recommended Posts

Posted

Hello friends.

I am trying to automate downloading from the website www.bseindia.com

the ulr is :::

http://www.bseindia.com/stockinfo/stockprc2_excel.aspx?scripcd=512093&FromDate=09/18/2000&ToDate=09/18/2010&OldDMY=D&ScripName=CRANES

I want to create an application which should ask the user to enter the script id and date range.

It should have the capability to import the list of script ids from a text file, and run at least run 5 threads of the ulr simultaneously.

In the above ulr the script id is 512093 and the date range is from 09/18/2000 to 0918/2010.

Is it possible to write a small programme ?

Safdar

Posted

Hello friends.

I am trying to automate downloading from the website www.bseindia.com

the ulr is :::

http://www.bseindia.com/stockinfo/stockprc2_excel.aspx?scripcd=512093&FromDate=09/18/2000&ToDate=09/18/2010&OldDMY=D&ScripName=CRANES

I want to create an application which should ask the user to enter the script id and date range.

It should have the capability to import the list of script ids from a text file, and run at least run 5 threads of the ulr simultaneously.

In the above ulr the script id is 512093 and the date range is from 09/18/2000 to 0918/2010.

Is it possible to write a small programme ?

Safdar

Lurk the helpfile some more, find the topic type about what you're trying to do.

I'm sure there is a function or UDF for this.

Posted

I have used inetget() with success.

Inetget("http://www.bseindia.com/stockinfo/stockprc2_excel.aspx?scripcd=512093&FromDate=01/18/2010&ToDate=09/18/2010&OldDMY=D&ScripName=CRANES","E:\data\512093.csv")

It has given me a great deal of pleasure, as, me being a compleate newbee, this is my first ever code.

Now I will try to incorporate it somehow in to inputbox().

Thanks for the suggestions.

Safdar

Posted

Kindly Help as I am not able to figure out how to replace "scripcd=512093" from the url to user defined input using iputbox()

$scripcd = InputBox("Question", "Enter the scrip Id")

when the user enters , say, 500410 the "scripcd=512093" in the url should change to 500410

http://www.bseindia.com/stockinfo/stockprc2_excel.aspx?scripcd=512093&FromDate=09/18/2000&ToDate=09/18/2010&OldDMY=D&ScripName=CRANES

Safdar

Posted

when the user enters , say, 500410 the "scripcd=512093" in the url should change to 500410

http://www.bseindia.com/stockinfo/stockprc2_excel.aspx?scripcd=512093&FromDate=09/18/2000&ToDate=09/18/2010&OldDMY=D&ScripName=CRANES

Safdar

you could do like...

$firsturl = "http://www.bseindia.com/stockinfo/stockprc2_excel.aspx?scripcd=512093&FromDate=09/18/2000&ToDate=09/18/2010&OldDMY=D&ScripName=CRANES"
inetget(StringReplace($firsturl,"512093",InputBox("Scripcd","prompt"))

that assumes they're only going to give you the number you're looking for, and only the number has to change...

you could also do like...

$scripcd = InputBox("Question", "Enter the scrip Id")
_IECreate("http://www.bseindia.com/stockinfo/stockprc2_excel.aspx?scripcd=" & $scripcd & "&FromDate=09/18/2000&ToDate=09/18/2010&OldDMY=D&ScripName=CRANES")

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
×
×
  • Create New...