integrate images inside a .dll - NinjaTrader Programming | futures io social day trading
futures io futures trading


integrate images inside a .dll
Updated: Views / Replies:1,082 / 6
Created: by SARdynamite 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
 

integrate images inside a .dll

  #1 (permalink)
Elite Member
Belgium
 
Futures Experience: Advanced
Platform: SaxoTrader
Broker/Data: SaxoBank
Favorite Futures: ESTX
 
Posts: 290 since Dec 2009
Thanks: 242 given, 109 received

integrate images inside a .dll

Hello,

I have scripts that I would like to pass to friends and relatives but protected as .dll

Those strategies include custom buttons with images I created for the purpose.
Those images are now stored on a folder within C:\ and I call them within the script to use for the buttons.

I'd like to know if there is a way to include the images natively inside my .dll ? I've tried a few things but can't make it work.
The goal is that the script can be imported just like a regular indicator and install itself the images on a misc. folder.

If that's not possible, I'll have to use and provide an installer aside. I'd prefer to avoid that.

Merry christmas

Reply With Quote
 
  #2 (permalink)
Site Administrator
Manta, Ecuador
 
Futures Experience: Advanced
Platform: My own custom solution
Favorite Futures: E-mini ES S&P 500
 
Big Mike's Avatar
 
Posts: 46,238 since Jun 2009
Thanks: 29,350 given, 83,220 received

 
Thread Moved


Moved from: NinjaTrader
Moved to: NinjaTrader Programming



When creating a new thread, note which subforum you are in. Here is a short list of suggestions:

- Topic: Anything to do with an Elite indicator -> Subforum: The Elite Circle
- Topic: Looking for an existing indicator, or how-to use an indicator -> Subforum: (the platform)
- Topic: Programmer needing help with non-Elite indicator -> Subforum: (the platform) - Programming
- Topic: Want an indicator created/modified -> Reply to "Want indicator created free" in Elite Circle
- Topic: Vendors (trading rooms, commercial indicators) -> Subforum: Vendors/Product Reviews
- Topic: Discussion of Forex or Currency trading -> Subforum: Forex and Currency Trading
- Topic: Journals of your trading -> Subforum: Trading Journals or Elite Trading Journals
- Topic: General trading related discussions -> Subforum: Traders Hideout
- Topic: Discussion of a trading method -> Subforum: Traders Hideout
- Topic: Automated Trading -> Subforum: Elite Automated Trading

Last, any Elite Member may create more or less any of these topics in The Elite Circle at your own discretion (your support is appreciated).

This is just a short general list and doesn't cover everything. If you are unsure where to create your new thread, just create it in Traders Hideout and a moderator will move it if necessary.

-- Big Mike Trading


Due to time constraints, please do not PM me if your question can be resolved or answered on the forum.

Need help?
1) Stop changing things. No new indicators, charts, or methods. Be consistent with what is in front of you first.
2) Start a journal and post to it daily with the trades you made to show your strengths and weaknesses.
3) Set goals for yourself to reach daily. Make them about how you trade, not how much money you make.
4) Accept responsibility for your actions. Stop looking elsewhere to explain away poor performance.
5) Where to start as a trader? Watch this webinar and read this thread for hundreds of questions and answers.
6)
Help using the forum? Watch this video to learn general tips on using the site.

If you want
to support our community, become an Elite Member.

Reply With Quote
 
  #3 (permalink)
Site Administrator
Manta, Ecuador
 
Futures Experience: Advanced
Platform: My own custom solution
Favorite Futures: E-mini ES S&P 500
 
Big Mike's Avatar
 
Posts: 46,238 since Jun 2009
Thanks: 29,350 given, 83,220 received


You can call them from a website easily enough, not sure about actually encoding them and embedding them inside a DLL.

How to embed resources in ASP.NET 2.0 assemblies

You might try googling for MIME or base 64 encode and c# .net and see if that gets you anywhere, as I imagine you would need to basically hard code the encoded string for the image, then decode it and display it.

Mike

Due to time constraints, please do not PM me if your question can be resolved or answered on the forum.

Need help?
1) Stop changing things. No new indicators, charts, or methods. Be consistent with what is in front of you first.
2) Start a journal and post to it daily with the trades you made to show your strengths and weaknesses.
3) Set goals for yourself to reach daily. Make them about how you trade, not how much money you make.
4) Accept responsibility for your actions. Stop looking elsewhere to explain away poor performance.
5) Where to start as a trader? Watch this webinar and read this thread for hundreds of questions and answers.
6)
Help using the forum? Watch this video to learn general tips on using the site.

If you want
to support our community, become an Elite Member.

Reply With Quote
The following 2 users say Thank You to Big Mike for this post:
 
  #4 (permalink)
Elite Member
Belgium
 
Futures Experience: Advanced
Platform: SaxoTrader
Broker/Data: SaxoBank
Favorite Futures: ESTX
 
Posts: 290 since Dec 2009
Thanks: 242 given, 109 received

Thanks Mike.

I had thought about reading them online but I will try to code their conditional download on startup and see if that can be acceptable.

Reply With Quote
 
  #5 (permalink)
Elite Member
Vienna Austria
 
Futures Experience: Advanced
Platform: NinjaTrader
Favorite Futures: Forex
 
AlBundy's Avatar
 
Posts: 25 since Jun 2013
Thanks: 10 given, 11 received

Solution

Hi Mike,

thank you for the perfect hint regarding base64!
This is the code which works:

 
Code
        using System.IO;
        public Bitmap base64ToImage( string base64String )
        {
            // Decode the string and create a memory stream on the decoded string data.
            MemoryStream stream = new MemoryStream(Convert.FromBase64String(base64String));

            // Create a new bitmap from the stream.
            return new Bitmap(stream);
        }
Here you can convert any picture to a base64 c# string:
Base64 Image Encoder

Best Regars!


Last edited by AlBundy; July 30th, 2014 at 05:18 AM.
Reply With Quote
The following 3 users say Thank You to AlBundy for this post:
 
  #6 (permalink)
Elite Member
tenerife/españa
 
Futures Experience: Beginner
Platform: ninjATRADER
Favorite Futures: currency futures
 
Posts: 1 since Sep 2016
Thanks: 0 given, 0 received

Goodnight.
Could someone write an example code please?
I have converted the image to Base64 and it gives me a very long code that I do not know what to do with it.
I would like to assemble the dll with an image that I have in my computer so that when another person uses it on another pc it looks like the image.
Regards and many thanks to all.

Reply With Quote
 
  #7 (permalink)
Elite Member
Vienna Austria
 
Futures Experience: Advanced
Platform: NinjaTrader
Favorite Futures: Forex
 
AlBundy's Avatar
 
Posts: 25 since Jun 2013
Thanks: 10 given, 11 received

Yes, it is a very long code because each byte of the image is converted to a character. So a 1 KB image will produce a string of around 1'300 bytes.

Reply With Quote

Reply



futures io > > > > > integrate images inside a .dll

Thread Tools Search this Thread
Search this Thread:

Advanced Search



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

Linda Bradford Raschke: Reading The Tape

Elite only

Adam Grimes: TBA

Elite only

NinjaTrader: TBA

January

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Images don't work in tapatalk theprophe Feedback and Announcements 11 May 23rd, 2011 05:03 AM
Cant view images Linds Tech Support 3 March 5th, 2011 07:37 PM
How-to attach images to a wiki article Big Mike Help, Tutorials, and How-Tos 0 June 28th, 2010 08:46 AM


All times are GMT -4. The time now is 02:28 PM.

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-12 in 0.09 seconds with 19 queries on phoenix via your IP 54.163.209.109