Help Not Available

G

GRayL

I am running Office 2000 under XP Home. When I go into VB
using Ctl G, get into Help and enter "openrecordset", I
get 18 topics, the first of which is "OpenRecordSet
Method". However, there is no help available on the right
side of the screen. It remains the weclome screen to
Visual Basic. That is the case for the first 14 topics.
Only the last four provide help. I get the same when I
enter a module. As per the knowledge base, I removed the
key [HKEY_CURRENT_USER\Software\Microsoft\Office\9.0
\Common\HelpViewer] from the registry to no avail. I was
trying to use visual basic to create a line delimited
text file from a small table. My code executes, but does
not produce the textfile. It looked like a context
problem and I needed Help to try to resolve the use of
openrecordset, open, and print.
 
G

GRayL

Wayne:

Further to your suggestion, I added the help files and
its now working for the most part. However I am having
trouble gettting the following code to execute. When I
included "mydb as database in the dim statement, the
compiler came back with "Compiler error, User-defined
type not defined." When I removed "mydb as database" it
seemed to work fine yet produced a zero length file
Tel1.txt. When I executed the second bit of code in the
immediate window, it produced the results expected. I
removed Office 2000 Disk 1 and Disk 2, reinstalled Disk
1, and installed SR 1 to no avail.
I thought that "database" was in the "list of
properties/methods". Could I have a sick CD? Have I lost
a lot of time on this one. I appreciate any help you can
give me.

GRayL

Private Sub Command0_Click()

On Error Resume Next
Dim myrs As Recordset, strvar As String, intnum As Integer
Set mydb = CurrentDb

Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum

Do
Write #intnum, myrs!LNAME
myrs.MoveNext
Loop Until myrs.EOF
Close #intnum
Set myrs = Nothing
Set mydb = Nothing
End Sub


--------Immediate Window Code-------------
Set mydb = CurrentDb
Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum
do: write #intnum,myrs!lname: myrs.movenext: loop until
myrs.eof
close #intnum

-----Original Message-----
This sounds a little different than what I normally see, but see if this
will help anyway.

http://support.microsoft.com/default.aspx?scid=kb;en- us;249065&Product=acc2000

--
Wayne Morgan
Microsoft Access MVP


I am running Office 2000 under XP Home. When I go into VB
using Ctl G, get into Help and enter "openrecordset", I
get 18 topics, the first of which is "OpenRecordSet
Method". However, there is no help available on the right
side of the screen. It remains the weclome screen to
Visual Basic. That is the case for the first 14 topics.
Only the last four provide help. I get the same when I
enter a module. As per the knowledge base, I removed the
key [HKEY_CURRENT_USER\Software\Microsoft\Office\9.0
\Common\HelpViewer] from the registry to no avail. I was
trying to use visual basic to create a line delimited
text file from a small table. My code executes, but does
not produce the textfile. It looked like a context
problem and I needed Help to try to resolve the use of
openrecordset, open, and print.


.
 
T

Tom Wickerath

Hi GRayL,

You received the compile error because you are using DAO code, but Access 2000 does not
include a reference to the DAO Object Library by default.

1. Open your code module, click on Tools > References, and then find the reference that
reads:

Microsoft DAO 3.6 Object Library

Place a check to select it, and then click on the OK button to dismiss this dialog.


2. Make the following modifications to your code:

Add
Dim mydb As DAO.Database after On Error Resume Next

Change
Dim myrs As Recordset
to Dim myrs As DAO.Recordset

Qualifying the recordset type is a good idea, so that you don't have to worry about
priority issues between the DAO and ADO Object Libraries. See
http://support.microsoft.com/?id=202192 for more information. Note: You don't really need
to qualify DAO.Database, since there is no ADO equivalent, but I think its still a good
idea because it makes your code more readable.

Assuming that your recordset includes a field named LNAME, you should be all set.

Tom
______________________________________________


Wayne:

Further to your suggestion, I added the help files and
its now working for the most part. However I am having
trouble gettting the following code to execute. When I
included "mydb as database in the dim statement, the
compiler came back with "Compiler error, User-defined
type not defined." When I removed "mydb as database" it
seemed to work fine yet produced a zero length file
Tel1.txt. When I executed the second bit of code in the
immediate window, it produced the results expected. I
removed Office 2000 Disk 1 and Disk 2, reinstalled Disk
1, and installed SR 1 to no avail.
I thought that "database" was in the "list of
properties/methods". Could I have a sick CD? Have I lost
a lot of time on this one. I appreciate any help you can
give me.

