Question : Display image

I have created two separate applications on is a setup tool that an admin will use to create all the configuration information for the users application. This configuration information is going to be stored inside an XML file. The user application will then read the XML file and apply all settings with in that XML file.

Part of those setting is displaying map images of a building in thumbnail format. Now I am unsure which way will be the easier of the two ideas I have. My first idea is to have the application read a directory destination from the XML file and display the images in that directory in thumbnail format. Then the user can click on the thumbnail and the image will be displayed in full size in a second window. In the second window the user should be able to zoom and pan the image.

 However the problem with idea one is I also need the icon image to be displayed over top the map images representing specific security device like a locked door, intercom station, video camera, and so on. So I thought the user application could read the image file name from the XML file and display that and it would also have the icon image location stated there as well. Grant I would still have to tell it what directory the image was in but the second idea might be easier since I need the icon image as well.

The XML schema I have is something like this:



   
      C:\Projects\AV4.1\Imagesectory>
     
        Testing image.bmp
       
         
            icon idle.bmp
            250,175n>
         

         
            icon idle.bmp
            270,175n>
         

         
            icon idle.bmp
            230,175n>
         

       

     

   

 



The code I am using for my two forms is attached below.


I want to know which way is better to read my information from the XML and how to go about doing it?

Answer : Display image


Please provide more information:
Can you post your form code?
Also provide some guidance regarding program usage? (how many doors, readers/door, icons, maps)
Is it going to be only one GUI and one setup program in the whole site?

I do not think that your xml as is will solve your problems.
For starters, you need:
An icon list which contains what kind of icon is and information about where to load it.
A map list that contains all maps, in here you can specify the icon id as well as the visual display properties.
Note: This can be separate xml files or included as a node, but if the number of points is huge you file as well will be
If you need to read Xml just use XmlDocument and xpath notation:
http://www.codeproject.com/KB/cpp/myXPath.aspx
http://www.c-sharpcorner.com/UploadFile/mahesh/ReadWriteXMLTutMellli2111282005041517AM/ReadWriteXMLTutMellli21.aspx

I did work for an Australian company that did this sort of work (SCADA security application that integrates video, intercom and access control) and we use a database because of the number of points, reference integrity and concurrency issues due to multiple GUIs accessing the setup data.
Random Solutions  
 
programming4us programming4us