|
I have sql query in C#
SELECT Last_Date
FROM MYTABLE
WHERE Last_Date > CONVERT(DATETIME, '13.11.2007 22:43:50', 103)
Note: Last_Date column data type is datetime
Example; If my Last_Date column like this
13.11.2007 22:43:49
13.11.2007 22:43:50
13.11.2007 22:43:51
So this query return this values
13.11.2007 22:43:50
13.11.2007 22:43:51
If I change ">" operator to ">=" operator, result is same. How can I eleminate "13.11.2007 22:43:50" value? I want to get greater than (">") values.
Thanks..
|
|
|
|
|
There is a micro second component, I believe. Try 22:43:50.999
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 )
|
|
|
|
|
Yes, its true. I know but how can I solve my problem. I think this is related about style code "103". But I don't know which style code is correct my problem. I search but I can't find.
|
|
|
|
|
First of all what u need to do AFAIK is to split the datetime into three parts lik date,time and am/pm. then put the checking.this will fetch u the xact result.
Cheers
Bino
www.codepal.co.nr
|
|
|
|
|
Hello,
How can I make a button's backgroundimage enabled when I clicked the button.
Normally, I wrote, button1.bacgroundimage=null; There is button's background image, firstly, I want not to show, after clicking I want to show this background image.
|
|
|
|
|
Thanks for quick reply,
but, in design page, I gave one image as button's background image in properties after that when i clicking to button, i want to see this backgroundimage.(i am beginner in programming)
|
|
|
|
|
Thanks so much for your answers.
I can make now.
|
|
|
|
|
I need to do the following automatically.
1. Detect when or if a pocket PC is connected via USB
2. If connected, search for a specific xml file on the pocket PC
3. Copy the file to the desktop hard drive
4. Delete the file from the pocket PC
Any help or pointers to get me started would be great!
|
|
|
|
|
|
Many thanks! Seems to be just what I need to get started.
|
|
|
|
|
Hi,
In a dataGridView, I can Load data from single table of DB and save back the changes to DB using SqlDataAdapter,DataTable,SqlCommandBuilder (for auto generate of Insert,Update,Delete statements).
Now this don't work on View (Join and nested query), that data gets from multi Tables.
How can I do this to this operation done on Multi Tables?
Best wishes
|
|
|
|
|
Wouldn't a neat and cool stored procedure that handles the Insert/Update/Deletes be more cool, elegant and robust, since you particularly mentioned about multi tables?
|
|
|
|
|
Hi All
I have a problem. I have a field that holds a country code and a combobox that has a list of of all countries. I would like to search for the country code from the combo box list of countries, get its index and display it in the combo box as the default item.
Any suggestions will be greatly appreciated.
Thanks
|
|
|
|
|
Does this help?
int nIndex = combo.FindString (field.Text);
if (nIndex != -1) {
combo.SelectedIndex = nIndex;
combo.Text = combo.SelectedItem.ToString();
} /ravi
|
|
|
|
|
Thanks Ravi it worked
Below is the final code:
private void pnlDriverAddress_Enter(object sender, EventArgs e)
{
if (Mode == eMode.Add || Mode == eMode.Edit)
{
if (cmbDACountry.SelectedIndex == -1)
{
int nIndex = cmbDACountry.FindString(MDI.Country.ToString());
if (nIndex != -1)
{
cmbDACountry.SelectedIndex = nIndex;
cmbDACountry.Text = cmbDACountry.SelectedItem.ToString();
}
}
}
}
|
|
|
|
|
Hello everyone,
I have a WebBrowser control in my Windows Application. If I am not mistaken the WebBrowser control is just the parsing engine of the browser.
I would like to transform the WebBrowser control into a full-fledged browser like Microsoft® Internet Explorer, and like to add a custom tool bar with new feateures (buttons) for the custom built tool bar. If I am not mistaken that sould be done using Browser Helper Objects (BHO).
I was wondering if anyone canbe kind enough to point me to the right direction for this project.
Thank you very much and have a great day.
Khoramdin
|
|
|
|
|
Khoramdin wrote: If I am not mistaken the WebBrowser control is just the parsing engine of the browser.
No, it's also a full-fledged renderer and controller.
/ravi
|
|
|
|
|
how i can connected to USB barcode scanner ?
And read barcode from this device programming
123
|
|
|
|
|
Most barcode scanners act just like a keyboard and will send the data scanned directly to the control that has the focus without any programming. If yours is different, consult the manufacturer's documentation.
|
|
|
|
|
thanks. but i meaning my programm read from scanner by timer.because some time lost focus of control
then barcode can't send data to control(Textbox)
123
|
|
|
|
|
|
i have big probelm when you used Localiztion
these my code:
public Form1()
{
Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("ar-eg");
Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("ar-eg");
InitializeComponent();
}
Form2 f;
private void Form1_Load(object sender, EventArgs e)
{
f = new Form2();
f.MdiParent = this;
f.Show();
f.BringToFront();
}
when Maximized Form(f) then Minimized and
then Maximized Form(f) send to back and i can't see my form2(f)
123
|
|
|
|
|
Hi there.
I urgently want to have my c# app running in a firefox session as a
plug-in. There is this one article describing how to implement an
OpenGL sample as a firefox plugin[^] but that one is for C++ only.
How to achieve the very same for some C# app ?
|
|
|
|
|
The plug-in itself will have to be in native code. From there, have your plugin load a control from your .NET app and display it in the window.
|
|
|
|
|
Yes, that's what i thought myself so far.
I'm just installing my old dust-bitten copy of MSVC++ 6.0 to do this.
So there is no easier way to achieve what i'm asking for ?
As i wish to have my app running as a plug-in for FF and IE as well,
i suppose i'll end up having THREE projects:
The main app itself, written in C#,
the app compiled as ActiveX user control, so it can be plugged into IE,
the app compiled as dll, wrapped into C++ code, so it can be plugged into FF.
Correct ?
|
|
|
|