Lost Password?

Go Back   CodeCall Programming Forum > Software Development > Visual Basic Programming

Visual Basic Programming Discussion forum for Visual Basic, an event driven programming language and associated development environment from Microsoft for its COM programming model.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 12-07-2007, 09:14 AM
kresh7 kresh7 is offline
Learning Programmer
 
Join Date: Jun 2007
Posts: 99
Rep Power: 5
kresh7 is on a distinguished road
Default Can somone help me with this project

hi everyone im making a mistake in my vb project it use cmd commands

the code of the cmd looks like this

copy /b "c:\file.jpg" + "c:\file.rar" "c:\new.jpg"
how to use it now on my vb when
file.jpg is text1 and file.rar is text2 and new.jpg is text3 on the command buttom the code should execute

i tryed somthing like this
shell "copy /b" & " " & """ & "c:\" & text1.text & ".jpg" & """ etc etc etc can some help me pls
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #2 (permalink)  
Old 12-07-2007, 10:28 AM
TcM's Avatar   
TcM TcM is online now
Moderator
 
Join Date: Aug 2006
Location: In a technologic world :p
Posts: 7,360
Rep Power: 67
TcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud of
Default

create a bat file from that code and then execute the bat
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 12-07-2007, 11:55 AM
kresh7 kresh7 is offline
Learning Programmer
 
Join Date: Jun 2007
Posts: 99
Rep Power: 5
kresh7 is on a distinguished road
Default

no i want to use the shell command but im making something wrong it doesent work the code that you see isent compled

i want to insert it to a command button and when the button gets klicked it execute the command with text1 text2 text3
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 12-07-2007, 12:08 PM
TcM's Avatar   
TcM TcM is online now
Moderator
 
Join Date: Aug 2006
Location: In a technologic world :p
Posts: 7,360
Rep Power: 67
TcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud of
Default

it's gonna be a problem because copy is a shell command and not a file, so it says file not found.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 12-08-2007, 10:58 AM
kresh7 kresh7 is offline
Learning Programmer
 
Join Date: Jun 2007
Posts: 99
Rep Power: 5
kresh7 is on a distinguished road
Default

yes i know but i know that i can use batch commands when i use shell example shell "shutdown -s -t 60"
i need that to the problem is im making some mistakes cuz theres a lot & like you see
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #6 (permalink)  
Old 12-08-2007, 04:27 PM
TcM's Avatar   
TcM TcM is online now
Moderator
 
Join Date: Aug 2006
Location: In a technologic world :p
Posts: 7,360
Rep Power: 67
TcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud of
Default

You know why that works? Because in the system32 folder there is a file named shutdown.exe, if there wasn't that file that command would not execute like the copy command!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 12-09-2007, 12:05 PM
kresh7 kresh7 is offline
Learning Programmer
 
Join Date: Jun 2007
Posts: 99
Rep Power: 5
kresh7 is on a distinguished road
Default

So do you mean i cant use that command even if its a batch command ?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 12-09-2007, 01:07 PM
TcM's Avatar   
TcM TcM is online now
Moderator
 
Join Date: Aug 2006
Location: In a technologic world :p
Posts: 7,360
Rep Power: 67
TcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud ofTcM has much to be proud of
Default

You can create a batch file using VisualBasic and then execute it. But you cannot run that command directly using the shell command.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
A cool project idea. AlexanderRybak Community Projects 3 02-11-2008 02:37 AM
java project ideas trolls1234 Java Help 2 09-13-2007 11:11 AM
Project: UniBB TkTech Community Projects 8 09-05-2007 06:30 AM
Contributing to a project Jordan Community Projects 7 09-15-2006 04:43 PM
Community Project! - Recent project gone sour Crane C# Programming 5 09-09-2006 02:13 PM


All times are GMT -5. The time now is 06:47 PM.

Contest Stats

Xav ........ 162.68
delia ........ 100
neerlin ........ 100
satrian ........ 100
nik68 ........ 100
chili5 ........ 70.08
morefood2001 ........ 42.41
MeTh0Dz|Reb0rn ........ 28.44
RyanTuosto ........ 20
gamiR ........ 19.64

Contest Rules

CodeCall Goal

Goal: 100,000 Posts
Complete: 68%

Ads