|
|
|
how can print text in position 10' , 20' in the paper
Palestine
|
|
|
|
|
|
Hi,
I have a variable called "toDate" which is a string containing "10/1/2006". I need to pass it to a SELECT statement as follows:
selectTransactions.CommandText = "SELECT * FROM [transactions] WHERE ([Date] > #6/1/2006#) AND ([Date] < #toDate#) ";
It doesn't work of course - how do I get the variable into the statement?
Glen Harvy
|
|
|
|
|
Use parameters:
myCommand.CommandText = "SELECT ColumnNames FROM TableName WHERE DateColumn = ?";
myCommand.Parameters.Add("?", toDate);
NOTE: The parameters must be added in the order they are specified in the SELECT statement. The ? represents the placeholder for the parameter.
|
|
|
|
|
|
Hey.
I know that the Structured Query Language for MDB (Access) is differrent then the SQL of MySQL.
I'm currently moving my databases from Access to MySQL, but I don't know the syntax of the SQL.
If anyone can help me, or give me a dictionary or some internet help and some samples, I would appriciate it.
Thanks alot.
NaNg.
(I've posted this message in SQL\ADO\ADO.NET forum also, but it is very sleepy in there)
|
|
|
|
|
NaNg15241 wrote: I've posted this message in SQL\ADO\ADO.NET forum also, but it is very sleepy in there
That really isn't a valid reason to cross post.
NaNg15241 wrote: I know that the Structured Query Language for MDB (Access) is differrent then the SQL of MySQL.
I'm currently moving my databases from Access to MySQL, but I don't know the syntax of the SQL.
They are both based on the ANSI SQL-92 standard so there should be enough similarities to get you started.
Other than that you should read the documentation for MySql http://dev.mysql.com/doc/refman/5.1/en/index.html[^]. That is the best solution for you because then you will have a better understanding of what MySql is doing.
|
|
|
|
|
i have to use of DrawItem event and I want to set righttoleft=yes for listbox , but it doesnt work!!!!
this.li_author_persian.RightToLeft=RightToLeft.Yes;
help please!!!!
|
|
|
|
|
DrawItem before set RightToLeft=yes?
or after ?
-- modified at 6:49 Sunday 13th August, 2006
|
|
|
|
|
what do u mean by before or after?!!!
<br />
private void listbox1_DrawItem(objectsender,System.Windows.Forms.DrawItemEventArgs e)<br />
{<br />
<br />
this.listbox1.RightToLeft=RightToLeft.Yes;<br />
<br />
}
|
|
|
|
|
do u try set this.listbox1.RightToLeft=RightToLeft.Yes; when you initialize the listbox control?
|
|
|
|
|
I tried it before, but it didnt work.
|
|
|
|
|
may be you need contact MS support.
|
|
|
|
|
Are you eventually using Windows 98 or Millenium Edition? MSDN says that the ListBox.RightToLeft property has no effect on these platforms.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
|
Hmm, in this case I think it has something to do with your custom implementation. If I drop a new ListBox onto my Form and assign RightToLeft.Yes everything works fine.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
Do u use any drawitem event for your list box and set Drowmode in the listbox properties window to "OwnerDrawFixed", the righttoleft wont work !!!
try it .
|
|
|
|
|
No just dragged onto my form from the toolbox. As I said it has something to do with your implementation. If your drawing the items yourself, you have to care about the RightToLeft yourself.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
I found it myself :
use these codes in DrawItem event of the listbox
StringFormat salign= new StringFormat() ;<br />
salign.Alignment=StringAlignment.Far;<br />
Font font=new Font("Tahoma",8,System.Drawing.FontStyle.Bold);<br />
Brush Author_default=Brushes.SaddleBrown;<br />
e.Graphics.DrawString("aaaa",font, Author_default,e.Bounds,salign);
|
|
|
|
|
Hello guys,
I've problem to open SCSI tape device from C#.
I want to work with it in "old way", I mean to create
handle to file ( device file ), then to open stream,
and to perform read/write operations.
1) First problem is that I don't know device file name ( where can I find it )?
2) The second question , is there another way to work with SCSI tape device, I mean is there infrustructure in .NET 2.0 to read/write directly to SCSI tape
|
|
|
|
|
did you get the answer?
I'm exactly in the point that you've mentioned but 6 years later.
|
|
|
|
|
Hi
Help me please
I could change color the rectangular which is showed when an item in listbox is focused, but while the selected item is changing , the color change into a blue again and after a while change into the color which I set for it.
I dont want this changing, what can I do ?!!
|
|
|
|
|
can you post some code which contain your problem?
|
|
|
|