?
Solved

Folder Item , ShellFolderView

Posted on 2001-06-13
11
Medium Priority
?
918 Views
Last Modified: 2008-03-17
I am not a VB expert and I just can't get this thing to work.
In html you can use :
<input type="file">

all I'm trying to do is this exact thing.

My code so far for this part is :

Private Sub b_browse_Click()
Dim browseForFiles As New ShellFolderView
Dim pfi As FolderItem
Dim fileReturnName As String
fileReturnName = browseForFiles.PopupItemMenu(pfi)
End Sub


the popupItemMenu returns an error , and I just can't understand why.
My idea is that I need to do something with the pfi (set a folder) but I can't understand how.

0
Comment
Question by:avner
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 2
  • 2
  • +1
11 Comments
 
LVL 1

Expert Comment

by:wgilster
ID: 6187328
Which tlbs or dlls are you referencing to give you the ShellFolderView object?
0
 
LVL 14

Author Comment

by:avner
ID: 6187339
I just found the answer.

Instead of using :

Dim browseForFiles As New ShellFolderView

I'm using :
Dim myShell As New Shell
Dim FoldItem As FolderItem
Dim l1 As Long
Dim l2 As Long
Set FoldItem = myShell.BrowseForFolder(l1, "Select Folder", l2)



And it works..

I'll leave the question open because I know I'll have a different question in a few momments.
0
 
LVL 14

Author Comment

by:avner
ID: 6187351
As I thought it dosen't work.

the code is :
Dim myShell As New Shell
Dim FoldItem As FolderItem
Dim l1 As Long
Dim l2 As Long
FoldItem = myShell.BrowseForFolder(l1, "Select Folder", l2)


It opens the GUI as I want , but when I close it (and the return thing get to work) I get an Error.

I have a reference to "Microtosft Shell control and automation"
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 16

Accepted Solution

by:
Richie_Simonetti earned 200 total points
ID: 6187433
Try:
set FoldItem = myShell.BrowseForFolder(l1, "Select Folder", l2)


0
 
LVL 14

Author Comment

by:avner
ID: 6187443
Solved the problem .

Thanks.
0
 
LVL 9

Expert Comment

by:Valliappan AN
ID: 6187462
In that case, you could delete this one, and post another, with the relevant title, so that more experts, could help you.

Cheers.
0
 
LVL 9

Expert Comment

by:Valliappan AN
ID: 6187469
sorry, just its all the posting/accepting delay/speed issues. ignore the message.
0
 
LVL 14

Author Comment

by:avner
ID: 6187472
The complexity of deleting a question , creating a new one and then accepting an answer dosen't worth it.

My opinion.
0
 
LVL 14

Author Comment

by:avner
ID: 6187480
I'll ignore it now :)
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 6187636
I'm going crazy!
Avner, are you editing this question along way?
0
 
LVL 14

Author Comment

by:avner
ID: 6187821
I Swear god I didn't !
0

Featured Post

Enroll in August's Course of the Month

August's CompTIA IT Fundamentals course includes 19 hours of basic computer principle modules and prepares you for the certification exam. It's free for Premium Members, Team Accounts, and Qualified Experts!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
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…
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…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

764 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