|
you could trap for keycode of 13
|
|
|
|
|
Thanks!
I'm new at this.
I assume that key code 13 is the Enter key, but how do I "trap" it?
Thanks Again!
nvmoss
|
|
|
|
|
You "trap" it by adding this code in the KeyDown event
If e.KeyCode = Keys.Enter Then
End If
HTH
"if you vote me down, I shall become more powerful than you can possibly imagine" - Michael P. Butler.
Support Bone
It's a weird Life
|
|
|
|
|
I don't know why, but KeyPress tends to work better for this (for me, at least) than KeyDown .
' include whatever controls you want to have this functionality
Private Sub KeyPressed(ByVal sender As Object, ByVal e As KeyPressEventArgs) Handles _
TextBox1.KeyPress, TextBox2.KeyPress, TextBox3.KeyPress, TextBox4.KeyPress
If e.KeyChar = ChrW(13) Then
ProcessTabKey(True)
e.Handled = True
End If
End Sub
This isn't the only way to do what you want, but it works.
Charlie
if(!curlies){ return; }
|
|
|
|
|
Hi,
Help me, how we can create windows local user by program.
srinivasraom
|
|
|
|
|
Hi ,,,
I have made an application which uses CrystalReport 8.5 Viewer(that comes with .net setup). I made a setup so that the client can view the reports. I read in the help file that to include all the files for CrstalDecisions we need to include 3 Msm files i.e. merge modules in the setup. They are MANAGED_ENU.MSM, DATABASE_ACCESS_ENU.MSM, REGWIZ.MSM. I couldnt find MANAGED_ENU.MSM, instead of it I included MANAGED.MSM. I also couldnt find DATABASE_ACCESS_ENU.MSM, instead of it I included DATABASE_ACCESS.MSM. They contain the files needed for CrystalDecisions. But when I included REGWIZ.MSM , it doesnt show me any files in the list(When we see the file list in Mergemodule by including it in the setup). It shows empty list. As per the help file, REGWIZ.MSM contains a file called KEYCODEV2.DLL. But its missing in the MSM FILE. And the error I am getting when I try to open the report at clients place is "INVALID KEY CODE". So where should I find these three files so that I can include it in the project. I searched it on the net but could nt get any of these files.
What are the other options for this error???
Thanks Tasnim
|
|
|
|
|
I got this error once when i registered .net. What i did to correct the problem if this helps at all i uninstalled the crystal reports portion of the .NET installation and reinstalled.This seemed to correct my problem hope this helps.
|
|
|
|
|
Hi
I have prepared an application in VB.Net, i have used Crystal Report 9 to make Reports. Component on VB.Net Form i am using is the one which comes together with the VS.Net, i.e of Crystal Report 8.5. So when i make setup (i include all the necessary files like Crystal Descision files) setup installs the product successfully but when i run the project it gives error of KeycodeV2.dll not found, but it is there in the desired path.
Can anyone help me for the problem, it would be really nice as only this report portion is left.
Thanks for going through
Be Humble in Victory and Strong in Defeat. -Het
|
|
|
|
|
Het2109 wrote:
gives error of KeycodeV2.dll not found, but it is there in the desired path
Did you get a licence key for Crystal Reports? I had this problem, and if I remember correctly, to fix it you get a (free) licence key from Crystal Decisions, and stuff that into the Serial Key (?) property for the Crystal merge module in your setup.
It's something like that anyway, I mentally purge myself of Crystal related things as far as possible
Ian Darling
"One of the few systems...which has had “no deaths” in the reliability requirements." - Michael Platt
|
|
|
|
|
|
i want make an application who open one document word or excel.and i want to know how to do that .
|
|
|
|
|
|
sorry,but the link don't work, can you give me an other link.
thank you
|
|
|
|
|
ProCess.STarT("filename") will open a doCumenT in word exCel or any doCumenT u desire To open.
Be Humble in Victory and Strong in Defeat. -Het
|
|
|
|
|
Hello,
when i play a sound file like mp3 or wav with MediaPlayer or anything like
this, i would like to get the volume level of the sound card in real time.
The data is then sent to the serial port. How do i get this data. I tried to
find some samples in msdn or internet but i couldn t find any useful code.
There is the winmm.dll which supports calls to waveIn and waveOut but all
the samples use them to set or get the master volume. That is not what i
need. I thought i found a sample in msdn, but this doesnt work. Is directX a
way to solve this problem?
Can anybody
help me??
|
|
|
|
|
Do you want the "volume level" or the sampled peaks of the output going to the speakers?
Volume is simple, you've already found the code for it.
Sampling the output is a whole other story. Now you have to consider getting the output of 1 to 8 speakers. This sampling can occur very fast, but can your serial port implementation keep up with the rate of data you want to transmit? How fast are you looking at sending data out the serial port?
You might want to look at this[^] link for a sample on MSDN.
RageInTheMachine9532
|
|
|
|
|
Can anybody tell me..How to insert table in richtextbox control as in MS word..I'll be helpful to u...PLease help me sir..
I'll be very thankful to u.
OK! Good Bye...Have a Nice Life..Bye. Sumit Kapoor
---Sumit Kapoor---
|
|
|
|
|
1. You can insert the RTF code using SelectRTF, you'd have get the basic code from wordpad, then modify it a bit.
2. Also you can (although I've not been able to get it to work myself), create a word object and add a table, see the newsgroups for example.
However, even if you get point 1 working there is a problem.
Tables cells don't word wrap in the richtextbox.
I've been looking for a solution to this was a day or two.
I've just been looking at the OLE Object example on this site, I thought I might be able to insert HTML, but I can't get it to work. Even if I could I'd then have a problem with resizing columns.
I've just about ready to give up.
|
|
|
|
|
I am wandering how you would create a menu completely in code. I want to be able to make a menu completely from scratch in code. I really need the code for vb 6.0 mainly but i would like to know how to do it in both 6.0 and .NET if possible. Thank you for any help you can give me.
|
|
|
|
|
I never tried this kind of thing but hope you can do this using API's.
Yogendra Agarwal
Telemune Software Solutions Pvt. Ltd.
Mobile: +91 9818899010
|
|
|
|
|
Hy All.
I have following problem.
"Run time error 426. One form MDI only admitted"
The code allows to print from one form which shows a print preview and, after that, it's possible to click on print commandbutton:
Private sub cmdPrint_click()
gprint = True
Call frmMain.ActiveForm.printText
Unload me
End Sub
Main form is frmMain (MDIForm1). I don't understand why there are two MDI form loaded, as seems to say message error.
Elsewhere, in another similar step, I got same message (in this step I load an image into the document.
The code is following:
Private InsertImage_click()
Clipboard.clear
clipboard.setdata Picture1.Picture
SendMessage frmMain.ActiveForm.Text1.hwnd WM_Paste, 0, 0
Unload Me
End Sub
I suspect it's wrong "frmMain".
Who can help me?
Thanks in advance.
Ric
|
|
|
|
|
at main form when you click a command button another form loads when i select the existing value in the popup form
i use .show method at that time i want to close the main form and open the main from with the existing value
Please help
|
|
|
|
|
at the main form write this also
main.hide(this will hide the main form)
and when another form is loaded then
also create a command button there and write in the code window the following in click event
|
|
|
|
|
write in the main form command button
main.hide
also when second form is loaded then
create a commandbutton and write the following code
me.hide
main.show
|
|
|
|
|
Hi,
I am trying to create a SPARSE file that reflects the size of an original file. for excample, I would like to create a 33gb(Logical) file that is physically only a few bytes.
I am able to create a 0(logical/physical) byte file only with the following code but I can't seem to get the Logical value assigned. Could someone tel me what I'm missing?
Module Module1
Public Declare Function CreateFile Lib "kernel32" Alias "CreateFileA" ( _
ByVal lpFileName As String, _
ByVal dwDesiredAccess As Integer, _
ByVal dwShareMode As Integer, _
ByVal lpSecurityAttributes As Integer, _
ByVal dwCreationDisposition As Integer, _
ByVal dwFlagsAndAttributes As Integer, _
ByVal hTemplateFile As Integer) As Integer
Public Declare Function SetFilePointer Lib "kernel32" Alias "SetFilePointer" ( _
ByVal hFile As Integer, _
ByVal lDistanceToMove As Integer, _
ByVal lpDistanceToMoveHigh As Integer, _
ByVal dwMoveMethod As Integer) As Integer
Public Declare Function SetEndOfFile Lib "kernel32" ( _
ByVal hFile As Integer) As Integer
Public Declare Function CloseHandle Lib "kernel32" ( _
ByVal hObject As Integer) As Integer
Public Declare Function DeviceIoControl Lib "kernel32" ( _
ByVal hDevice As Long, _
ByVal dwIoControlCode As Long, _
|ByVal lpInBuffer As String, _
ByVal nInBufferSize As Long, _
ByVal lpOutBuffer As String, _
ByVal nOutBufferSize As Long, _
ByVal lpBytesReturned As Long, _
ByVal lpOverlapped As String) As Long
End Module
Public Class Form1
Inherits System.Windows.Forms.Form
Const _WIN32_WINNT = 5
Public Const CREATE_ALWAYS = 2
Public Const CREATE_NEW = 1
Public Const OPEN_ALWAYS = 4 'Create if doesn't exist
Public Const OPEN_EXISTING = 3
Public Const TRUNCATE_EXISTING = 5
Public Const FILE_ATTRIBUTE_ARCHIVE = &H20
Public Const FSCTL_SET_SPARSE = &H900C4
Public Const MOVEFILE_REPLACE_EXISTING = &H1
Public Const FILE_ATTRIBUTE_TEMPORARY = &H100
Public Const FILE_BEGIN = 0
Public Const FILE_SHARE_READ = &H1
Public Const FILE_SHARE_WRITE = &H2
Public Const GENERIC_READ = &H80000000
Public Const GENERIC_WRITE = &H40000000
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim h
Dim d
Dim n
Dim dw As Integer
Dim lDist As Integer
h = CreateFile("D:\Wes.log", GENERIC_WRITE + GENERIC_READ, 0, 0, CREATE_ALWAYS, 0, 0)
dw = 0
d = DeviceIoControl(h, FSCTL_SET_SPARSE, n, 0, n, 0, dw, 0)
lDist = 8
MsgBox(h & " " & lDist)
SetFilePointer(h, 0, lDist, FILE_BEGIN)
CloseHandle(h)
End Sub
|
|
|
|