|
RogerLum wrote: I'm currently in my final year and i'm developing a sofware for my final year project.
Well, that's a good start. YOU'RE developing the software.
RogerLum wrote: Would really appreciate if i could also have the developed source code
Oh wait, I was wrong. I thought you said you were developing it?
Tell you what. I'll just get in touch with somebody at Microsoft and tell them I'm developing an Operating System, if only they'll give me the source code to Windows 7 to act as a reference.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
My blog | My articles | MoXAML PowerToys
|
|
|
|
|
Dear All
I've been trying to code a code that record the users' voice from the mic but I seem to get stuck in some portion in which it keep showing me the error that the Microsoft.visualbasic.devices is missing? any help
here is my code incase the problem is on my code
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Microsoft.VisualBasic.Devices;
using Microsoft.VisualBasic;
using System.Runtime.InteropServices;
namespace WindowsApplication1
{
public partial class Form1 : Form
{
[DllImport("winmm.dll", EntryPoint = "mciSendStringA", CharSet = CharSet.Ansi, SetLastError = true, ExactSpelling = true)]
private static extern int mciSendString(string lpstrCommand, string lpstrReturnString, int uReturnLength, int hwndCallback);
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
}
private void Record_Click(object sender, EventArgs e)
{
mciSendString("open new Type waveaudio Alias recsound", "", 0, 0);
mciSendString("record recsound", "", 0, 0);
}
private void SaveStop_Click(object sender, EventArgs e)
{
mciSendString("save recsound c:\\record.wav", "", 0, 0);
mciSendString("close recsound ", "", 0, 0);
Computer c = new Computer();
c.Audio.Stop();
}
private void Read_Click(object sender, EventArgs e)
{
Computer computer = new Computer();
computer.Audio.Play("c:\\record.wav", AudioPlayMode.Background);
}
}
}
|
|
|
|
|
Stop using the Computer class, and use the same instance of a SoundPlayer class instead
|
|
|
|
|
I'm not familiar with that class really; thankx for your help I appreciate it
|
|
|
|
|
The SoundPlayer class is new to the .net framework, version 2.0. It provides the StartAsync and Stop methods. Put it as a variable in the SaveStop_Click and the Read_Click voids, and instantiate it. Then, just call the methods. Overall, it would look like this:
private void SaveStop_Click(object sender, EventArgs e)
{
SoundPlayer player = new SoundPlayer();
player.Stop();
}
private void Read_Click(object sender, EventArgs e)
{
SoundPlayer player = new SoundPlayer(@"C:\record.wav");
player.PlayAsync();
}
|
|
|
|
|
Project-Add Reference-
in the .Net Option Find Micorsoft.VisualBasic and Add it to the Reference
you will find you can using the namespace now;
|
|
|
|
|
hi!!
Am developing smart device application using vs2008(.net compact framework 3.5)now my query is how to rollover the picures using c#.net ?am usig picturebox control...can anyone please help me...
Thanks in Advance...
|
|
|
|
|
mouseover
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
I'm not certain whether the CF supports this, but you could use the MouseEnter and MouseLeave events
|
|
|
|
|
if I'm not wrong then almost all smart devices are touch screen. And that thing is not gonna work...isnt it ?
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I've come across this problem. you can do on touch to change it but on mouse over, like you I don't think would work.
|
|
|
|
|
Hi Friendz,
I developed a c# application and I want to run it as a Web Service.
How could I do that?
Please help me.
Warm Regards,
Sreenivas
|
|
|
|
|
There are loads of references and samples for developing web services in c#, MS even include a template project. Google will give you thousands of examples.
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
I am using window application in C#
I have a form having five user control and each user control having multiple controls or may have multiple user controls.
I want to do validation in each child controls in the form using DICTIONARY.
Once user clicks the OK button user will come to know in which user control's child control having the error with proper message.
Can any one guide me plzz
with regards
|
|
|
|
|
hey friends,
am developing an automation addin to excel using c#, upon building and running my project, an excel instance opens up. Now, i have somethings relevant to this excel to save to an xml. Thus, I need a seperate xml to every seperate instance of excel. For later uses I should be able to save my excel sheet and upon opening this saved sheet, I should be able to read from the corresponding xml file too! I am generating the xml file in my code itself. Thus, I need a unique name/id to name these "excel---xml" pairs and thus be able to read from the corresponding xml whenever i open any saved sheet.
more or less like.. i need... book1.xls----book1.xml & book2.xls----book2.xml & so on...
regards.
|
|
|
|
|
How about Guid.NewGuid() ?
|
|
|
|
|
but hey, i should be able to save the sheet and re open and re use the sheet and its corresponding xml right... this guid.newguid() would give every time a new globally unique identifier. This way, how can I fetch the guid of my currently opened sheet(which was saved earlier) so that I'll open the correct xml?
|
|
|
|
|
I think you must create a new Guid using Guid.NewGuid() and put that Guid in your excel sheet and xml. Then if you open it, just open the excel sheet, get the guid from that sheet, and find the same guid in xml.
|
|
|
|
|
erm.. will have to work on it..
|
|
|
|
|
Is there a way I can know whether my Instance(excel) is saved or not?! So that I can use in the OnDisconnection() part of the code?!
|
|
|
|
|
Why not use something like YourApplication00001.xls
Keep an internal counter somewhere and increment the 1 evertime it is opened.
You could even ask the user for the name to use if you wanted to.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
well, he might not save certain instances at all... nd i feel it's weird to ask something like.. would you like to save this? If yes, enter the name, because it's quite variable, if in the last moment he decides to save... hence i need something like... MyApplication.guid() or something.. I've tried using Hinstance..Index.. blah blah.. but no help.
|
|
|
|
|
I would assume that the c# DLL can get access to the user.applicationdata folder so you should be able to store the number in there. Add enough 0 so you can not reasonably run out. Not sure an xl add in has that access though.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
im currently working on a C# project which needs to program out a font dialog box.
i have searched the net but mostly of them are those kind which have to click on a button before the font dialog box pops out.But i want the font dialog box to be on my form.When i debug, i see the font dialog box and i can display my selected font on a sample box there.
Hope that someone can understand and help me.
Thanks in advance.
|
|
|
|
|
Dude for that you need to make your own . . .
You need to make buttons and generate events, etc etc. .
|
|
|
|