Wednesday, November 7, 2007

Meet friends in shenzhen







It has been a long time , Pip and his gf ,also my good friend ,came to Shenzhen. It is really great. After Long time have not seen them , i really miss pip and ate , snow and lim. Hehe... Really preciate their coming.



To tell the truth, i m not familiar with shenzhen at all ,but i m growing up in China ,heheh..... So i can handle something in Shenzhen. We enjoyed the lunch together , i don't know whether they like it ,hehe ...






Pip is looks like my best friend,--Paul Fu. Rembemer that after the new year in china , i went back to manila , i encountered some problem. I did something seems not good to Paul. And i can not forgive myself. Pip tell me try to tell him the truth. Thx. I did not. But i already can accept the reality. And paul seems not angry with me at all . Great , i hv these 2 friends.




After Lunch , we went to DongMen(East Gate), a shopping street. There are people around here and there. We Looked around the street , pip and lim had some food , they found that it was not the same taste as HK 's. Heeeeee.




Every weekends , there's crawd in DongMen Street, you just can see the head of people , you can not see your own feet.We had lunch in a restaurant in HaoWeiZhan(好味栈).

It was the second time i went there , so i don't know whether there's any bar there. I just called my friends , they tell me that there's a bar named BenSE (actual character).














IN the bar we enjoy the music , Pip doubt that whether the singer will sing Chinese Song. hehe . It turned out that he can not understand it ,heheh......
After that we went back to the Vienna Hotel ShenZhen .It is really a excited day , coz i met these 2 good friends in oneday , hehe ..
The next day , we went to the window of the world, but i hope they were not disappointed with it. hehe , Coz there really only the models to see... I should bring them to the Happy Vollay
Hoped they can stay much longer time , but times really short when i realized that they were going back. Don't want to wave hands to them in Station.
I m planning to arrange the visa , but it is really hard to arrange the time . ...









































Wednesday, October 31, 2007

robocopy tools(Windows2000 server shared folder access control copy )



As the data server is changed to another server machine. The shared source should be relocated to another server , but the access control rights should be maintained. Xcopy can do it in the same machine , but it can not support different machines copy action.
Howerver , there's another way to do it .Symantec Back up software can do it , but it nid you to pay, though there's trail period , but if we do it ourselves , whether there's another way to do it .
The answer is yes. There's another tools for it : RoboCopy.
Fist you have to select a diretory for the distination for the copied files :




Then choose which file you want to copy, after that you can do it yourself,
Then it will run the robocopy command to relocate the shared source to the distination you made.
http://www.sh-soft.com/front_content.php?idcat=36 here's the like for the GUI for the robocopy.













Tuesday, October 30, 2007

KVM keyboard Mouse down

In the office , when we install symantic Back up Software , there's someproblem happened to our KVM interated Keyboard and mouse .Only the vedio function works well but the keyboard and the mouse can not work.Though we tried to switch it between 1 to 16 resource by button.
It still can not work.So we tried to power off and then power on , it stil not work.
finnally we called the support service. And the next day the man came to our office brought a new keyboard and moused integrated in the keyboard . then i Helped him to changed the keyboard. still can not work .So he called the factory and ask for helpping .At last he tried the 'B'+16. and input the default password "00000000" it works now this time.
Well done, there's no manual for the user but you ask them to support the server room . so wat will happen if they don't know how to solute the problem in KVM down.
The KVM is a small issues , but if you encounted that problem , it will also affect the normal working schedule.
so in the server room , there's no small issues. hehe , take all the issues as the big deal , it will help you to avoid lots of problem.

Monday, October 22, 2007

how to restore database from sql server 2005 to SQL server2000

                       how to restore database from sql server 2005 to SQL server2000

想从sql server 2005 的数据库备份恢复数据到2000,会遇到错误 "Too many backup devices specified for backup or restore; only 64 are allowed.

(Microsoft SQL Server, Error: 3205)"

用detach和attach同样不行,"Error 602 Severity Level 21 Message Text

Could not find row in sysindexes for database ID %d, object ID %ld, index ID %d. Run DBCC CHECKTABLE on sysindexes."


 

 

How to Downgrade a Database from SQL Server 2005 to SQL Server 2000

As you may all know, SQL Server 2005 request a minimum of 8GB RAM to work… let say satisfactorily. I first didn’t knew that and after a while from the upgrade I did from SQL Server 2000 to 2005 my SQL Services were starting to crash three or four times per DAY!!! 

At first I thought I was being attacked, but soon I realized it was nothing like that. I then decided to downgrade to an SQL Server 2000 edition. Though I looked around the internet to find some information on how to do that, I got very disappointed when I realized that no actual documentation of any kind could be found for that. So I am posting this thread to inform you on the procedures I had to follow for this action. 

Before beginning I must assume, firstly that the user, who will attempt such thing, has a basic knowledge of SQL Environment, secondly that he has the two versions already installed (both 2000 and 2005), that a basic backup of the databases has been created and finally that all the 2005 SQL Server Users have been created at the SQL Server 2000 environment as well.

