Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Image location held in xml file. Want to use this in picturebox

Posted on 2007-11-21
1
Medium Priority
?
441 Views
Last Modified: 2008-02-01
Hey,

I have an xml file that looks like so..
<?xml version="1.0" encoding="utf-8"?>
<configuration>
    <business>
      <image>C:\Logo.png</image>
    </business>
</configuration>

I use this code to get the string C:\Logo.png...
            XmlDocument doc = new XmlDocument();
            doc.Load(c:\myxml.xml);            
            XmlNodeList BusinessNodeList = doc.SelectNodes("/configuration/business/image");
            foreach (XmlElement BusinessImageElement in BusinessNodeList)
            {
                BusinessImageLocation = BusinessImageElement.InnerText;
            }

How can I use "BusinessImageLocation" as the image in a picturebox?
0
Comment
Question by:Antonio King
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 7

Accepted Solution

by:
bungHoc earned 2000 total points
ID: 20326521
string path = BusinessImageElement.InnerText;
pictureBox.Image = Image.FromFile(path);
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

721 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