I've been searching for another way to do the same thing the asp.net literal control used to do. For those who don't know it, it allows us to format HTML and store it in a database, for instance, and when we load it is already formatted. Personally, I don't quite like to do this, but I'm working on a project where the company implemented it like this, so unless they agree to change it, I'll have to find a solution for this.
So, is there any way reach the same end as the literal control did?
Related
So I have an Excel file that functions as a report folks fill out daily. I'd like to have it as it's own tab, but when they're done filling it out, they FILE > SAVE AS to the Team files. Basically a quick access tab, where they would then save each file to a folder that functions as an archive.
Is this possible? If so, what am I missing during setup?
Thanks!
So I guess it's kind of possible to do what you're wanting, maybe by hosting the spreadsheet somewhere else (not in the general "Shared" folder in the Team's SharePoint site), and making it Read Only so users have to save it elsewhere, but for something like this, it really sounds like more of a "form" type of scenario, and I'd suggest looking to a more standard form solution. Maybe look into Microsoft Forms, Power Apps, or even Forms for Excel (Also part of Office 365, but stores the final result into a spreadsheet in your OneDrive). It depends on the Excel and what it's doing, of course, but this is assuming it's a reasonably simple form. If not, post a comment here with more information and I can update this answer / suggest alternatives.
I want to build an application that displays the content that user types on the command prompt to the display like a presentation.
I am writing this application in golang. If there are existing libraries that I can use to do this great and if not would need direction how to approach solving this.
I did search on the internet for pointers but found none.
Have a look at the present tool, it does a similar thing using flat files and might even be useful for you.
https://godoc.org/golang.org/x/tools/present
I recently automated the creation of Powerpoint Presentations in a site I'm making. I found the Office Interop libraries extremely simple to use.
Office isn't built for this kind of thing in a webserver environment, so I'm looking at creating the Powerpoints using Open Office XML, only it's so extremely complex. For example I downloaded some code to create a blank presentation with some text. This code was around 300 lines! Using the Office Interop libraries I could do the same thing in just a couple of lines of code.
I don't have time, nor do I want to attempt to learn how to interact with the Open Office XML libraries, so I'm hoping someone has made a wrapper for the Open Office XML libraries. So far all my searching has only given me one result, Aspose Slides for .NET. This looks really hopeful, but it also looks rather expensive
Has anyone ever used a decent wrapper or alternative before?
If you are looking at automating the creation of Powerpoint presentation files, I'd say you continue with OpenXML, there's nothing better than it. Everything else is either paid or don't offer entire gamut of functionality that Open XML can provide.
If you find creating a blank file tedious, you could save an empty file somewhere and use that as a template for performing further operations on it.
The only thing close to a wrapper for PowerPoint I've found is the Open XML PowerTools. It includes a PresentationBuilder class which can be used for some specific tasks like combining slides from multiple PowerPoint documents into a new document. Although its pretty limited in its functionality you could extend the class.
However, I've come to the conclusion that there just is not a good wrapper out there so I've had to do what everybody pretty much recommends and that is using the Open XML SDK Productivity Tool and the Reflect code button.
I put together a basic presentation then Reflect Code and put that into a class. Yes its a lot of lines of code and its not the most elegant solution but it does work. Then from there I can extend or modify that class to do the specific things I need to do with each slide. The Productivity Tool is a big help for figuring out the code need to do specific things. I try to keep it simple and just do one or two things at a time, Reflect Code, then look at the code to see what it does.
You could try SoftArtisans PowerPointWriter, it has a template mode that allows you to start with an existing PowerPoint file with a few place holders, and merge your data with your presentation with as little as 5 lines of code.
Disclaimer: I work for SoftArtisans
is there any way to speed up the string localization on ASp.Net mvc3 with razor? Lest say I write on my .cshtml "Hello World", and then I want to send that "Hello world" to the resources, with an automatic Id and refactor that string to the calling the resource, with just some clicks. Something like http://resourcerefactoring.codeplex.com/ but for VS 2010 and razor.
And Free!
Thanks!
So I touch some few lines of the Resource Refactoring Tool and I make it work with Razor (cshtml files). You can find the source and the installer here: http://www.ranu.com.ar/2011/07/faster-localization-on-aspnet-mvc3-with.html
I have used a helper for this, which get's a key for what you need to translate like this
#Html.Translate("MyHeader1")
and in the helper I took the value from the resources file I used, but you can also use a DB or what ever you want to getting the translation data.
String translated = (String)helper.ViewContext.HttpContext.GetGlobalResourceObject("Translation", key);
For development I add an # in front of the key, if no translation could be found, this way if I have something like #MyHeader1 in my user interace I know there is something I have to translate.
Interesting.. I wasn't aware of that project as it seems pretty nice - too bad there haven't been recent updates to it. So is your question how to extract them easier, or develop using resource files from the start? Ideally you can just create on resource file, and use it directly by programming against the resource name to start - no extracting required then. You can simply copy and paste your resource files, rename them and change the language content. See
http://www.codecapers.com/post/How-to-Localize-an-ASPNET-MVC-Application.aspx
I want to dynamically load (AJAX) the text from some Microsoft Word files into a webpage. So I might have a link to essays I've written and upon mouseover have it load the first few sentences in a tooltip.
Only if you have a parser. I think the new format is a zip archive with XML schema. But the old one is just binary.
There are some parsers out there.
I know of wvWare but it seems it's outdated. (http://wvware.sourceforge.net/)
This is maybe something worth looking at: http://poi.apache.org/hwpf/index.html
And yeah, forgot to mention how to do this. :-)
First you need to make the javascript ask for the data through ajax. The serverside has to take care of the parsing and return the text to the javascript. This will be a pain in the ass. I haven't done this myself and have never tried the parsers I linked, so I'm not sure if they suit you. Images, stylesheets, etc.... not sure if that will be useable.
At least, good luck.
For security reasons, it is not possible to directly load a local file (such as a Word document) into the page using simply Javascript. The user will need to upload the file to the server, which you will want to parse on the server and then you can load whatever result you like into the page using Ajax.
It sounds like you mean to upload your files (e.g. essays) to your server to allow users to download them, and want to create a server-side page that will parse the files and print the first few lines (so it can be called by an AJAX method that displays a preview on hover).
To suggest a tool for this, we'll need to know whether these are "old" Word format (Office 2003 - extension is .doc) or "new" Word format (Office 2007 - extension is .docx).
It will also be good to know what you're using to create your pages server-side, since different document-reading tools support different programming languages. If you're using Java to read .doc files, you can use the tool we use at my place of work, which is POI (http://poi.apache.org/). If you're using something else, try searching google for {read in }, e.g. {read .docx in ruby}.
If all of this is Greek to you and you have no prior experience with developing custom server-side web code, this is probably going to be unnecessarily painful and you should consider an alternative (like manually creating a 3-line text "preview" page for each regular page, and then just showing that).