|
Thanks! It looks good.
I'll check it out.
|
|
|
|
|
i wanna new features about 2008,2010 and 2012 its urgent please ...........mail me vsateesh.mca@gmail.com or call me 9014470340
Thanks And Regards
v sateesh
9014470340
|
|
|
|
|
|
And you like spam, don't you?
Now everyone knows your email address, and even your phone number. What a good invitation to spammers!
|
|
|
|
|
There will be tons of information available on msdn and on the internet.
No one but spammers will respond to you if you give your email id out on a public forum.
|
|
|
|
|
|
SateeshVankayala wrote: urgent please
Urgent for you, not to anyone else.
And you seriously think people will draft an email or call you to provide you with the information you need? If this is your attitude towards learning, I'm sure you wouldn't learn anything in your life.
|
|
|
|
|
In keypress event the character which i press should come after my input which i send using send keys.
here is the code
if asc(e.keychar)=102 then 'ascii value of "f"
system.windows.forms.sendkeys.send("A")
end if
"f" should come after "A",but it is displaying as "fA"
How to solve this guys....
|
|
|
|
|
|
You can set the SuppressKeyPress property of the KeyEventArgs supplied in your event handler to true and then pass on both A and F in the SendKeys.
|
|
|
|
|
Hi,
I have created a custom addIn for outlook 2007 using VS2010.
I have created a custom Ribbon using xml containing a single toggleButton control. This is for new message screen. After clicking the "New Mail Message" from outlook custom ribbon visible along with the toggle button. Once I pressed the toggle button and sent the mail the toggle button remains same (on press) for every new message later. Can anybody please help me how to make toggleButton getPressed status to unchecked for every new mail message click event.
Thanks.
|
|
|
|
|
Why are you even using a toggle button? Why not a normal button??
|
|
|
|
|
byte b1 = 4;
byte b2 = 2;
byte result = b1 - b2 //error here Cannot explicitly convert type 'int' to 'byte'. Are you missing a cast?
Question is : where does the compiler see the 'int' here, where all variables are byte?
|
|
|
|
|
It is a feature of C#. The byte variables are widened to integers before performing the subtraction. Hence, the result is an integer. You can prove this to yourself with this:
object o = b1 - b2;
MessageBox.Show("o is a: " + o.GetType().FullName); So to get rid of that nasty error:
byte result =(byte)(b1 - b2); See: Why do operations on "byte" result in "int"?[^] for an explanation of why this was done.
|
|
|
|
|
|
Guys i am designing a editor,and in this editor i am using keypress event to block the pressed key and adding my input key to the text box.While adding the characters the scroll bar is automatically moving to the top of the page
i have used "textbox1.scrollcaret" also but it is always making the cursor line to be a last line.
Example
after few lines have been entered
if i add
if asc(e.keychar)=102 'For "f" ascii value of f is 102
e.handled =true
textbox1.text=textbox1.text + "c"
end if
How to solve this problem guys....
|
|
|
|
|
You are making it to complex.
Private Sub TextBox1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles TextBox1.KeyPress
If e.KeyChar = "f"c Then
e.KeyChar = "c"c
End If
End Sub
This will work fine for the user using the keyboard, but have you thought about how you are going to handle the user pasting text? That will not get translated using this method.
|
|
|
|
|
Thanks a lot "TnTinMn" this has solved my problem exactly.
|
|
|
|
|
When I press any character in any editor the corresponding character should not be displayed on the screen and instead of the blocked character i would like to display my own characters in that editor.
i have to do this with my minimized form i.e when my form is in background and when it is closed the inputs should be displayed on the screen as i type.
How to do this process?
|
|
|
|
|
You can't. Minimized forms do not receive input. Further, it'll never work for "all applications"; I doubt that Warcraft lets you modify the contents of the password-textbox.
Did you try the virtual keyboard I linked to in your previous post?
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
ya i took those two lines of code but i dont know how to use it.
Can you give me any example how to use it......plzzzzzz.
|
|
|
|
|
Hi everybody,
I have a simple project with a form and a class in another file to manage the COM port (from the article "Smart Device Print Engine for Compact Framework" by Orkun GEDiK).
I open the COM port and I start its thread for receiving data.
I want to write the received data in a textbox in the form.
To do this, every byte I receive, I assign the value of this byte to a byte variable of the form called byt and I call from inside the loop of the thread a function in the form that stores all the bytes in a string dati (in hexadecimal format):
Public Sub ScriviTesto2()
Dim str As String
If InvokeRequired Then
Invoke(New Action(AddressOf ScriviTesto2))
Return
End If
Try
str = Hex(byt)
dati &= str & " "
Catch ex As Exception
MessageBox.Show(ex.ToString)
End Try
End Sub
This seems to work because if I run the code step by step I see that the string dati grows byte by byte and contains the correct values.
When there are no more bytes to receive, always from inside the loop of the thread, I call another function of the form that should write my string in a text box:
Public Sub ScriviTesto3()
If InvokeRequired Then
Invoke(New Action(AddressOf ScriviTesto3))
Return
End If
TB1.Text &= dati & vbCrLf
End Sub
...this function write nothing in the text box... why?
The string data contains the right values, is not empty.
I tried another way: I don't call the last funcion (ScriviTesto3() ) but, when there are no more bytes to receive, I click a button of the form that do the same:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
TB1.Text &= dati & vbCrLf
End Sub
In this case, when I click the button the string dati is empty... I don't know why.
I add the declaration of the involved variables:
Public Class Form1
Public byt As Byte
Protected dati As String
...
Can anyone help me?
Thanks in advance.
|
|
|
|
|
steve_9496613 wrote: I call another function of the form that should write my string in a text box: Pass the data to display there as a parameter.
steve_9496613 wrote: In this case, when I click the button the string dati is empty... I don't know why. Access to the form's field isn't thread-safe. You could lock it in a property, but that slow down things nicely. Hence, I'd suggest to create a list of bytes on your receiver-thread, and to pass this as a paramater to the form, say, once a second.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Thanks Eddy.
I have modified the first function as you suggested to do for the second one:
Public Sub ScriviTesto2(ByVal dato As Byte)
Dim str As String
If InvokeRequired Then
Invoke(New Action(Of Byte)(AddressOf ScriviTesto2), dato)
Return
End If
Try
str = Hex(dato)
dati &= str & " "
TB1.Text &= Hex(dato) & " "
Catch ex As Exception
MessageBox.Show(ex.ToString)
End Try
End Sub
In the receiver thread I call this function every byte I receive, passing to it the byte just received.
As before the string dati grows byte by byte so I can say that I correctly pass the parameter dato to this function but nothing is written in the text box TB1 .
Writing byte by byte in a textbox is not the fastest way but I just wanted to see if passing data as parameter to the function could be the solution.
Perhaps the text box is not the right objet to use or, more likely, I'm missing something important.
I did another try: as you suggested I created a byte array in the receiver thread, I fill it with the bytes received and at the end of data reception I call another function in form1 passing to it the byte array:
Public Sub ScriviTesto4(ByVal datiIn As Byte())
Dim i As Int32
If InvokeRequired Then
Invoke(New Action(Of Byte())(AddressOf ScriviTesto4))
Return
End If
For i = 0 To (datiIn.Count - 1)
TB1.Text &= Hex(datiIn(i)) & " "
Next
TB1.Text &= vbCrLf
End Sub
Running step by step in debug I see that the array datiIn contains the right bytes and also the TB1.Text contains the right values but I see nothing in the text box in the form!
What I'm doing wrong?
|
|
|
|
|
steve_9496613 wrote: Perhaps the text box is not the right objet to use or, more likely, I'm missing something important. It's not optimal, but it should display some text. That's what it's there for.
steve_9496613 wrote: Running step by step in debug I see that the array datiIn contains the right bytes and also the TB1.Text contains the right values but I see nothing in the text box in the form! Did you create the textbox on the mainthread?
For i = 0 To (datiIn.Count - 1)
string x = Hex(datiIn(i)) & " "
TB1.Text = TB1.Text + x
Next Can you write the string x to the debugger?
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|