Click here to Skip to main content
15,890,845 members
Home / Discussions / C#
   

C#

 
QuestionRe: Dataset TableNewRow Event Pin
Midnight Ahri4-Jul-12 22:22
Midnight Ahri4-Jul-12 22:22 
AnswerRe: Dataset TableNewRow Event Pin
OriginalGriff4-Jul-12 22:34
mveOriginalGriff4-Jul-12 22:34 
AnswerRe: Dataset TableNewRow Event Pin
Midnight Ahri4-Jul-12 23:04
Midnight Ahri4-Jul-12 23:04 
GeneralRe: Dataset TableNewRow Event Pin
OriginalGriff4-Jul-12 23:59
mveOriginalGriff4-Jul-12 23:59 
GeneralHow to Update DataTable to MySql database Without loop Pin
rongvangso74-Jul-12 15:26
rongvangso74-Jul-12 15:26 
GeneralRe: How to Update DataTable to MySql database Without loop Pin
Abhinav S4-Jul-12 16:16
Abhinav S4-Jul-12 16:16 
GeneralRe: How to Update DataTable to MySql database Without loop Pin
amirafoods4-Jul-12 20:25
amirafoods4-Jul-12 20:25 
GeneralSOLVED!! (do the happy dance!) Dictionary Error? (or User Error! more likely) Pin
glennPattonWork34-Jul-12 5:33
professionalglennPattonWork34-Jul-12 5:33 
Hi All,
Pete O'Hanlon has helped me with this ([^]Yesterday & before) but the thing is I still need a prod in the correct direction, to give the correct and full story (which might make more sense to Pete!) I have to write some software to interface to a board with a USB, I am not happy about installing the driver that installed already and breaking things. I have written successfully some code to check for the driver installed. In thinking that the driver in the future could be updated I wanted to check the date and or revision of the driver so if I install over the old driver only if it's earlier than the one I need.
The code I had was
C#
ServiceController[] scDevices = ServiceController.GetDevices();

      MessageBox.Show("Device driver services on the local computer");

           foreach (ServiceController scTemp in scDevices)
           {
           lstDrivers.Items.Add(scTemp.ServiceType + "," + scTemp.ServiceName +
            "," + scTemp.DisplayName);

           }
This will shove all the installed drivers to a list box another bit of code
C#
index = lstDrivers.FindString("KernelDriver,FTDIBUS,USB Serial Converter Driver");
         if (index != -1)
         {
             lstDrivers.SetSelected(index, true);

         }

Using this method using ServiceController.GetDevices() I think the reference Pete gave me yesterday doesn't really help with the issue I was having, I would like to be able to read all the data concerning the drivers date and version at both the install & run time
(thinking it would be useful for another project) I would like to know two things a) how to use the bit of code Pete supplied, b) Should I do the driver as part of the setup or tell the user "if it don't appear install this!"?
Glenn(sorry for being thick!)

modified 5-Jul-12 11:54am.

AnswerRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon4-Jul-12 6:36
mvePete O'Hanlon4-Jul-12 6:36 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork34-Jul-12 22:37
professionalglennPattonWork34-Jul-12 22:37 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon4-Jul-12 23:09
mvePete O'Hanlon4-Jul-12 23:09 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork34-Jul-12 23:35
professionalglennPattonWork34-Jul-12 23:35 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon4-Jul-12 23:43
mvePete O'Hanlon4-Jul-12 23:43 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork35-Jul-12 0:04
professionalglennPattonWork35-Jul-12 0:04 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon5-Jul-12 0:11
mvePete O'Hanlon5-Jul-12 0:11 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork35-Jul-12 0:30
professionalglennPattonWork35-Jul-12 0:30 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon5-Jul-12 0:32
mvePete O'Hanlon5-Jul-12 0:32 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork35-Jul-12 0:45
professionalglennPattonWork35-Jul-12 0:45 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon5-Jul-12 0:54
mvePete O'Hanlon5-Jul-12 0:54 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork35-Jul-12 1:35
professionalglennPattonWork35-Jul-12 1:35 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon5-Jul-12 1:53
mvePete O'Hanlon5-Jul-12 1:53 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork35-Jul-12 2:24
professionalglennPattonWork35-Jul-12 2:24 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork35-Jul-12 4:46
professionalglennPattonWork35-Jul-12 4:46 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
Pete O'Hanlon5-Jul-12 5:33
mvePete O'Hanlon5-Jul-12 5:33 
GeneralRe: Dictionary Error? (or User Error! more likely) Pin
glennPattonWork35-Jul-12 5:41
professionalglennPattonWork35-Jul-12 5:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.