Click here to Skip to main content
15,888,610 members
Home / Discussions / C#
   

C#

 
AnswerRe: FILETIME implementation in C# Pin
Richard MacCutchan29-Oct-15 23:06
mveRichard MacCutchan29-Oct-15 23:06 
GeneralRe: FILETIME implementation in C# Pin
Member 1206160030-Oct-15 0:09
Member 1206160030-Oct-15 0:09 
GeneralRe: FILETIME implementation in C# Pin
Richard MacCutchan30-Oct-15 1:05
mveRichard MacCutchan30-Oct-15 1:05 
QuestionVS_FIXEDFILEINFO implementation in C# Pin
Member 1206160028-Oct-15 23:51
Member 1206160028-Oct-15 23:51 
AnswerRe: VS_FIXEDFILEINFO implementation in C# Pin
Richard MacCutchan29-Oct-15 0:06
mveRichard MacCutchan29-Oct-15 0:06 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Member 1206160029-Oct-15 1:00
Member 1206160029-Oct-15 1:00 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Richard MacCutchan29-Oct-15 1:04
mveRichard MacCutchan29-Oct-15 1:04 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Member 1206160029-Oct-15 1:08
Member 1206160029-Oct-15 1:08 
This is why I am saying it seems a bit advanced for me. This is how I have reached so far with bit of googling, maybe you can help further?

C#
[System.Runtime.InteropServices.DllImport("coredll")]
       private static extern bool GetFileVersionInfo(string filename, UInt32 handle, UInt32 len, IntPtr buffer);

       [System.Runtime.InteropServices.DllImport("coredll")]
       private static extern UInt32 GetFileVersionInfoSize(string filename, out UInt32 handle);

       [System.Runtime.InteropServices.DllImport("coredll")]
       private static extern bool VerQueryValue(IntPtr buffer, string subblock, out IntPtr blockbuffer, out int len);


           UInt32 msb = (UInt32)System.Runtime.InteropServices.Marshal.ReadInt32(verbuffer, 8); // Read the dwFileVersionMS field

           UInt32 lsb = (UInt32)System.Runtime.InteropServices.Marshal.ReadInt32(verbuffer, 12); // Read the dwFileVersionLS field

           major = (msb & 0xFFFF0000) >> 16; // Extract the top 16bits from dwFileVersionMS

           minor = (msb & 0x0000FFFF); // Extract the low 16bits from dwFileVersionMS

           build = (lsb & 0xFFFF0000) >> 16; // Extract the top 16bits from dwFileVersionLS

           revision = (lsb & 0x0000FFFF); // Extract the low 16bits from dwFileVersionLS


But I don't know what is verbuffer?
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Richard MacCutchan29-Oct-15 5:16
mveRichard MacCutchan29-Oct-15 5:16 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Member 1206160029-Oct-15 5:19
Member 1206160029-Oct-15 5:19 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Richard MacCutchan29-Oct-15 5:39
mveRichard MacCutchan29-Oct-15 5:39 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Member 1206160029-Oct-15 3:05
Member 1206160029-Oct-15 3:05 
AnswerRe: VS_FIXEDFILEINFO implementation in C# Pin
OriginalGriff29-Oct-15 0:11
mveOriginalGriff29-Oct-15 0:11 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Member 1206160029-Oct-15 0:59
Member 1206160029-Oct-15 0:59 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
OriginalGriff29-Oct-15 1:18
mveOriginalGriff29-Oct-15 1:18 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Member 1206160029-Oct-15 1:22
Member 1206160029-Oct-15 1:22 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Dave Kreskowiak29-Oct-15 4:03
mveDave Kreskowiak29-Oct-15 4:03 
GeneralRe: VS_FIXEDFILEINFO implementation in C# Pin
Member 1206160029-Oct-15 5:16
Member 1206160029-Oct-15 5:16 
Questionc# Pin
Member 1152168528-Oct-15 20:42
Member 1152168528-Oct-15 20:42 
AnswerRe: c# Pin
OriginalGriff28-Oct-15 22:44
mveOriginalGriff28-Oct-15 22:44 
AnswerRe: c# Pin
John Torjo28-Oct-15 23:15
professionalJohn Torjo28-Oct-15 23:15 
Questionpivot - Variab;le y axis Pin
Member 1206164728-Oct-15 9:15
Member 1206164728-Oct-15 9:15 
AnswerRe: pivot - Variab;le y axis Pin
OriginalGriff28-Oct-15 22:45
mveOriginalGriff28-Oct-15 22:45 
AnswerRe: pivot - Variab;le y axis Pin
Richard MacCutchan28-Oct-15 22:48
mveRichard MacCutchan28-Oct-15 22:48 
Questionhow to read a serial data and then observe it in a box with c#? Pin
ssssdaaads28-Oct-15 3:25
ssssdaaads28-Oct-15 3:25 

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.