GRayL

Private Sub Command0_Click()

On Error Resume Next
Dim myrs As Recordset, strvar As String, intnum As Integer
Set mydb = CurrentDb

Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum

Do
Write #intnum, myrs!LNAME
myrs.MoveNext
Loop Until myrs.EOF
Close #intnum
Set myrs = Nothing
Set mydb = Nothing
End Sub


--------Immediate Window Code-------------
Set mydb = CurrentDb
Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum
do: write #intnum,myrs!lname: myrs.movenext: loop until
myrs.eof
close #intnum

-----Original Message-----
This sounds a little different than what I normally see, but see if this
will help anyway.

http://support.microsoft.com/default.aspx?scid=kb;en- us;249065&Product=acc2000

--
Wayne Morgan
Microsoft Access MVP


I am running Office 2000 under XP Home. When I go into VB
using Ctl G, get into Help and enter "openrecordset", I
get 18 topics, the first of which is "OpenRecordSet
Method". However, there is no help available on the right
side of the screen. It remains the weclome screen to
Visual Basic. That is the case for the first 14 topics.
Only the last four provide help. I get the same when I
enter a module. As per the knowledge base, I removed the
key [HKEY_CURRENT_USER\Software\Microsoft\Office\9.0
\Common\HelpViewer] from the registry to no avail. I was
trying to use visual basic to create a line delimited
text file from a small table. My code executes, but does
not produce the textfile. It looked like a context
problem and I needed Help to try to resolve the use of
openrecordset, open, and print.


.
 
T

Tom Wickerath

The declarations shown in Example 2 of KB articles 202192 and 289664, as shown today, are
incorrect:

Example 2: ADO Objects
Reference: Microsoft ActiveX Data Objects 2.1 Library
Declaration: Dim myRecordset as ADO.Recordset

The Declaration should read:
Dim myRecordset As ADODB.Recordset

Ref.: http://support.microsoft.com/?id=202192
Last Reviewed: 2/16/2001 (1.0)

and http://support.microsoft.com/?id=289664
Last Reviewed: 11/6/2003 (3.0)


___________________________________________


Hi GRayL,

You received the compile error because you are using DAO code, but Access 2000 does not
include a reference to the DAO Object Library by default.

1. Open your code module, click on Tools > References, and then find the reference that
reads:

Microsoft DAO 3.6 Object Library

Place a check to select it, and then click on the OK button to dismiss this dialog.


2. Make the following modifications to your code:

Add
Dim mydb As DAO.Database after On Error Resume Next

Change
Dim myrs As Recordset
to Dim myrs As DAO.Recordset

Qualifying the recordset type is a good idea, so that you don't have to worry about
priority issues between the DAO and ADO Object Libraries. See
http://support.microsoft.com/?id=202192 for more information. Note: You don't really need
to qualify DAO.Database, since there is no ADO equivalent, but I think its still a good
idea because it makes your code more readable.

Assuming that your recordset includes a field named LNAME, you should be all set.

Tom
______________________________________________


Wayne:

Further to your suggestion, I added the help files and
its now working for the most part. However I am having
trouble gettting the following code to execute. When I
included "mydb as database in the dim statement, the
compiler came back with "Compiler error, User-defined
type not defined." When I removed "mydb as database" it
seemed to work fine yet produced a zero length file
Tel1.txt. When I executed the second bit of code in the
immediate window, it produced the results expected. I
removed Office 2000 Disk 1 and Disk 2, reinstalled Disk
1, and installed SR 1 to no avail.
I thought that "database" was in the "list of
properties/methods". Could I have a sick CD? Have I lost
a lot of time on this one. I appreciate any help you can
give me.

GRayL

Private Sub Command0_Click()

On Error Resume Next
Dim myrs As Recordset, strvar As String, intnum As Integer
Set mydb = CurrentDb

Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum

Do
Write #intnum, myrs!LNAME
myrs.MoveNext
Loop Until myrs.EOF
Close #intnum
Set myrs = Nothing
Set mydb = Nothing
End Sub


--------Immediate Window Code-------------
Set mydb = CurrentDb
Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum
do: write #intnum,myrs!lname: myrs.movenext: loop until
myrs.eof
close #intnum