Step 1 Generating Scripts for the Database Elements and Structures

1) Right-click over the desired Database at 2005, Choose Tasks and the Generate Scripts (Option).

2) At the pop-up Dialog Box click at the Script All Objects in the selected Databases check box, to activate it and then Click the Next Button.

3) Set the following Elements to the following Values

a. Script Collation , set to TRUE

b. Script Database Create, set to TRUE

c. Script of SQL Version, set to SQL SERVER 2000

d. Script foreign keys, set to FALSE

e. Script Triggers, set to FALSE

Then Hit the Next button

4) Select the way the generated scripts should be saved (There are different selections. The most common one is Clipboard). Finally click the Next button till you reach the end.

5) Click Finish

After completing this procedure, we have to move to the SQL SERVER 2000 environment. Here, by using the Query Analyzer, we will have to run the scripts that were generated using the master database. Copy and Paste the script at the Query Analyzer and run it. After that the Structure of the Database will be created.

Be careful, the SQL Server 2005 Edition inserts the Views in a random place through the script. Therefore, all the scripts that are referred to the Views MUST be moved to the end of the script. If the Query Analyzer shows some errors do not be bothered. Delete all the elements created from the script and after you fix the code run it again.


Step2 Moving the data from 2005 to 2000

1) After completing the previous step successfully, moving the data follows. Right-click at the 2005 database you used to run the previous step and select Tasks and then choose the Export Data (option).

2) From the pop-up Dialog Box, select the Source Db and Click at the Next Button.

3) At the next step you will have to choose the destination server and the destination Database for the Data to be exported. Then Click Next.

4) A List of all the Source Database’s Elements will appear in the screen. Select one by one all the Elements you wish to move and for each one click at the button Edit Mappings (Located at the bottom right corner of the Dialog Box just under the Elements list). A new Dialog box will pop-up. Select the Delete rows in Destination Tables option and activate the Enable Identity Insert Option. (Remember to repeat this action for each of the selected Element from the list that will be moved.

CAUTION!!! A malfunction of the SQL Server 2005 has been found. Not sure why, after multiple tries I have observed that when I tried to move more than twelve Elements at once, the Export Data Wizard of SQL Server 2005 seemed to disable the Enable Identity Insert Option that was activated over the Edit Mappings Dialog Box. But if the number of the selected Elements is smaller than 12 no problem seemed to appear.

Step 3 Generating Scripts for the Database Foreign Keys and Triggers

Finally, to successfully finish the downgrade of the Database, the Triggers and the Foreign Keys of the DB must be produced. The procedure that should be followed is the one stated next:

1) Right-Click at the SQL 2005 Database and Select from Tasks Menu the Generate Scripts Option.

2) Using the pop-up Dialog Box make sure that the check box Script All Objects in the selected Databases is not enabled and hit the Next Button.

3) Set all the Elements on the List to a False Value except the ones that follow:

a. Include IF NOT EXISTS , set to TRUE

b. Script Owner, set to TRUE

c. Script of SQL Version, set to SQL SERVER 2000

d. Script foreign keys, set to TRUE

e. Script Triggers, set to TRUE

Then Hit the Next button 

4) After finishing reading the Elements of the Database, a new list will appear at the Dialog Box. Make sure that you select ONLY THE TABLES of the Database and hit the Next Button.

5) At the screen that follows hit the Select All button and the Next.

6) Select the way the generated scripts should be saved (There are different selections. The most common one is Clipboard). Finally click the Next button till you reach the end.

7) Click Finish Button.

After completing this procedure, we have to move to the SQL SERVER 2000 environment. Here, by using the Query Analyzer, we will have to run the scripts that were generated using the master database. Copy and Paste the script at the Query Analyzer and run it. After that the Foreign Keys and the Triggers of the Database will be created.

After these steps the database should be fully functional under the SQL Server 2000 edition.

www.hellasinternet.com

During Export data from 2005 to 2000 ,there's may be some problem , wat i encountered is that though 2005 management info shows successfully exported, but it just export 1 record into the disternation table.

So inorder to solve the problem , you 'd better use the disternation database to import data from 2005 ,that will be much useful. And the problem solved.

Good luck!



Sunday, September 16, 2007

Iphone's Price Down $100

The IPhone has descreased $100 , as the previous Price is $599 for 8G IPhone.It Caused the customers who already Paid $599 for the IPhone rather disppointed with the Company of the IPhone. They Write emails to the SEO of Apple. Also the stoke is decrease as 1.3% .

As the Ipod just made sales of 1000,000.But as the descrease of the Price of the Iphone (8G),

the sales ratio will be definitely increase to 1000,000 in short term.

But as the Iphone got 3G Service and the Processing ability of the Processor .


