|
Hi Guffa,
I get the following error message:
ERROR [HY104][Microsoft][Microsoft Access ODBC Driver]Invalid precision value
Thanks for your reply. Bye for now.
JC.
|
|
|
|
|
I need to write a .NET Windows Desktop app that interrogates the Windows Task Manager to see what processes are running. This is for a Internet Explorer based Kiosk. The app would check every few seconds to make sure that there is an instance of Internet Explorer running. This is in case that some user who comes to the kiosk terminates Internet Explorer. If Internet Explorer stops running the app would fire off a new instance of Internet Explorer.
How can I interrogate the Windows Task Manager in C#. Is there an API, or set of classes for that? Is there a better way to do this than what I am proposing?
Thanks!
Mark
|
|
|
|
|
You don't need to access Task Manager directly. Use the System.Diagnostics.Process class.
|
|
|
|
|
Ok heres what i'm trying to do:
I'm trying to make a class that will handle all the drawing of my sprites for my game i'm making. This class is dubbed "The SpriteEngine". What the sprite engine does is this: It holds everything that needs to be drawn in an Indexer and when the time comes to draw the stuff it draws each thing to a specific "Layer/Level/Surface" of the screen. There are multiple "Layers" to the screen. Once all the drawning to the layers is done it drawns all the "Layers" to a surface called "back" which is then flipped on to a surface called "front" which is displayed.
My problem is that i need to be able to make the each "Layers" dead space (or the space nothin was drawn on) invisible, so when i stack the layers on to the back surface you can see them all. I was attempting to do this with a ColorKey before, but i recently noticed i was drawning the "Layers" with a Draw cmd not a DrawFast cmd and i can't seem to find a Draw cmd Flag that will take into account a ColorKey?
If anyone has any better ideas on how to do this I would very much appreciate the input!
Note: I'm doing this layering thing so i won't always have to redraw the whole screen even though
only 1 thing changed
Thanks!
|
|
|
|
|
Hi,
I just wanted to get a general Idea about how to record sound with C#. I know you can record sound with DirectSound but as I see it, you can only record from the known Devices.
My problem is, that I want to record sound wich comes from other programs. These programs can be games or voice communication tools or simply everything that comes from your soundcard. It is even possible?
greets,
Alexander
-- modified at 20:05 Tuesday 7th March, 2006
|
|
|
|
|
Hello Alexander,
I donn't know why you want this but suggest you to visit here.
I hope it will fullfil your requirement.
Best of luck
Divyang Mithaiwala
System Engineer & Software Developer
|
|
|
|
|
Hi!
If you select the stereo mixer output as recording device, you can record every sound that's being played, regardless of the application that produces the sound.
Check out the sound & multimedia control panel for a list of audio devices. The audio source used for recording can be selected from the recording volume control.
There are articles here on CP about recording sound via the WaveIn API and articles about the mixer interface. They should be very helpful.
Regards,
mav
--
Black holes are the places where god divided by 0...
|
|
|
|
|
Can call webservice before the form is unloaded(WebApplocation)? How to get the size of IE window?
|
|
|
|
|
I dl a project which contains 2 projects and Im able to run the application in Visual Studio Express but when I
attempt to view the Windows Form it prompts me a Warning.
Im not able to view or modify the form and all its goodies
because of this. The message Im getting claims
"The class Terminal can be designed, but is not the first class in the file. Visual Studio requires that designers use the first class in the file. Move the class code so that it is the first class in the file and try loading the designer again".
Can someone shed some light on this.
P.S. Im new to C# and Visual Studio.
Tks,
mangotj
|
|
|
|
|
You can't have a class defined in that file before Terminal is:
namespace Blah
{
class Terminal { ... }
}
--
I've killed again, haven't I?
|
|
|
|
|
Being more a DB developer and not a graphics or games developer, I'm moving onto a new project where in it's simplest form involves the user specifying a start and end point on the screen, and a duration in seconds where I need to move an image from start to end over the specified period of time. The user might also want to specify the movement is in either a direct straight line or curved.
What's the best approach? Simply calcutate a list of points between A and B for the duration and then move the image using a timer through the list of points. Or is there a standard algolrithm that's normaly used.
Andy
|
|
|
|
|
If you store the coordinates or calculate them on the fly is just a matter of taste. The calculations are not complicated, so it doesn't matter.
Just specify the functions for the x and y coordinates depending on the time. For a linear movement it would be:
x = xstart + (time/totaltime) * dx
y = ystart + (time/totaltime) * dy
---
b { font-weight: normal; }
|
|
|
|
|
Thanks for this. But what if I allow the user to draw a curve on the screen. How do I trace this path. Is there a .NET routine that will provide the points for curve or would I have to calculate the points.
Regards
Andy
|
|
|
|
|
What kind of curve? An arc? A Bezier curve?
---
b { font-weight: normal; }
|
|
|
|
|
Ideally a Bezier curve.
regards,
Andy
|
|
|
|
|
Found the solution for Curves etc.... If I create a GraphicsPath, and a curve, then call Flatten(), the array of points in the GraphicsPath becomes more detailed.
Regards
Andy
|
|
|
|
|
Hi I have following Code attempting to Send email using my Hotmail Account. I am providing correct user information but I am getting Message "Access Denied", Can you please help me how can I get over this problem.
string postBody = null;
// Dump mail headers.
postBody += "MAIL FROM:<" + from + ">\r\n";
postBody += "RCPT TO:<" + to + ">\r\n";
postBody += "\r\n";
postBody += "From: " + quote + fromName + quote + " <" + from + ">\r\n";
postBody += "To: <" + to + ">\r\n";
postBody += "Subject: " + subject + "\r\n";
postBody += "Date: " + timeStamp + " -0000\n";
postBody += "\r\n";
// Dump mail body.
postBody += body;
XMLHTTP xmlHttp_ = new XMLHTTP();
// Open the connection.
try
{
xmlHttp_.open("POST", sendUrl_, false, "myHotmail@hotmail.com", "myPassword");
//MessageBox.Show(xmlHttp_.statusText);
}
catch (Exception err)
{
MessageBox.Show("Error Openning Send Email : " + err.Message);
}
// Send the request.
xmlHttp_.setRequestHeader("Content-Type", "message/rfc821");
xmlHttp_.send(postBody);
|
|
|
|
|
Have you tried using the System.Net.Mail or System.Web.Mail namespace for e-mail?
|
|
|
|
|
I tried with SMTP class of .NET 2 and I have successfully sent email with that. (System.NET.MAIL), But In my application I wanted to use HOTMAIL as an alternative option to SMTP because most of the regular users are not aware of SMTP server and most ISP blocks using different SMTP other than their own SMTP server for sending email. You know what I mean, Right ? So, I am being desperate to use Hotmail as an option. Please help..........
|
|
|
|
|
Hotmail doesn't allow external access without a subscription anymore. That may be the problem, try a e-mail service that allows external access(i.e. - Outlook).
|
|
|
|
|
Hi,
can you give me some more clue about email service of Outlook ? Do every used must have outlook installed to use that service ?
|
|
|
|
|
Outlook doesn't use a service. I was refering to the protocol it uses. When using the HTTP protocol Outlook no longer has access to Hotmail without you paying a sunscription for this ability. Some e-mail services now require that you pay to be able to use third party e-mail software. Now depending on how you are sending your SMTP mail you may have to pay this subscription inorder to be able to use their SMTP server.
Another option is not to use Hotmail's SMTP servers. You might be able to set it up on your machine, or there are many free SMTP servers out there.
|
|
|
|
|
Hi, Actually I am talking about Windows Application, not Website. So, I know there are so many free SMTP servers available, but Most of the ISP blocks their users using any SMTP server other than their ISP provided Server. So, I was looking for an alternative way so that without My software's user's direct attention, email could be sent.
|
|
|
|
|
|
Hi, guys.
I have a MTG Smart Backup drive enclosure with a "one-touch" backup button. However, the backup software that came with the system will only detect physical drives attached to the system. What I want to do is write my own backup solution that will not only work with physical drives, but with mapped network drives.
What I need though, is a way to capture when the button has been pressed. I have tried a search on the internet through Google, but can't find a link to the manufacturer's website. The software was provided by VIA, which doesn't mention the software anywhere on their website.
My thought was to use a Spy or Trace program to capture the message sent from the hardware button to Windows, but I'm having a problem finding such a utility on the Internet, and I only have SharpDevelop and Visual C# Express to work with, neither of which have such a utility that I can find. Any ideas would be greatly appreciated. Thanks.
Flynn
PS -- The enclosure can be found at http://www.geeks.com/details.asp?invtid=EC-2501U[^] and the model number is EC-2501U. A search on Google reveals a number of links to sales sites. I've been unable to find a link a site for the manufacturer.
|
|
|
|