October 14th, 2008, 05:51 AM
Sharepoint based C# application
I am making a Web App in C# that interacts with Sharepoint Server 2003. I am stuck at a situation, please go thru it below to see, if someone can give some suggestions or walk through for the same:
About the Web App: My web application has many pages and most of these pages fetch data from a shpt lists and then displays it on the page.
Scenario : I have a feature in my application, that if someone wants to display an HTML file, they can add it in "Reference to Content" (the Reference to Content is the page property, which acts like the Data Source of the content to be displayed on the page), and then my code, gets the html as string and then renders it on the website. To do so, what my user does is, they create a Word Document with all the stylings and save it in the "htm" format, upload this htm page on the sharepoint server and give it as reference of the page. And then my code, at the time of rendering, will download the html file code as string on the clients machine and population the html page.
Problem : The problem starts if someone wants to have an image in the html file. What happens is, if i create a word doc and insert an image in it and save it in the htm format, the images are stored separately in a folder, which is then referenced in the htm file. So, when my code tries to render this page, it doesnt get image at the location (which is usually a folder with the same name on the same level of the path).
1. Either there is way to upload the images in the sharepoint server and then reference it so that when I download the html as string, it refers to the image stored online. But I dont think thats going to work. What do you think?
2. Another possible solution I thought was to store this word docs as "mht" instead of "htm", since mht stores images in one file and not separately in a different folder. But when I tried doing this, I found out I just cannot follow the usual process of download the files code as string and then rendering it online, coz this gives some kind of encoded string to me, on some searches on google, I found out that I need to do some kind of VML processing, which I dont have clues about how to do that thing in c#. Do you know any way out of it?
October 20th, 2008, 06:10 PM
Can someone please answer to the above problem? May be VML processing is a solution? But how do we do it?
There's another problem that I am stuck on:
I am using the SHPT Web Services to get the data from the SHPT Lists. But, in few lists, when I try to get the View collection using the "Views.GetViewCollection() method", a 'Microsoft.SharePoint.SoapServer.SoapServerException' gets thrown. And when I looked into the exception details, it says "Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)."
Can someone please help?
October 20th, 2008, 06:44 PM
I foound out the reason for this problem, here's the reason:
Originally Posted by codenamevirus
1. I created a list with the name org_roles - so the url was http://myserver.com/lists/org_roles/allitems.aspx
2. later I renamed this list to organisation_roles - but the url remained the same.
3. Now when I try to access the list, it tries to search on the server a list with the name "Org_Roles" but its not present there, since it has been renamed to "Organisation_Roles" because of which it throws a soap server exception.
Now, there can be 2 solutions:
1. Either i use the GUID of the list instead of the names
2. or I somehow obtain the new Display Name of the list, and then try to access it.
But, i dont know how to proceed for both the ways. All I get is the url to list, how can I get the GUID of the list or the display name?
Please help, i m very close to solve a major problem...I am really desparate for it.
By Soda_Popinsky in forum The Security Tutorials Forum
Last Post: August 1st, 2005, 06:07 PM
By gore in forum Operating Systems
Last Post: March 7th, 2004, 07:02 AM
By qod in forum The Security Tutorials Forum
Last Post: February 27th, 2004, 02:03 AM
By -DaRK-RaiDeR- in forum Newbie Security Questions
Last Post: December 14th, 2002, 07:38 PM
By Noble Hamlet in forum AntiOnline's General Chit Chat
Last Post: March 17th, 2002, 08:38 AM