In china , I think coz the Iphone was limited that :
Just can be used in America And Eroupe .Then
The fans of IPhone. they tried many ways to dencrypt the machine.
And as a result , one of the user tried to dencrypt it in "hard" way, but it caused a exporsion.

Sunday, July 1, 2007

casino filipino

Today is the last holiday i m in manila , then i go to Finlipino Casio to have the taste of Gambling ,then the first i won 1500 Pesos ,hahah , i set 13 then it made me win 800pesos ,hehe .the feeling is so cool ,the i put 500 pesos , it gone ,last time i lost it , again 500 , lost again. Finally , i lost wat i won. It is goog experience and bad experience .Good thing , it tell me that gambling is not the good game for the guy , always earn money by gambling , and bad thing is that , i lost money. But it make me clear that , when i feel bad, i won't put my money all to wat it was high risk.
when i feel is may lost , it will happens that it must be lost. So the feeling will always tell me wat to next. When feel bad, just leave the seat , let yourself cool down. Life is that , how to make decision and when it is the highest benefits, just leave, at all you win. But you still go on , you will lose all you got and you have. so wat i try to say is that , every one should care about the feeling .Don't always in the high risk state, hehehe , hope i will be clear about this point. No one force you to make decision ,and if it must be , take it in the most high bebefit, and then just leave it to the fate. that's all.
The first thing is how make correct decision , though i still young , then i knows how to make me clear about the point , then i will be the valuable thing i learn in Casino. hahhaha , you got experience you learned . Then it will be the most good thing you must learned .If it wins ,you will always just stay there, and life is not joke, hope you knows this point.

Thursday, June 28, 2007

Wealthtoolbox (earn your first $100 soon just one click)

http://www.wealthtoolbox.com
Just click the link above and sign up with your paypal email address, you will get $100 at once.Then most oftenly go to your account ,you will find that they do give you $5 each time you login. Please don't be histate,you may lose the chance to get your first $ 100from the web.Though you hope can earn money on web by writing blog,and it is another chance you can do it just by once sign up and visit the web with your account.If you don't believe you can check it with a email that don't have any relationship with your private information. though they did not get any information from you .It is a trick again, It suppose to that they will just get your email adress and it is paypal true account. Now it is really the account you sign for paypal, do you think it it goes to your pocket without even pray for? i don't think so, so if you are not mind , can just try the like above and just sign use your useless email address. it will be much safe than use paypal account.
and you can also read this article about it .http://turnonepoundintoonemillion.blogspot.com
but it will be the bonus given to you 2years later? just click the link above , to see this kind of "trick"go get the money .

Wednesday, June 27, 2007

google trends (www.google.com/trends)

google.com/trends is a link that you can check the keywords you input for searching ,is most used by which countries and which cities , then you may know wat the countries and the citizens , the most actually ideas and thoughts in their mind. Such as "Fuck" and "Shit",you may check which counties ,their people always searching for it. The ranks and the trends they showed out.Go ,then you may know it ,hehe .. i think it is easy for you just guess ,that which kind of character they may have.

Tuesday, June 26, 2007

samsung SSD harddisks


now SSD (solid state disk),nearly it compatable with the PCMCIA of notebook ,65G for $500. And samsung is the first manufature publish this kind of disk.Now it has 18G and 65G 18" ssd,suit for umpc and notebook,laptop. and for 3.5' sata ssd ,it is now up to 256,and more.But for 2.5' ,it is just published recently,here is QPI 's products:

now the price is too high, lets wait for 2 or 3 years, it will the same as notebook, it is another battle for the digits manuafatures,and now after 360G sata hard disk , the express card ssd will be the new for every digit funs.the stable and the speed and the storage are the factors that all the users care about , so when a product comes out it should be shows the function and quanlity.

now

Monday, June 25, 2007

excel report genarting (the function inside of excel)

  将数据导出到Excel的方法有多种,速度有快慢之分,我用过三种方法,速度都比较快,下面的一种利用Excel内置的功能,是三种之中最快的。其中最主要的是下面两句:
xlQuery := xlSheet.QueryTables.Add(ADOQExport.Recordset ,xlSheet.Range['A3']);
xlQuery.Refresh;
  不过我这里稍为复杂一点,要通过某种条件完成分类汇总。

function ExportToExcel: Boolean;
var
xlApp, xlBook, xlSheet, xlQuery: Variant;
SQLCmd: String;
i, iNextRow: Integer;

//设定单元格默认格式
procedure ExcelSetDefaultFormat;
begin
xlSheet.Cells.Font.Name := '宋体';
xlSheet.Cells.Font.Size := 12;
xlSheet.Cells.VerticalAlignment := 2;
//xlSheet.Cells.RowHeight := 17.25;
xlSheet.Range['C:D'].HorizontalAlignment := xlCenter;
end;

