|
I am trying to launch the winzip.exe application from within my application and when I use the System.Diagnostics.Process method It errors out.. can someone please provide me with a simple shell of code that would accept the winzip.exe application name and file path, src file and dest file and a waitPeriod param. I really need this
I am using C# 2005 studio express.
Thanks
mrcaston@webcust.com or
marselle.r.caston@jpmchase.com
MRC
|
|
|
|
|
Hello
I suppose you write it like this:
Process.Start(@"C:\Program Files\Winzip\Winzip.exe %1 MyFile.zip");
or something similar? Instead, only write the zip file name:
Process.Start("MyFile.zip");
and the windows explorer will launch the default program associated with that file type -usually will be Winzip-.
Regards
|
|
|
|
|
Hi
Use this one.
process1.StartInfo.FileName="C:\\Program Files\\Winzip\\Winzip.exe";
process1.StartInfo.Arguments="Myfile.zip";
process1.Start();
enjoy!!!
<marquee>nishu
|
|
|
|
|
How to change the color of the complete row in my datagridview?
1. read the information from a file //DONE!
2. fill the cells with information //DONE!
3. add the cells to the row //DONE!
4. add the row to the datagridview //DONE!
5. display the datagridview //DONE!!
This is what should be done:
if the cell[0] Value == "FALSE"
set the row backgroundcolor to red
think this has to be done between step 3 and 4.
Would appreciate every hint.
Thx,
Ezazazel
|
|
|
|
|
Hello
Try changing DataGridView.Rows[X].DefaultCellStyle.BackColor for that row.
Regards
|
|
|
|
|
There is a property called AlternativeColor, i think. That property makes every second row a different color.
|
|
|
|
|
Is there an implementation for CORBA in Visual Studio 2005 / especially C# (free- or gnu would be perfect)
If yes, where can I get it?
Thx,
Ezazazel
|
|
|
|
|
You mean like this[^]?
Sorry... I cheated and used Google.
led mike
|
|
|
|
|
found the same one but it cannot be downloaded
I do use google...
|
|
|
|
|
ezazazel wrote: but it cannot be downloaded
I downloaded it with no problem.
led mike
|
|
|
|
|
no, not for me - not a single link works, always 404 error
could you plz post your dl -link
thx
|
|
|
|
|
at the bottom of the page it says:
Remoting.Corba development is hosted on SourceForge at http://sourceforge.net/projects/remoting-corba/ .
led mike
|
|
|
|
|
|
I would like to show a VC8 C# Form inside a VC6 C++ MDI application. Is this possible? If so can anyone refer me a web-site as to how this is done? I am thinking about creating a C# DLL that can be loaded into the VC6 C++ MDI application that can return Child window.
Chris
|
|
|
|
|
I want to write a program in c# with this feature:
program call to a phone number and when phone have been answered,play a sound message(Wave file)for it.
please guide me how can i do it?
|
|
|
|
|
Hello
This will involve 2 parts:
1- Calling the phone : You will be using something calld TAPI 3.0 to do it.
2- Playing the audio stream to the modem's voice line: You'd use DirectX to do it.
Search CodeProject's articles section for details.
Regards
|
|
|
|
|
Excellent and Great. I really did not know that dialing phone call was so easy with C#. I already found a nice article in CodeProject for using TAPI.
http://www.codeproject.com/cs/internet/devangpro.asp[^]
Before I was harvesting for articles in google about dialing phone using C# and I did not know the right keyword and I ended up with some commercial libraries which was sooo expensive like starting from 1000US$.
By the way,
Nader Elshehabi wrote: 2- Playing the audio stream to the modem's voice line: You'd use DirectX to do it.
-- Why do I need so complicated solution to play audio stream to the modem's voice line ( I mean, using DirectX). Should not there be some easy windows method to play mp3 files directly to Modem's Voice line ?
Do you know any article which describe How to play mp3 files or direct Microphone line to Modem's voice line ?
Regards and thansk always
As you are the best friend for all C# coders in this forum.
Emran
|
|
|
|
|
Hello
Well, now we know TAPI could save someone 1000$. This could work as a commercial .
Playing audio directly to any audio line using DirectX sound reasonable, doesn't it? It's all I can think of.
About the article try this[^]. I don't think it considers modem voice line, but it discusses audio lines in general. If it doesn't work, hint me and I'll investigate more.
Extra Regards
|
|
|
|
|
Hi.thanks for your guidances.
I downloaded TAPI 3.0 example but I receive this error message during execution of program:'compobj.dll is too old for the ole2.dll initialized (Exception from HRESULT: 0x8004000E (OLE_E_WRONGCOMPOBJ))'.
please introduce a higher version of this DLL file.
best regards.
|
|
|
|
|
Posting the code that throws that exception would do some help. I think it is not TAPI related at all!!
Regards
|
|
|
|
|
Hi.
I use this code to call to a number:
TAPI3Lib.ITAddress ln=null;
ln=ia[line];
if(textBox1.Text.Length!=0)
{
MessageBox.Show(""+textBox1.Text,"Calling to");
try
{
if(!h323)
{
bcc = ln.CreateCall(textBox1.Text,TapiConstants.LINEADDRESSTYPE_PHONENUMBER|TapiConstants.LINEADDRESSTYPE_IPADDRESS,TapiConstants.TAPIMEDIATYPE_DATAMODEM|TapiConstants.TAPIMEDIATYPE_AUDIO);
bcc.SetQOS(TapiConstants.TAPIMEDIATYPE_DATAMODEM|TapiConstants.TAPIMEDIATYPE_AUDIO,QOS_SERVICE_LEVEL.QSL_BEST_EFFORT);
bcc.Connect(false);
}
else
{
bcc = ln.CreateCall(textBox1.Text,TapiConstants.LINEADDRESSTYPE_IPADDRESS,TapiConstants.TAPIMEDIATYPE_AUDIO);
bcc.Connect(false);//I receive Error in this line!!!
}
}
catch(Exception exp)
{
MessageBox.Show("Failed to create call!","TAPI3");
}
}
else
{
MessageBox.Show("Please enter number to dial.. ");
}
best regards.
|
|
|
|
|
I think this should be:
bcc = ln.CreateCall(textBox1.Text,TapiConstants.LINEADDRESSTYPE_PHONENUMBER,TapiConstants.TAPIMEDIATYPE_AUDIO);
bcc.Connect(false);
if you want to make a voice call. Why set it to DATAMODEM?!!
Regards
|
|
|
|
|
thank you so so much.your guidance solve my problem.now please help me in these cases:
1-how can I understand that phone have been answerd by program code?
2-how can I play a wave file for listener?
I have a special thanks.
best regards
|
|
|
|
|
Um.. Sorry! I haven't gone that far in TAPI. There ought to be an event fired when the phone is answered, but I don't remember it. Mose of my work with TAPI was about Data calls. Search for the event notification registration. You should register the event that you want to handle. About the voice file playing, modem's line is just another audio line. You got two options:
1- There is a stream object that is associated with the call -maybe even multiple streams-. Check it out if you can stream your audio through it.
2- Use DirectX to play the audio to the modem's audio line as you would to the speakers.
I hope I could have helped you better, but as I told you, my experience is with data calls. Good luck!
Regards
|
|
|
|
|
Hi.
I wrote a program with C# and use TAPI.My program dial a number and play a wave file for listener.
I use a event handler for managing call state:
m_CTapi.CallStateEvent += new CTapi.CallStateEventHandler(MyCallStateEventHandler);
public void MyCallStateEventHandler(Object sender, CTapi.CallStateEventArgs e)
{
switch ( e.CallState )
{
case CTapi.LineCallState.LINECALLSTATE_CONNECTED:
lsb_CallStatus.Items.Add("Call Connected...");
break;
case CTapi.LineCallState.LINECALLSTATE_DISCONNECTED:
lsb_CallStatus.Items.Add("Call Disconnected...");
break;
case CTapi.LineCallState.LINECALLSTATE_ONHOLD:
lsb_CallStatus.Items.Add("Call Hold...");
break;
case CTapi.LineCallState.LINECALLSTATE_IDLE:
lsb_CallStatus.Items.Add("Call Idle...");
break;
case CTapi.LineCallState.LINECALLSTATE_PROCEEDING:
lsb_CallStatus.Items.Add("Call in Progress...");
break;
case CTapi.LineCallState.LINECALLSTATE_OFFERING:
lsb_CallStatus.Items.Add("Call Offering...");
break;
case CTapi.LineCallState.LINECALLSTATE_ACCEPTED:
lsb_CallStatus.Items.Add("Call Accepted...");
break;
case CTapi.LineCallState.LINECALLSTATE_DIALING:
lsb_CallStatus.Items.Add("Call Dialing...");
break;
case CTapi.LineCallState.LINECALLSTATE_RINGBACK:
lsb_CallStatus.Items.Add("Call Ringback...");
break;
case CTapi.LineCallState.LINECALLSTATE_BUSY:
lsb_CallStatus.Items.Add("Call Busy...");
break;
case CTapi.LineCallState.LINECALLSTATE_SPECIALINFO:
lsb_CallStatus.Items.Add("Call Special Info...");
break;
case CTapi.LineCallState.LINECALLSTATE_DIALTONE:
lsb_CallStatus.Items.Add("Dial Tone...");
break;
}
}
Now my problem:when program dial a number and receive the first telephone ring,MyCallStateEventHandler receive 'Connected' event but I need to understand when a person pick up the phone(and he is listening)????how can I do this?
It's wonderful that these call states never happened:
LINECALLSTATE_ONHOLD,LINECALLSTATE_ACCEPTED,LINECALLSTATE_OFFERING,LINECALLSTATE_RINGBACK,LINECALLSTATE_BUSY,LINECALLSTATE_SPECIALINFO,LINECALLSTATE_DIALTONE
please help me to solve my problem.
best regards
|
|
|
|