Hello Everyone, I need a little help in a program I'm trying to make.
A part of it is like this, and I need help on getting the date to update every time it is run according to the computers date....
example:
shell "xcopy d:hofadomma.txt d:a /e /y /d:07/09/2002"
now, The problem is..... how do I get the computers current date and fill into the date part everytime the program is run, in that exact format too! Any help is appreciated. Thanks.
Comments
:
: A part of it is like this, and I need help on getting the date to update every time it is run according to the computers date....
:
: example:
:
: shell "xcopy d:hofadomma.txt d:a /e /y /d:07/09/2002"
:
: now, The problem is..... how do I get the computers current date and fill into the date part everytime the program is run, in that exact format too! Any help is appreciated. Thanks.
:
format$(Now(),"mm/dd/yyyy")
: :
: : A part of it is like this, and I need help on getting the date to update every time it is run according to the computers date....
: :
: : example:
: :
: : shell "xcopy d:hofadomma.txt d:a /e /y /d:07/09/2002"
: :
: : now, The problem is..... how do I get the computers current date and fill into the date part everytime the program is run, in that exact format too! Any help is appreciated. Thanks.
: :
:
: format$(Now(),"mm/dd/yyyy")
Thanks
:
: : :
: : : A part of it is like this, and I need help on getting the date to update every time it is run according to the computers date....
: : :
: : : example:
: : :
: : : shell "xcopy d:hofadomma.txt d:a /e /y /d:07/09/2002"
: : :
: : : now, The problem is..... how do I get the computers current date and fill into the date part everytime the program is run, in that exact format too! Any help is appreciated. Thanks.
: : :
: :
: : format$(Now(),"mm/dd/yyyy")
:
:
: Thanks
: :
: Well that helped Alot! One last thing..... anyone know how to do this? When the program is run, how do you make it invisable, just show up in the task manager, not the task bar...... the program loads on formload so there is no interface or controls, just pure work as soon as it's executed. Thank you for your future help...
:
Add a .bas module. Copy the code from Form_Load to a sub in the module named Main. Remove the form from the project. Run or compile. VB will complain about startup, select Sub Main. It should now work as you want.
[code]
Private Sub Main()
'Code here
End Sub
[/code]
VB doesn't make it real obvious, but no forms are required. As long as you have a form or a Sub Main, your app can execute.
: :
:
: Add a .bas module. Copy the code from Form_Load to a sub in the module named Main. Remove the form from the project. Run or compile. VB will complain about startup, select Sub Main. It should now work as you want.
: [code]
: Private Sub Main()
:
: 'Code here
:
: End Sub
: [/code]
: VB doesn't make it real obvious, but no forms are required. As long as you have a form or a Sub Main, your app can execute.
:
If you need a form, because you have controls, then set the form's .Visible property=False
If you can set the .BorderStyle property=0, it won't show in the task bar.
In your case, Mike's suggestion is best.
: : :
: :
: : Add a .bas module. Copy the code from Form_Load to a sub in the module named Main. Remove the form from the project. Run or compile. VB will complain about startup, select Sub Main. It should now work as you want.
: : [code]
: : Private Sub Main()
: :
: : 'Code here
: :
: : End Sub
: : [/code]
: : VB doesn't make it real obvious, but no forms are required. As long as you have a form or a Sub Main, your app can execute.
: :
:
: If you need a form, because you have controls, then set the form's .Visible property=False
: If you can set the .BorderStyle property=0, it won't show in the task bar.
: In your case, Mike's suggestion is best.
:
Or maybe its Dave's?
: :
: Or maybe its Dave's?
:
If you're talking 'bout me, it's Mike.