//输出标题
procedure ExcelSetHeader;
begin
xlSheet.Range['A1'].Value := '显示在报表第一行的标题';
xlSheet.Range['A1:F1'].HorizontalAlignment := 7;
xlSheet.Range['1:1'].Font.Size := 18;
xlSheet.Range['1:1'].Font.Bold := true;
xlSheet.Range['A2'].Value := '文件编号:WL/B 19';
xlSheet.Range['A2'].Font.Size := 11;
xlSheet.Range['F2'].Value := '记录编号:GZ-023';
xlSheet.Range['F2'].HorizontalAlignment := xlRight;
xlSheet.Range['F2'].Font.Size := 11;
xlSheet.Range['A3'].Value := 'XXXXX有限公司';
xlSheet.Range['F3'].Value := '日期:2005-X-X' ;
xlSheet.Range['F3'].HorizontalAlignment := xlRight;
//输出字段名
ADOQExport.SQL.Strings[4] := 'where 1=0';
if ADOQExport.Active then ADOQExport.Requery else ADOQExport.Open;
xlQuery := xlSheet.QueryTables.Add(ADOQExport.Recordset ,xlSheet.Range['A4']);
xlQuery.FieldNames := true;
xlQuery.RowNumbers := False;
xlQuery.FillAdjacentFormulas := False;
xlQuery.PreserveFormatting := True;
xlQuery.RefreshOnFileOpen := False;
xlQuery.BackgroundQuery := True;
xlQuery.RefreshStyle := xlOverwriteCells; //xlInsertDeleteCells;
xlQuery.SavePassword := True;
xlQuery.SaveData := True;
xlQuery.AdjustColumnWidth := True;
xlQuery.RefreshPeriod := 0;
xlQuery.PreserveColumnInfo := True;
xlQuery.Refresh;
iNextRow := 5;
end;

//设置页脚
procedure ExcelSetFooter;
begin
xlSheet.PageSetup.LeftFooter := '制表:' + DM.UserInfo.UserName;
xlSheet.PageSetup.CenterFooter := '审核:';
xlSheet.PageSetup.RightFooter := '第 &P 页,共 &N 页';
end;

//输出汇总数据
procedure ExcelSetSum;
begin
xlSheet.Range[Format('A%d', [iNextRow])].Value := '条数合计(条)';
xlSheet.Range[Format('A%d:B%0:d', [iNextRow])].HorizontalAlignment := 7;
xlSheet.Range[Format('C%d', [iNextRow])].Value := FloatToStr(DBGridEh1.Columns[6].Footer.SumValue);
xlSheet.Range[Format('C%d:F%0:d', [iNextRow])].HorizontalAlignment := 7;
xlSheet.Range[Format('A%d:F%0:d', [iNextRow])].Font.Bold := true;
Inc(iNextRow);
xlSheet.Range[Format('A%d', [iNextRow])].Value := '重量合计(kg)';
xlSheet.Range[Format('A%d:B%0:d', [iNextRow])].HorizontalAlignment := 7;
xlSheet.Range[Format('C%d', [iNextRow])].Value := FloatToStr(DBGridEh1.Columns[7].Footer.SumValue);
xlSheet.Range[Format('C%d:F%0:d', [iNextRow])].HorizontalAlignment := 7;
xlSheet.Range[Format('A%d:F%0:d', [iNextRow])].Font.Bold := true;
end;

//根据类别输出数据到Excel
procedure ExportData(DataType: Byte);
begin
SQLCmd := Format('where DataType=%d ', [DataType]);
ADOQExport.SQL.Strings[4] := SQLCmd;
if ADOQExport.Active then ADOQExport.Requery else ADOQExport.Open;
ProgressBar1.StepIt;

if not ADOQExport.IsEmpty then begin
//标题
xlSheet.Range[Format('A%d', [iNextRow])].Value := DM.GetDataTypeStr(DataType);//将DataType转换为相应的文字显示
xlSheet.Range[Format('A%d:F%0:d', [iNextRow])].HorizontalAlignment := 7;
xlSheet.Range[Format('A%d:F%0:d', [iNextRow])].Font.Bold := true;
Inc(iNextRow);

xlQuery := xlSheet.QueryTables.Add(ADOQExport.Recordset ,xlSheet.Range[Format('A%d', [iNextRow])]);
xlQuery.FieldNames := false;
xlQuery.Refresh;
Inc(iNextRow, ADOQExport.RecordCount);
xlSheet.Range[Format('A%d', [iNextRow])].Value := DM.GetDataTypeStr(DataType) + '合计(条)';
xlSheet.Range[Format('A%d:B%0:d', [iNextRow])].HorizontalAlignment := 7;
xlSheet.Range[Format('C%d', [iNextRow])].Value := Format('=SUM(C%d:C%d)', [iNextRow-ADOQExport.RecordCount, iNextRow-1]);
xlSheet.Range[Format('D%d', [iNextRow])].Value := Format('=SUM(D%d:D%d)', [iNextRow-ADOQExport.RecordCount, iNextRow-1]);
xlSheet.Range[Format('A%d:F%0:d', [iNextRow])].Font.Bold := true;
Inc(iNextRow);
end;
ProgressBar1.StepIt;
end;

