Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    Visual Basic




Key Scan Code To Launch Application


hi sorry if this is a silly question but i am new to vb, i am trying to wright an app to launch a .exe when one of the custom buttons is pressed on my dell insperon 8100 dell provide an application to do this but you can only customise 2 of the 4 buttons and id realy like to be able to customise all 4. looking at the dell program i get what i think are the button scan codes from the registory (e001 to e004) but i am unshure how to right them into an app the closist i have is this:
If GetAsyncKeyState(vbKeyQ) Then
Shell ("C:Program FilesMicrosoft Visual StudioVB98vb6.exe")
End If
but i am unshure how to change the key as its a non standard key i need to put the scan code in rather than a difrent vbkey

thanks for your help




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Does Anyone Know Of Code That I Could Use To Make My VB Application Launch Another .exe?
Hi all, I'm having a miserable time finding any resources on making my VB applications launch other applications. Isn't there a command or a chunk of code somewhere that would allow me to do that? Thanks for ANY input on this!

Global Events For Keyboard SCAN CODE && ASCII CODE Event Trapping?
OK, don't be mad at me, if this is a stupid question, but I'm quite new to VB, so here's my Q:
Is there any global event (not KeyUp/KeyDown/KeyPress) to trap keyboard keypresses with SCAN codes? It is very important to have the exact scan code. I want to use an API function to simulate the pressed keys on an other machine, and I need to have the scan code. By the way, API function calls won't do it for me, I need an EVENT! (I don't want to call functions over and over again e.g. in a timer event. This is too -slow-)
So if anyone out there can help me, please do!
You won't regret it!

Thanks to all....

Scan Command From VB Application
Hi

I have a database application in vb6 and I want to have an option in it that when user choose it can make some scans with special name.I dont mean to right an scaner program but how send commands to scaner from my application.

for example how can I know that scaner application provides COM components .

any help please.

Scan IPs Range With VB Application
Hi all,

I want to develop an application which shound accept IPs range input by user and then the program will scan this range and display live host information. I have a few question list below:

- How can i format the text box in order to trigger user to input correct IP address format (123.123.123.123). I found many application display their text box when form load like that. How can i do that in VB? (displayed: ____._____.____.____)

- Anyone can show me the scan process (algorithm)?

- Gather available information about scanned IP.

Thank in advance.

.:ldlp:.

Help Me Code Scan Ip
i want code scan ip
please....

How To Get Then Scan Code Value Of Key ?
Hi all !

I want to know if its possible to get the scan code value when a key is press on the keyboard in visual basic. The KeyDown or KeyPress message doesn't provide the information is there another way ? I know the OnKeyDown Message in win32 using VC++ provide such information but where can i find it in VB ??

Thanx
Charles

Launch Another Application
Hi,

How I can run an application from VB. I have used "Shell" command but it seems that it runs just executable (*.EXE) files but I want to lauch a Document like (*.DOC or *.XLS or etc.).
I am using VB.NET.

Please help me,
Regards,
Mansour

Launch Application From VB6?
How would you make VB6 launch an application/program/exe when a button is clicked? I want it to do "application path & test.exe" like that.

How To Launch A Vb Application From Web ?
Hi,
I have written a VB application.
I have few requirements as follows:
1)I need to launch a vb application from web site.
2)If application is not installed in the client machine need to launch the Setup for application from the Site.
and then launch the application.
3)Need to write Launch dll and launch the aplication from dll, instead of signing the total exe.
4)Need to launch some downloader activex exe from site with passing parameters to it.

Please suggest me the ideas for achiving the above things.

Thanking you
P01

Launch Application
Can anyone tell me how I can open a file using a specified application. For example how would I open a txt file in MS Word. I know I can use Shell to open a file using the file associated application, but I am unsure how to specify the application I wish to use to open the file.


Many Thanks

