|
Dave Kreskowiak wrote:
You should be checking this BEFORE your MDI child form is created. Not checking for it in the child form.
Thanks for the reality check. You are right. I needed that.
I was hoping to keep all the code for each form within the individual child, and find an event that would allow me to confirm that the window was created, so I could close it. But why make life difficult.
Thanks again.
|
|
|
|
|
The forms in your application should each be responsible for one thing and one thing only. In your case, you have the data entry form responsible for two things. The first is checking to see if it is needed, and the second, obviously is the data entry. Always(!) keep this functionality seperate.
If it's a data entry form, it strictly handles data entry. If it's a form that displays records and lets a user pick one to edit, it handles strictly that. Create another form that handles editing the record picked.
I've seen a couple people that wanted to hide the datagrid and put up a run-time generated list of controls on the same form. WHY? Why must these people do it the hard way???? Always favor functionality over looks. If your app looks great, but works like crap, its headed for the Add/Remove Programs control panel.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi all.
My environment is Win XP, VB.NET.
I have a simple picture box that is FIXED size and I want it to show a picture at a run time. But every time I insert a picture in it it shows me just a small portion of the entire picture.
How do I make my picture box display the entire picture without resizing itself....
|
|
|
|
|
By changing the properties of the picture box so that it scales the image to fit the picture box.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
I need to write an app that plays only AVI files, nothing else. Anyone know the best way to start, or any good resources?
|
|
|
|
|
Here's one using DirectShow
http://www.codeproject.com/useritems/direct_show_-_playa.asp
and here's another one
http://www.vbcodesource.com/exampleNet.html
(4th one down)
|
|
|
|
|
i am looking at the vbcodesource.com example because i dont do ++
Why am i getting squiggly lines under this
Imports Microsoft.DirectX.AudioVideoPlayback
That is exactly how it is in the project. Any ideas???
|
|
|
|
|
You probably don't have the Managed DirectX SDK installed. Get it here[^].
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
when i get the DirectX SDK where do i put the extracted files?????
|
|
|
|
|
Does anyone know any programs for recording (as in a movie file) actions performed as they look on the screeen. Say i want to write a tutorial on how to use a program, what would i use to record into a movie file the steps i take. Its hard to explain, i hope you guys understand what im looking for.
|
|
|
|
|
You want to do something like the guys over at learnvisualstudio.net? You could try CamStudio... You can get it here:
http://curl.planetmirror.com/pub/winsite/winxp/graphics/CamStudio.exe
There was another program out there I saw before that worked well, but I'd have to search for it. Let me know if camStudio doesn't work for you.
|
|
|
|
|
I found a different one called hypercam and it works but i am going to try the camstudio too, thanks
|
|
|
|
|
Do you have a link to HyperCam? Thanks!
Have a great day!
j2associates_NO_SPAM_@yahoo.com
|
|
|
|
|
|
Thanks for posting the link!
Have a great day!
j2associates_NO_SPAM_@yahoo.com
|
|
|
|
|
You could try Microsoft Movie Maker. It's free with XP. ULead Video Studio I heard is a good one.
But you will also need a video editing board which allows you to connect the media source to your computer. When you buy it video software should come with it also.
|
|
|
|
|
Here is a sample from my connect.vb file. It shows a testing (dev) version of a button and the real version of the button. (These are command buttons in my Excel addin) I want them both to bring up the same form with a different db connection. Is there a way to pass a variable that gets set in these subs to the form?
Private Sub MyUpload_dev_Click(ByVal Ctrl As Microsoft.Office.Core.CommandBarButton, ByRef CancelDefault As Boolean) Handles MyUpload_dev.Click
Dim frm As New frmGOUpload
frm.XLA = excelApp
frm.WS = excelApp.Workbooks(1).ActiveSheet
frm.Show()
End Sub
Private Sub MyUpload_Click(ByVal Ctrl As Microsoft.Office.Core.CommandBarButton, ByRef CancelDefault As Boolean) Handles MyUpload.Click
Dim frm As New frmGOUpload
frm.XLA = excelApp
frm.WS = excelApp.Workbooks(1).ActiveSheet
frm.Show()
End Sub
This is kind of what I am thinking of trying to do in the form:
If <variable> = 'dev' then
Dim wsrv As New SEOWS_dev.Service1
else
Dim wsrv As New SEOWS.Service1
end if
|
|
|
|
|
Make a public Property on your saecond form. Set the property to whatever value you need to pass before the form is shown.
Dim frm As New frmGOUpload
frm.connString = "Whatever..."
frm.XLA = excelApp
frm.WS = excelApp.Workbooks(1).ActiveSheet
frm.Show()
Public Class frmGOUpload
...
Private m_ConnectionString As String
...
Public Property connString() As String
Get
Return m_ConnectionString
End Get
Public Set(ByVal Value As String)
m_ConnectionString = Value
End Set
End Property
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
"Normal" Concatenation of many small strings seems to be very slow in VB6.
Is there a something like a "string builder" or "preallocation"?
Pandoras Gift #44: Hope. The one that keeps you on suffering. aber.. "Wie gesagt, der Scheiss is' Therapie" boost your code || Fold With Us! || sighist | doxygen
|
|
|
|
|
In VB6? I seem to remember that there was a Join function somewhere. ... searching... Ah! Here we go, Join function[^]
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
True, but that only joins an array...
Dim strReturn as String
Dim arrString(3) as String
arrString(0) = "This "
arrString(1) = "is "
arrString(2) = "an "
arrString(3) = "example."
strReturn = Join(arrString)
strReturn now equals "This is an example."
|
|
|
|
|
Your point being?
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Simply stating that though you are correct, the method is clumsy due to VB6 in itself being very limiting in its string concat abilities.
(ie. Not as simple as the StringBuilder class that was mentioned)
|
|
|
|
|
Considering this is the only function VB6 has to combine a bunch of smaller strings together into a single string, without using string concatentation, I think your point is moot. The goal of the OP was to get quicker performance out of putting the strings together, which Join will do, not to make it look pretty in code.
In VB6, you have two ways to do this. Either use string concatenation or use Join.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Dave Kreskowiak wrote:
In VB6, you have two ways to do this. Either use string concatenation or use Join.
Strictly, this is 100% true... but you can wrap the JOIN call into something easier (and more familiar to use)
Here's a good article:
VBScript StringBuilder[^]
|
|
|
|