I'm currently working on a project where we're doing some automated testing.We're using a Rohde and Schwarz Vector Network Analyzer to do our testing, and the interface it provides for communication is GPIB. On my laptop it simply plugs in as USB.
I am making a program that edits my website with the input that I put in. But, it is requiring multiple forms (obviousily), but I don't know how to make it close the one I am in while opening the other. For example: I have a form that opens first that requires a Username and Password, so nobody can obviousily use it without knowing them. When I submit the correct username and password and go on with the editing, I need the login form to close. I do not know the coding for this part. Is it:
I am trying to open an audio device using the waveOutOpen function in winmm.dll and receiving a WAVERR_BADFORMAT error. It was working fine when I was just using the WAVEFORMATEX structure alone but unfortunately this has the limitation of only handling 16bit audio and I would like to handle higher resolutions.
So i want these If statements to first see if discharge date has value and admit is null to do this ... and inorder to do this i have to open my other SQL reader which is dr1. becuase at this time i have dr2. open. How do i get around this since i cant read from two stream writer at the same time.
If dr2.Item("DischargeDateTime").ToString <> "" And dr2.Item("AdmitDateTime").ToString = "" Then 'patien is showing a dishcharge dat but NO Admit date
I have form1 and form2 and have when a user clicks on an icon on form1 it shows form2 and hides form1. But how would I get it to when a user closes form2 it will show form1 again?
I want to make a program where I can open a program, and my vb program starts with it. My VB program will then use a timer to count to an hour, and then close out of both programs. So i started experementing with things and this is what i came up with:Dim myprocess As Process = System.Diagnostics.Process.Start("C:\Program Files\Internet Explorer\iexplore.exe")
That opens my program fine, but I dont know how to close it from there. Also I want my vb program to start automaticaly, not hit a button and my other program shows up.
When connecting to a Sybase ASE database via ODBC using the code below, I'll occasionally get a '[IM006] [Microsoft][ODBC Driver Manager] Driver's SQLSetConnectAttr failed' error. this be caused by my code? I read here that I should be using the 'With' statement instead, but I don't understand how that would affect this.
I got stuck up with one issue of inventory/stock calculations and put my problem in four threads and grasped some ideas and thoughts for that. But could not find SQL query for this issue in those threads. i am able to construct SQL query for stock/inventory calculations. Since I could not find any SQL query as an example on this issue inspite of spending a lot of time and search, deifinitely there might be so many examples but i was unable to reach them, so after constructing this query i wanted to share my humble effort with all. It may be a second thought for beginners like me having the same problem.The second purpose of placing this query here is to welcome improvement or alternate of this query.
I have created a splash screen and it fades in. When the splash screen closes, the main form (MDI) should open. The main form opens but then immediately closes. vb Public Class frmSplash Private Sub frmSplash_FormClosing(ByVal sender As Object, _ ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing 'Open the MDI form. frmMain.Show() End Sub [Code] .....
Finally starting some coding in VB.Net, I notice over the years, that we can say (in VB6)
Code: Dim MyForm_Stock as NEW frmStock
in the same session, being able to open, say 3 Stock Forms at the same time and maintain details independently of each of the other forms. Also am I able to maintain separate Database connections and the same table being opened and updated independently of each other by each separate form. What is actually taking place in terms of memory being used by each process? My ultimate goal is to be able to have ONE Module with all the possible data Connection and Recordset Opening and closing options, which I have failed miserably to do in my VB6 experience. Data access is an obvious module based set of subroutines. Others could be Date routines eg, Week Number of the year, Days Diff, Days to, etc. [Code]
It is my goal to write a program to run a retail store. I am an intermediate Access developer, so I have a good grasp of the basics.However, I find that developing in VB 2010 is quite different.I will have forms for:
Company Information Employee Information Supplier Information Customer Information Invoices & Purchase Orders
All I really need to know at this point is the code to open and close each form.
I am currently designing a calibration system for some equipment and want to be able to create a simple interface (initially) that will read real time samples from the Agilent 34970A (Data Acquisition Unit) and display them in a text box continuously until a separate button is pressed, which would interrupt the process. Here is some of my Private Sub StartSampleButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles StartSampleButton.Click
I am currently designing a calibration system for some equipment and want to be able to create a simple interface (initially) that will read real time samples from the Agilent 34970A (Data Acquisition Unit) and display them in a text box continuously until a separate button is pressed, which would interrupt the process. Here is some of my
Private Sub StartSampleButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles StartSampleButton.Click ioDmm.WriteString("MEAS:VOLT:DC? AUTO,MAX,(@101)") RealTimeSample.Text = ioDmm.ReadNumber End Sub
When I press the StartSampleButton, it takes a single sample from the 34970A and places the result in the RealTimeSample box (no problems here). The problem comes in when I want to do multiple samples. I've been trying something along the lines of:
Private Sub StartSampleButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles StartSampleButton.Click While 1 ioDmm.WriteString("MEAS:VOLT:DC? AUTO,MAX, (@101)")
I have 2 functions for opening and closing Windows Explorer, which is still working fine with Windows XP and even Vista. The same functions not working on Windows 7. Following are the functions:
I have 2 functions for opening and closing Windows Explorer, which is still working fine with Windows XP and even Vista. The same functions not working on Windows 7
Dim HTProcess As New Hashtable Private
[code]...
And 'CloseFolder' functions not able to close the Windows Explorer in Windows 7
I am currently working on a project that has a splashscreen This splash screen is designed to be shown when the main form begins to load its requirements, and then closes once it has loaded... Currently it works like so:
Private Sub frmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load frmSplash.Show() dolotsofloading() frmSplash.Close() End Sub
A Problem in accessing a device from VB Windows cannot load the device driver for this hardware because there is a duplicate device already running in the system. (Code 42) This error is because i am using 2 devices of the same company which has the mass usb storage on it and when i install one of the device the other hides. So one is detected the Other is not. It also give a error called designed dragnonacally something...
Form1 is a mdi container. It has a bunch of forms that can load inside of it as mdi children. If I close each open form inside the form1, and then click the red X at the top right, application exits fine.If I click the red X without closing the forms inside I get: An unhandled exception of type 'System.CannotUnloadAppDomainException' occurred in mscorlib.dll
Additional information: Error while unloading appdomain. (Exception from HRESULT: 0x80131015) However I can break from it. How do I get the application to not show that error? What must I do to fix those inside forms or close when the red x is clicked?
Dim frm As Form For Each frm In Forms Set frm = Nothing Next frm
The above code is what I used in VB6 to close all forms associated with my programs before my program closed. I have been searching for information on how to make sure all forms are closed when closing a VB2008 program.
I have seen info on using the Project Property Shutdown mode When startup form closes and I currently have this set.
Is this all that is really necessary? Will the garbage disposal close everything else to free up RAM?
Also, if I have several forms open and want to close all from the main form without closing each one individually, what is the best approach? Is there a collection like in VB6, go through the collection, compare it to the name of the main form and close it if it is not the main form?
I have the following code to close a form which is a child. The problem is that when it closes, it closes the MDI parent too.
Private Sub frmTransaction_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing If ListView1.Items.Count >= 1 Then
I need to control a device with a GPIB port. I have the commands that I need to use to do this; but I don't know which is the sintaxis in Visual Basic.
For example if I need to send a instruction like "START:0.01" to the external device which are the libraries that I have to include?, how should I write the programming line to do this?
The main tasks that I need to program are sending data, receiving data, and saving data
I want to take opening balance when i open a report between date parameter it show the opening balance, actually i have three columns "description" "debit" "credit" in crystal report now i want to add 1 more field which come throuhd formula which is opening balance. i have a data of debit credit from 2006. but user choose to show the data from 2008 so i want that the balcne from sum of debit and credit side between 2006 to 2007 end come in the shape of opening balance in the report and then add the debit and credit side of report into opening balance. i put a following fromual bt not accept it sum ({vr_detail.debitT})-sum({vr_detail.creditT}) > {?strtdte}
I can get the LAN Device Names (using code below) but how do you get those strings from the "Name" column (see image) that the user can change?
' get list of enabled lan card device names Dim cat As New PerformanceCounterCategory("Network Interface") Dim instances As String() = cat.GetInstanceNames() For Each instance As String In instances Debug.WriteLine(instance) Next
I`m working on a project where i have connected a FPGA chip to the PCI bus but now i am trying to figure out how to communicate in VB to that device? Normally the device has memory assigned to it in XP (address h00000200 to h0000037F) but i don`t know how to read/Write to that memory directly in VB...