begin
Result := true;
ShowProgress(0, cbbDataType.KeyItems.Count*2+2, 0); //调用前面例子中的函数显示进度面板
Screen.Cursor := crHourGlass;
try try
//建立OLE对象
xlApp := CreateOleObject('Excel.Application');
xlBook := xlApp.Workbooks.Add;
xlSheet := xlBook.Worksheets['sheet1'];
xlApp.Visible := false;
ProgressBar1.StepIt;
//设置格式
ExcelSetDefaultFormat;
//输出标题内容
ExcelSetHeader;
ProgressBar1.StepIt;

//查询结果,导到EXCEL
for i:=0 to cbbDataType.KeyItems.Count-1 do //cbbDataType: TDBComboBoxEh
ExportData(StrToInt(cbbDataType.KeyItems.Strings[i]));
//输出汇总内容
ExcelSetSum;
//设置边框
xlSheet.Range[Format('A4:F%d', [iNextRow])].Borders.LineStyle := xlContinuous;
xlSheet.Cells.EntireColumn.AutoFit;
//输出页脚
ExcelSetFooter;
except
if not VarIsNull(xlApp) then
begin
xlApp.Quit;
xlApp.Disconnect;
xlApp := Unassigned;
xlApp := NULL;
end;
result := false;
Exit;
end;
finally
pnlShadow.Visible := false;
pnlProgress.Visible := false;
Screen.Cursor := crDefault;
xlSheet := Unassigned;
xlBook := Unassigned;
if not VarIsNull(xlApp) then begin
xlApp.Visible := true;
xlApp := Unassigned;
end;
if ADOQExport.Active then ADOQExport.Close;
end;
end;

Saturday, June 23, 2007

Contract translation(English to chinese)

Yesterday,one of my friends ,asked me to translate a contract for him, just becoz he is familiar with Education only, and i m having a job much closer to business.You know it is worth 500,000 US dollars,so i don't know have to help him and i still have to work on my task of project, so i just promised him that if he can not find other guy to help him i can only help him to do the rest of the translation during weekend.And now i am doing it , mostly ,the i had some business english during my collage,but it just for 2months , and did not use it too often, recently.So i have to remind all i learned during the collage.So it bring me back to the collage time,hehehe , so many words familiar."business Invioce" "all risks" "shipping point" "destination point" "contract period" "business days" "calendar days" ................so many things like this, i think it will make me get much of the business aera, though i wrote to my boss, that i will learn business deeply, since it becoz to truth aready and so quickly becoming.hehehe , you have to say , you wish it comes. it is the last weekend here i m in manila,hehe the time and days are under counted before i leave Philippines.Hope everyfriends here got happy.

Thursday, June 21, 2007

How long is your life ---deathclock

Every body just have the life one time , we like to say that Life won't take twice.So you have to take care fo yourself and others , be kindly treat yourself the best enviroment and the mood, it is better for your health and your family.And if you already know how long you still can live ,then wat wil you do first, something
urgent, something necesary. And we remind that the female called Hellen Keller and her famous article <> , i just don't know how to translate it correctly. But it is the same meaning to you , that during your life you just have oneday you can see, then wat you will do ~? you should think of it , it won't take you too much time ,then you will find out wat is the truth healthy and time meaning to you.here , we got the deathclock, according to your information you submitted , it will measure your healthy and then get the supposed result for you, and then , you can see how long is your life will be , and how much time you still have, and the time keeping on deducting , and time gone 1 second by 1sencon. hows your feeling , don't tell others, just ask yourself, wat have you done and wat you achived and wat you have donated? then wat else~?~?you got it ! deathclock


cool black cars----cool













