bretbouchard / yahoo-finance-managed

Automatically exported from code.google.com/p/yahoo-finance-managed
0 stars 0 forks source link

Option Expiration date specification ignored in Options Download #22

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Use the enclosed .CS file to attempt to download multiple option expirations 
for stock symbol.

What is the expected output? What do you see instead?
- Should display options for different months.
- Displays options for the same month, multiple times.

Do you have other informations?
- Project file attached
- First "OUTPUT" column is option symbol.
- Should change name based on option expiration.
- Ex: TLT110729xxx..., TLT110820xxx..., TLT110917...
- Using latest available yahooManaged.dll
- Running Mono 2.10.2

Suggestions to fix the defect?
- Not sure why the expiration is getting lost.

Original issue reported on code.google.com by eto...@gmail.com on 29 Jul 2011 at 12:46

Attachments:

GoogleCodeExporter commented 8 years ago
What do I need to be able to build in VS or MonoDevelop?  I wanted to fix/debug 
this myself, but I'm unable to build from source. 

Both complain about errors in syntax/get/set properties and other places.

Original comment by eto...@gmail.com on 29 Jul 2011 at 6:24

GoogleCodeExporter commented 8 years ago
I will check this issue.
You'll need VS2010 for that syntax. In VS2010 you can just write:

Puplic Property TestProperty as String = "Test"

That will automatically declare a property and a variable as string and will 
initialize it with a value; without a set/get.
That's not possible in VS2008 (and obviously in MonoDevelop).

Maas

Original comment by Maas...@gmail.com on 30 Jul 2011 at 12:05

GoogleCodeExporter commented 8 years ago
Hi,
the problem was the expiration date parameter format. It only accept the format 
[yyyy-mm]. Actually, when you set a date with a month less than 10 (october) 
the passed format is [yyyy-m]. So, actually only october, november and december 
returns correct results. For other months it will return the newest month 
results.
The fix will be released with next version.

Maas

Original comment by Maas...@gmail.com on 30 Jul 2011 at 8:16

GoogleCodeExporter commented 8 years ago
If you don't want to wait, here the (very simple) solution:
1) Go to QuoteOptionsDownload.DownloadUrl function
2) Replace this:
[...]" AND expiration=""{0}-{1}"""[...]
with this:
[...]" AND expiration=""{0}-{1:00}"""[...]
3) Compile

Maas

Original comment by Maas...@gmail.com on 30 Jul 2011 at 8:20

GoogleCodeExporter commented 8 years ago
Thank you for the help :)

Original comment by eto...@gmail.com on 1 Aug 2011 at 4:52

GoogleCodeExporter commented 8 years ago
Fixed/Done with version 0.9

Original comment by Maas...@gmail.com on 1 Aug 2011 at 9:51