when i load up a project stored on a network drive that uses ocx controls(also stored on the network drive), it always brings up an error saying that it was unable to load the control except when i run it on the machine where the ocx's were compiled. i would like to be able to edit the project...
if i add in a "promptcurrent = promptcurrent - 1" as shown, the codes works! i think there must have been some confusion as to me thinking the timer sub would exit when the timer was disabled. turns out it runs the rest of the code.... thanks for the help!
Private Sub Timer1_Timer()...
never mind the messy coding- i just need to know if i can call public subs in other forms from inside a case statement inside a timer.
it runs the line immediately after the call form2.mysub() but form2.mysub is never run!
am i allowed to call public subs in other forms from a timer? it seems not to be able to call them...
Call Form2.mysub
--> it never enters form2.mysub() !!!argh!
-------
Private Sub Timer1_Timer()
Dim mFileSysObj As New FileSystemObject
Form11.Text2.Text = Str$(promptCurrent)
If...
I know about the findwindow technique. How do I do the reverse of that? That is, knowing the handle of the desired window, how can I grab its title? What other information can I grab knowing just the handle? Thanks
I have a set of data that I would like to plot as a line graph: x vs y. My data consists of one array for the x axis points and another same-sized array for the corresponding y values at each x axis point. This should make one line. How do I plot this in MSchart? I am using the follwing code I...
thanks,
i ended up using:
Public Sub checkExit()
temphandle = FindWindow(vbNullString, windowstring)
If temphandle = 0 Then
dummyvar = MsgBox("Fortran program died", vbOKOnly + vbCritical, "DOH!")
End If
End Sub
i'll just stop multiple instances of...
i have the handle of a program that i shelled and am controlling with my VB gui. sometimes this other non VB program exits of its own accord. is there a way i check in every once in a while to see if a program is still running? i have the handle of the program to work with. there may be other...
Form6.List2.AddItem ("K/z0 (" & trim$(Str$(j)) & "," trim$(Str$(j+1)) & ") ="
i want the final string to look like:
K/z0 (0,1) =
how do i do this? i'm getting a syntax error on compile at the moment
ahh found it:
Private Sub MDIForm_QueryUnload(Cancel As Integer, UnloadMode As Integer)
Dim response As Integer
response = MsgBox("Are you Sure you want to Exit?", vbExclamation + vbYesNo + vbApplicationModal, "Exit")
If response = vbNo Then Cancel = 1
End Sub
i know this is an option on child and regular form windows, but it doesn't appear in the MDI window properties. Is there an easy way to disable the top right hand corner X (exit) button? i've seen some pretty complicated solutions involving how the toolbar is drawn...
is there a built in function in VB that returns the max value and its position in an array?
i seem to remember this being in other languages but haven't found it for VB yet.
if all else fails, i suppose the few lines of code needed could be written myself - i just figure that somebody else has...
also, is there any way to "see" what is going on in the console app? sometimes my console app exits while the vb is still running and I can't tell. thanks.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.