Help using Twitterizer in an indicator - NinjaTrader Programming | futures io social day trading
futures io futures trading


Help using Twitterizer in an indicator
Updated: Views / Replies:1,306 / 7
Created: by cunparis Attachments:0

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

Help using Twitterizer in an indicator

  #1 (permalink)
Trade with the flow
Paris, France
 
Futures Experience: Advanced
Platform: Market Delta & Ninjatrader
Favorite Futures: ES
 
cunparis's Avatar
 
Posts: 2,563 since Jun 2009
Thanks: 1,157 given, 2,030 received

Help using Twitterizer in an indicator

I'm trying to add Twitter capability to an indicator but I'm really stuck. I'm using Twitterizer which seems to be the leading .NET Twitter API.

I've copied their code from the samples:

Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).


And I add a reference to the Twitterizer DLL and it's JSON dependancy:

Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).


But when my code executes I get an error:

Could not load file or assembly 'Twitterizer2, Version=2.4.0.2028, Culture=neutral, PublicKeyToken=xxx' or one of its dependencies. The system cannot find the file specified.
So now I'm stuck. I posted at the ninja forums but so far no response. There are a few other files that come with it, I can't add references to them because they're not DLL files. I put them in the same directory as the twitterizer DLL.

Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).


I think Ninja is not picking these up. I'm not sure where else I can put them.

If anyone has any ideas I'd be very grateful. Thanks.

Reply With Quote
 
  #2 (permalink)
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
  #3 (permalink)
Administrator: Retired Backtester
 Vendor: speedytradingservers.com 
Rennes France
 
Futures Experience: Advanced
Platform: NinjaTrader
Broker/Data: IB/Kinetick
Favorite Futures: Futures
 
sam028's Avatar
 
Posts: 3,366 since Jun 2009
Thanks: 3,573 given, 3,982 received


Twitterizer libs, did you recompile them in .Net 3.5 ?
It's .Net 4.0 by default, that will be your next problem .
I work on this last week, and ended by creating a .Net 4.0 console .exe, called asynchronously byt my NT strats.

Success requires no deodorant! (Sun Tzu)
Reply With Quote
 
  #4 (permalink)
Trade with the flow
Paris, France
 
Futures Experience: Advanced
Platform: Market Delta & Ninjatrader
Favorite Futures: ES
 
cunparis's Avatar
 
Posts: 2,563 since Jun 2009
Thanks: 1,157 given, 2,030 received


sam028 View Post
Twitterizer libs, did you recompile them in .Net 3.5 ?
It's .Net 4.0 by default, that will be your next problem .
I work on this last week, and ended by creating a .Net 4.0 console .exe, called asynchronously byt my NT strats.

Thanks Sam I hadn't even thought of that. I don't have .NET experience outside of Ninjascript. This is going to be a tough one.

I don't think I can do asynchronous because I want my indicator to display tweets on the chart window.

Reply With Quote
 
  #5 (permalink)
Elite Member
Paris
 
Futures Experience: None
Platform: NinjaTrader
 
Posts: 1,176 since Oct 2009
Thanks: 227 given, 4,095 received

Ninja doesn't load libraries in My Documents/Ninjatrader 7 ..... at runtime. You need to put the libs in Ninja binaries folder.

Reply With Quote
 
  #6 (permalink)
Trade with the flow
Paris, France
 
Futures Experience: Advanced
Platform: Market Delta & Ninjatrader
Favorite Futures: ES
 
cunparis's Avatar
 
Posts: 2,563 since Jun 2009
Thanks: 1,157 given, 2,030 received


gomi View Post
Ninja doesn't load libraries in My Documents/Ninjatrader 7 ..... at runtime. You need to put the libs in Ninja binaries folder.

I put them there and got the same result. I'll restart Ninja after the close and see if that makes a difference.

Next task is to find someone with Twitterizer compiled for .NET 3.5 or a volunteer to compile it. The developer told me it should compile for 3.5 without any problems, but I don't have visual studio.

Reply With Quote
 
  #7 (permalink)
Elite Member
Paris
 
Futures Experience: None
Platform: NinjaTrader
 
Posts: 1,176 since Oct 2009
Thanks: 227 given, 4,095 received

You should try to run process monitor to see what file it's trying to load and why it's not finding it.
Process Monitor

Concerning Visual Studio, you can download VS express for free.
Free Developer Tools - Visual Studio 2010 Express | Microsoft Visual Studio

Reply With Quote
 
  #8 (permalink)
Trading Apprentice
Philippines
 
Futures Experience: Beginner
Platform: NinjaTrader
Favorite Futures: Futures
 
Posts: 7 since Sep 2014
Thanks: 1 given, 0 received

Post To Twitter

hello everyone.. need help, I'd tried to post a tweet in the twitter in the using ninjatrader Indicator, this code was working in the ASP.NET but not in the ninja,,, I got this error when I compile it.

The name 'Response' does not exist in the current context
The name 'Request' does not exist in the current context

any can help pls??
try
{

var oauth_consumer_key = "consumerKey";
var oauth_consumer_secret = "ConsumerSecret";


if (Request["oauth_token"] == null)
{
OAuthTokenResponse reqToken = OAuthUtility.GetRequestToken(
oauth_consumer_key,
oauth_consumer_secret,
Request.Url.AbsoluteUri);

Response.Redirect(string.Format("This is a Link to reconize if it is Success or not",
reqToken.Token));

}
else
{
string requestToken = Request["oauth_token"].ToString();
string pin = Request["oauth_verifier"].ToString();

var tokens = OAuthUtility.GetAccessToken(
oauth_consumer_key,
oauth_consumer_secret,
requestToken,
pin);

OAuthTokens accesstoken = new OAuthTokens()
{
AccessToken = tokens.Token,
AccessTokenSecret = tokens.TokenSecret,
ConsumerKey = oauth_consumer_key,
ConsumerSecret = oauth_consumer_secret
};

TwitterResponse<TwitterStatus> response = TwitterStatus.Update(
accesstoken,
"status = " + msg +"Instrument = " +Instrument.FullName
+"Direction = " +SignalType +"Close Price = " +Close[0] +"Date/Time = " +SignalTime);

if (response.Result == RequestResult.Success)
{
Response.Write("we did it!");
}
else
{
Response.Write("its all bad.");
}
}
}
catch( Exception ex )
{
Console.WriteLine(ex);
Print("----------end-------------");
}

Reply With Quote

Reply



futures io > > > > > Help using Twitterizer in an indicator

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

Jigsaw Trading: TBA

Elite only

FuturesTrader71: TBA

Elite only

NinjaTrader: TBA

Jan 18

RandBots: TBA

Jan 23

GFF Brokers & CME Group: Futures & Bitcoin

Elite only

Adam Grimes: TBA

Elite only

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding Constant Line Indicator to Another Indicator ceramictilepro NinjaTrader Programming 9 September 22nd, 2011 11:43 PM


All times are GMT -4. The time now is 06:21 AM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts
Page generated 2017-12-14 in 0.22 seconds with 19 queries on phoenix via your IP 54.160.245.121