It happens that Madiya formulated :
On Sunday, 10 March 2013 00:39:45 UTC+5:30, GS wrote:
Adding to Herald's sage suggestion.., you should set your reference
to the earliest version of Excel that you expect users to be using.
This is not a rule but more of a 'best practice'. The VB runtime
will, in all likelyhood, reset the ref to whatever version of Excel
is installed on the user's machine. -- Garry Free usenet access at
http://www.eternal-september.org Classic VB Users Regroup!
comp.lang.basic.visual.misc microsoft.public.vb.general.discussion
Thanks both of you.
I do have set referance to excel object.
I am opening my file via VB6 by using commondialog and filetitle
property, and then i also created an arrey and removed all duplicates
from the arrey using John's code. Now I have filtered the list with
1st aarey element. At this poing, I have to select only filtered
cells. I was trying to that by using autofilter, special cells
visible only but getting error as above.
Is there any additional referances required?
Pl guide me as I am fairly biginer.
Regards,
Madiya
There's a lot of automatic object refs in VBA that you need to
compensate for in VB6. For example, your line of VBA code...
With .AutoFilter.Range
...in VB6 is coded as...
With XLWBSR
With .AutoFilter.Range
...which implies that .AutoFilter.Range is a member of the Workbooks
object since XLWBSR refs a workbook. The .AutoFilter.Range object is a
member of the Worksheet object, and so the error raised!
What you need to do is identify all auto-refs in your VBA code and edit
to include fully-qualified refs. (The ObjectBrowser in the VBA IDE is a
good place to start)
Also use fully-qualified refs in your VB6 code.
--
Garry
Free usenet access at
http://www.eternal-september.org
Classic
VB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public.
vb.general.discussion