Welcome Guest.   Make a donation to an author on the site October 01, 2014, 05:18:57 AM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
Read the Practical Guide to DonationCoder.com Forum Search Features
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: [1]   Go Down
  Reply  |  New Topic  |  Print  
Author Topic: First real program - Probably need help throughout  (Read 1841 times)
mediaguycouk
Supporting Member
**
Posts: 244


see users location on a map View Profile WWW Give some DonationCredits to this forum member
« on: May 12, 2008, 04:01:56 AM »

A task at work would be easier if I wrote a program to handle it, so I'm going to try and write a C# Application. As I'm new I thought I might document my progress here so you can tell me if I'm being noobish with something or I've missed things.

I learn best by trying and then improving, so this should help me.

The overview is that we have a program called Squeeze that converts files into Flash FLV files. We have a filestore on the same server and Squeeze has 'watch folders' that when you put a file in the folder it will automatically convert it.

This program will have to
  • Check that squeeze is running
  • Look in a database or text file to see which files need moving into the watch folder
  • Move files in and out of the watch folders
  • Move some special files into different folders
  • Send resultant files into a network drive

Things that I don't currently know how to do

  • Check that a program is running
  • Check that a network drive exists and works before sending files to it
  • Most unexpected errors

I'll update you as I go along and please chip in if you see a way of helping.
Logged

Learning C# - Graham Robinson
Renegade
Charter Member
***
Posts: 11,442



Tell me something you don't know...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #1 on: May 12, 2008, 10:45:42 PM »

http://forums.microsoft.c...ostID=499885&SiteID=1

http://www.c-sharpcorner..../FindListProcessesCS.aspx

Those will help for the first one of your questions. i.e.: System.Diagnostics.Process.GetProcesses()

Logged

Slow Down Music - Where I commit thought crimes...

Freedom is the right to be wrong, not the right to do wrong. - John Diefenbaker
mediaguycouk
Supporting Member
**
Posts: 244


see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #2 on: May 15, 2008, 05:12:36 AM »

This all seems to be going remarkably easily. I've been making individual programs to try out all the steps and they seem to be working exactly as they should.

I've got
  • System.IO.File.Copy moving files from folder to folder
  • Timer waiting 10 minutes before checking the watch folders
  • System.Diagnostics.Process.Start starting up squeeze
  • Processes.GetProcesses checking through the open programs to see if my program is already running

Next step is getting the program to check files in and out of a mySQL database. I've done it with a MSSQL database so it shouldn't be too much of a problem. Then I'll just have to put it all together.
Logged

Learning C# - Graham Robinson
Pages: [1]   Go Up
  Reply  |  New Topic  |  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.026s | Server load: 0.32 ]