dcsimg
www.webdeveloper.com
Results 1 to 12 of 12

Thread: XML from MDB

  1. #1
    Join Date
    Feb 2003
    Location
    Whitley Bay, UK
    Posts
    23

    Question XML from MDB

    What's the easiest way to convert an MDB file (Access database) to an XML file? (Oh, and what's the cheapest way??)

  2. #2
    Join Date
    Dec 2002
    Location
    Calgary, Canada
    Posts
    2,653
    Personally I'd prefer to write an application using Java/DOM APIs that would read the db and spit out the XML.To me its the best and cheapest way,on the other hand,if you think thats hard to do then there are utilities that can do it for you, XMLSpy is one of those.

    Cheers

    Khalid

  3. #3
    Join Date
    Feb 2003
    Location
    Whitley Bay, UK
    Posts
    23
    Thanks Khalid, but I'd have to get a Java development environment and learn it first! I suppose I could use VS.NET.

    I've got XML Spy, but only the home version, which doesn't (I think!) do that function.

  4. #4
    Join Date
    Dec 2002
    Location
    Calgary, Canada
    Posts
    2,653
    It should not be too hard to do this with VB,
    I could help you with Java but never tried creating/writing XML with VB..:-(

    Cheers

    Khalid

  5. #5
    Join Date
    Feb 2003
    Location
    Whitley Bay, UK
    Posts
    23
    I'm looking into using Delphi 7 for this at the moment, Khalid. I'll let you know how it goes. Thanks for the help.

  6. #6
    Join Date
    Dec 2002
    Location
    Calgary, Canada
    Posts
    2,653
    Sounds good..:-)




    Khalid

  7. #7
    Join Date
    Feb 2003
    Location
    Whitley Bay, UK
    Posts
    23
    I didn't use Delphi 7 after all - I only have the Personal edition, which lacks the functionality I need.

    So, I turned to my VS.NET Beta 2 - created an adapter and a dataset basically using drag-and-drop, and typed about 5 lines of C# in - and now I have an XML file from the database!!

    Next problem. I want to convert the XML to HTML, so I need an XML Stylesheet. The problem comes when I try to output a link to a file ...
    <td> <a href="<xsl:value-of select="FileLink"/>"> Click Me </a> </td>
    ... there's a syntax problem with double-quotes in there. Any suggestions?

  8. #8
    Join Date
    Dec 2002
    Location
    Calgary, Canada
    Posts
    2,653
    use html entities
    &amp;quot;

    This should take care of it

    Khalid

  9. #9
    Join Date
    Feb 2003
    Location
    Whitley Bay, UK
    Posts
    23
    Khalid,

    You are brilliant! Thanks.

  10. #10
    Join Date
    Feb 2003
    Location
    Whitley Bay, UK
    Posts
    23
    Hang on, that didn't work ...

  11. #11
    Join Date
    Dec 2002
    Location
    Calgary, Canada
    Posts
    2,653
    Ok her eit goes man,I think you are trying to create a link using XSL,if thats the case you are doing it completely wrong,here is the correct syntax.

    <td>
    <a target="_blank">
    <xsl:attribute name="href">
    <xsl:value-of select="FileLink"/>
    </xsl:attribute>
    Click Me
    </a>
    </td>

    Cheers

    Khalid

  12. #12
    Join Date
    Oct 2008
    Posts
    1

    Request for the code

    Hi White,
    I have come across this forum while searching for sample code to convert a MDB file into XML file.In this forum you said that, you have written the code for converting the mdb file into xml file. [mod]no contact information[/mod].
    Thanks in advance....

    Rgds,
    Sudhir M




    Quote Originally Posted by AWhiteC View Post
    What's the easiest way to convert an MDB file (Access database) to an XML file? (Oh, and what's the cheapest way??)

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles