资源描述:
《notes学习中自己总结.docx》由会员上传分享,免费在线阅读,更多相关内容在应用文档-天天文库。
1、实例:NOTES弹出各种输入框,选择框SubClick(SourceAsNavigator)DimsessionAsNewNotesSessionDimuiwsAsNewNotesUiWorkSpaceDimuidocAsNotesUiDocumentDimSourceDocAsNotesDocumentDimSourceViewAsNotesViewDimSetupviewAsNotesViewDimSetupDocAsNotesDocumentDimSourceDBAsNotesDatabaseSetSourceDB=Sess
2、ion.CurrentDatabaseDimPersonDBAsNewNotesDatabase(SourceDB.Server,"APSYSSYS0001.NSF")DimPersonViewAsNotesViewDimCardViewAsNotesViewDimCardDocAsNotesDocumentDimPersonDocAsNotesDocumentDimPersonView1AsNotesViewDimPersonDoc1AsNotesDocumentSetCardView=PersonDB.GetView("C
3、ardidView")SetSetupView=SourceDB.GetView("View-SystemSetup")SetSetupDoc=SetupView.GetDocumentByKey("Form-SystemSetup")IfSetupDocIsNothingThenMessagebox("Error:Cantfindsystemdoc,pleasetryagainorcallMISDept!")ExitSubEndIfDimDataDBAsNewNotesDatabase(SourceDB.Server,"APO
4、FFICEAP077A.NSF")DimDataViewAsNotesViewDimDataDocColAsNotesDocumentCollectionDimDataDocAsNotesDocumentDimEmpNoAsStringDimIDNoAsStringDimLotNoAsStringDimV1AsNotesItemDimV2AsNotesItemDimV3AsVariantDimV4AsNotesItemDimV5AsNotesItemDimV6AsNotesItemDimV7AsNotesItemDimV8AsN
5、otesItemDimRemainAsStringDimsssAsStringDimshouldAsString'---------------------------------------------------------------------------------------'2011/11/07NICK增加,要求進行選擇領料或者退料..並修改流程DimSelect1AsVariantDimChose(2)AsVariantChose(0)="1.領料單"Chose(1)="2.退料單"Select1=uiws.Pro
6、mpt(PROMPT_OkCancelList,"Selection","SelectaFormtype.",Chose(2),Chose)IfSelect1="1.領料單"ThenEmpNo=Inputbox$("PleaseinputyourEmpNo!!","請輸入員工編號")IfEmpNo=""ThenExitSubEndIfIfSetupDoc.InputType(0)="B"ThenIfLen(EmpNo)<12ThenMessagebox("錯誤:請用讀卡機刷識別證!!")ExitSubElsesss=Left(Em
7、pNo,7)IfLeft(sss,3)<>"019"ThenMessagebox("錯誤:本系統僅供南茂員工使用!!")ExitSubElseshould="S"+Right(sss,4)EndIfEndIfElseif(SetupDoc.InputType(0)="C")Then'rAns=uiws.Prompt(PROMPT_PASSWORD,"PleaseInputyourEmpNo!!","PleaseUseSenseMachine")'IfIsempty(rAns)Then'ExitSub'EndIf'EmpNo=Cst
8、r(rAns)IfLen(EmpNo)<10ThenMessagebox("錯誤:請用感應器刷感應卡!!")ExitSubEndIf%REMEmpNo1=Format(Val("&H"+Right(EmpNo,6)),"00000000")SetC