Visual Basic Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreVisual Basic Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
A high performance database engine using optimized data access for all development environments including Delphi, Visual Studio .NET, Visual Basic, Visual FoxPro. and more. Learn More
  #1  
Old March 1st, 2003, 03:44 AM
AlienX's Avatar
AlienX AlienX is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Location: Philippines
Posts: 30 AlienX User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 34 sec
Reputation Power: 6
File Transfer using Direct Cable Connection

I URGENTLY NEED HELP!

I need a code in VB6 that will enable me to send files using Direct Cable Connection. I need this as a part of my project in school and I don't have any idea on how to implement it. Any help would be highly appreciated. Thanks in advance...

Reply With Quote
  #2  
Old March 1st, 2003, 09:31 PM
customfittech customfittech is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2003
Location: St. Louis, MO USA
Posts: 43 customfittech User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
There are various ways, one being to output directly to the port.

I'll post a zip file including code I've used at one of my clients to talk RS-232, but if you want more than that, please specify what kind of cable you're using.
__________________
- Chris of Custom Fit Technology
http://www.customfittech.com

Access to MySQL Conversion Tool,
Visual XSLT Conversion Tool

Reply With Quote
  #3  
Old March 1st, 2003, 10:01 PM
customfittech customfittech is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2003
Location: St. Louis, MO USA
Posts: 43 customfittech User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
K here's the library reference:

Microsoft Comm Control 6.0 (in the Components page)

This means you need a Comm control little icon thingy on a form to reference as an object in code. Mine is called "com"

Here's the code FOR LISTENING:
com.CommPort = 1

' Set the port number
com.Settings = "9600,N,8,1"
' you may not need to set anything for direct cable
' Tell the control to read entire buffer when Input is used
com.InputLen = 0
com.RThreshold = 1
' Open the port.
com.InBufferSize = 8000
com.PortOpen = True

Here's the code FOR TALKIN':

com.CommPort = 1

' Set the port number
com.Settings = "9600,N,8,1" ' Set UART parameters
com.PortOpen = True
com.Output = s
' in my code, s is a string, in yours in may not, so maybe try
' a byte array?


Hope this helped some

Last edited by customfittech : March 1st, 2003 at 10:03 PM.

Reply With Quote
  #4  
Old March 2nd, 2003, 02:29 AM
AlienX's Avatar
AlienX AlienX is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Location: Philippines
Posts: 30 AlienX User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 34 sec
Reputation Power: 6
Quote:
Originally posted by customfittech
There are various ways, one being to output directly to the port.

I'll post a zip file including code I've used at one of my clients to talk RS-232, but if you want more than that, please specify what kind of cable you're using.


Oh! sorry forgot to specify the cable. I don't know the exact name for it but I'll be using a cable for the Printer Port (DB25).

Reply With Quote
  #5  
Old March 2nd, 2003, 02:33 AM
AlienX's Avatar
AlienX AlienX is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Location: Philippines
Posts: 30 AlienX User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 5 m 34 sec
Reputation Power: 6
QUESTION:
What if I'll use the Serial Port (DB9)? Is it possible? Will the source code change? (Please tell/show me how).

Thank's for the code you've just given me. There's something I forgot to mention on my first post. Since it's only you who replied, I just hope you could do me a favor... (I might sound a "lamer" here but pardon me coz I'm a beginner in terms of Serial Programming (if that's what they call it).)

Here it is...
I'd like to implement a program that'll allow both users (on each end) to upload a file via Direct Cable Connection (may it be a DB25 or a DB9 cable). Let's say both Computers have a folder Downloads. When I upload a file to the other PC, it'll automatically be saved under the folder Downloads of the other computer connected to mine. Same goes if the other computer sends a file to me.

It'll be of much help if you could send me a ZIP (which includes the .vbp, .frm, etc.) file for the Project. (Please) Coz I really need to finish my program before Feb 5. I'm really loosing hope on this...

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreVisual Basic Programming > File Transfer using Direct Cable Connection


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
Accelerating Trading Partner Performance
One in five. That's how many partner transactions have at least one error. That is an amazing statistic, particularly given the extraordinary leaps in innovation across the global supply chain during the past two decades. Download this white paper to learn more.

 
Competing on Analytics
This Tech Analysis is designed to help identify characteristics shared by analytics competitors, and includes information about 32 organizations that have made a commitment to quantitative, fact-based analysis.

 
Cost Effective Scaling with Virtualization and Coyote Point Systems
An overview of the industry trend toward virtualization, how server consolidation has increased the importance of application uptime and the steps being taken to integrate load balancing technology with virtualized servers.

 
Five Checkpoints to Implementing IP Telephony
Implementation planning for IP PBX software and IP telephony has become vital as businesses replace discontinued legacy PBX phone systems. This informative whitepaper outlines five "checkpoints" for any implementation plan that will help make IP communications a successful proposition.

 
Hosted Email Security: Staying Ahead of New Threats
In the last two years, email has become a fierce battleground between the nefarious forces of spam and malware, and the heroes of messaging protection. The spam volumes increased alarmingly every month, bringing clever new forms of phishing and virus propagation attacks.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway