|
Glad to help
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Individuality is fine, as long as we do it together - F. Burns
Help humanity, join the CodeProject grid computing team here
|
|
|
|
|
GetFileName returns the name of the file: "song.mp3" - i.e. without the path. If you have this in the current directory (as in the case of the project directory) then it can find it. Give it the whole pathed file name and you should be fine. Try
if (File.Exists(listBox1.SelectedItem.ToString())
{
dsAudioPlayer1....
}
else
{
MessageBox.Show("Cannot find \"" + listBox1.SelectedItem.ToString() + "\"");
}
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|
|
Hi.
I have searched and searched and finally at the end of my tether!
My task is quite simple but I cannot find a solution. I would like to store various lists of Key Value pairs to use in my application as these may change in the future.
Can any one point me in the right direction?
The FoZ
|
|
|
|
|
Hi,
From the design point of view, get a list of all combo box from your applicatoin and save all values in database with combo name and values in one table. Later you can allow to change values by providing configuration screen to the user, that will update the this table.
|
|
|
|
|
Thanks for the reply. It is something that I have considered but it's one of those things where I would like to use the AppConfig file route as that means adding more tables to the already huge database (which is out of my control and will need permission for) and the data is very unlikely to change. It would be a nice hurdle to jump over in my project.
The FoZ
|
|
|
|
|
Hi,
It may be a stupid question But I want to know that is it possible to use IDTExtensibility interface in VSTO projects?
If YES,please give me an example..
Thanks
|
|
|
|
|
my application is windows based (C#.net)
i have two forms both containing a windows media player
i go to first form(Form 1) and start a file in media player now if i go to second form and start a file in media player there also , the media player in form 1 should stop
how will i achieve this??
i have tried all the methods but nothing have worked like
Test ts = new Test(); [First Form]
ts.axWindowsMediaPlayer1.Stop();
ts.axWindowsMediaPlayer1.settings.volume=0;
ts.axWindowsMediaPlayer1.Dispose();
ts.axWindowsMediaPlayer1.currentPlaylist.clear();
ts.axWindowsMediaPlayer1.close();[Error-com object that has been seperated from its underlying RCW cannot be used]
plzz help
|
|
|
|
|
See when you create another object of form1 from form2, it doesn't mean you will get running instance. You need to get instance of same form previously loaded. So from the startup method, create two objects of form1 and form2 and use it in both form instead of creating new object and this will work.
|
|
|
|
|
I have some trouble in implementing the linked list in C#.NET. Is there any specific link or samples available , which gives clear picture as how to implement the doubly linked list in C#.NET.
|
|
|
|
|
|
Why? Use List<T> and it's little cousins. It works, without you having to faff about.
If you must create it yourself, then what is the problem? It's not exactly difficult, just labourious and a re-invention of the wheel...
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|
|
Well, Griff, I think you mean LinkedList<T>, since a List<T> is just a dynamically-resized array.
LinkedList<T> might support his purposes, but it does have some weaknesses... It doesn't let you do some of the fancier things, like splitting a list into pieces, or connecting two lists together to make a larger one... These are things you can do if you implement your own.
Unless .NET has a class that does that, which I just haven't stumbled upon yet.
|
|
|
|
|
right.
Luc Pattyn
Have a look at my entry for the lean-and-mean competition; please provide comments, feedback, discussion, and don’t forget to vote for it! Thank you.
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
Ian Shlasko wrote: I think you mean LinkedList<T>, since a List<T> is just a dynamically-resized array
POETS day disease, probably! (I'm just amazed I remembered to use < and > from the buttons - I normally forget and it all starts to fall apart...)
No trees were harmed in the sending of this message; however, a significant number of electrons were slightly inconvenienced.
This message is made of fully recyclable Zeros and Ones
|
|
|
|
|
|
Hi,
I have the following string and i will pass the filename and then i want to get the corresponding path...
<br />
string url = @" --------------Boundary-00=_BLD1cvEPKmuNkgPvUNY3 Content-Type: text/plain; charset=utf-8; name=footer.txt Content-Disposition: attachment; filename=\""footer.txt\"" Content-Transfer-Encoding: base64 G:\test\Attach\test\footer.txt --------------Boundary-00=_BLD1cvEPKmuNkgPvUNY3-- ";<br />
<br />
Regex r = new Regex(@"[a-z]:\\([a-z1-9\.\s]+\\)+[a-z1-9\.\s]+\.\w",RegexOptions.IgnoreCase);<br />
<br />
string regString = r.Match(url).ToString();<br />
I am able to get the output as :
G:\test\Attach\test\footer.t
In the above url string there maybe a chance that there will be 2 or more attachment codes like the above in the same string. I want to get the path alone like G:\test\Attach\test\ by passing a filename along with extension.
I don't know how to do it? Can someone pls help me out.
Thanks,
Raja.
|
|
|
|
|
Hi,
System.IO.Path class offers methods to operate on paths.
Luc Pattyn
Have a look at my entry for the lean-and-mean competition; please provide comments, feedback, discussion, and don’t forget to vote for it! Thank you.
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
Hi All,
I have developed an application using C# WinApp VS 2005 and MYSQL 5.0.1. My Query is it
possible by any means that I can create a setup application that can identify and install MySQL
Server on the deployment machine if its not installed on it. Also it will run the script file to create
database and user into MySQL Server. I have done some googleing but was unable to find
appropriate answer. Can it be done using InstallShield? If so, How to do it?
Its very urgent.
Please Help me.
Thanx in Advance,
Regards,
Paramhans Dubey
|
|
|
|
|
Hi all,
Is there any other links or forums that you know,
where the DOM related question are posted.
Because i don't get people related DOM here.
if some one has any idea please lead me
thanks
|
|
|
|
|
Hi,
do you need help with the DOM regarding XML. Then I would post the question in the XML/XSL forum. If you need help implementing this in C#, I would post here...
Regards
Sebastian
|
|
|
|
|
syntax error converting varchar valu' ' to a column of datatype int...
i got the above error can anybody tell solution to this...
|
|
|
|
|
if you post the code block that giving this error we'd be glad to help. I don't think anyone here have that prediction ability.
|
|
|
|
|
Hi,
Try to give the code snippet, so that you can get the help immediatly
and try to give proper subject name.
|
|
|
|
|
You are trying to put a varchar value in a integer column. It might be having string which cannot be converted to integer.
It's not necessary to be so stupid, either, but people manage it. - Christian Graus, 2009 AD
|
|
|
|
|
I have absolutely no idea what you're talking about, are you sure you should be posting this in the C# forum?
|
|
|
|