9 Novembre 2007 alle 09:56 #121296
I’m not experienced in VB programming. I need to copy all files from a folder to a USB stick. Does somebody know, how to copy a folder under WinCE ? I wrote a test script:
Public Sub Click()Dim fso As ObjectIf RunningOnCE ThenSet fso = CreateObject(‘filectl.filesystem’)fso.CopyFile ‘SDMMC CardTest*.*’,’SDMMC CardTestCopy’ElseSet fso = CreateObject(‘Scripting.filesystemobject’)fso.CopyFile ‘D:Test*.*’,’D:TestCopy’End IfEnd Sub
It works on PC but it doesn’t work on the Panel. I get the message ‘ActiveX Automation: server could not be found.’ Do I use a wrong filesystem name? I found this one ‘filectl.filesytem’ for WinCE. Or there is another problem with ActiveX ?
May be you know another way how to copy or move a folder…
My Vipa panel works with Windows CE 5.0 and Movicon V10.2.0.955 SP1.
Thanks in advance for your support !
Zuzana14 Novembre 2007 alle 17:16 #121297Movicon69Partecipante
Hello.I think that the USB kay is not called D: but its root name should be HardDisk. Try to explore the panel with ActiveSync without the USB key then put it in and find a new folder appears: that’s the root name.14 Novembre 2007 alle 18:16 #121298
Hi,thanks for your remark. I only mentioned the USB stick in my text to explain the main reason for this topic. You are right that the name of the USB stick is ‘Harddisk’ on the panel. However, there is no problem with it. The problem is that WinCE doesn’t recognise the object fso.
My script is only an example and should copy the folder ‘Test’ to the folder ‘TestCopy’ (if the project is running on TP the both folders are on SDMMC Card, if it is running on PC the both folders are on D:).
Bye,Zuzana15 Novembre 2007 alle 08:58 #121299HansMembro
Hi, frequently happens that objects on a desktop environment have different class name, or do not exist at all, on a CE platform, depending on the image created by the manufacturer.
Anyway, there’s a bit more complicate way to do the same, using the basic function to manage files. Looking at the help on line of the basic, you’ll find a group of function for the files and folder management.for example:FileCopy ‘Storage Card est_ umber1.tr’,’Storage Cardack umber1.tr’works on a CE panel.The bad is that you can’t use *.*, so you yhave to use Dir to enumerate all the files and folder and make a loop to copy all the items…
Bye15 Novembre 2007 alle 09:47 #121300
Hi, Hans, thank you for your advice. I didn’t come to the idea to enumerate all the files first by using Dir!
Zuzana12 Maggio 2019 alle 11:55 #132361AspernaPartecipante
You can get the all details that how you can copy this or move the all formats on it this was good to get the data. I need to share this details with others so I post this to https://newtheory.com/easy-freelance-work-for-students/ this was belong to me or it have many more useful articles on it.15 Maggio 2019 alle 15:14 #132370Brian_73Partecipante
- Devi essere connesso per rispondere a questo topic.