Just a quick guess:
The connection string is very sensitive to spaces. Make sure they are omitted, such as in "SourceDB = ".
I've never seen connection coding using a "With" statement. Not that it wouldn't make sense, though. Try coding without it and let us know.
This question relates to WORD VBA only:
I know I can use this:
Me.Textbox1.Value = 2345 or Me.Textbox1.text = "Hello"
and
x = Me.Textbox1.Value (or text)
But in this case if have multiple frames and tabs
I have a form -- frmMain
frmMain has mpgWizard -- a multipage control...
Believe it or no, that doesn't work either. I'm at a loss.
Word VBA has no LostFocus event in a textbox. It's wierd. Many things in VB, Excel VBA, Access VBA are not in Word VBA, said "Ripley."
I honestly believe that the cursor is in the textbox, but it isn't visible. I can use...
I can't get the cursor back into the textbox (or list, or combo) in Word 2000. This does work in Word 97, though.
Can anyone help?
Private Sub Textbox1_Exit (ByVal Cancel as MSForms.ReturnBoolean)
If Not IsNumeric(TextBox1.Text) Then
MsgBox "Please enter a numeric value"...
Sometimes you need to purposely select the macro and help options when installing. Many people never get to the macro programming, and don't use them.
Second, you may wish to check to see if your ActiveX files have been referenced.
Go to any "code" page in the Macro Editor, click on...
I am creating a project with many, many panels using multipage. I have lots and lots of controls -- text, combo, etc.
I have written the following code to change the background color on entry and exit.
I have also written the following code to format the text boxes for date and amount...
Thanks, Rick. That may be the way I have to go. There's some really good DLL and OCX files out there, but for the sake of our users machines (banks, lenders, etc.), we try to avoid adding anything more than necessary.
Makes it quite a challenge. Maybe someone can direct me to some free code...
Can anyone supply the values in the registry for the templates directory for Users, Workgroups, and documents when Word 2000 is installed on an NT system?
Could you also provide Word 97 values on an NT?
Thanks,
Dan
i.e., System.PrivateProfileString(""...
Is this your own ActiveX control? What version of VB are we in?
Unfortunately I have found super features in VB5 and VB6 that are not in VBA5 and VBA6, and vice versa. Very frustrating.
Dan
I would like to add Calc.exe to my VBA Word project. That is, the user can click a button on my form, and calculator will appear. Can I capture or control any buttons, menus, or textboxes in Calc using VBA? The user will make a calculation, which then must appear in the form textbox (for...
Well, I'm not very good at API, but what about SendKeys.
I just tested Access, and on placing the cursor in the textbox, then pressing the Insert key, it changed the cursor.
So, perhaps OnFocus Then SendKeys????
Dan
I have textboxes on a form, some of which are coded to change the background color in the Enter and Exit event. The last textbox on the form, however, does not change the background color on Exit (tabbing out of textbox to next control, which is a command button). I have tried many different...
I have created the following to reuse my code for textboxes by creating a class to handle the enter and exit events.
I can get the change event and several others after running this code, but what happened to the enter and exit? I really do need the enter and exit events.
This code is placed...
I have written the following code in a form and in a class module (actually I got help from the internet). It works fine in VBA 6.0 (Word 2000), but will not work in VBA 5.0 (Word 97) -- it actually was written for VB.
I am writing an automation document with Word and need my new programming...
My text file consists of 53 variables I must retrieve and use to populate parallel variables in a Word template.
I discovered, after much frustration, that I can import a tab-delimited file AS LONG AS I leave the name xxx.CSV. It absolutely WILL NOT work with xxx.TXT.
So I simply added code...
I have the following code in my VBA module which works fine on a comma delimited text file. However, my text file is tab delimited. I have looked everywhere for a comparable statement to "Microsoft Text Driver ..." for tabs.
Can someone put me onto the correct coding?
On Error GoTo...
This website shows an example of ASP to Word, but there's lots of links that may be helpful.
www.asptoday.com/articles/19990825.htm (or just www.asptoday.com)
Dan
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.