|
vipin1981@gmail.com and what is urs
Vipin
|
|
|
|
|
joyful_neon@hotmail.com
can i add u in instant messenger?
|
|
|
|
|
i dont use msn messenger. if u have yahoo messenger or if u have google account register in orkut.com and let me know. i will add u to my friends list. and by the by where r u from.
Vipin
|
|
|
|
|
hi vikin i have jus sent an email to u.. i dunno if u could actually open the attachment from there.. but like i mentioned in the email, i will add u in yahoo messenger when i get home.. so for now guess i jus keep trying. . thanks man
|
|
|
|
|
actually i cant access mails during my office hours. any way i will check out during our break. till then post ur doubt here. If i know i will surely help u.
Vipin
|
|
|
|
|
I am placing a textBox control in richtext Box.So by default the cursor will come to richtextbox control.How to place the cursor in textbox which is inside richtextbox.
|
|
|
|
|
It sounds something wierd "textbox in richtextbox". But...
if you want the cursor to come first in textbox, then change
the TabIndex property from textbox and richtextbox.
// Cursor go to textbox
this.textbox.TabIndex = 0;
this.richtextbox.TabIndex = 1;
// Cursor go to richtextbox
this.textbox.TabIndex = 1;
this.richtextbox.TabIndex = 1;
|
|
|
|
|
Personally speaking, this sounds like a REALLY stupid design. Why you would put a textbox inside a richtext box is beyond all normal reasoning. However, you need to either change tab order or do a textbox1.Focus() call.
|
|
|
|
|
Hi all!
Sorry for my poor english....
Here my problem, I created WebBrowser,and now I need to disable, "Select_all" and "Copy" fulctions in browser.
I disabled ContextMenu, but keys Ctrl+A, Ctrl+C working.
I tryed to using ProcessCmdKey,ProcessDialogKey,for catching this Keys but "Ctrl+A, Ctrl+C" are not catching....
If somebody knows how do it, please help me...
P.S. Sorry for my mistakes.
|
|
|
|
|
Try this.
var isIE = ( document.all != null );
function initIframe()
{
if ( isIE )
{
//wiring to onkeydown event
editor.attachEvent('onkeydown', editorEvents);
...
}
else
{
editor.addEventListener('keypress', editorEvents, true);
...
}
}
function editorEvents(evt)
{
//this is just old habit
evt = ( evt == null ) ? event; evt;
var keyCode = evt.keyCode ? evt.keyCode : evt.charCode;
var keyCodeChar = String.fromCharCode(keyCode).toLowerCase();
if ( !isIE )//-->If FireFox
{
if (evt.type=='keypress' && evt.ctrlKey)
{
...
}
}
if ( isIE )//-->If IE
{
//changed the type to "keydown" to catch new wiring.
if (evt.type=='keydown' && keyCodeChar=='v' && evt.ctrlKey)
{
//do something.
//setting the returnValue will cause the event to stop bubbling.
evt.returnValue = false;
//no return needed
}
}
return true;
}
Vipin
|
|
|
|
|
Thank's for You help, but how can I use Your sample for axWebBrowser1?
I'm only junior in programming, and very much I don't understand...
|
|
|
|
|
paste this code in the key press event of the textbox or text area where u want to disable the Ctrl+V or Ctrl+C keypress.
Vipin
|
|
|
|
|
Sorry but my WebBrowser was created in Windows Application, VS 2003, FW 1.1, here sample:
private AxSHDocVw.AxWebBrowser axWebBrowser1;
private void Form1_Load(object sender, System.EventArgs e)
{
object oURL = "www.codeproject.com";
object oEmpty = "";
axWebBrowser1.Navigate2(ref oURL, ref oEmpty, ref oEmpty, ref oEmpty, ref oEmpty);
}
//Event which open links in new windows\
private void axWebBrowser1_NewWindow2(object sender, AxSHDocVw.DWebBrowserEvents2_NewWindow2Event e)
{
if (this.axWebBrowser1.ReadyState != SHDocVw.tagREADYSTATE.READYSTATE_COMPLETE)
{
e.ppDisp = null;
e.cancel = true;
return;
}
FEX f1 = new FEX();
f1.Text = "(New window)";
e.ppDisp = f1.axWebBrowser1.Application;
f1.Show();
}
And how I can use Your sample? Sorry but I don't know....
|
|
|
|
|
if ( e.Control && e.KeyCode == Keys.A || e.Control && e.KeyCode == Keys.C )
{
MessageBox.Show( "Control key + A pressed");
}
let me know if this works.
Vipin
|
|
|
|
|
Hi!
Sorry but WebBrowser haven't event KeyDown.... And Your sample doesn't work...
In my sample, some keys work normal...but "Ctrl+A, Ctrl+C" - does'nt work.
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
{
if (keyData == (Keys.Control | Keys.N))//Normal
{
if (this.axWebBrowser1.ReadyState != SHDocVw.tagREADYSTATE.READYSTATE_COMPLETE)
{
return false;
}
FEX f1 = new FEX ();
f1.Text = "(New window)";
f1.Show();
return true;
}
else if (keyData == (Keys.Control | Keys.Q))//normal
{
MessageBox.Show("Q");
return true;
}
else if (keyData == (Keys.Escape))
{
this.Close();
return true;
}
else if(keyData == (Keys.A | Keys.Control))
{
MessageBox.Show("113"); //Doesn't work
return true;
}
else
{
return base.ProcessCmdKey(ref msg, keyData);
}
}
P.S. Sorry for my mistakes!!!
|
|
|
|
|
Hi folks,
I have a simple question for ya (At least I hope it is!)... How can my app find out what folder it is in? This might change regularly, so it needs to know lol
Cheers, Ben.
|
|
|
|
|
Hi,
try this
System.AppDomain.CurrentDomain.BaseDirectory()
Or
system.Environment.CurrentDirectory
"A good programmer is someone who looks both ways before crossing a one-way street." -- Doug Linder
Anant Y. Kulkarni
|
|
|
|
|
Thanks, this worked
Environment.CurrentDirectory
|
|
|
|
|
Do not use Environment.CurrentDirectory. It could potentially change between application launch and accessing of the property. If you're writing a WinForms app, use Application.StartupPath[^] instead. If it's a command line app, use the first property suggested by the other poster AppDomain.CurrentDomain.BaseDirectory[^].
|
|
|
|
|
In addition to what Senthil said:
The Environment.CurrentDirectory property contains the current working directory. The startup working directory can be specified in the properties for an application, so even if you don't change the working directory from your program, there is still no guarantee that the application file is in the current working directory.
---
b { font-weight: normal; }
|
|
|
|
|
Hi,
I believe I am familiar and know the concept of OOP.
Can you recommend a book on OOP in C# please?
Thanks
|
|
|
|
|
I recommend you Wrox Professional C#.
Saqib
|
|
|
|
|
Try the excellent 'Programming C#' by Jesse Liberty.
Dave
|
|
|
|
|
Try SAMS C# Unleased, if you are a starter on the .NET framework
Oliekrokenosterpikkelikkeastrysvoel
|
|
|
|
|
Hi All,
I use FileSystemWatcher for monitoring some folders. When a new file is created i wait until it is completly written to disk and then i copy that file to another folder. I am using the FileSystemWatcher events OnCreated(), OnChanged, OnError(). Proper handlers are attached to these events. This code worked perfectly until yesterday. Yesterday suddenly the FileSystemWatcher stopped giving events for file creation, change etc. Not even an Error occured. what may be the probable reason ? Is there any dependancy for FileSystemWatcher ? I didnt changed the code which was working. So i think if there is any dependancy it might be external.
I tried to search the net for a possible solution but i only found that there are a lot of people complaining about FileSystemWatcher. So i will also like to know if there is some other class or component available which can just replace FileSystemWatcher ?
Any sort of information or help will be appreciated. Please reply as soon as possible since i have wasted a hell lot of time on this FileSystemWatcher !
Thanks in Advance.
"A good programmer is someone who looks both ways before crossing a one-way street." -- Doug Linder
Anant Y. Kulkarni
|
|
|
|