$$Excel-Macros$$ Re: Saving a txt file to an ftp server

2009-07-21 Thread ju...@thepepeshow.com

Hello MartyH,

I was able to do this by installing NcFTP on my computer.  It is
available here: http://www.ncftp.com/download/.  You want to install
the client (not server.)

Once you install that program, modify the following code to accomplish
saving to an FTP file:

Sub SaveTXT2FTP()
'
' SaveTXT2FTP Macro
'

' ** Declarations **
Dim strFileName As String
Dim strPath As String

Dim strFTPServer As String
Dim strFTPPath As String
Dim strFTPUsername As String
Dim strFTPPassword As String

'  Settings *
strFTPServer = "ftp.server.com"
strFTPUsername = "username"
strFTPPassword = "my.password"
strFTPPath = "path"

strPath = "C:\Users\Publice\Documents\"
strFileName = "Filename.txt"

' * Export to TXT File *
ActiveWorkbook.SaveAs Filename:=strPath & strFileName, _
FileFormat:=xlTextMSDOS

' * Upload to FTP Server **
Shell ("C:\Program Files\NcFTP\ncftpput.exe -u " & strFTPUsername
& _
" -p " & strFTPPassword & " " & strFTPServer & " " & _
strFTPPath & " " & strPath & strFileName)

End Sub

I tested on my computer using Excel 2007 and it worked.  You can copy
and paste the sections into the appropriate place in your code.  The
section "Export to TXT File" does not have to be copied if you will be
using your own.  However, just make sure you specify the file in the
"Settings" section.

Please post back if this was helpful, or if you have any issues.

