Capturing Variables To A Flatfile After .exe Error?
May 21, 2009
Is there a way of capturing the current contents of all the variables in a VB .NET application when the .exe crashes?Ideally I would like to write out the current contents of all variables to a flatfile when an .EXE crashes.
View 2 Replies
ADVERTISEMENT
May 12, 2010
What code do I use tocapture the variables entered into a menu strip text box for use in the program
Public Class Form1
Dim TestDuration As Integer
Dim Frequency As Double
[code].....
View 3 Replies
Feb 9, 2012
I was creating some complex applications in Visual Basic .NET 2008 and since they are in the testing phase right now, people manage to find an error or two every so often that causes the program to crash. The problem is that there is a tracking piece to it that logs who is currently using the programs. When a user logs in, it logs that they are currently logged in, and if the form close event is fired, the log is deleted to show that they have closed it.
Now my problem comes whenever the form crashes from an error since it won't trigger the close event and therefore makes the log become inaccurate. My question is if it is possible to capture any error that the form would have in the form of an event?
View 2 Replies
Apr 16, 2009
this code using an OLEDB source will populate the OutputColumnCollectionbelow it, the code using a flatfile source will not populate the OutputColumnCollection.
Why not?
Microsoft.SqlServer.Dts.Runtime.Application a = new Microsoft.SqlServer.Dts.Runtime.Application();
[code]......
View 2 Replies
Feb 18, 2009
I'm having issues w/ querying the database w/ user selected dates. Hardcoded everything worked fine but when I started to use the DateTimePicker things stopped working.
Dim sqlcn As New SqlConnection(db.dbcn)
Dim cmd As SqlCommand = sqlcn.CreateCommand()
cmd.CommandText = "SELECT * FROM TABLE " _
& "WHERE CHK_DT BETWEEN @BeginDt and @EndDt"
[Code]...
View 1 Replies
Dec 11, 2011
Last year (2010) I came across a FANTASTIC command that allowed me to take a string of variables with a common delimiter and break it all back out into separate variables (possibly an array) with one statement.
[Code]...
As long as the delimiter was a unique specifiable character, this one-statement command could break it out into elements. my memory and point me in the right direction.
View 2 Replies
Sep 27, 2010
I have code, shown below, that works all except for 1 thing: The variables being passed byRef get passed, but once modified in the else section of the "if me.invokerequired" code of RecordData, the variables are never updated in the calling function. To reiterate, the calling function does not receive the updated data that is in the variables custid and amt.When debugging, I see the data change in the else section of "if me.invokerequired", but once it returns from the callback the data is missing.[code]
View 15 Replies
Mar 23, 2012
I define some global variables of a class as follows:
Private Class MyClass
Private var1 as Decimal
Private list1 as List(Of string)[code].....
But I found that after this form is closed, all above variables, var1, list1, list2 still exist in memory. I thought they should be collected by gc since the form is already disposed as I confirmed.
Add: I have monitored half an hour after the form is closed. But these variables are not collected by gc. I have an automatic update procedure on the form which uses above variables.Since the above variables still hold values, the automatic update procedure is always called which causes exception. (One quick fix is to check if form.isDisposed in update procedure. But I do not think this is elegeant. Besides, these variables occupy memory.)
View 2 Replies
Jan 7, 2010
Does the memory used in declaring variables are reclaimed by the OS when these variables go out of scope?Does the memory used be released by setting thier value to nothing? if not, then how can I force the garbage collector to run or excecute at a certain/desired time..How about in Windows Forms..How can we make sure that the memory used in initializing and showing forms be released if those forms were closed?
View 13 Replies
Mar 8, 2011
Question 1: What is the difference between "Background Worker" and "Worker Pool" as indicated within the MSDN samples provided.
Question 2: I noticed while using, AddressOf _Function_, variables cannot be passed; what would be an efficient solution to this?
Question 3: While using multithreading is it required to invoke before setting variables, or only form properties?
Question 4: While using System.Net.Sockets is it safe/efficient to use Application.DoEvents while waiting for new data; or would be using a Do While loop be fine without DoEvents since the action would be multithreaded? Note: there can be up to 2000-3000 sockets in use at a time.
View 10 Replies
Jun 9, 2012
I'm new in .NET programming.I have a class Form1 that includes Button1_Click event.Button1_Click creates a multiple Text Boxies at run time)Here is the class:
Public Class Form1
Dim shiftDown As Integer
Dim counter As Integer
[code].....
View 3 Replies
Jun 4, 2011
I want to capture a still picture in any format like .png,.jpg,.bmp etc. using a webcam.And want to save that in directory.
View 3 Replies
Mar 14, 2010
How can I capture text from cmd.exe window? Tried GetWindowText, but this only returns the title.
View 6 Replies
Jun 16, 2010
I am using a DataGridView, which is bound to a dataset. There is a bindingNavigator as well.
when a user deletes a row by clicking "bindingNavigatorDeleteItem" button, I am trying to get the row being deleted.
private void bindingNavigatorDeleteItem_Click(object sender, EventArgs e)
{
int crow = gridEventType.CurrentCell.RowIndex;
but it returns the newly selected row AFTER deletion of a selected row.
so, If I have two rows
0
1
2
and I delete 2
crow is 1, not 2.
Am I missing something here?
2. How do I know whether certain rows are modified in datagridview?
View 3 Replies
Oct 19, 2006
I am trying to make a simple personal program and cannot figure out how to capture a section of the screen.I want it to work like prt scr does except it captures a specified rectangle instead of the entire screen. I am thinking I have to use Drawing.Graphics but am not sure.
View 11 Replies
Feb 8, 2010
The below is my program so far
Public Class Form1
Private Display As Boolean
Private WithEvents tmr As Windows.Forms.Timer
[code]....
Upon clicking the button a series of letters are displayed to the screen.I would like to be able to capture the time taken to press the letter shown.
View 8 Replies
Apr 30, 2010
I am trying to modifying the "Math Quiz" tutorial to be more user friendly.
The initial tutorial does not consider the users efforts to answer the math problems as quickly as possible.
The problem is that you must use the mouse or tab key rather than the "enter" key to move to the next control after answering. I believe using the "Enter key to be much more intuitive.
Therefore, I wish to modify the program to either:
1. Check the KeyPress event of the NumberUpDown controls to watch for the "Enter" key to be pressed, and if it is, check to ensure that the current NumberUpDown control is not empty (= Nothing) and if both are True, to then TAB to the next control in the TAB order; OR
2. Uses the PreviewKeyDown event to transpose the "Enter" into a "Tab" automatically so the application will then TAB to the next control in the TAB order.
With all of the new changes to VB 2010 from the last version I actually used professionally (VB6), things are REALLY different, so I no longer know how to accomplish this same task in the new manner. especially if it contains working CODE, because I have always learned better the first time from an example. here is my version of the tutorial Code:
'--- Create a Random object to generate random numbers.
Private objRandomValue As New Random
'--- The Integers will store the numbers for the
' addition problem.
[Code]....
View 4 Replies
Dec 7, 2011
Okay, so I know how to capture a screenshot of the Active Window, but if the active window is a game, then the screen is just black. What do I need to do to be able to also capture ingame screens?
View 3 Replies
Dec 1, 2009
I was wondering if there is an easy way to analyse sound that is sent to the speakers (just before it's played). For example when playing a song in winamp or windows media player. Or is it easier to write plugins for those programs to form an interface with your own program?
View 2 Replies
Aug 9, 2010
I have a datagridview (unbound). Fields are Name, Family Name and Phone No and a checkbox colum.
There are ten rows in that DataGridView.
There is an OK button
I need to get message of showing which rows user has checked. The message should appear when user clicks OK button. There could be several message, checking each row one by one, in a loop.
I am not able to get this message. I tried following code in OK button
Dim strCB As String = dgvChooseQs.Rows(0).Cells(3).Value.ToString
Cell(3) is my checkbox. Donot consider Rows(0), at the moment I am just checking value at row 0
View 2 Replies
Jan 16, 2008
I have read and tried a dozen or more examples of trying to capture the Enter key in a datagrid, but I have yet to find something that works. My scenario is :
ds.Tables.Add(dt)
dt.Columns.Add("Inventory Nr", GetType(System.String))
dt.Columns.Add("Cases", GetType(System.Int32)) Inventory Nr in the next row.
[code].....
View 1 Replies
Dec 18, 2010
I'm currently trying to Capture through DirectSound, I've been trying toying around with WaveLib(Ported to VB) but this is very confusing. Anyway, I cant figure out how I am supposed to do this and would like some assistance. The end goal of this project is to: Record Microphone > Encode with Speex Codec > Send over UDP > Decode > Play on Speakers
View 3 Replies
Nov 18, 2011
i use with this code: Dim bounds As Rectangle
Dim screenshot As System.Drawing.Bitmap Dim graph As Graphics bounds = Screen.PrimaryScreen.Bounds
screenshot = New System.Drawing.Bitmap(bounds.Width, bounds.Height, System.Drawing.Imaging.PixelFormat.Format32bppArgb)
graph = Graphics.FromImage(screenshot)
graph.CopyFromScreen(bounds.X, bounds.Y, 0, 0, bounds.Size, CopyPixelOperation.SourceCopy)
PictureBox1.Image = screenshot
But when I try it in games,it shows only a black picture.
View 4 Replies
May 28, 2007
I would really like to get some VB.net program code for still image capturing using a Webcam.I've searched the web for quite a while now but did not get any codes. Currently i have a code for capturing video. In that code an image can be captured, but only with 640 X 480 resolution (Maximum Video resolution for my web camera). The WM_CAP_DLG_VIDEOFORMAT dialog box only allows the resolution to be set up to 640 X 480.
[Code]...
View 6 Replies
Jul 18, 2012
I'm just wondering if it's possible to add the mouse when capturing the screen or monitor in vb.net?
because I'm doing a project that would record the screen and I'm actually successfull doing that by capturing the screen and include it in a timer, but my only problem is the mouse or the cursor isn't showing.
below is my sample code.
Dim ScreenSize As Size = New Size(TotalScreenWitdh, MonitorHeightArray(0))
Dim BMP As New Bitmap(TotalScreenWitdh, MonitorHeightArray(0))
[Code].....
View 5 Replies
Aug 26, 2008
We are using avicap32.dll for capturing Pictures from Webcam,and we want to display the list of connected Webcam names but we are only able to get the driver name for webcam by using capGetDriverDescriptionA method. Is there any method to get the name of the webcam like "asus W120"
View 5 Replies
Nov 21, 2010
I'd like to start by saying that simply though searching, DreamInCode has taught me alot about VB.NET. In fact, I would imagine without DIC as a resource, I probably wouldn't have been able to move forward and learn most of what I know now, just because I got stuck on some things here and there.Anyway, I searched around for information regarding how to "capture" a minimize event in VB.NET. I am working on the GUI for an application that I would like to have minimize to the system tray. Currently, instead of accomplishing this with the minimize function, I do it on the FormClosing event like this:
Private Sub MainFrm_FormClosing(ByVal sender As System.Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles MyBase.FormClosing
'Cancel the attempt.
[code]....
That code works, and upon making the form visible again with Me.Visible = True the form is restored to its original position. However, prior to the form being hidden, the window manager draws a minimize and restore effect before eventually hiding it. Any change to the WindowState _after_ hiding the form does not appear to have any effect, so when the form is unhidden it is still minimized.is there a way to capture Minimize events, and when captured, is it possible to cancel them in a manner similar to what I did with the FormClosing event?
View 2 Replies
Aug 3, 2011
I'm stuck here in a code that requires me to capture the printer name and storing the file name as well.
The code is hown as below:-
Dim dir_info As New DirectoryInfo(strDirectory) 'the directory is D:jeremyPrint ServicePrint ServicePL"
dInfo = New DirectoryInfo(strDirectory)
[Code]....
View 2 Replies
Mar 20, 2012
I have an application that primarily moves files from one location to another. I need to get the user's response when asked by Windows if they would like to overwrite or rename the new file because it already exists in the destination selected on the form. I basically need to receive a boolean value so i can update the transaction logs.[code]
View 5 Replies
Apr 3, 2011
Now i'm capturing frames from webcam and send them via UDP, it's not realtime. Is it streaming?
View 4 Replies