|
|
How can i control a digital camera using c# in windows application? If anyone has any idea please help me out...
|
|
|
|
|
Vicky2Galaxy wrote: How can i control a digital camera using c# in windows application?
If it comes with a development API, you can use that, else I don't think you can handle it.
|
|
|
|
|
Selected Canon cameras come with full SDK support, the SDK is free from Canon, and I have an article on Code Project ( this site ) with a C# wrapper for that SDK and a sample application.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
|
Hello everyone,
I think tonight is not my night... I wondering if any of you has gotten this exception or know why i am getting it.
System.InvalidOperationException was unhandled
Message="SetCompatibleTextRenderingDefault must be called before the first IWin32Window object is created in the application."
Source="System.Windows.Forms"
StackTrace:
at System.Windows.Forms.Application.SetCompatibleTextRenderingDefault(Boolean defaultValue)
at Client.Program.Main() in I:\Documents\Server\Client\Client\Program.cs:line 17
I have 2 applications a client and a server and i Compiled them both on the same computer before it did not seem to be any problem but not it does...
I wonder why?
Thanks in advance
Luis E Tineo S
|
|
|
|
|
Looks like a race condition, and it looks like you're setting this property too late in your application's lifetime.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
I don't really understand but how can I fix it because running it from within vs2005 I don't get the exception on either the client or the server !?
Luis E Tineo S
|
|
|
|
|
What do you do before you call SetCompatibleTextRenderingDefault? If you create an instance of a form, simply do that after the call to SetCompatibleTextRenderingDefault.
Experience is the sum of all the mistakes you have done.
|
|
|
|
|
Good Day Sir/Maam,
I know my subject is so confusing, sorry. I'll explain a bit more clear.
If you have winzip or winrar installed on your computer, there will be a menu named "Add to filename.zip" or "Add to filename.rar" when you right click a file.
I want to implement this feature in my project (I am asked by my professor to create a file encrypter application). So I want to have a "Encrypt this File" menu in the "right click" menu.
For starter, if I click the "Encrypt this File", I want the file path of the file to pop up on the message box of my program. How can I go about with this?
Sorry if I my english is really bad.
Thank you in advance.
|
|
|
|
|
You have to work with windows registry !!!
|
|
|
|
|
Good Day Abhijit,
I am aware of that fact. I just read this CP article -> http://www.codeproject.com/csharp/appendmenu.asp
However, there is no instruction on how to add an icon for the context menu.
Do you have any idea on how to put an icon on the left of the context menu?
|
|
|
|
|
|
Thanks for the reply.
I have been reading http://www.codeproject.com/csharp/SimpleContextMenu.asp but can't find a way to apply the command to all files (*.*), the instruction there was file type specific.
In my case, I want to allow the user to right click any file type and be able to "encrypt" it.
Thank you!
-- modified at 2:49 Wednesday 14th November, 2007
|
|
|
|
|
If u get an answer for this pls inform me,im also interested in this
pls mail me
seanarcher25@gmail.com
Cheers
Bino
www.codepal.co.nr
|
|
|
|
|
http://www.codeproject.com/csharp/SimpleContextMenu.asp[^]
Process Narrative for ALL FILES/FOLDERS:
1. [HKEY_CLASSES_ROOT\*\shell] -> Create Shell Key Under \*\
2. [HKEY_CLASSES_ROOT\*\shell\opennotepad] -> Add Context Menu
@="Open with Notepad"
3. [HKEY_CLASSES_ROOT\*\shell\opennotepad\command] -> Specify Command
@="C:\\WINDOWS\\system32\\NOTEPAD.EXE %1"
|
|
|
|
|
Hi All,
Iam having one table in that i have 3 fields
UserId Password ULock
veeresh xyz 1
1-Unlock
0-Lock
If some budy enters wrong password 3 times that userid should be locked.
i.e ULock value should be 0.I need c# code for this.Please help me on this.
i want to join this group
|
|
|
|
|
Hi Veeru,
I guess you want to lock the table for that particular user, not for others, Correct...........
Here is your Answer:
When user enter password, take a count of his attempts. This you will have to do on the Ok button. Whenever he clicks on OK button after supplying the password, the value of Count will increase by 1. Every time you check the value of count.If it is 3 then fire a Update SQL Query to change Unlock value from 1 to 0.
Lets Try this.........
Binod
|
|
|
|
|
you can use a simple counter for that
|
|
|
|
|
Hi,
As suggested by other other fellows, have a counter in authentication procedure/routine, count for invalid tries, and if the count reaches 3, change the ULock to 0. You can even add a column for the total number of times the account ws locked in the same column. Just an idea!
Regards,
Adeel
Do rate the reply, if it helps or even if it doesnot, because it helps the members to know, what solved the issue. Thanks.
|
|
|
|
|
I wil just tell u the Procedure to be done.
1.Initailly the default value of ULock will be 1.
2. Declare a variable WrongPwdCount=0;
3.Check the status of the ULock
if ULock==0
Display the Message as " Your account is locked"
else
WrongPwdCount++;
4. if WrongPwdCount==3
Change the ULock=0
else
Do a successful login
Let me know if this works....
Otherwise Let me send a code for the same
Regards
Basavarajayya
|
|
|
|
|
Try This.
SqlConnection con = new SqlConnection("Data Source=;Database=;User Id=;Password=");
SqlCommand cmd;
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
hfCounter.Value = "1";
}
}
protected void btLogin_Click(object sender, EventArgs e)
{
try
{
con.Open();
string xSql="select * from <trackuser> where userid='" + txtUser.Text + "' and pswd='" + txtPswd.Text + "'";
cmd = new SqlCommand(xSql,con);
SqlDataReader rd = cmd.ExecuteReader();
int x = Convert.ToInt32(hfCounter.Value);
if (x == 3)
{
lblMsg.Text = "User Locked....!";
// write your process here. to change the Lock Status from 0 to 1 OR 1 to 0 etc...
}
else
{
if (rd.HasRows != true)
{
x++;
hfCounter.Value = x.ToString();
}
}
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
}
finally
{
con.Close();
}
}
I hope Helps you out. I used Two TextBox, Label, Button, HiddenField
" Good Things Goes with Good People "
|
|
|
|
|
I would like to know how we can determine whether a function call is resolved at runtime or compile time.
Thanks in Advance
Anand
Not everything that can be counted counts, and not everything that counts can be counted
|
|
|
|
|
How about using Reflection?
|
|
|
|
|
Thanks.
But I would like to find when is the reference resolved really at runtime or compile time. We say a simple function call is resolved at compile time and something complex with inheritance is resolved at run time. How can I really see it or make sure that how its done. Is there any way to find it with reflection libraries. If yes give me some examples.
Thanks a lot
Anand
Not everything that can be counted counts, and not everything that counts can be counted
|
|
|
|