|
The Garbage Collection doesn't run instantly so objects can hang around in memory for a while.
Another option is that you might have a memory leak, heres an article on common winform memory leaks.
http://blogs.msdn.com/davidklinems/archive/2005/11/16/493580.aspx[^]
To definativly find out you could use a profiler like Redgate's Ants or Jetbrains dotTrace.
|
|
|
|
|
When you start a .NET application it allocates a big heap of memory for its own use and the framework memory handling system (also the "garbage collection") works with this.
When you work in VB6 the app grows the heap each time you need more memory.
Since heap management takes clock cycles, the .NET designers have traded memory footprint for speed (and stability).
The analogy is like if you are building a wall. The .NET way is to order a palette of bricks (which takes up space on your driveway) and take from the palette as the wall is built - only getting another palette if the current one runs out whereas the VB6 way is to go to the store for each brick in turn.
|
|
|
|
|
when i want to run the project that i made it yesterday and it was working very well
the vb show me this error
error while trying to run the project : could not load file assembly 'ehab' or one of it's dependancies.the module was expected to contain an assembly manifest
any one have any suggestion...?
|
|
|
|
|
It's saying that it can't find an assembly, called "ehab", probably "ehab.dll", in the application's startup folder. Did you miss copying all the .DLL files from your build folder to the folder where you deployed your app? Did you delete anything?
|
|
|
|
|
I want to know
How to Create New folder and existing delete folder using VB.Net.
My another question is how to delete file.
|
|
|
|
|
There are lot of tutorials related to your Question.
Get it[^]
Regards,
Satips.
|
|
|
|
|
|
Glad to help Always
Regards,
Satips.
|
|
|
|
|
Hi,I'm a newbie here.
I've searching a solution for this particular problem and I couldn't found any of it.Here is my question:
1.How to give a single datagrid cell some color and it will turn back to default color in a 5 second.
eg: the default color is black and we turn it to green. after 5 second, it will turn back to black.
2.How to color a row or cell border,whether top, bottom , left or right of the row/cell.
Hope somebody can help me.
Thanks.
|
|
|
|
|
Something tells me I'm going to regret doing this...
Which version of the .NET Framework are you using? Are you using a DataGrid or a DataGridView?? Yes, it makes a huge difference!
|
|
|
|
|
i'm using datagrid , visual studio 2003
|
|
|
|
|
See this[^] little FAQ on the DataGrid. It's full of examples like what you're looking for. It's show you how to paint rows, columns, and cell. It will NOT show you how to flash different colors though. For that, you have to use the information you get from these code samples and a Timer to get the colors to flash.
|
|
|
|
|
thanks to your url, Dave.
|
|
|
|
|
im having trouble with my program... im new to vb.net so please forgive me... i got it to run a batch file... now i want it to run the program with arguments at the end because the program wont run it gives me win32 errors... so far this is the code
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
System.Diagnostics.Process.Start("C:\folder\filetorun.exe")
End Sub
End Class
this code works... but i want it to look like this...
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
System.Diagnostics.Process.Start("C:\folder\filetorun.exe update -verify")
End Sub
End Class
this is what gives me problems... anything after the file wont work...
eventually i want to be able to enter the destination of the install into a tex box and it install to the directory
someone please help
my email is lan-lord@cinci.rr.com
|
|
|
|
|
|
You have to supply the arguments seperate from the path to the .EXE:
Process.Start("C:\folder\filetorun.exe", "-verify")
|
|
|
|
|
I am trying to call a DataTable in one Public Sub from another Public Sub. The IDE is giving me the error 'Name 'dt' is not declared'.
How can I pass this DataTable from one Public Sub to another?
Thanks,
Dan
|
|
|
|
|
where did you declare the DataTable and what its access modifier ??
When you get mad...THINK twice that the only advice
Tamimi - Code
|
|
|
|
|
Here are my two subs, both subs' access are public.
<br />
Public Sub DiseaseList(ByVal connectionString As String)<br />
'Disease List<br />
Dim strSQLDiseaseList As String = "Select DiseaseName, DiseaseCode, SurveillanceFormFlag, TwentyFourHRReportFlag, CausativeOrganismFlag, SerotypeFlag, SiteOfInfectionFlag From Disease"<br />
Dim daDisease As New OleDbDataAdapter(strSQLDiseaseList, connectionString)<br />
Dim dtDisease As New DataTable("Disease")<br />
<br />
<br />
Try<br />
daDisease.Fill(dtDisease)<br />
Catch ex As Exception<br />
MessageBox.Show(ex.Message)<br />
End Try<br />
<br />
<br />
With cboDiseaseName<br />
.DropDownStyle = ComboBoxStyle.DropDownList<br />
.DataSource = dtDisease<br />
.DisplayMember = "DiseaseName"<br />
.ValueMember = "DiseaseCode"<br />
.SelectedIndex = cboDiseaseName.FindStringExact("")<br />
End With<br />
'End Disease List<br />
End Sub<br />
And here is the second, this one is trying to see values of the datatable dtDisease.
<br />
Private Sub cboDiseaseName_SelectedValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles cboDiseaseName.SelectedValueChanged<br />
<br />
Dim dvFilter As DataView = Nothing<br />
<br />
dvFilter = dtDisease<br />
<br />
<br />
End Sub<br />
|
|
|
|
|
In your case, you would have to move the declaration for dtDisease to class-scope to do this:
Public Class MyForm
Inherits System.Windows.Forms.Form
Private dtDisease As DataTable
Public Sub DiseaseList(ByVal connectionString As String)
'Disease List
.
.
dtDisease = New DataTable("Disease")
.
.
End Sub
Private Sub cboDiseaseName_SelectedValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) _
Handles cboDiseaseName.SelectedValueChanged
Dim dvFilter As DataView = Nothing
dvFilter = dtDisease...
End Sub
|
|
|
|
|
Hi,
I posted this message last week but didn't get any reply.
Maybe my question was not clear, so here it comes again:
I made a vb6 application which reads a html file from
the WWW and writes this html file to disk
using the URLDownloadtoFile of "URLMON.DLL".
Then the application reads the file and put the content
of this file in a single string.
Next the application will manipulate the string for special
purposes.
I now am looking for a solution to skip the write and
read to/from disk and fill the sting directly.
I suppose this could be done with the URLOpenStream or
URLOpenPullStream functions of "URLMON.DLL".
I couldnot get this working.
Please can anybody give me a clue or, if possible, provide me with
an example?
Thanks in advance.
Hans Vanmeel
|
|
|
|
|
You didn't get a reply because none has any experience with UrlMon and VB6. There's not examples that I could find in VB6 that use any of the UrlMon URL to Stream functions.
I don't have any examples and I don't have VB6 any longer either.
If you were using VB.NET, this would be very easy using the built in classes of the .NET Framework.
|
|
|
|
|
A manager wanted to know how to subtract working days from an actual date. The only problem is the second date is not a date, but a number.
For example:
Date1: 01-July-2007
He wants to know what the date would be if we subtract 10 working days. Excel will take the date minus 10 no problem, and it will calculate working days between two actual dates, but I cannot figure out how to finagle this thing to automatically subtract working days without intermediate steps. Is there a non-documented function like DATEDIF in excel that might help?
______________________
stuff + cats = awesome
|
|
|
|
|
I seem to remember a Workday function in Excel...
|
|
|
|
|
The only thing is that you have to put two dates, like workdays (01-Jan-2007, 31-Jan-2007). I tried using a number for the second value and it bombed out.
______________________
stuff + cats = awesome
|
|
|
|