--==)) Justo ((==--

On Jul 20, 4:06 am, MartyH  wrote:
> Hi all,
>
> I currently have a macro that takes data from a spreadsheet and
> reformats it to a pipe delimited .txt file then saves to a location on
> my C: drive.
> I then manually place the file on an ftp server - is there any way
> that I can save the file direct to the ftp server or move it from my
> C:drive to the ftp server?
>
> I have read a few articles on API that seem to suggest a solution but
> my VBA understanding isn't quite to the level where I can fully
> undersatnd the code in published examples and thus tweak it to my
> exact requirements.
> Any help would be freatly appreciated.
>
> Many thanks,
>
> MartyH

--~--~-~--~~~---~--~~
--
Some important links for excel users:
1. Excel and VBA Tutorials(Video and Text), Free add-ins downloads at 
http://www.excelitems.com
2. Excel tutorials at http://www.excel-macros.blogspot.com
3. Learn VBA Macros at http://www.vbamacros.blogspot.com
4. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 

To post to this group, send email to excel-macros@googlegroups.com
If you find any spam message in the group, please send an email to:
Ayush Jain  @ jainayus...@gmail.com or
Ashish Jain @ 26may.1...@gmail.com
<><><><><><><><><><><><><><><><><><><><><><>
HELP US GROW !!

We reach over 5,000 subscribers worldwide and receive many nice notes about the 
learning and support from the group. Our goal is to have 10,000 subscribers by 
the end of 2009. Let friends and co-workers know they can subscribe to group at 
http://groups.google.com/group/excel-macros/subscribe
-~--~~~~--~~--~--~---



$$Excel-Macros$$ Re:

2009-07-21 Thread ju...@thepepeshow.com

Name: Justo Morales
Subject: Data Summary
Detail: Sometimes you need to get a summary of many different values.
However, you may not be sure what fields you have listed.  For
example, say you have the total number of colors produced by day for
an entire month.  You want to know exactly how many of color was
produced for the month.

Our example will use column A as the date, column B as the color, and
column C as the amount.  We don't know how many different colors were
used so, we'll need to find that out first.  Assuming row one is the
header and there are 200 records, highlight B1:B200.  Under data,
filter, select Advanced.  Click on "Copy to another location" and
"Unique records only."  Click on the "Copy to" field and click on E1.
$E$1 will appear in the "Copy to" field.  Click OK.

On cell F2 (F1 is empty, but can be the field header) enter =SUMIF(B
$2:B$200,E2,C$2:C$200).  Copy the formula down (using Ctrl+D or your
preffered method of copying cells) to cover all the colors.

That's it! You know have a summary by color produced for the entire
month.

On Jul 21, 8:18 am, Ayush  wrote:
> Dear Members,
>
> Let us begin week # 29 quiz with the hope of high participation.
>
> Last Date of Submission of tips : 26th July 2009.
>
> PLEASE NOTE THAT THE TIPS SUBMITTED IN THIS POST WILL ONLY BE
> CONSIDERED FOR PRIZES.
> DO NOT START NEW THREADS OR POST FOR SUBMISSION OF TIPS.
>
> You need to submit your name, Subject & the details of tips and
> tricks.
> DO let me know if you need any clarifications.
>
> Let me begin by submitting the first tip for this week competition.
> ---­
> Name : Ayush Jain
> Subject :  Convert rows to columns & viceversa
> Detail : You can convert rows to columns (and columns to rows) by
> highlighting the cells you want to switch around, clicking on Edit,
> Copy, selecting a new cell and then going to Edit, Paste Special…
> Finally, place a tick in the Transpose box on the dialog box and click
> on OK.
>
> Who is next 
> ---­--

--~--~-~--~~~---~--~~
--
Some important links for excel users:
1. Excel and VBA Tutorials(Video and Text), Free add-ins downloads at 
http://www.excelitems.com
2. Excel tutorials at http://www.excel-macros.blogspot.com
3. Learn VBA Macros at http://www.vbamacros.blogspot.com
4. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 

To post to this group, send email to excel-macros@googlegroups.com
If you find any spam message in the group, please send an email to:
Ayush Jain  @ jainayus...@gmail.com or
Ashish Jain @ 26may.1...@gmail.com
<><><><><><><><><><><><><><><><><><><><><><>
HELP US GROW !!

We reach over 5,000 subscribers worldwide and receive many nice notes about the 
learning and support from the group. Our goal is to have 10,000 subscribers by 
the end of 2009. Let friends and co-workers know they can subscribe to group at 
http://groups.google.com/group/excel-macros/subscribe
-~--~~~~--~~--~--~---



Re: $$Excel-Macros$$ Fwd:

2010-07-02 Thread ju...@thepepeshow.com
Dave, I think Praveen was looking for the count from right to left.
Your example formula results with 17 not 8.  However, building on your
formula, you can simply subtract from the length of the cell.  Here is
counting from right to left:

=LEN(A1)+1-FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1),LEN(TRIM(A1))-
LEN(SUBSTITUTE(A1," ",""

Praveen, let us know what works for you.

On Jul 2, 4:37 pm, Dave Bonallack  wrote:
> Hi Praveen,
> It's a bit long-winded, but here's a formula to find the position of the last 
> space in Cell A1:
>
> =FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1),LEN(TRIM(A1))-LEN(SUBSTITUTE(A1," 
> ",""
>
> Regards - Dave.
>
>
>
> > Date: Fri, 2 Jul 2010 19:48:01 +0530
> > Subject: $$Excel-Macros$$ Fwd:
> > From: bhspra...@gmail.com
> > To: excel-macros@googlegroups.com
>
> > Hi Friends,
>
> > Is there any way to find the position of the space in a word from right 
> > side.
>
> > Ex: United States of America - here the position of the space from
> > right side is 8.
>
> > --
>
> > Regards,
> > praveen
>
> > --
> > --
> > Some important links for excel users:
> > 1. Follow us on TWITTER for tips tricks and links 
> > :http://twitter.com/exceldailytip
> > 2. Join our LinkedIN group @http://www.linkedin.com/groups?gid=1871310
> > 3. Excel tutorials athttp://www.excel-macros.blogspot.com
> > 4. Learn VBA Macros athttp://www.quickvba.blogspot.com
> > 5. Excel Tips and Tricks athttp://exceldailytip.blogspot.com
>
> > To post to this group, send email to excel-macros@googlegroups.com
>
> > <><><><><><><><><><><><><><><><><><><><><><>
> > HELP US GROW !!
>
> > We reach over 7000 subscribers worldwide and receive many nice notes about 
> > the learning and support from the group.Let friends and co-workers know 
> > they can subscribe to group 
> > athttp://groups.google.com/group/excel-macros/subscribe
>
> _
> New, Used, Demo, Dealer or Private? Find it at 
> CarPoint.com.auhttp://clk.atdmt.com/NMN/go/206222968/direct/01/

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
HELP US GROW !!

We reach over 7000 subscribers worldwide and receive many nice notes about the 
learning and support from the group.Let friends and co-workers know they can 
subscribe to group at http://groups.google.com/group/excel-macros/subscribe