Help! How Do You Launch An Application?
Hi!
I was wondering if anyone knew how to launch an application like ICQ. How do I detect if it is installed, and how do I launch it? thanks for any help you can give!

Launch An Application From VB6
I need to be able to terminate another application from within a VB6program and also launch another application.

Does anyone know how to do this?

Thanx in advance.

Best Way To Launch Application
I have develope an app using vb6 , access 2k.
I have Menu bars in my app, i iknwo three way to design my app
1. Mdi form , that contains other MDI child forms and start application using MDI form
2. start appin sub main with displaying mdimain.show and proceed.
3. have a simple form , set menu and use other forms

what's is best way to launch my app, it contains recordset forth & back with db ??
thanx in advance

It May seem Impossible, But Possibly We don't know the way how to reach there ????

How To Launch A Vb Application From Web
Hi,

I have written a VB application.
I have few requirements as follows:
1)I need to launch a vb application from web site.
2)If application is not installed in the client machine need to launch the Setup for application from the Site.
  and then launch the application.
3)Need to write Launch dll and launch the aplication from dll, instead of signing the total exe.
4)Need to launch some downloader activex exe from site with passing parameters to it.

Please suggest me the ideas for achiving the above things.

Thanking you
P01

Get AT Keyboard Scan Code
How do I get the raw scan codes send by AT keyboard in VB? Is there any API for doing this?

How To Retrieve Scan Code From VB?
Hi,

Does anybody know how to retrieve scan code for a key press in VB?

My requirement is if user presses a key, I have to display that key in a text box.

For keys like F1 etc. I need to get SCAN Code, as it doesn't have a ASCII code.

Pls. help me.

Thanks,
Sateesh.

Scan A Page Using Code
how to scan a page using VB?
(controlling the scanner thru code)

Cannot Locate My Application To Launch
Hi please help me out here

I compiled my program and tried to intall it on a client computer. When i try to launch my program from Start>All Programs>my application, it failed to locate the my application.exe. I need to browse and click on the exe file to launch it. Thereafter, it can launch from Start>All Programs>my application without problems.

What is the problem? How do i rectify this?

Thanks in advance.

Launch And Close An Application
HI all,

I need to automate the process of launch, wait for loading and close of word, pdf, txt files one by one from folder having 100's of files.(btw i am using VB6.0) I used ShellExecute to launch the files but i am not able to get the process id to kill it. Can somebody help me get the process id or suggest a different method to do this.

Thanks,
Sam

Launch A Separate Application From VB6
Can you have VB launch a separate application? I need to write a VB6 program that will check to see if conditions are met to launch a separate application and then return to my VB program when the application is ended. Is this possible?

Check Whether Application Has Been Launch
Is there a way to check the other application has been launched ? I would like my program to launch a 3rd party program (not sure what the program was written in what langauge) to perform some calculation. I would then have to keep checking whether the program has completed the calculation, and the way my program should check is whether the program has been closed. Please help. Thx.

How To Launch A Pdf File From VB Application?
Hi,

Is there a way to launch a pdf file in Acrobat Reader from a VB application? For example, I have a simple VB standalone application to search for a pool of pdf files, and upon clicking on one of the pdf files, VB will launch Acrobat Reader and the pdf file appears.

Would appreciate deeply if anyone can help or point to any reference for this.

Many thanks :)
Jason



Launch An Application When Another App Is Launched
OK Guys,

I need to launch an application when Internet Explorer or Netscape Navigator is launched.

When the user opens a browser I need my application to fire up.

Can this be done.

I would realy, really appreciate your help!!!!!

Thanks,

Mike

Get Application Launch Path
How can I get path where application runs from in the program?

Thank you

UserControl Project (VBG) Does Not Launch My Application
I have this user control project (.vbg) which includes the UC and also the program to test it.


Code:
+--OCX(MyOCXProject.vbp)
| |
| + -- User Controls
| |
| + -- MyUserControl(MyUserControl.ctl)
|
+--Project1
|
+ -- Form1(frmTest.frm)
On the test form I loaded the user control to test it. It loaded OK. No problem here.