add your web url into search engine(google,yahoo,msn,msn live...

This summary is not available. Please click here to view the post.

Wednesday, June 20, 2007

laptop wireless online easily

It has been many times that i have the laptop with Wifi but always have to put it on my knees , it lots of harm and radiative ,so harmful to our healthy.And we still have to go with it.But there's so many cases that one kind provide us the function that we can put our laptop /notebook on it. it goes convinient.see...

Now it is $150 but i think , someone will just buy a cheaper one ,hehe , i m not ask you to buy it , just tell you that there's lots of cases when you are travelling you can choose one of them ,make your trip much convinient and much funny ,easily. I like travel and there's much cases must consider , the hotel ,the ship , the plane, the train, still the taxi, especial you are in the foreign countries it will make you much scear of that encountering the urgent event. it will make you trouble and unhappy.So becareful and take care of your own treasures. I m sure you will be the one who find out whether there's peace place you should payattentoion. In case some of the travellors have encountered the cases that their passports lost , so they have to turn to the ambossors that will provide them the temporary passport to endup their staying in the countries they visiting.It is an awful experience , isn't it~?~?

Tuesday, June 19, 2007

GFW----great fire wall/government fire wall

GFW, I wanna write something about GFW for a long time ,but did not in the mood to do it ,hehe ,now i wanna talk something about it , it called great fire wall, may make you remaid that the Great wall of china, right , you are definitly correct. It has the same function that can block the enemies outside of it , so it also help the internet user in china to be seperated with the harmful information and porn goods&infomation.But it blocks Blogspot, wiki,and flikr,may be my blog will be blocked ,just because of the GFW, but i still wanna talk about it ,it blocks our own freedom and our democracy.it also have another name----government fire wall.i think , though now i am afraid that i can not open it in china, and it is that i can not open my blog and update it.and i keep in searching the way to avoid of the situation.and now i think i got it.http://www.great-firewall.com/if you are chinese you can understand it.it is better.otherwise , you just download it and set the proxy it provided ,or just download the Tor
it is the decode way to break the block.and chinabloggersare blocked sometimes ,just becoz some of the members wrote something with the content of harmful.
we have the ways to break the GFW.1.just set the foreign countries proxy(for chinese)
2.download the plungin software for firefox
3.have the Tor to solve the problme
and i still wanna to see whether there's another way to solve the problems.

Saturday, June 16, 2007

Father'sday

After i came back from RP(robinsion's place) where we always got our vegetables there and other goods.It is surprised to find it is nearly the fathers' day.
It is my first time to talk to my father directly , just wat i don't think he did right to me or to the family. He accepted my advice, but i don't know whether he will change his own style, as i know he is a indepent man , and powerful in my eyes.I m so fear of him. And now we talk to each other fairly and frankly , i think it is better that good for me to get close to my father. and the chart lasted for nearly 1 hour, he got tired and don't want me to waste too much money on the talk. It is the first time, i talked so much with him. And during the years with him , i also went against him several times, it made him so sad for years. And last we did not talk to each other too much until i went to collage i started to talk to him oftenly , but not so long time. Unforgetful , so i just blog it.
type ur summary here

type the rest here

Friday, June 15, 2007

Occupation Planning

<> the book i bought in RP(robinson Place) ,200peso . When i in the jeepney i just read it ,and back to apartment i just make it as oral material , and read it before i went to bed, every night recently , i can not sleep early. It seems that all the guys after nearly 1 years of getting his first job , he got himself lost ,and after that he started to think about the plan the moment or before the moment he got his first job, all the guys have their own life plan and occupation plan for their life as well as job.
and it will go with the way according to the plan~? I don't think so, he is the environment,You won't know wat is the next will happen .But there's another way that as the Buddha said, everything has been set by the God.And your future is like a play that written by the God , you are just the actor who acted as the Play note. Though you encounter the trouble , it is also the scene that has been set there waiting for you .
It said just to the Normal people.And the abnormal ones are in the different situation,----special cases.Though the God can not arrange them.Who are they~?------ the much kindly ones and the much bad. It is a big variable. The will be the guys not in the play note . So are you going to be the ones that fully according to the routine that already set for you , or select the different way for yourself.It depends on your own behavior. So now , it is a much faster society, and the feed back also so fast, that if you don't have a strong heart , you can not afford of it.So i don't want to work just one career during my life, maybe it will be much easier for a guy that only have one career in his life.But it will be much bored that so tedious, i can not use to it. And i hope can try different roles in the society, first be the low level in it , now i going over it . second should be the much higher level. It means the manager level. But now it will be my first step, i know it is hard for me right now , coz i have to learn much more. And i will be always ready to get the new information from now on. Won't hope so, just do it!~!!!it will be much valuable that it will make much efforts .Second , i will set up my own company,it is a dream to me till now ,hehe ,everyone hope that can have his own business when he start to work. I m dreaming, as someone said:"don't stop dreaming, it will give you power!" But i have to remember that , it will be a good dream. Just step and step forward it. One of my office mate said that he will going to be a author after several years , but in people's mind is that , the authors almost can not be a rich guy. No. it is wrong viewpoint . I have to say that , it won't be proved in china.The most famous guy in china is Hanan(same pronunciation,but different Chinese characters), he got into high school successfully just by his own power of running 1000 meters only by 3'11'' that was when he is graduated from middle school with failed of examination. But he did it to get into the high school. See , it is another clues that life can be changed just coz the life variety.
and he got rich just by writing books, I think he is the first 16 years old only but already published his first book. <1 degree below zero> ..etc. wat i can not list completely. And he already can afford to the Benz Car he has , you can find out how rich he is . And he is not the most successful one being author. YI Zhongtian, who is writing the comment about the <> .He studied <> just for 10 years and he became successful and famous after he giving the comments on the management topic generated from three kingdoms on TV. and the series make hime became famous soon.(in chinese it said being famous just during one night) how fast it was.hehe , and he can get the money that just by writing books about history and generate the management points for the mordern society.¥2,000,000 at least for one year.Just have the version right, and famous name. hehe its value can be see . and another typical example is the author, named Wang shuo, he is now opened his own blog, and talking about his own life on it. and he disenclosed his private life about used to get chicks for playing before,it makes his name gose with the F words and S words across china.and it also make him being a charactical Pig, it means that too special and can not be accepted by the public and normal people. But his books are really good. But hanhan is against him,hahhaha .. famous against famous , it is typical in china.
Books, careers, occupation, money, famous .. it rushed into our life, and still keep being like this in a fast speed can not be imagined.How to go and where to go.... the famous star in HK said this after HK goes back to China. WE have to arrange the plan fit for ourself. Budda said that , just according to your own will and really feeling from your heart.

Tuesday, June 12, 2007

excel application control




 
全面控制 Excel

首先创建 Excel 对象,使用ComObj:

Dim ExcelID as Excel.Application

Set ExcelID as new Excel.Application

1) 显示当前窗口:

ExcelID.Visible := True;

2) 更改 Excel 标题栏:

ExcelID.Caption := '应用程序调用 Microsoft Excel';

3) 添加新工作簿:

ExcelID.WorkBooks.Add;

4) 打开已存在的工作簿:

ExcelID.WorkBooks.Open( 'C:\Excel\Demo.xls' );

5) 设置第2个工作表为活动工作表:

ExcelID.WorkSheets[2].Activate;

或 ExcelID.WorkSheets[ 'Sheet2' ].Activate;

6) 给单元格赋值:

ExcelID.Cells[1,4].Value := '第一行第四列';

7) 设置指定列的宽度(单位:字符个数),以第一列为例:

ExcelID.ActiveSheet.Columns[1].ColumnsWidth := 5;

8) 设置指定行的高度(单位:磅)(1磅=0.035厘米),以第二行为例:

ExcelID.ActiveSheet.Rows[2].RowHeight := 1/0.035; // 1厘米

9) 在第8行之前插入分页符:

ExcelID.WorkSheets[1].Rows[8].PageBreak := 1;

10) 在第8列之前删除分页符:

ExcelID.ActiveSheet.Columns[4].PageBreak := 0;

11) 指定边框线宽度:

ExcelID.ActiveSheet.Range[ 'B3:D4' ].Borders[2].Weight := 3;

1-左 2-右 3-顶 4-底 5-斜( \ ) 6-斜( / )

12) 清除第一行第四列单元格公式:

ExcelID.ActiveSheet.Cells[1,4].ClearContents;

13) 设置第一行字体属性:

ExcelID.ActiveSheet.Rows[1].Font.Name := '隶书';

ExcelID.ActiveSheet.Rows[1].Font.Color := clBlue;

ExcelID.ActiveSheet.Rows[1].Font.Bold := True;

ExcelID.ActiveSheet.Rows[1].Font.UnderLine := True;

14) 进行页面设置:

a.页眉:

ExcelID.ActiveSheet.PageSetup.CenterHeader := '报表演示';

b.页脚:

ExcelID.ActiveSheet.PageSetup.CenterFooter := '第&P页';

c.页眉到顶端边距2cm:

ExcelID.ActiveSheet.PageSetup.HeaderMargin := 2/0.035;

d.页脚到底端边距3cm:

ExcelID.ActiveSheet.PageSetup.HeaderMargin := 3/0.035;

e.顶边距2cm:

ExcelID.ActiveSheet.PageSetup.TopMargin := 2/0.035;

f.底边距2cm:

ExcelID.ActiveSheet.PageSetup.BottomMargin := 2/0.035;

g.左边距2cm:

ExcelID.ActiveSheet.PageSetup.LeftMargin := 2/0.035;

h.右边距2cm:

ExcelID.ActiveSheet.PageSetup.RightMargin := 2/0.035;

i.页面水平居中:

ExcelID.ActiveSheet.PageSetup.CenterHorizontally := 2/0.035;

j.页面垂直居中:

ExcelID.ActiveSheet.PageSetup.CenterVertically := 2/0.035;

k.打印单元格网线:

ExcelID.ActiveSheet.PageSetup.PrintGridLines := True;

15) 拷贝操作:

a.拷贝整个工作表:

ExcelID.ActiveSheet.Used.Range.Copy;

b.拷贝指定区域:

ExcelID.ActiveSheet.Range[ 'A1:E2' ].Copy;

c.从A1位置开始粘贴:

ExcelID.ActiveSheet.Range.[ 'A1' ].PasteSpecial;

d.从文件尾部开始粘贴:

ExcelID.ActiveSheet.Range.PasteSpecial;

16) 插入一行或一列:

a. ExcelID.ActiveSheet.Rows[2].Insert;

b. ExcelID.ActiveSheet.Columns[1].Insert;

17) 删除一行或一列:

a. ExcelID.ActiveSheet.Rows[2].Delete;

b. ExcelID.ActiveSheet.Columns[1].Delete;

18) 打印预览工作表:

ExcelID.ActiveSheet.PrintPreview;

