S
sujata_ghosh
thanks both of you,
my desired purpose has solved with combine coding of both of you.
but Tom, there is a mistake in your coding, that is why is doesn't
execute following code of the code:
Workbooks.Open Filename:="\\SS\ss_d\HOTEL HOST INTL. ROOM BILL
FORMAT\ROOM BILLS FORMAT IN EXCEL\all room bill 1 to 6.xls"
ActiveWindow.WindowState = xlMaximized
because you closing the main sheet from where this macro is working
using following command:
ActiveWorkbook.close SaveChanges:=False
but code of Bob is solve the purpose:
Workbooks.Open Filename:="\\SS\ss_d\HOTEL HOST INTL. ROOM BILL
FORMAT\ROOM BILLS FORMAT IN EXCEL\all room bill 1 to 6.xls"
Windows(fname1 ).Activate
ActiveWorkbook.Save
ActiveWorkbook.Close
Windows("all room bill 1 to 6.xls").Activate
ActiveWindow.WindowState = xlMaximized
hope you will agree with me with the mistake.
but Tom, your following code is realy easy one:
fname1 = "RM-1 " & format(Date,"dd-mm-yy") & ".xls"
i hope Bob also appreciate this.
any way i have combine both of your code, and solve most of my
purpose.
i am gratefull to both of you that i have learnt new things from you.
can any one of you give me idea on the following:
1) how i will ingone the message box of 'Replace file', which is
showing eveytime, that my file is file is exist. i will save my file
any number of time in a day or as monthly, as i add new date in it.
how i will set this?
2)the file, all room bill 1 to 6.xls, sheet contain date and as well as
all button, which excute these macros. they are on the O columns and i
have data from A to N column so i want to save the data of this column,
there will be any number of rows in these columns, there is no need of
the insert button in daily and monthly excel file. is this possible?
for your reference i am giving following information, which should be
maintain in every daily and monthly files, which are creating during
excution of code.
* row height is fixed to 41.25 pixel
* there is fixed title, which will print on the top of the everypage,
everytime, which are in terms of row $1:$8
i have locked those button so they don't get printed during data
printing.
if you need any more information please feel free to ask me.
hope i am clear regarding my desired job.
thanks,
sujata.
my desired purpose has solved with combine coding of both of you.
but Tom, there is a mistake in your coding, that is why is doesn't
execute following code of the code:
Workbooks.Open Filename:="\\SS\ss_d\HOTEL HOST INTL. ROOM BILL
FORMAT\ROOM BILLS FORMAT IN EXCEL\all room bill 1 to 6.xls"
ActiveWindow.WindowState = xlMaximized
because you closing the main sheet from where this macro is working
using following command:
ActiveWorkbook.close SaveChanges:=False
but code of Bob is solve the purpose:
Workbooks.Open Filename:="\\SS\ss_d\HOTEL HOST INTL. ROOM BILL
FORMAT\ROOM BILLS FORMAT IN EXCEL\all room bill 1 to 6.xls"
Windows(fname1 ).Activate
ActiveWorkbook.Save
ActiveWorkbook.Close
Windows("all room bill 1 to 6.xls").Activate
ActiveWindow.WindowState = xlMaximized
hope you will agree with me with the mistake.
but Tom, your following code is realy easy one:
fname1 = "RM-1 " & format(Date,"dd-mm-yy") & ".xls"
i hope Bob also appreciate this.
any way i have combine both of your code, and solve most of my
purpose.
i am gratefull to both of you that i have learnt new things from you.
can any one of you give me idea on the following:
1) how i will ingone the message box of 'Replace file', which is
showing eveytime, that my file is file is exist. i will save my file
any number of time in a day or as monthly, as i add new date in it.
how i will set this?
2)the file, all room bill 1 to 6.xls, sheet contain date and as well as
all button, which excute these macros. they are on the O columns and i
have data from A to N column so i want to save the data of this column,
there will be any number of rows in these columns, there is no need of
the insert button in daily and monthly excel file. is this possible?
for your reference i am giving following information, which should be
maintain in every daily and monthly files, which are creating during
excution of code.
* row height is fixed to 41.25 pixel
* there is fixed title, which will print on the top of the everypage,
everytime, which are in terms of row $1:$8
i have locked those button so they don't get printed during data
printing.
if you need any more information please feel free to ask me.
hope i am clear regarding my desired job.
thanks,
sujata.