When I click on Run a HTML document is launched instead of my test application.

What's going on here? How do I get it to launch my test program?

If I only bring up the test program (Test.vbp) by itself and click on Run it works OK and the UC works also.

Launch Visio File From Application
I am having a problem figuring out what references and objects I need to add to my VB Application to launch a predrawn visio file.

I have done searches and have had little success, and was wondering if someone could point me in the right direction.

I do not want to display the drawing to the form, so I'd like to launch visio itself with the file I pass to it. At this time I don't even really need to interract with it (although this may become necessary in the future), but rather just to display it when necessary. I am simply looking to pass a filename to a function to launch visio separately when called. The computers using my app would have their own copy of Visio, so if necessary, I might be able to do it through the command line (shell) or something, if I could figure out the correct params to get the file open, but I am hoping there is a VISIO object or something that I can use within VB. Any hints or suggestions would be greatly appreciated!

Thanks,
Brian

Launch My Application While Logging Out The System
Hello all,

I have an VB6 app. I would like to launch my application while logging out the PC. Is there any way to do that ?

let me know

Launch A VB Application From Access 2003
I have a VB6.0 application that should be launched from Access 2003 application. I am clear on how to launch the VB6 application.

But, if users try to launch the VB6 application separately, it shouldn't run.

How can I do this?

Thanks
nath :

How To Launch An Application Automatically When A USB Pluged In?
how to launch an application automatically when a USB pluged in?

Is it possible in VB? or have to use other methods?

thx

Launch An Application At A Precise Moment...
i want for example display a msgbox when it's 8:00 AM every day or one day, how can i do?

ex:


show = #8/23/2002 8:00:00 PM#
If Now = show Then
MsgBox "wake up!"
End If

but i don't know where put this code if i want it works all the time...

How Do I Launch Explorer From My Visual Basic Application ?
I can launch the explorer using the following command:

Public Function StartExplorer(Path As String) As Long

Dim Scr_hDC As Long
Scr_hDC = GetDesktopWindow()

StartExplorer = ShellExecute(Scr_hDC, "Open", Path, _
"", "C:", SW_SHOWNORMAL)

End Function

where Path is C:

But how do I get the sidewindow which lists all the folders to appear ?

Launch An Application / Command And Be Notified When Finished
Hi, I want to lauch an application or a command from my task scheduler and be notified when each of my task are finished.

I don't want to stop the execution of my program until each task is finished.


Thank you very much

Launch Mail Application And Attach A File
Hi, I'm new to the forum, been programing VB6 for about year and a half now. I need to know how can I open the default mail application with a File Attached already, so the user doesn't have to look it up. I have used ShellExecute with "mailto:" to send mail, but how can I attach the file?

Thanks!

Launch Application And Run A File Using ActiveX Script
Hi,
as a beginning developer in SQL Server I need to import data into SQL. The data I need to import into SQL comes after an automated query is run against some base tables. The automation at present is performed using a windows scheduled task that opens up oracle discoverer which in turn runs the query.

Is there a way of bypassing the windows scheduled task and have activeX vb script open oracle discoverer and run my query by name.

Your help is much appreciated

Thanks

