|
i guess you need to communicate with windows API
i would love to know how u will do it!
|
|
|
|
|
Running an application on startup[^]. As far as I know, msconfig reads those registry keys, so it should appear
Between the idea
And the reality
Between the motion
And the act
Falls the Shadow
|
|
|
|
|
Hi,
there are many ways to do this, and it depends on the intelligence you need behind this.
If all you need is a fixed menu item (fixed text, fixed command line to execute) for files, folders or files+folders then it takes two registry entries:
// create registry entries to get an entry in the Explorer context menu for all files and folders:
// (replace AllFilesystemObjects by * for files not folders)
// HKEY_CLASSES_ROOT\AllFilesystemObjects\Shell\SomeNameYouChoose.ContextMenu:
// (Default) Open in my program
// HKEY_CLASSES_ROOT\AllFilesystemObjects\Shell\SomeNameYouChoose.ContextMenu\Command:
// (Default) path_to_my_exe "%1"
If you need some code to run before the context menu appears (because you need to compute the right menu item text, etc) then it gets more complex.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
|
Hi I developed an application (C#) which draws some images on windows form. I am able to load images but trying to load swf file, but when I am trying to do load this swf file I am unable to load it. I tried to load it using flash control which has been provided as a activeX control but using that swf gets loaded but not able to see it properly. My application runs very slowly.
Pls suggest how to run an swf file into .Net (C#)
SNI
|
|
|
|
|
Why not use a WebBrowser control and Navigate to the path of the SWF file?
|
|
|
|
|
no.. it is a requirement that i need to run .swf file in windows form using C#.
SNI
|
|
|
|
|
A WebBrowser control does that. I think it instantiates a COM object representing a flash player behind the scenes anyway, just like the AxShockwaveFlash class. Alternatively, you could parse the file format and draw the shapes with the coordinates specified. I can't help you beyond that though
Between the idea
And the reality
Between the motion
And the act
Falls the Shadow
|
|
|
|
|
Hai!
How to Calculate Total Elapsed time from given starting value and ending value when the the given values are greater than 24(ie Meter Readings)(for eg:Starting time=1015:35,Ending time=1058:15)
Plz Send any Ideas,
Thank You
|
|
|
|
|
what do u mean by 1015:35 is it H:M if it's
TimeSpan end = new TimeSpan(1015, 35, 0);
TimeSpan start = new TimeSpan(1058, 15, 0);
TimeSpan sub= end.Subtract(start);
double TotalSeconds = sub.TotalSeconds;
|
|
|
|
|
DateTime date1 = System.Convert.ToDateTime(txtstarttime.Text);
DateTime date2 = System.Convert.ToDateTime(txtendtime.Text);
TimeSpan ts = new TimeSpan();
ts = date2.Subtract(date1);
DateTime dt = DateTime.MinValue.Add(ts);
txttottime.Text=ts.Hours + ":" + ts.Minutes + ":" + ts.Seconds ;
I have used this but it Produce error when the given values are greater than 24
|
|
|
|
|
What format are txtstarttime.Text and txtendtime.Text in? Are they hours:minutes:seconds like your output? If so, then you can replace the System.Convert.ToDateTime calls with System.DateTime.Parse("input goes here", "hh:mm:ss", null)
|
|
|
|
|
|
You can replace the System.Convert.ToDateTime calls with System.DateTime.Parse("input goes here", "hh:mm", null). The first parameter will be your Text properties instead of the string "input goes here"
|
|
|
|
|
Hi,
Hmm, you need to stop for a moment and think about what you are trying to do.
If the measured time span is 24 hours or more then information about the number of days that have passed is required to perform the calculation.
If the time span is guaranteed to be less than 24 hours the following pseudocode is valid
duration = endtime - starttime;
if duration < 0 then duration = duration + 24 hours;
Note how this would fail as soon as the actual time span is 24 hours or more.
Alan.
[EDIT corrected error in code fragment]
modified on Sunday, May 31, 2009 9:29 AM
|
|
|
|
|
u can use this but i don't recommend it
string x1="1015:35";
string[] r=x1.Split(':');
TimeSpan end = new TimeSpan(int.Parse(r[0]), int.Parse(r[1]), 0);
//bla bla bla
//bla bla bla
TimeSpan sub= end.Subtract(start);
|
|
|
|
|
If you convert those strings to DateTime structures (possibly using DateTime.ParseExact, I don't know the exact form of the strings you gave) then you can simply subtract the starting time from the ending time to get the elapsed time as an instance of the TimeSpan structure. That lets you access such properties as TotalHours, TotalMinutes, TotalSeconds and TotalMilliseconds
|
|
|
|
|
Dear all,
I am assigned to a project where I have to develop a web service which will serve client with different video files according to some certain criteria of the client. A large number of video files will be stored in the web server for this purpose and in the client end a C# application will be used for watching the sent video.
I am a newbie. I have basic idea on designing webservice and consume them from client end. But I've never dealt with video stuffs. Please give me an insight on how can I start designing this project. Also please refer me some useful articles regarding this. I have to design both the server and client end softwares.
with thanks
|
|
|
|
|
Hallo,
I have the follwing problem:
I bought es closed source dll which has several non
virtual methods which I want to override in order
to do model based testing.
Does anybody know a trick by using System.Reflection or
anything else to override a non virtual method?
|
|
|
|
|
You can try the "Subclass and override" technique for non-virtual members.
Here is an explanation of this technique: [^]
I hope this helps you to solve your problem.
Nuri
|
|
|
|
|
No, I don't know of any way to do that at runtime. Most mocking frameworks require methods to be virtual (DynamicProxy[^]..).
TypeMock[^] somehow manages to do that for non-virtual methods, but is unfortunately closed source.
Have you thought about doing this with compile time flags and the "using" declarative? Something like
#if DEBUG
using MyType = Project.MockTypes.MockType
#else
using MyType = Project.RealTypes.RealType
#endif
|
|
|
|
|
No, you can't, you should wrap the classes instead.
|
|
|
|
|
Hello,
i am using microsoft indexing services for searching documents. but when i search for arabic words an error occur indicating that following : --The query contained only ignored words--.
Any help was appreciated.
Regards.
dghdfghdfghdfghdgh
|
|
|
|
|
Show me the Query ,
And fix your Signature
I know nothing , I know nothing ...
|
|
|
|
|
I have an application that uses some transparent windows that are put on an other application's windows. These transparent windows contains some boxes that are meant to show some information on the windows of the other application. A need that when the use clicks on the transparent parts of my windows, mouse clicks are carried to the element that is below my transparent windows.
I use a .net Form with background color set to the transparentkey.
Everything works good under Win XP but under Vista the transparent window blocks every mouse click , it's transparent for the eyes but not for the mouse.
Anyone knows a solution?
|
|
|
|