|
|
try this:
string.format("{0:d10}",345);
|
|
|
|
|
Hello,
When i read the string from BDD, like this :
<br />
oleDbConnection1.ConnectionString = oleconnexion; <br />
this.oleDbDataAdapter1.SelectCommand.CommandText = "SELECT * FROM CSV2 ";<br />
dataSet2.Clear();<br />
oleDbDataAdapter1.Fill(this.dataSet2.Tables["CSV2"]).ToString();<br />
DataTable dataTable1 = dataSet2.Tables[0];<br />
this.oleDbConnection1.Close();<br />
<br />
<br />
String id_client = dataSet2.Tables["CSV2"].Rows[0]["id_client"].ToString();<br />
<br />
the caracters é, à , è shows like square, help me to resolve this problem, thank you verry mutch.
|
|
|
|
|
1. Verify that your database has a correct encoding like utf8 (ie: are the data already fked up?)
2. In your connection string, specify the encoding. It's often some kind of optional parameter.
|
|
|
|
|
In database the caracters are true, thank you verry mutch.
|
|
|
|
|
hi evryone
i have 2 combobox's that fill whit a data
if combo1 is focus and i press [down key] - i whant to focus combo2
(whitout change the selected index place in combo1)
how can i do it ?
thank's for any help
|
|
|
|
|
Catch "Keys.Down" in the appropriate eventhandler, and do a Combo2.Focus();
Enjoy
I are troll
|
|
|
|
|
plus
e.Handled = true; to avoid SelectionChange(I think it may work)
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-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Good call! I alway notice that I forget that line during the first run ^_^
I are troll
|
|
|
|
|
thank's for the help, but i know this
the problem is when i press the down key the focus get to combo2
but, in combo1 the selected item is change - and i whant him to stay
|
|
|
|
|
Just gave it a try, and you're right - it didn't work. At least, not in the KeyUp event. The KeyDown-event did the trick;
private void comboBox1_KeyDown(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Down)
{
e.Handled = true;
comboBox2.Focus();
}
}
Enjoy
I are troll
|
|
|
|
|
thank's !!!!!
|
|
|
|
|
I are troll
|
|
|
|
|
I'm inheriting Process class and add some of my own methods but there is a problem that is preventing me to do so...
public class XProcess : Process
{
public bool GetProc(string name)
{
Process[] tp = Process.GetProcessesByName(name);
if (tp.Length == 1)
this = tp[0]; <<< Error : Cannot assign to '<this>' because it is read-only
else
return false;
return true;
}
}</this>
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-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
You can't assign to "this" as you correctly noticed, but you can return a new instance from your method;
public class XProcess : Process
{
public XProcess GetProc(string name)
{
Process[] tp = Process.GetProcessesByName(name);
if (tp.Length == 1)
return tp[0];
return null;
}
}
Hope this helps
I are troll
|
|
|
|
|
ahm...I do not want to create a new instance, I just want to set the currect instance.
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-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
You can't recreate yourself, since you already exist. I guess the best bet is to clone yourself and dispose of your original self
I are troll
|
|
|
|
|
Hi,
by creating an instance of class Process, you do not create a Windows process, you create an object that represents a new or an existing Windows process.
GetProcessesByName, GetProcessByID and the like create zero or more Process instances and zero processes;
the Process instances contain information about the Windows processes.
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
modified on Sunday, June 12, 2011 8:11 AM
|
|
|
|
|
yes thats why I made it static method now.
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-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Hi,
yes it should be static, it is not using any instance members of the XProcess class.
Two comments:
1.
if that happens to be the only method in the class, no need to inherit from Process.
2.
what do you want to happen when two or more processes exist by that name? at the moment (i.e. the last code shown) you get none of them...
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
modified on Sunday, June 12, 2011 8:12 AM
|
|
|
|
|
This is what I'm using
public static XProcess GetProcessByName(string name)
{
Process[] tp = Process.GetProcessesByName(name);
if (tp.Length == 0)
return null;
else
return (XProcess)tp[0];
}
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-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
modified on Tuesday, February 17, 2009 1:09 AM
|
|
|
|
|
Does that compile?
tp[0] is a Process but not an XProcess, so the method does not return the type its declaration promised.
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
|
|
|
|
|
opppss i copied old one, corrected now
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-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
modified on Sunday, June 12, 2011 8:12 AM
|
|
|
|
|
HAHAHA http://www.codeproject.com/script/Forums/View.aspx?fid=1649&msg=2927732
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-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|