Object Missing = Code Inside ...scan It Forever =[
Im sirrting aginst that code for 60min and its 8:00 am and i dident sleep =
i cant find what wrong!?@
its says object missing ....and highlight that
"Set Label.Container = Picturebox1"

Code:
Private Sub Form_Load()
Dim Picutrebox As PictureBox
'make the form pixels for easier drawing... doesn't have to be though
Me.ScaleMode = vbPixels

'draw picturebox
Set PictureBox = Me.Controls.Add("VB.Picturebox", "Picturebox1")
With PictureBox

.Left = 1080 + 255 * 1
.Top = 5040
.Width = 500 * 2
.Height = 500 * 2
.Visible = True
.BackColor = &H8000000F
End With
Dim Label As Label
Set Label = Me.Controls.Add("VB.Label", "CMLabel1")

Set Label.Container = Picturebox1
With Label
.Left = 0
.Top = 0
.Width = 500
.Height = 500
.Enabled = False
.Visible = True
.Caption = "345 X 345"

End With
End Sub

and ... is it possible to check if ther is internet connection on the computer?
which includes routers

Pleas Help:How To Launch Visual Basic Application In A PC Using Another Computer.
Hi,

Here is the case.I have two computers.Computer1 and Computer2.I have a program that will lock the screen of a PC.The "Lock-Screen" Program is installed in Computer2.But how can i run the program in Computer2 through Computer1 so I can lock its screen.

Hoping for your help!

Thank you!

Code Needed For Excel To Scan Column C If Value >0 Then Copy Row Into New Sheet
I need help creating a proposal work sheet in excel. Where user enters value in column c if they want to select the row. I want them to hit the "calculate" button and the macro search column C for a value greater than 0. If>0 then copy row into row of new sheet 'quote'. The sheet 'quote' is formatted to resemble letterhead and will be printed out so the copied in rows should begin at row 15. Any help is appreciated I am a complete novice at this. thanks

Slow File Load Time...scan Code Question
Hello

I am working on a small app to load *.tga images. I need to get byte level info from the various format fields contained within the image.

I'm reading the file into an array called imagearray() but it seems to take WAY TOO LONG to scan it in. Is my selection of code appropriate? Do you know of a better way?

code...

.............................................................................

Open FilePathandName For Binary Access Read As filenumber

For filescan = 1 To filesize
Get filenumber, filescan, imagearray(filescan - 1)
Next

.............................................................................
For a 250k file this takes ages ~ 10 secs.

Best regards

Alex

Launch An EXE From Code
I need to launch an EXE from within a program, how can I do that?

Launch VPN Connection Via Code
I have some VPN connections set up in the Control Panel -> Network Connections location. No special software, just standard Windows stuff.

Is there a way to launch these connections and connect via code? The forum archives didn't turn up much.

Thanks!

Dave

Small Code To Launch Help
I've seen a lot of code for launching Help, but is there a command that just simulates pressing the F1 key? I'm trying to launch Help from a command button and from a menu option. So far, the only thing I can get to work is the F1 key but I want the user to have other options. There's lots of other Help code on this site but it's pretty complicated (or I'm just stupid). Any ideas?

Programming A Code To Launch A Game In IE
Hey there!

I need some help on coding a file so I can launch SWAT 4 in my internet browser.

ex. swat4://xxx.xxx.xxx.xxx

My code right now looks like below but when I launch the link in IE the swat4.exe comes with a fault "missing startup.ini file" UNKNOWN: appInit

Set Sh = CreateObject("WScript.Shell")
key = "HKEY_LOCAL_MACHINESoftwareSierraSWAT 4InstallPath"
ExeFile = Sh.RegRead(key) & "ContentSystemSwat4.exe"
Command = ExeFile & " " & Mid(Wscript.Arguments(0),7)
Sh.Exec(Command)

What have I done wrong here?

BTW my registry file looks like this:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOTAAO]
@="URL: Americas Army Protocol"
"URL Protocol"=""

[HKEY_CLASSES_ROOTAAOshell]

[HKEY_CLASSES_ROOTAAOshellopen]

[HKEY_CLASSES_ROOTAAOshellopencommand]
@="cmd /c %%windir%%\aaourl.vbs "%1""



I'm new to VB so bare with me

Hopefully someone can help me out

Best regards

VoltureX

Launch External App Code Problem
Hi,

I'm writing a small menu appn which will give the uses buttons to launch different programs with predefined templates.


I have written the following code, which I think should work, but it doesn't, I'm new to VB and can't work it out, any help would be greatly appreciated.
I get the following error: "Compile Error: User defind data type not defined"

Thanks

Richard


Dim wd As New Word.Application
Dim Doc As Word.Document
Set wd = CreateObject("Word.Application")
Set Doc = Word.Documents.Open("C:WINDOWSApplication DataMicrosoftTemplatesCALL REPORT.dot")
wd.Visible = True
wd.Activate

Launch Another Program...why Doesn't My Code Work?
Code:
Private Sub cmdInst1_Click()
If lblStatus.Caption = "iPaq Status: Device Connected" Then
'ShowProps App.Path & "InstallersVideosetup.exe", Me.hwnd
'ShowProps "F:iPaq Installer FINALInstallersVideosetup.exe", Me.hwnd
'ShellExecute Me.hwnd, vbNullString, "setup.exe", vbNullString, App.Path & "InstallersVideo", SW_SHOWNORMAL
ShellExecute Me.hwnd, vbNullString, "setup.exe", vbNullString, "F:iPaq Installer FINALInstallersVideo", SW_SHOWNORMAL
Else
MsgBox "Please put your iPaq in the hot-sync cradle.", vbOKOnly, "Error"
End If
End Sub

I've tried to use ShellExecute and ShellExecuteEx from the WinAPI, both with no success. I need to launch a program that is in a subfolder of the VB program.

EX: App.Path & "InstallersVideoSetup.exe" is the program I need to run.

VB.NET 2003 Code To Launch External File...
I have been looking for the simple code to launch an external file (.exe, .ink, .whatever) and then quit the VB Program... I have no idea how to go about doing this but have been adamantly searching. Obviously I am a bit of a beginner if I have no idea how to do something I know is probably so simple. I want this to be able to be done on a button click event. Please include as much code as possible so I can figure out what is right.

The sequence of events that I want to happen:
Button Click
C:/file.exe launched & (simultaneously) the VB Prog. ends

C:/file.exe continues to run

Please Have A Look At My Code,I'm Trying To Launch A MS WORD Template But No Luck!!
Hey,
I have been using this code for like a month now, and all of a sudden it has started to give me errors:

VB Code:
Dim oWord as Word.ApplicationSet oWord = New Word.Application[b]    oWord.Application.Documents.Add "C:ProgramsNetDoctorGCashReceipt.dot", False, wdNewBlankDocument[/b]        oWord.Visible = True    oWord.Activate    oWord.Application.ActiveDocument.Bookmarks("NAME").Range.InsertAfter frmGroupMember.lblName.Caption    oWord.Application.ActiveDocument.Bookmarks("Date").Range.InsertAfter Format(Date, "DD/MM/YYYY")    oWord.Application.ActiveDocument.Bookmarks("Amount").Range.InsertAfter "Euros." & txtAmount.Text & " " & "ONLY"

The error is on the bold line, saying: Method Add of Object Documents has failed.

How To Launch The Code For Txtbox1 In Form1 If I Click Cmdbutton In Form2?
hi guys! I hope you understand what I want I mean in subject, I really don't know how to say it. btw, here's what I want to do. For example I have 2 forms, in the first form I have there a txtbox while in form 2 I have there a cmdbutton. If I click that cmdbutton in form 2, I want this code to launch be txtbox.text="" in form1. But I don't how to do that in different forms. Anybody who could help me with this?

"Failure is the key to success. So try and try until you succeed!"

Edited by - chubzyko on 6/6/2008 9:11:45 AM

Launch A VB Application Through An Associated File And Pass The File's Name As A Para
I have a VB6 application that opens files with a Common Dialog procedure. I want to be able to launch this application
clicking a file with an appropriate extension (this is easily
done) but also to pass the file's name as a parameter, so
that no open Common Dialog procedure will be necessary
in this case.

How can this be accomplished? I am extremely new to this
language. Thanks a lot!!

rr.

Copyright © 2005-08 www.BigResource.com, All rights reserved