|
You can use the DrawToBitmap method on your panel, and then copy your bitmap into the clipboard. Copying a control into the clipboard, copies the control. Not a picture of it.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi everybody
I have a combobox on a cell of datagrid
I want do a action flow:
After I chose a value for combobox, I press enter, the cursor have to jump to next cell.
Please help me soon,
Sorry if I write not exactly
If you can please write me a email to dungbt84@gmail.com
Thank you a lot,
|
|
|
|
|
use CellEndEdit or CellValueChanged event, and increase the column index
private void dataGridView1_CellEndEdit(object sender, DataGridViewCellEventArgs e)
{
int Cindex = e.ColumnIndex + 1;
dataGridView1[Cindex, e.RowIndex].Selected = true;
}
hope this will help
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
modified on Tuesday, February 26, 2008 3:16 AM
|
|
|
|
|
thank you for your help but I can't use.
My problem flow:
I have to create a datagrid(for example 5 columns and 3 rows).
If my cursor is at [0,0].When I press enter my cursor jump to [3,0], press enter next it jump to [4,0].
(columns 4 include the comboboxs). After I chose value at combobox. I press enter, the curtor jumb immediate to [1,0].
I think it is so difficult, please help me!
Thank you again,
|
|
|
|
|
so you will need to code yourself, like
if (e.ColumnIndex == 0)
{
}
else if (e.ColumnIndex == 3)
{
}
.........
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I can't do as you said.
Please try to help me again.
|
|
|
|
|
well,
if (e.ColumnIndex == 0)
DGV[3, e.RowIndex].Selected = true;
else if (e.ColumnIndex == 3)
DGV[4, e.RowIndex].Selected = true;
else if (e.ColumnIndex == 4)
DGV[1, e.RowIndex].Selected = true;
hope this will help
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
C# default that if you press enter the cursor jump down. So I can't do like as you said.
I think I have to change control. But I can't.
Please help me!
Thz,
|
|
|
|
|
why you cant do????? if you do then it will work else wont and never
i gave you entire code that you need, just put them in CellValueChanged or CellEndEdit event
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I have to override protected bool ProcessCmdKey(ref System.Windows.Forms.Message msg, System.Windows.Forms.Keys keyData) and use sendkey method.
I finished this problem
Thz you a lot,
|
|
|
|
|
why are you making it complicated, however it could be done by that easy way.
anyway its your wish
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I'm trying to figure out a good way to make an installer for my C# app. It needs to be able to target both 32 and 64 bit systems, downloading the correct version of .NET for each if it's missing from the target system. I looked at InstallShield first as a well-known option, but found that the edition I would need costs around $1.5K. Can any one recommend a good solution for creating installers that doesn't cost quite that much?
|
|
|
|
|
Advanced Installer is a good option, I've used it for years.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hello,
i use ConfigurationManager and i don't find how to add <!-- comments --> and breaklines in my config file between the config.AppSettings.Settings.Add
Is it possible?
|
|
|
|
|
Cptkli wrote: i use ConfigurationManager and i don't find how to add and breaklines in my config file between the config.AppSettings.Settings.Add
Is it possible?
Not using Settings.Add, no it's not. Comments aren't a setting are they? You could get away with doing it using the various methods exposed by the XmlDocument class though.
I'd give you a link to the MSDN docs on XmlDocument, but our firewall sucks and is having a hard time with HTML compression.
|
|
|
|
|
After adding set-up for the project I need to create the folders after the installation path.I am doing this statically now by giving the path and adding
Directory.CreateDirectory("path");
But I want to make this dynamic and I want those folders to be created in any path that user selects.Is this possible?
Thanx in advance.
|
|
|
|
|
Do you want to create directory where program is installed ? Use Application.ExecutablePath to get the executable path, and use Directory.CreateDirectory() to create.
|
|
|
|
|
You can use a FolderBrowserDialog to let the user select a base folder and then use Directory.CreateDirectory() to create the folder he wants. Is that what you are looking for?
Cheers,
Vikram.
"real dictators don't loose[sic] elections." - Diego Moita.
|
|
|
|
|
Thank you Vikram,
Where should I use FolderBrowserDialog?Since the installion path is by default provided by .Net as
C:\programfiles\ProjectName
I need to edit this part so that though the user alters above path next folder after ProjectName is created.
Thank you.
|
|
|
|
|
how to create new folder in runtime using .net with c#
when i register a user details that time create a folader in my particular directory.if u know the code replay to me.
Hi,Im Razana
|
|
|
|
|
Directory.CreateDirectory() ?
|
|
|
|
|
if (!Directory.Exists("D:\\YourFolderName"))
{
DirectoryInfo dirIn = Directory.CreateDirectory("D:\\YourFolderName");
}
|
|
|
|
|
Hi,
I am trying to find if a local printer is connected before printing in my C# application. There are APIs of winspool.drv which give info on printer's status but not if it is connected or no.. Any ideas?
Thanks
|
|
|
|
|
you can use
string printerName = "";
ManagementObjectSearcher searcher2 = new ManagementObjectSearcher("Select Name from Win32_Printer ");
foreach (ManagementObject cdrom in searcher2.Get())
{
printerName = cdrom["Name"].ToString();
}
it gives u the printer name ie installed on your system
|
|
|
|
|
Thanks
I tried the above piece of code.ManagementObjectSearcher gives error, I am using .Net 2.0. I guess this is not included in this version.
Also, this gives the name of the printer installed in the system and not connected to the system. This may work despite of the printer not being connected
|
|
|
|