Is there any MathML Renderer Component for .Net App? - c#

Is there any component of MathML Renderer which can be used by Dot Net App? I hope you could help me find one no matter how much it costs.
Detailed Requirements:
it can provides a control for equation edit
it must not be a COM component
it must support Content MathML markup (it will be better if it could support both Content and Presentation markup)
it could generate the markup according to the formula
it could generate the formula according to the markup
I have found some tools such as MathML .Net Control and NuGenEQML .Net, but unluckily, both two components don't support Content Markup.

I have the same need. There's only three options that I am aware of:
= MathFlow by Decision Science - I will soon be evaluating this one and am hopeful it will be my new solution; they've provided presentation MathML for MS Word for a long time; they finally came out with a Content MathML offering
= Integre - I've used their COM control in .NET... painful; they have a Java one, but was never able to get them to do a .NET wrapper; they are working on a Flash one that I thought I'd be able to wrap and embed, but I've grown tired of waiting
= Forumulator by Hermitech - seems to be a step down from the two above
If you uncover any others, please post here.

Related

How to add Image to tileItemElement in a tilecontrol Winforms without the GUI interface in the .NET framework

tileItemElement5.ImageAlignment = DevExpress.XtraEditors.TileItemContentAlignment.TopCenter;
tileItemElement5.ImageScaleMode = DevExpress.XtraEditors.TileItemImageScaleMode.ZoomInside;
tileItemElement5.ImageSize = new System.Drawing.Size(200, 135);
Here I want to assign an image to my tileItemElement5. I don't know how to do that
Looking at the documentation for DevExpress WinForms, you can just assign an image directly to the TileItemElement.
tileItemElement.Image = Properties.Resources.delete_icon;
You can get the image from your Properties/Resources as I did in the short example, or load it in code.
Link to the documentation and a tip
DevExpress provides a very detailed documentation with lots of examples, I recommend that you utilize your search engine next time because 99% of the time, you will find an answer on their website.
Because DevExpress provides libraries for multiple platforms and frameworks, I recommend that you preface your search engine search with "DevExpress C# WinForm" then type in the issue or what you are looking for. This will make sure that you get results that match your development environment.

Easiest way to draw tree diagrams?

I want to have a program which generates diagrams for trees, ones looking pretty much like this
It is to be a part of a project I am working on using C#, but if there is a way to make a Python or Javascript do it, that be okay as well. Maybe some C# library, or JavaScript/Python library with parameters I can provide to it ?
The most important thing, regardless of the programming language, is that it be easy to use.
You may want to use pydot, which is an interface to the Graphviz .DOT format visualization software. As outlined in the Graphviz guide, the .DOT format lets you design graphs similar to the one you posted as well as more much more sophisticated ones.
Here's an example from the pydot doc:
import pydot
graph = pydot.Dot('graphname', graph_type='digraph')
subg = pydot.Subgraph('', rank='same')
subg.add_node(pydot.Node('a'))
graph.add_subgraph(subg)
subg.add_node(pydot.Node('b'))
subg.add_node(pydot.Node('c'))
If you're looking at Javascript instead, canviz is a well-respected library that allows you to draw .DOT graphs to browser canvases.
There is a C# wrapper around the Graphviz bindings.
I'm working on a project that generates trees with Graphviz (not in C# though) and it works great.

How to write a simple designer for printed reports

