?
Solved

Web Service Visual Studio 2010

Posted on 2011-04-20
5
Medium Priority
?
657 Views
Last Modified: 2012-08-13
Hi,

I'm new to web services and I need to create a web service that will receive XML files and attachments (jpgs and pdfs).  I will be using http and I need it to update a SQL Server 2005 backend after a check has been done on the data.  I have Visual Studio 2010.

I'm really struggling to know where to start.  I have been sent an example XML file and then individual pdf and jpgs and was wondering if anyone could give me some pointers...

Any help would be appreciated.

<?xml version="1.0"?>
<TestJob xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <Id>ea9c7d87-fcdb-42c1-b03d-db2fa3983fa5</Id>
  <BasePageAddress>21.8888.0.50</BasePageAddress>
  <DateOfLastTransaction>2010-06-23T16:30:23</DateOfLastTransaction>
  <User>
    <Id>90575e9e-5869-473a-b013-3553851e8b35</Id>
    <PenID>AJX-AAJ-DNE-AM</PenID>
    <FirstName>Fred</FirstName>
    <Surname>Blogs</Surname>
    <Username>fbloggs</Username>
    <Admin>true</Admin>
  </User>
  <Status>Sent</Status>
  <FormType>TestWorksReport</FormType>
  <JobNo>1115128</JobNo>
</TestJob>

Open in new window

0
Comment
Question by:Tra71
  • 2
  • 2
5 Comments
 
LVL 8

Expert Comment

by:edemcs
ID: 35434884
Create the web service by creating the asmx file and Web Service Project.  If you want to transfer the PDFs and/or jpeg, I'd suggest encoding the file in BASE64 and then sending it through the web service.  The recipient can then decode the BASE64 field into that file type.
0
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 2000 total points
ID: 35439383
0
 

Author Comment

by:Tra71
ID: 35441866
Thanks for your help, I'm still looking into it.  

Was after code examples if at all possible.  I'm new to both Visual Studio and Web Services...

Thanks again
0
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 35441973
>Was after code examples if at all possible.  I'm new to both Visual Studio and Web Services...

The trouble is that you are new and we can only provide generic code samples so it would be more confusing for you. Hence I posted links to tutorials so that you can learn and possibly use code from tutorials.
0
 

Author Comment

by:Tra71
ID: 35449640
Thanks, will take a look at the links.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
In real business world data are crucial and sometimes data are shared among different information systems. Hence, an agreeable file transfer protocol need to be established.
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Loops Section Overview
Suggested Courses
Course of the Month14 days, 15 hours left to enroll

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question