-----Original Message-----
This sounds a little different than what I normally see, but see if this
will help anyway.

http://support.microsoft.com/default.aspx?scid=kb;en- us;249065&Product=acc2000

--
Wayne Morgan
Microsoft Access MVP


I am running Office 2000 under XP Home. When I go into VB
using Ctl G, get into Help and enter "openrecordset", I
get 18 topics, the first of which is "OpenRecordSet
Method". However, there is no help available on the right
side of the screen. It remains the weclome screen to
Visual Basic. That is the case for the first 14 topics.
Only the last four provide help. I get the same when I
enter a module. As per the knowledge base, I removed the
key [HKEY_CURRENT_USER\Software\Microsoft\Office\9.0
\Common\HelpViewer] from the registry to no avail. I was
trying to use visual basic to create a line delimited
text file from a small table. My code executes, but does
not produce the textfile. It looked like a context
problem and I needed Help to try to resolve the use of
openrecordset, open, and print.


.
 
G

GRayL

Tom: Many thanks. Works like a charm. Merry Christmas,

GRayL

-----Original Message-----
Hi GRayL,

You received the compile error because you are using DAO code, but Access 2000 does not
include a reference to the DAO Object Library by default.

1. Open your code module, click on Tools > References,
and then find the reference that
reads:

Microsoft DAO 3.6 Object Library

Place a check to select it, and then click on the
OK button to dismiss this dialog.
2. Make the following modifications to your code:

Add
Dim mydb As DAO.Database after On Error Resume Next

Change
Dim myrs As Recordset
to Dim myrs As DAO.Recordset

Qualifying the recordset type is a good idea, so that you don't have to worry about
priority issues between the DAO and ADO Object Libraries. See
http://support.microsoft.com/?id=202192 for more
information. Note: You don't really need
to qualify DAO.Database, since there is no ADO
equivalent, but I think its still a good
idea because it makes your code more readable.

Assuming that your recordset includes a field named LNAME, you should be all set.

Tom
______________________________________________


Wayne:

Further to your suggestion, I added the help files and
its now working for the most part. However I am having
trouble gettting the following code to execute. When I
included "mydb as database in the dim statement, the
compiler came back with "Compiler error, User-defined
type not defined." When I removed "mydb as database" it
seemed to work fine yet produced a zero length file
Tel1.txt. When I executed the second bit of code in the
immediate window, it produced the results expected. I
removed Office 2000 Disk 1 and Disk 2, reinstalled Disk
1, and installed SR 1 to no avail.
I thought that "database" was in the "list of
properties/methods". Could I have a sick CD? Have I lost
a lot of time on this one. I appreciate any help you can
give me.

GRayL

Private Sub Command0_Click()

On Error Resume Next
Dim myrs As Recordset, strvar As String, intnum As Integer
Set mydb = CurrentDb

Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum

Do
Write #intnum, myrs!LNAME
myrs.MoveNext
Loop Until myrs.EOF
Close #intnum
Set myrs = Nothing
Set mydb = Nothing
End Sub


--------Immediate Window Code-------------
Set mydb = CurrentDb
Set myrs = mydb.openrecordset("add_list")
intnum = FreeFile
Open "D:\data\ol2data\temp\Tel1.txt" For Output As intnum
do: write #intnum,myrs!lname: myrs.movenext: loop until
myrs.eof
close #intnum

-----Original Message-----
This sounds a little different than what I normally see, but see if this
will help anyway.

http://support.microsoft.com/default.aspx?scid=kb;en- us;249065&Product=acc2000

--
Wayne Morgan
Microsoft Access MVP


I am running Office 2000 under XP Home. When I go into VB
using Ctl G, get into Help and enter "openrecordset", I
get 18 topics, the first of which is "OpenRecordSet
Method". However, there is no help available on the right
side of the screen. It remains the weclome screen to
Visual Basic. That is the case for the first 14 topics.
Only the last four provide help. I get the same when I
enter a module. As per the knowledge base, I removed the
key [HKEY_CURRENT_USER\Software\Microsoft\Office\9.0
\Common\HelpViewer] from the registry to no avail. I was
trying to use visual basic to create a line delimited
text file from a small table. My code executes, but does
not produce the textfile. It looked like a context
problem and I needed Help to try to resolve the use of
openrecordset, open, and print.


.


.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top