|
There is nothing wrong with your query per se, but it's better to avoid using strings as dates in your code when talking to databases - if the date formats are different, you will land in trouble.
It would be better still to avoid queries and use stored procedures.
Cheers,
Vikram.
"But nowadays, it means nothing. Features are never frozen, development keeps happening, bugs never get fixed, and documentation is something you might find on wikipedia."
- Marc Clifton on betas. Join the CP group at NationStates. Password: byalmightybob
|
|
|
|
|
Hello all,
I am rather new to .Net and c# and I'm involved in a project using ip cameras to acquire video in asf/MPEG4 format. I would like to convert these videos to avi. I don't really want someone to give me an entire application to do this, but rather to point me in the general direction which I should take. I have already searched a bit on the net, but I haven't found a lot of interesting stuff.
Thank you in advance for any help you might give me.
Erik Ekhaugen
|
|
|
|
|
I remember a hosted service like Media-convert.com
|
|
|
|
|
A program that I use that I do not believe has a programming interface that you can use with C#, is Super Video Converter. It converts video/audio of any file format to that of another. However, as said, I do not believe it can be used programmatically.
Regards,
Thomas Stockwell
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.
Visit my homepage Oracle Studios[ ^]
|
|
|
|
|
How do you create a mesh file with the .x extension?
-----
Note: *** Never give me an answer have anything to do with Visual Studio. I don't have this program, and it'll be that way for a long, long time. ***
|
|
|
|
|
Use a 3D modelling package to design your objects and export them to DirectX .X format.
Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic 2006, 2007
|
|
|
|
|
What I am attempting to do (Probably isn't possible) is get a filled System.Configuration.Configuration object based on the executable or dll location\\name. I want to get the user settings from the configuration file. I found a function called System.Configuration.ConfigurationManager.OpenExeConfiguration() that seems to do ALMOST what I want. You can EITHER send in the exe location\\name OR a configuration user level. It would be great if I could send in both the exe location\\name and the user level. Basically what I want to do is have App1 change the user configuration settings of App2, App3, and App4. Is there anyway to do this?
Chris
|
|
|
|
|
Hi,
Do you people know when you click once in a treeview node in explorer for example?
We can then rename directly that item.
What do i need to do in order to implement that?
Thx,
Nuno
|
|
|
|
|
You may create a custom control that on the rename shortcut converts the node head to a textbox and take the text and set it .
OR
Handle the F2 shortcut for example, and pop a custom messagebox up, take the new name, and set the text to it.
|
|
|
|
|
Here is some code, you can refer,
string
selectedNodeText;
private void RenametoolStripMenuItem_Click(object sender, EventArgs e)
{
TreeNode node = this.treeView.SelectedNode as TreeNode;
selectedNodeText = node.Text;
this.treeViewTestplan.LabelEdit = true;
node.BeginEdit();
}
void treeView_AfterLabelEdit(object sender, System.Windows.Forms.NodeLabelEditEventArgs e)
{
TreeNode node = this.treeView.SelectedNode as TreeNode;
this.treeViewTestplan.LabelEdit = false;
if (e.Label.IndexOfAny(new char[] { '\\', '/', ':', '*', '?', '"', '<', '>', '|' }) != -1)
{
MessageBox.Show("Invalid StepName.\n" +
"The step Name must not contain " +
"following characters:\n \\ / : * ? \" < > |",
"step name Edit Error", MessageBoxButtons.OK,
MessageBoxIcon.Error);
return;
}
if (string.IsNullOrWhiteSpace(e.Label))
{
MessageBox.Show("Step name is Invalid");
e.CancelEdit = true;
return;
}
string label = (!string.IsNullOrEmpty(e.Label) ? e.Label :selectedNodeText);
if (null != e.Label)
{
(node.ExecutionObject as Step).Name = label;
}
}
void treeView_KeyDown(object sender, System.Windows.Forms.KeyEventArgs e)
{
if (e.KeyCode == Keys.F2)
{
this.RenametoolStripMenuItem_Click(this, null);
}
}
|
|
|
|
|
I am experimenting with a GUI for a character based application.
The existing program has a field that accepts F1, F2, etc to go
from menu to menu. What I would like to do is create a form that
upon clicking a button would pass the corresponding function key
to the field in order to have the application progress.
I don't know if what I want is even possible so just pointing me
in the right direction would be appreciated. I guess this is more
of a general "how do I" kind of question.
Thank you in advance!
|
|
|
|
|
It seems like what you are asking for is the API sendmessage command. It allows you to emulate key presses to another application/window/process.
techydog wrote: What I would like to do is create a form that
upon clicking a button would pass the corresponding function key
to the field in order to have the application progress.
I am a bit confused with this part, otherwise I may be able to be more specific.
Regards,
Thomas Stockwell
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.
Visit my homepage Oracle Studios[ ^]
|
|
|
|
|
What I would like to do is create a button in my app labeled F1 and when pressed the other app would recieve the F1 as if a user had actually pressed the key. My goal is a GUI for the orginal app if that makes sense.
When you say API sendmessage command, is there something I need from the orginal app or is this a .NET component I'm not familiar with?
|
|
|
|
|
The API sendmessage is actually a native command of Windows. I have not used sendmessage to emaulate keypresses but I know it is possible to do so. You may consider googling the subject. To help narrow your search first look for API Viewer and API Guide, these programs will help you in determining parameters and syntax for API calls.
Regards,
Thomas Stockwell
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.
Visit my homepage Oracle Studios[ ^]
|
|
|
|
|
Your help is greatly appreciated. I had now idea as to what to look for but you have pointed me in the right direction. I found a few examples of implenting API and sendmessage here and am now on my way.
Thank you very much for help.
Techydog
|
|
|
|
|
Hi!
i'm trying to list drives on pc. i used System.Management namespace for this purpose.
But i don't want to hear the disgusting noise while listing A: drive.
Does anyone help me?
|
|
|
|
|
If you are using .net 2.0 you can use the new driveinfo class. There is a getdrives method. That doesn't appear to make the A: drive make noise.
If you are using .net 1.1 I guess you could always disable your a: in the bios or something.
Hope that helps.
Ben
|
|
|
|
|
I'm not sure if this will help you.
string[] drives = Environment.GetLogicalDrives();
|
|
|
|
|
hello there,
i am working on a project of speech recognition in c#..
in this project the software will be able to execute some voice commond inputed through a mic. i cant generate grammar for the same
till now i dont have satisfactory progress. can anyone there help me regarding this?
thank you
alok
|
|
|
|
|
Hi ..
By next month i have to start my project, and even i am planning over Image and Speech processing.
So i dont think ill be of any help to you at the moment . But yeh you could be definately help to me. So when u get the right path then also do let me know about it and we can work on it together if you are not waiting for its completion that sooner.
Thanks
SS
|
|
|
|
|
|
Does anybody know how Microsoft is saving the rating info for e.g. images?
As far as I can discover, it is not saved in exif- or IPTC-tags.
Purpose is to use the rating info entered with Vista Photo Gallery in an other program...
|
|
|
|
|
I believe this is done with some kind of shell extension. Search this site's articles for shell-related interop, I believe there are some articles that show how to extend the shell to retrieve and save your own information per file.
I could be way off, though. Like ID3 tags, it may be stored as part of the file itself. I'm not a COM expert, nor a shell expert, so take this with a grain of salt.
|
|
|
|
|
i have four text box for different field(name,city,state,country) for searching and three different criteria of search(like member/guest/vendor)
i simply use if else statements but it is too long method
can any one tell me simplest way to impliment it
i use c# for code.
|
|
|
|
|
You can use switch statements to handle lots of if/else logic:
string s = "foo";
switch(s)
{
case "bar":
Console.WriteLine("It was bar!");
break;
case "foo":
Console.WriteLine("It was foo!");
break;
case "baz":
Console.WriteLine("It was baz!");
break;
}
|
|
|
|