19) 打印输出工作表:

ExcelID.ActiveSheet.PrintOut;

20) 工作表保存:

If not ExcelID.ActiveWorkBook.Saved then

ExcelID.ActiveSheet.PrintPreview

End if

21) 工作表另存为:

ExcelID.SaveAs( 'C:\Excel\Demo1.xls' );

22) 放弃存盘:

ExcelID.ActiveWorkBook.Saved := True;

23) 关闭工作簿:

ExcelID.WorkBooks.Close;

24) 退出 Excel:

ExcelID.Quit;

25) 设置工作表密码:

ExcelID.ActiveSheet.Protect "123", DrawingObjects:=True, Contents:=True, Scenarios:=True

26) EXCEL的显示方式为最大化

ExcelID.Application.WindowState = xlMaximized

27) 工作薄显示方式为最大化

ExcelID.ActiveWindow.WindowState = xlMaximized

28) 设置打开默认工作薄数量

ExcelID.SheetsInNewWorkbook = 3

29) '关闭时是否提示保存(true 保存;false 不保存)

ExcelID.DisplayAlerts = False

30) 设置拆分窗口,及固定行位置

ExcelID.ActiveWindow.SplitRow = 1

ExcelID.ActiveWindow.FreezePanes = True

31) 设置打印时固定打印内容

ExcelID.ActiveSheet.PageSetup.PrintTitleRows = "$1:$1"

32) 设置打印标题

ExcelID.ActiveSheet.PageSetup.PrintTitleColumns = ""

33) 设置显示方式(分页方式显示)

ExcelID.ActiveWindow.View = xlPageBreakPreview

34) 设置显示比例

ExcelID.ActiveWindow.Zoom = 100

35) 让Excel 响应 DDE 请求

Ex.Application.IgnoreRemoteRequests = False



用VB操作EXCEL

Private Sub Command3_Click()

On Error GoTo err1

Dim i As Long

Dim j As Long

Dim objExl As Excel.Application '声明对象变量

Me.MousePointer = 11 '改变鼠标样式

Set objExl = New Excel.Application '初始化对象变量

objExl.SheetsInNewWorkbook = 1 '将新建的工作薄数量设为1

objExl.Workbooks.Add '增加一个工作薄

objExl.Sheets(objExl.Sheets.Count).Name = "book1" '修改工作薄名称

objExl.Sheets.Add , objExl.Sheets("book1") ‘增加第二个工作薄在第一个之后

objExl.Sheets(objExl.Sheets.Count).Name = "book2"

objExl.Sheets.Add , objExl.Sheets("book2") ‘增加第三个工作薄在第二个之后

objExl.Sheets(objExl.Sheets.Count).Name = "book3"



objExl.Sheets("book1").Select '选中工作薄

For i = 1 To 50 '循环写入数据

For j = 1 To 5

If i = 1 Then

objExl.Selection.NumberFormatLocal = "@" '设置格式为文本

objExl.Cells(i, j) = " E " & i & j

Else

objExl.Cells(i, j) = i & j

End If

Next

Next



objExl.Rows("1:1").Select '选中第一行

objExl.Selection.Font.Bold = True '设为粗体

objExl.Selection.Font.Size = 24 '设置字体大小

objExl.Cells.EntireColumn.AutoFit '自动调整列宽

objExl.ActiveWindow.SplitRow = 1 '拆分第一行

objExl.ActiveWindow. SplitColumn = 0 '拆分列

objExl.ActiveWindow.FreezePanes = True '固定拆分 objExl.ActiveSheet.PageSetup.PrintTitleRows = "$1:$1" '设置打印固定行

objExl.ActiveSheet.PageSetup.PrintTitleColumns = "" '打印标题 objExl.ActiveSheet.PageSetup.RightFooter = "打印时间: " & _

Format(Now, "yyyy年mm月dd日 hh:MM:ss")

objExl.ActiveWindow.View = xlPageBreakPreview '设置显示方式

objExl.ActiveWindow.Zoom = 100 '设置显示大小

'给工作表加密码

objExl.ActiveSheet.Protect "123", DrawingObjects:=True, _

Contents:=True, Scenarios:=True

objExl.Application.IgnoreRemoteRequests = False

objExl.Visible = True '使EXCEL可见

objExl.Application.WindowState = xlMaximized 'EXCEL的显示方式为最大化

objExl.ActiveWindow.WindowState = xlMaximized '工作薄显示方式为最大化

objExl.SheetsInNewWorkbook = 3 '将默认新工作薄数量改回3个

Set objExl = Nothing '清除对象

Me.MousePointer = 0 '修改鼠标

Exit Sub

err1:

objExl.SheetsInNewWorkbook = 3

objExl.DisplayAlerts = False '关闭时不提示保存

objExl.Quit '关闭EXCEL

objExl.DisplayAlerts = True '关闭时提示保存

Set objExl = Nothing

Me.MousePointer = 0

End Sub