Click here to Skip to main content
15,911,315 members
Home / Discussions / C#
   

C#

 
QuestionConvert MFC Fonts to c# Fonts Pin
Tulika Shrivastava12-Feb-06 20:01
Tulika Shrivastava12-Feb-06 20:01 
AnswerRe: Convert MFC Fonts to c# Fonts Pin
Colin Angus Mackay12-Feb-06 20:19
Colin Angus Mackay12-Feb-06 20:19 
GeneralRe: Convert MFC Fonts to c# Fonts Pin
Tulika Shrivastava12-Feb-06 21:35
Tulika Shrivastava12-Feb-06 21:35 
QuestionDisplaying data from text file to dataset Pin
mitreviper12-Feb-06 19:37
mitreviper12-Feb-06 19:37 
GeneralRe: Displaying data from text file to dataset Pin
VMSSanthosh13-Feb-06 23:28
VMSSanthosh13-Feb-06 23:28 
QuestionIdentify domains in a lan Pin
sendmadhavan12-Feb-06 18:28
sendmadhavan12-Feb-06 18:28 
AnswerRe: Identify domains in a lan Pin
fearless stallion14-Feb-06 2:28
fearless stallion14-Feb-06 2:28 
GeneralRe: Identify domains in a lan Pin
sendmadhavan14-Feb-06 3:14
sendmadhavan14-Feb-06 3:14 
QuestionRun an application in two modes Pin
vinutha kempanna12-Feb-06 17:45
vinutha kempanna12-Feb-06 17:45 
AnswerRe: Run an application in two modes Pin
Colin Angus Mackay12-Feb-06 20:18
Colin Angus Mackay12-Feb-06 20:18 
QuestionAmpersand Char Pin
Paradox2212-Feb-06 14:56
Paradox2212-Feb-06 14:56 
AnswerRe: Ampersand Char Pin
Ravi Bhavnani12-Feb-06 15:41
professionalRavi Bhavnani12-Feb-06 15:41 
AnswerRe: Ampersand Char Pin
nta13712-Feb-06 17:06
nta13712-Feb-06 17:06 
AnswerRe: Ampersand Char Pin
Guffa12-Feb-06 22:24
Guffa12-Feb-06 22:24 
AnswerRe: Ampersand Char Pin
malharone13-Feb-06 3:05
malharone13-Feb-06 3:05 
JokeRe: Ampersand Char Pin
Paradox2213-Feb-06 13:28
Paradox2213-Feb-06 13:28 
QuestionJoystick value Pin
Danny198212-Feb-06 13:15
Danny198212-Feb-06 13:15 
AnswerRe: Joystick value Pin
Ravi Bhavnani12-Feb-06 13:23
professionalRavi Bhavnani12-Feb-06 13:23 
GeneralRe: Joystick value Pin
Danny198212-Feb-06 23:10
Danny198212-Feb-06 23:10 
GeneralRe: Joystick value Pin
Ravi Bhavnani13-Feb-06 1:51
professionalRavi Bhavnani13-Feb-06 1:51 
GeneralRe: Joystick value Pin
Danny198213-Feb-06 12:27
Danny198213-Feb-06 12:27 
QuestionOpening the Shell File/Folder Properties Dialog Pin
DigitalKing12-Feb-06 12:53
DigitalKing12-Feb-06 12:53 
AnswerRe: Opening the Shell File/Folder Properties Dialog Pin
Ravi Bhavnani12-Feb-06 13:12
professionalRavi Bhavnani12-Feb-06 13:12 
GeneralRe: Opening the Shell File/Folder Properties Dialog Pin
DigitalKing12-Feb-06 13:39
DigitalKing12-Feb-06 13:39 
Great! Thanks.

In case anyone else is interested, here's the code I came up with.
private const uint SW_SHOW = 5;
private const uint SEE_MASK_INVOKEIDLIST = 0xC;
private struct SHELLEXECUTEINFO
{
    public int cbSize;
    public uint fMask;
    public IntPtr hwnd;
    public string lpVerb;
    public string lpFile;
    public string lpParameters;
    public string lpDirectory;
    public uint nShow;
    public uint hInstApp;
    //optional fields
    public string lpIDList;
    public string lpClass;
    public IntPtr hkeyClass;
    public IntPtr dwHotKey;
    public IntPtr hIcon;
    public IntPtr hProcess;
}

[DllImport("shell32.dll")]
private static extern long ShellExecuteEx(ref SHELLEXECUTEINFO s);

public static void DisplayFileProperties(string path)
{
    SHELLEXECUTEINFO shInfo = new SHELLEXECUTEINFO();
    shInfo.lpFile = path;
    shInfo.nShow = SW_SHOW;
    shInfo.fMask = SEE_MASK_INVOKEIDLIST;
    shInfo.lpVerb = "properties";
    shInfo.cbSize = Marshal.SizeOf(shInfo);
    ShellExecuteEx(ref shInfo);
}

QuestionProblem for change datagrid property in form1 from other forms Pin
hdv21212-Feb-06 12:45
hdv21212-Feb-06 12:45 

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.