This is a migrated thread and some comments may be shown as answers.

[Solved] Browsing files

7 Answers 182 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Inge Wandsvik
Top achievements
Rank 1
Inge Wandsvik asked on 11 Jun 2008, 07:42 AM
I'm not sure if this is the correct forum, but I am having problems with the File Browser control (http://www.telerik.com/demos/aspnet/prometheus/Controls/Examples/Integration/FileBrowser/DefaultVB.aspx). I can not find out to what assembly "Directories" belongs. Here is the code where it fails:
    Sub RadGrid1_NeedDataSource(ByVal source As Object, ByVal e As GridNeedDataSourceEventArgs)  
        RadGrid1.DataSource = New Directories().GetFilesAndFolders(Server.MapPath("~/"))  
    End Sub 'RadGrid1_NeedDataSource 
Anyone with a solution?

7 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 11 Jun 2008, 07:44 AM
Hello Inge,

Directories.cs can be found in App_Code/Grid folder.

All the best,
Vlad
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Inge Wandsvik
Top achievements
Rank 1
answered on 11 Jun 2008, 07:56 AM
Thanks, but the file Directories.cs does not exist. There is 2 Grid folders under App_Code, Grid and Grid_VB but no file called Directories.cs.
0
Vlad
Telerik team
answered on 11 Jun 2008, 07:58 AM
Hi Inge,

I have attached the file.

Regards,
Vlad
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Inge Wandsvik
Top achievements
Rank 1
answered on 11 Jun 2008, 08:02 AM
Thank you very much :-)
0
Inge Wandsvik
Top achievements
Rank 1
answered on 11 Jun 2008, 11:40 AM
I think i was too quick there... Now i get an error in the .js file saying Directories is undefined. Here is the code that fails:
    function clientNodeClicked(sender, args)  
    {  
        alert('You Clicked');  
        Directories.GetFilesAndFolders(sender.get_selectedNode().get_value(), updateGrid);  
    }  
 
The alert works, but when it enters the next line the error shows. An other thing is that i had to create a webservice and replace the file Directories.cs with the new created Directories.asmx and copy the content of the .cs file into the newly created webservice. Could this be a reason for the error?
0
Inge Wandsvik
Top achievements
Rank 1
answered on 12 Jun 2008, 06:38 AM
Am i the only one that has experienced this???
0
Rosen
Telerik team
answered on 16 Jun 2008, 08:46 AM
Hello Inge Wandsvik,

Can you please check whether you added a reference to the webservice in the ScriptManager and it is pointing to the correct service?

Regards,
Rosen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Grid
Asked by
Inge Wandsvik
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Inge Wandsvik
Top achievements
Rank 1
Rosen
Telerik team
Share this question
or