|
i have a program that goes into a folder looks into each subfolder and gets all the .jpg files and stores the file names in an array which i then use to insert the path into a msde database. My problem is either one of two things happen
1.the form freezes but the program still does what it needs to
2.or the program simply just freezes
the machine i am using has 1 ghz processor and 786 mb ram and my uses will not have computers even close to this so anybody have any suggestions?
|
|
|
|
|
|
you mean something like this :
VB:
<font color="blue">Private</font> <font color="blue">Sub</font> Button3_Click(<font color="blue">ByVal</font> sender <font color="blue">As</font> System.Object, <font color="blue">ByVal</font> e <font color="blue">As</font> System.EventArgs) <font color="blue">Handles</font> Button3.Click
<font color="blue">Dim</font> someStuff <font color="blue">As String</font>
<font color="blue">Dim</font> i <font color="blue">As Integer</font>
<font color="blue">For</font> i = 1 <font color="blue">To</font> 4
TextBox1.AppendText(someStuff & " : part : " & i & vbCrLf)
<font color="darkgreen">'/// do your stuff here .</font>
<font color="blue">Next</font>
<font color="blue">End</font> <font color="blue">Sub</font>
putting your stuff to do where it says "TextBox1.AppendText"
<font color="blue">Private void</font> ExpectingTwins(<font color="blue">string</font> twins)
{
<font color="blue">switch</font>(twins)
{
<font color="blue">Case</font> ("twins on the way"):
MessageBox.Show("for mr and mrs dynamic","twins on the way");
<font color="blue">break</font>;
}
}
|
|
|
|
|
Thanks. But I don't quite understand how to implement that in my program. It's maybe best to show you the code in question.
<br />
Private Sub K_Sten_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles K_Sten.Click<br />
/.../<br />
End Sub<br />
<br />
Private Sub K_Sax_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles K_Sax.Click<br />
/.../<br />
End Sub<br />
<br />
Private Sub K_Pase_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles K_Pase.Click<br />
/.../<br />
End Sub<br />
<br />
Private Sub K_Klar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles K_Klar.Click<br />
/.../<br />
End Sub<br />
<br />
Private Sub Huvud_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load<br />
/.../<br />
End Sub<br />
<br />
Private Sub K_Ny_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles K_Ny.Click<br />
This is where I want to go back to: Sub K_Sten_Click; Sub K_Sax_Click; Sub K_Pase_Click; Sub K_Klar_Click.
All of my subroutines runs independent of each other.
<br />
<br />
Private Sub M_Avsluta_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles M_Avsluta.Click<br />
/.../<br />
End Sub<br />
<br />
Private Sub M_Om_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles M_Om.Click<br />
/.../<br />
End Sub<br />
//OT
|
|
|
|
|
are you saying you want to cause the triggering of all those buttons in an event? so the loop causes these to do something : Sub K_Sten_Click; Sub K_Sax_Click; Sub K_Pase_Click; Sub K_Klar_Click.
<font color="blue">Private void</font> ExpectingTwins(<font color="blue">string</font> twins)
{
<font color="blue">switch</font>(twins)
{
<font color="blue">Case</font> ("twins on the way"):
MessageBox.Show("for mr and mrs dynamic","twins on the way");
<font color="blue">break</font>;
}
}
|
|
|
|
|
No, I just want those Sub routines to be reset when clicked on a button.
//OT
|
|
|
|
|
Now I have fixed the problem.
//OT
|
|
|
|
|
In Visual Basic 6 in Highschool we used MMControl 6.0 in order to play .WAV files in our applications?
That Was a long time ago. Can anyone please tell me where I can find some code in order to play sounds in my Application
Thank You
The Jazz Master 6000
DJ Badknees
Parma Grind Crew - www.geocities.com/parmagrindcrew
|
|
|
|
|
in vb.net do this :
VB:
<font color="blue">Private</font> <font color="blue">Declare</font> <font color="blue">Function</font> sndPlaySound <font color="blue">Lib</font> "winmm.dll" <font color="blue">Alias</font> "sndPlaySoundA" _
(<font color="blue">ByVal</font> lpszSoundName <font color="blue">As String</font>, <font color="blue">ByVal</font> uFlags <font color="blue">As Integer</font>) <font color="blue">As Integer</font>
<font color="blue">Const</font> SND_SYNC <font color="blue">As Integer</font> = &H0
<font color="blue">Const</font> SND_ASYNC <font color="blue">As Integer</font> = &H1
<font color="blue">Const</font> SND_NODEFAULT <font color="blue">As Integer</font> = &H2
<font color="blue">Const</font> SND_LOOP <font color="blue">As Integer</font> = &H8
<font color="blue">Const</font> SND_NOSTOP <font color="blue">As Integer</font> = &H10
<font color="blue">Dim</font> SoundName <font color="blue">As String</font>, wFlags <font color="blue">As Integer</font>, x <font color="blue">As String</font>
<font color="blue">Private</font> <font color="blue">Sub</font> Button2_Click(<font color="blue">ByVal</font> sender <font color="blue">As</font> System.Object, <font color="blue">ByVal</font> e <font color="blue">As</font> System.EventArgs) <font color="blue">Handles</font> Button2.Click
SoundName = "D:\Knock.wav"
wFlags = SND_ASYNC <font color="blue">Or</font> SND_NODEFAULT
x = sndPlaySound(SoundName, wFlags)
<font color="blue">End</font> <font color="blue">Sub</font>
putting your sound file's name where it says "D:\Knock.wav"
hope that helps
<font color="blue">Private void</font> ExpectingTwins(<font color="blue">string</font> twins)
{
<font color="blue">switch</font>(twins)
{
<font color="blue">Case</font> ("twins on the way"):
MessageBox.Show("for mr and mrs dynamic","twins on the way");
<font color="blue">break</font>;
}
}
|
|
|
|
|
Thanks Again...You are a life saver!
The Jazz Master 6000
DJ Badknees
Parma Grind Crew - www.geocities.com/parmagrindcrew
|
|
|
|
|
Hi,
I have a question regarding the use of a hllapi application to screen scrape in XP. Currently I have a hllapi program that screen scrapes from a 16 bit dos app. to a terminal emulator (Attachmate's Accessory Manager) in Windows 95. The problem in converting this to XP is that the hllapi program uses an INT 7F call and the location in the vector table points to the location of a virtual device driver (vxd's are not supported in XP). I was wondering if there was a way to write a VB hllapi program that would kind of act the same way as the current program but without the direct memory calls. THANKS!!!
Jordan
|
|
|
|
|
Yes, there is a 32-bit Windows specification for HLLAPI, called WinHLLAPI. It's focused on C/C++, but you can call it from VB6/VB.NET through the proper "Declares".
I worked a lot with Attachmate products and most of them support WinHLLAPI. Actually, most 3270/5250 emulators support WinHLLAPI and they normally provide some screen scraping samples.
Other alternatives:
The drawback is that, HLLAPI (which you are using now) and its Win32 counterpart, WinHLLAPI, although fine for single user/single machine applications, it is awful slow and too memory hungry for high-performance server applications, In this case, I discovered that by writing a TN3270 emulator I got about a 15x faster application, also saving several tenths of MB RAM.
If there is a LU6.2 transaction available, I would definitively go for APPC. Microsoft's Host Integration Server can map, through a simple wizard, an APPC to a COM+ component, easily used from VB6/VB.NET.
ORACLE One Real A$#h%le Called Lary Ellison
|
|
|
|
|
I've created an interface using C++/ATL which I can then implement in a coclass. What I want to do is to now build a VB COM object which implements the same interface. Is this possible or can VB only *use* a C++ coclass I've implemented in a COM server?
"The folly of man is that he dreams of what he can never achieve rather than dream of what he can."
"If you think education is expensive, try ignorance."
|
|
|
|
|
how can we create a toolbar type thing with a close button on its title bar...like theOffice toolbars
anand
|
|
|
|
|
Hi,all.
I want to use a work thread in my project .Who can help me .Please give me a sample.
|
|
|
|
|
First of all, what version of VB?
RageInTheMachine9532
|
|
|
|
|
dim thd as Threading.Thread<br />
<br />
Private Sub threadSub()<br />
'Some Code<br />
End Sub<br />
<br />
Private Sub threadLauncher()<br />
thd = new Threading.Thread(AddressOf threadSub)<br />
thd.Start()<br />
End Sub
This makes a thread running threadSub, if you want to keep this thread running you should
add code like this:
While True<br />
<br />
End While
Greetings....
|
|
|
|
|
I am using the ADODC control to manipultate data.
now I want to add new(record) data to my table for this purpose what I have tried is this code
"adodc.recordset.addnew"
but the error that comes on clicking the add button is data bound error this is because I think that I have not specified the field in which I want to insert new data. I have tried it unable to know how can i update,dalete, add new data.
Please if you can help me by giving certain example for practicing data base or refer any site that can help me.
I am using access on my back end.
Reply me soon
|
|
|
|
|
:?: How would I make the graphs I want to plot to be displayed in landscape layout?
How do I go about graphing data points into a line and bar graph?
thx
|
|
|
|
|
I would like to know where to start looking to create an application to read barcodes from images. I have very little knowledge of how an image file works.
Does anyone have any ideas on where I can start looking?
|
|
|
|
|
Not sure if this will help - I did it years ago in 'C'.
Back then we read the file as a binary input. found the width and height in the bitmap header file ( you should be able to find the structure layout on the net or use an API function.
Having discovered the start bit/byte (depends on the format) you can read across the pixels noting the colours.
Black on white should be relatively easy. Other colours need some thought!
Good luck.
I'm sure I've seen a sample of this in VB5 or VB6. I haven't migrated to .Net yet so couldn't say about that.
Alan ...
|
|
|
|
|
Does anyone know how to define multiple precompiler constants from the project properties dialog?
I've used single precompiler constants. I want to know how I can define more than one without defining the constant in code.
"It was when I found out I could make mistakes that I knew I was on to something."
-Ornette Coleman
|
|
|
|
|
|
Jonavis wrote:
any help?
Well, at first glance here the article is performing serial communication, however the application is designed to run under VB 6.0, not Visual Studio .NET. Are you trying to implement serial communication in .NET? There is a complete difference between VB 6.0 and VB.NET. Does this help?
-Nick Parker
|
|
|
|
|
thats what I need to find out is how to implement that on VB.net .. I need to get info from a GSM modem conected to my COMM ports...either by serial or USB.
help!!
(thanks)
|
|
|
|