Solved

Problem encounter in VB AsynRead

Posted on 1997-11-30
1
221 Views
Last Modified: 2008-03-06
I am developing a actice-x control which can perform downloading  . But everytime I get this error message : A Property or method call cannot include a reference to a private object, either as a argument or as a return value .

Below is my code :

Command1_Click()
   a = SourcePath
   SourcePath = a
End Sub

Public Property Get SourcePath() As String
    SourcePath = m_SourcePath
End Property

Public Property Let SourcePath(ByVal New_SourcePath As String)
     
       MstrPictureFromURL = New_SourcePath
        ' If program is in run mode, and the URL string
        ' is not empty, begin the download.
       AsyncRead New_SourcePath, vbAsyncTypePicture, _
            "SourcePath"

 PropertyChanged "SourcePath"
End Property
0
Comment
Question by:pcseah
1 Comment
 
LVL 8

Accepted Solution

by:
mrmick earned 100 total points
Comment Utility
I'm assuming the problem is in the line:

AsyncRead New_SourcePath, vbAsyncTypePicture, "SourcePath"

Try this instead (parens around New_SourcePath):

AsyncRead (New_SourcePath), vbAsyncTypePicture, "SourcePath"

What is the "MstrPictureFromURL"?
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now