|
-
Dec 12th, 2009, 08:58 PM
#1
Thread Starter
Hyperactive Member
Transfer Files!
hi guys how can i programatically do this task..
1. Open a wifi connection on a device (connect to a default network, let say linksys)
2. transfer xml file from mobile to PC (with default ip, ;et say 171.68.1.1)
3. Closse the wifi connection after the transfer
-
Dec 14th, 2009, 07:37 AM
#2
Frenzied Member
Re: Transfer Files!
Did we not cover this in your question last week?
I pointed you at a network connection video that shows you how to connect to a network, and FTP to transfer the file, or 'roll your own' transfer
Did that not do the job?
-
Dec 14th, 2009, 08:05 AM
#3
Thread Starter
Hyperactive Member
Re: Transfer Files!
is there another way aside from what we have cover last week? im just looking for some alternatives..
-
Dec 14th, 2009, 09:13 AM
#4
Frenzied Member
Re: Transfer Files!
As far as network connection is concerned - what was outlined is probably the best solution I have seen.
You can use the connection manager (there is a managed wrapper here)
For transferring, FTP, roll your own, map a drive, HTTP - all discussed last week
-
Dec 15th, 2009, 03:36 AM
#5
Thread Starter
Hyperactive Member
Re: Transfer Files!
here is my sample code and i just cant make it work..
Computer's IP is 192.168.1.118
Device IP is 192.168.1.117
Then i created a folder named Armada and Shared it to the network..
Device to PC...
vb Code:
Dim remotePath As String = "\\192.168.1.118\Armada\" 'PC path Dim localPath As String = "\Program Files\armada\armada.xml" 'Device Path If Directory.Exists(remotePath) = False Then MsgBox("Remote Path not Found") Exit Sub End If Try File.Copy(localPath, remotePath & "armada.xml") Catch ex As Exception MsgBox(ex.Message) End Try
PC to Device...
vb Code:
Dim remotePath As String = "\192.168.1.117\Program Files\" 'Device Path Dim localPath As String = "C:\Jigsaw\eBUS\ARMADA_GATEWAY\eTASUpload\Resources\armada.xml" 'PC path If Directory.Exists(remotePath) = False Then MsgBox("Remote Path not Found") Exit Sub End If Try File.Copy(localPath, remotePath & "armada.xml") Catch ex As Exception MsgBox(ex.Message) End Try
-
Dec 15th, 2009, 03:38 AM
#6
Re: Transfer Files!
Hey,
What happens when you run the above code? Do you get an exception? If so, what is it?
Gary
-
Dec 15th, 2009, 07:33 AM
#7
Thread Starter
Hyperactive Member
Re: Transfer Files!
it always display the message Remote Path not Found! it means it cant access the remoth path.. then i tried to remove this block of code and it just return IOexception as error message..
-
Dec 15th, 2009, 08:16 AM
#8
Re: Transfer Files!
Hey,
Have you correctly setup permissions on this remote share? Who has permission to access it?
Gary
-
Dec 15th, 2009, 10:52 AM
#9
Member
Re: Transfer Files!
Transfer files via HTTP and use this article. Follow it to the letter and you cannot go wrong. I am now successfully transferring files wirelessly to and from my mobile device after lots of (unsuccessful) pain with ftp
http://msdn.microsoft.com/en-us/library/aa446517.aspx
-
Dec 16th, 2009, 12:53 AM
#10
Thread Starter
Hyperactive Member
Re: Transfer Files!
i just shared the folder armada!..
@nevh2001 via HHTP requires an internet connection right?
-
Dec 16th, 2009, 02:00 AM
#11
Frenzied Member
Re: Transfer Files!
 Originally Posted by rothj0hn
i just shared the folder armada!..
@nevh2001 via HHTP requires an internet connection right?
A network connection - no necessarily an internet connection
-
Dec 16th, 2009, 02:56 AM
#12
Re: Transfer Files!
 Originally Posted by rothj0hn
i just shared the folder armada!..
@nevh2001 via HHTP requires an internet connection right?
Yes, you shared the folder, but what permissions did you set up for that share? Try giving the "Everyone" user full access to the share. If you can get that to work, then you can start restricting it back to a narrower group of people.
Gary
-
Dec 16th, 2009, 03:47 AM
#13
Thread Starter
Hyperactive Member
Re: Transfer Files!
my only concert about this process is there are too many things to configure, you need to setup the IIS. Unlike in a FTP transfer you dont have to do such things.
-
Dec 16th, 2009, 11:38 PM
#14
Thread Starter
Hyperactive Member
Re: Transfer Files!
i tried HTTP transfer but i always got this error, "Unable to connect to the remote server"
-
Dec 17th, 2009, 02:34 AM
#15
Re: Transfer Files!
Hey,
Did you have problems implementing the article that you were linked to? Or were you able to follow it exactly?
Gary
-
Dec 18th, 2009, 03:18 AM
#16
Thread Starter
Hyperactive Member
Re: Transfer Files!
i just do it exactly what the articles says.. if i test it while the mobile is sync to my pc it works fine. but if i try it via wifi it fails.. i tried to ping it and it do response so it means that it was connected to the network.
-
Dec 18th, 2009, 06:51 AM
#17
Frenzied Member
Re: Transfer Files!
Hi,
I hate to keep repeating this, but the Jim Wilson video on network connection goes through all these problems and ensures you get a correct network connection.
It could be a firewall issue too
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|