Google Mail Kalender Text & Tabellen Reader Web Mehr »
Kürzlich besuchte Gruppen | Hilfe | Anmelden
Google Groups-Startseite
Nachricht von Diskussion code to move files created between two dates to folder B?

Analysierte anzeigen - Nur Nachrichtentext zeigen

Reply-To: "gil" <NoG...@EmailAddress.com>
From: "gil" <gil...@bellsouth.net>
References: <eEBS2KmvHHA.4552@TK2MSFTNGP03.phx.gbl>
Subject: Re: code to move files created between two dates to folder B?
Date: Wed, 4 Jul 2007 13:54:28 -0400
Lines: 198
MIME-Version: 1.0
Content-Type: multipart/alternative;
	boundary="----=_NextPart_000_001B_01C7BE42.D81D8240"
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138
Message-ID: <#babfRmvHHA.4916@TK2MSFTNGP04.phx.gbl>
Newsgroups: microsoft.public.word.vba.general
NNTP-Posting-Host: adsl-074-167-179-099.sip.ard.bellsouth.net 74.167.179.99
Path: g2news1.google.com!news4.google.com!feeder1-2.proxad.net!proxad.net!feeder1-1.proxad.net!club-internet.fr!feedme-small.clubint.net!feeder.news.tin.it!207.46.248.126.MISMATCH!TK2MSFTFEEDS01.phx.gbl!TK2MSFTFEEDS02.phx.gbl!TK2MSFTNGP01.phx.gbl!TK2MSFTNGP04.phx.gbl

This is a multi-part message in MIME format.

------=_NextPart_000_001B_01C7BE42.D81D8240
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

or something like:

Dim strDefFilePath As String, strFileToCopy As String
Dim strSourcePath As String, strSourceFile As String
Dim objFSO As Object

strSourcePath =3D "c:\Patients\AMR\"
strDefFilePath =3D "c:\Patients\"
strFileToCopy =3D "TorrTod.doc"
strSourceFile =3D strSourcePath & strFileToCopy


strSourcePath =3D ""     ' identify folderA
strDefFilePath =3D ""     ' identify folderB
strFileToCopy =3D "CartSamu.doc"   ' but how to identify by date or =
time?
strSourceFile =3D strSourcePath & strFileToCopy

'   ... but it needs to move over up to 10 jpg files

:)
Gil


  "gil" <gil...@bellsouth.net> wrote in message =
news:eEBS2KmvHHA.4552@TK2MSFTNGP03.phx.gbl...
  Hi All, . I am seeking vba code to MOVE files created between date1 =
and date2 from folderA to folderB?

  =20

  ? Possibly something like:=20

  =20


      Dim date1 As String

      date1 =3D Selection.Text

  '   navigation code to new selection

      Dim date2 As String

      date2 =3D Selection.Text

      Dim folderA As String

  '    identify folderA

      Dim folderB As String

  '    identify folderB



  '   ??? Object.MoveFile Source, Destination


     WordBasic.CopyFileA folderA ?? FileName:=3D ??, =
Directory:=3DfolderB

  =20

  Cheers & tia

  Gil =20

  =20

------=_NextPart_000_001B_01C7BE42.D81D8240
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML xmlns:o =3D "urn:schemas-microsoft-com:office:office"><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.6000.16481" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#e0dfe3>
<DIV><FONT face=3DArial>or something like:</FONT></DIV>
<DIV><FONT face=3DArial></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial>Dim strDefFilePath As String, strFileToCopy As=20
String<BR>Dim strSourcePath As String, strSourceFile As String<BR>Dim =
objFSO As=20
Object</FONT></DIV>
<DIV><FONT face=3DArial></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial>strSourcePath =3D =
"c:\Patients\AMR\"<BR>strDefFilePath =3D=20
"c:\Patients\"<BR>strFileToCopy =3D "TorrTod.doc"<BR>strSourceFile =3D =
strSourcePath=20
&amp; strFileToCopy</FONT></DIV>
<DIV><FONT face=3DArial></FONT>&nbsp;</DIV><FONT face=3DArial>
<DIV><BR>strSourcePath =3D ""&nbsp;&nbsp;&nbsp; &nbsp;' identify=20
folderA<BR>strDefFilePath =3D ""&nbsp;&nbsp;&nbsp;&nbsp; ' identify=20
folderB<BR>strFileToCopy =3D "CartSamu.doc"&nbsp;&nbsp; ' but how to =
identify by=20
date or time?<BR>strSourceFile =3D strSourcePath &amp; =
strFileToCopy<BR></DIV>
<DIV>'&nbsp;&nbsp; ... but it needs to move over up to 10 jpg =
files</DIV>
<DIV>&nbsp;</DIV>
<DIV>:)</DIV>
<DIV>Gil</DIV></FONT>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV><FONT face=3DArial></FONT>&nbsp;</DIV>
  <DIV><FONT face=3DArial></FONT>&nbsp;</DIV>
  <DIV>"gil" &lt;<A=20
  href=3D"mailto:gil...@bellsouth.net">gil...@bellsouth.net</A>&gt; =