I'm currently having a couple of reports which I print from my Forms applications.
However building printed reports only with the built-in .NET printing methods is very tedious. Even just printing a simple table on a couple of pages with a little bit of formatting is a task for a couple of hours (if it should look nice).
What I need is a WYSIWYG-Designer for the layouts, so I'd like to write one.
It shouldn't be for End-Users, but for me as a developer, it's just about to create the layout what the report will look like with various arrangements/fonts/images/formats and so on and not have to do that by trial & error in code (and restart the app a zillion times).
So my specific questions:
What would I use as a canvas for editing and display of the report? An image-control/bitmap which I draw upon like on the printed document? Is there a better way?
Is drawing on a form comparable to drawing on a printed page? What about differences in resolution printer vs. screen?
How to get real WYSIWYG? Should I get the printer settings and create my canvas with the same resolution? Is there something else to consider?
I know that there are report designers around but I think it's sometimes good to understand the basic working principles of what you use and implementing them is for me the best way to do that.
I'm aware that this is not a specific question A to which the answer is always B, but if it were that way I would find an answer in Google pretty quickly.
Thanks in advance!
I can't say much about designing a WYSIWYG editor, but I have written a few custom in-house reporting engines for use by our development team.
There's two main ways I've created reports. The first is using PDFsharp (MIT-licensed) to manually layout pages which isn't for the faint-of-heart.
The second is using Winnovative's HTML to PDF library (not free, but royalty-free) which uses the current installed version of IE to do the layout and spit out a PDF. It looks like they've recently released a new version called EVO PDF which I have never used before.*
For the HTML to PDF solution, it supports JavaScript so you can add in charts from JavaScript libraries like flot or jqplot.
*I'm not affiliated with Winnovative.
You might want to save time and use Visual Studio HTML designer as your WYSIWYG editor.
What I'm currently doing is using ASP.NET MVC 3 as a simple reporting engine. You can use the MVC pattern to really separate your reporting data source (Model) and the rendering (View) while using Visual Studio as your report designer.
From your application you can easily call your actions with the report optional parameters. For example:
http://localhost/Report/Customer/Orders/1
You simply get the returning string from a WebClient's DownloadString method and you have your report generated.
There is some down side using HTML, mainly the difficulties to know when a page would break, but by using code in your View you can calculate the amount of repeating items and add a CSS break-page and re-starting your table's header on the next page.
You can achieve anything from graphics, to table, you can even generate link to other reports.
HTH.
Printing Reports in Windows Forms
http://msdn.microsoft.com/en-us/library/ms996472.aspx

Editing Microsoft Word Documents Programmatically

I want to know if this could be done.
I am building a data dictionary for our software system (school project), and I'm thinking of an automated way to do this. Basically I don't use much of Microsoft Word (2007), I only use it in documenting schools stuff, etc. I want to know if its possible to create/edit a Word document programmatically from a template.
The idea is, I will create a page on Word that contains an empty form that will be repeated on every page. For every data that I will input to my program, it will update the corresponding field in the form and skips to the next form.
The purpose of this, is to eliminate copy-paste methods (my habit) and to speed things up when doing the documentation.
Word automation, as suggested by others, will lead you to a world of hurt for two major reasons:
Office is not intended to be run unattended, so it can pop up message boxes at any time, and
It is (probably) not licensed to enable office functionality for computers which don't have it. If you generate a Word document on a web site using automation, you have to make sure that this functionality cannot be reached by computers which don't have office installed (unless they changed this rule in the last years).
I have used Aspose.Words, it costs a little, but it works well and is intended for this.
Not exactly sure what you really want, but creating word documents with c# shouldn't be any problem:
http://support.microsoft.com/kb/316384
If i find out your purpose correctly you need to visit this microsoft msdn link
Manipulating Word 2007 Files with OpenXML
Definitely possible. A fairly easy way of doing it using Office Automation. See this KB article for a basic sample: How to automate Microsoft Word to create a new document by using Visual C#
I think the main difference to that sample will be that you'll open your template and do SaveAs instead of creating a new document, but I can't remember exactly.
However, depending on your exact requirements, there might be better alternatives. For example, it's not recommended to do Office Automation on servers (including on webservers), so if that's needed you might want to look at something else.
You can use com interop of .net framework.
Understanding the Word Object Model from a .NET Developer's Perspective
Building COM Objects in C#
Using COM programming is not the best way as mentioned by erikkallen, I suggest using OPEN XML. It is really easy to use and your document generation operation will be very fast.
http://blog.goyello.com/2009/08/21/how-to-generate-open-xml-file-in-c-in-4-minutes/
http://msdn.microsoft.com/en-us/library/aa338205(v=office.12).aspx

Annotation Control (or Document Control w/ Annotation Support) in .NET

I am looking for a .NET library (or, more specifically, a .NET component) which allows me to write annotations to a document (not specifically a Word document - the component itself could display a document which I can also add annotations to). Even better would be something with similar functionality to the reviewing process in Microsoft Word, but I would be happy with just basic annotations.
I haven't been able to find anything very promising in Google searches, so I was wondering if SO would have any suggestions.
(Note: Unlike this question, my application is a standalone app and I am not looking to do this on the web.)
For those of you who might be looking, ScintillaNET supports annotations as well as markers (which is what I was looking for). The documentation is a little bit difficult to parse through (specifically the Scintilla documentation, which ScintillaNET comes from), but it is easy once you start getting the hang of it.
Hope this helps!

Categories