wrote in=20
  message <A=20
  =
href=3D"news:eEBS2KmvHHA.4552@TK2MSFTNGP03.phx.gbl">news:eEBS2KmvHHA.4552=
@TK2MSFTNGP03.phx.gbl</A>...</DIV>
  <DIV><FONT face=3DArial>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><o:p><FONT=20
  face=3D"Times New Roman">Hi All, =85 I am seeking vba code to MOVE =
files created=20
  between date1 and date2 from folderA to folderB?</P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><o:p><FONT=20
  face=3DArial></FONT></o:p>&nbsp;</P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><o:p><FONT =
face=3DArial>?=20
  Possibly something like:</FONT>&nbsp;</o:p></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><o:p><FONT=20
  face=3DArial></FONT></o:p>&nbsp;</P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"></FONT></o:p></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman"><SPAN style=3D"mso-spacerun: =
yes">&nbsp;&nbsp;&nbsp;=20
  </SPAN>Dim date1 As String<o:p></o:p></FONT></P><FONT=20
  face=3D"Times New Roman"><SPAN style=3D"mso-spacerun: yes">
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman"><SPAN style=3D"mso-spacerun: =
yes">&nbsp;&nbsp;&nbsp;=20
  </SPAN>date1 =3D Selection.Text<o:p></o:p></FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman">'<SPAN style=3D"mso-spacerun: =
yes">&nbsp;&nbsp;=20
  </SPAN>navigation code to new selection<o:p></o:p></FONT></P><FONT=20
  face=3D"Times New Roman"><SPAN style=3D"mso-spacerun: yes">
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt">&nbsp;&nbsp;&nbsp; =
Dim date2 As=20
  String<o:p></o:p></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt">&nbsp;&nbsp;&nbsp; =
</SPAN>date2=20
  =3D Selection.Text<o:p></o:p></FONT></P></SPAN></FONT>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman">&nbsp;&nbsp;&nbsp; Dim folderA As =
String</FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman">'&nbsp;&nbsp;&nbsp; identify=20
  folderA<o:p></o:p></FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman"><SPAN style=3D"mso-spacerun: =
yes">&nbsp;&nbsp;&nbsp;=20
  </SPAN>Dim folderB As String</FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman">'&nbsp;&nbsp;&nbsp; identify =
folderB</FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman"></FONT>&nbsp;</P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman">'<SPAN style=3D"mso-spacerun: =
yes">&nbsp;&nbsp; ???=20
  </SPAN>Object.MoveFile Source, Destination<o:p></o:p></FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman"><SPAN=20
  style=3D"mso-spacerun: yes"></SPAN><o:p></o:p></FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><FONT=20
  face=3D"Times New Roman"><SPAN style=3D"mso-spacerun: =
yes">&nbsp;&nbsp;=20
  </SPAN>WordBasic.CopyFileA folderA ?? FileName:=3D ??,=20
  Directory:=3DfolderB</FONT></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><o:p><FONT=20
  face=3D"Times New Roman">&nbsp;</FONT></o:p></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><o:p>Cheers &amp; =
tia</o:p></P>
  <P class=3DMsoNormal style=3D"MARGIN: 0in 0in 0pt"><o:p>Gil&nbsp; =
</o:p></P>
  <P class=3DMsoNormal=20
  style=3D"MARGIN: 0in 0in =
0pt"><o:p></o:p>&nbsp;</P></FONT></DIV></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_001B_01C7BE42.D81D8240--


Eine Gruppe erstellen - Google Groups - Google-Startseite - Nutzungsbedingungen - Datenschutzbestimmungen
©2009 Google