ضمیمهٔ کدهای ASCII و نمایه | Microsoft Access 2010 VBA

ضمیمهٔ کدهای ASCII و نمایه

توسط admin | گروه آموزش اکسس Microsoft access | 1405/05/16

نظرات 0

ضمیمهٔ کدهای ASCII و نمایه

ضمیمه — کدهای کاراکتر ASCII

این ضمیمه فهرست 255 کد کاراکتر ASCII (American Standard Code for Information Interchange) را که Access استفاده می‌کند ارائه می‌کند. این کدها با Functionهای Asc و Chr کار می‌کنند: Asc شمارهٔ ASCII یک Character را می‌دهد و Chr بر اساس شمارهٔ ASCII، Character را برمی‌گرداند.

همهٔ این Characterها را می‌توان با Chr در Text Stringها ساخت. مثال زیر Stringِ ABC را تولید می‌کند:

MsgBox Chr(65) & Chr(66) & Chr(67)

همچنین می‌توان Carriage Return و Line Feed را برای شکستن متن در نقطهٔ مناسب درج کرد. در جدول، علامت _ یعنی Character قابل نمایش وجود ندارد. از Character 128 به بعد Access از Extended Character Set استفاده می‌کند که ASCII واقعی نیست و تا حدی به Locale کاربر و PC وابسته است؛ بنابراین برای این محدوده ممکن است نیاز به آزمایش باشد.

کد ASCIIکاراکتر
1_
2_
3_
4_
5_
6_
7_
8_
9تب افقی
10رفتن به خط بعد
11تب عمودی
12پرش صفحه
13بازگشت ابتدای خط
14_
15_
16_
17_
18_
19_
20_
21_
22_
23_
24_
25_
26_
27_
28_
29_
30_
31_
32فاصله
33!
34"
35#
36$
37%
38&
39'
40(
41)
42*
43+
44,
45-
46.
47/
480
491
502
513
524
535
546
557
568
579
58:
59;
60<
61=
62>
63?
64@
65A
66B
67C
68D
69E
70F
71G
72H
73I
74J
75K
76L
77M
78N
79O
80P
81Q
82R
83S
84T
85U
86V
87W
88X
89Y
90Z
91[
92\
93]
94^
95_
96`
97a
98b
99c
100d
101e
102f
103g
104h
105i
106j
107k
108l
109m
110n
111o
112p
113q
114r
115s
116t
117u
118v
119w
120x
121y
122z
123{
124|
125}
126~
127_
128
129_
130
131ƒ
132
133
134
135
136ˆ
137
138Š
139
140Œ
141_
142Ž
143_
144_
145
146
147
148
149
150
151
152˜
153
154š
155
156œ
157_
158ž
159Ÿ
160_
161¡
162¢
163£
164¤
165¥
166¦
167§
168¨
169©
170ª
171«
172¬
173­
174®
175¯
176°
177±
178²
179³
180´
181µ
182
183·
184¸
185¹
186º
187»
188¼
189½
190¾
191¿
192À
193Á
194Â
195Ã
196Ä
197Å
198Æ
199Ç
200È
201É
202Ê
203Ë
204Ì
205Í
206Î
207Ï
208Ð
209Ñ
210Ò
211Ó
212Ô
213Õ
214Ö
215×
216Ø
217Ù
218Ú
219Û
220Ü
221Ý
222Þ
223ß
224à
225á
226â
227ã
228ä
229å
230æ
231ç
232è
233é
234ê
235ë
236ì
237í
238î
239ï
240ð
241ñ
242ò
243ó
244ô
245õ
246ö
247÷
248ø
249ù
250ú
251û
252ü
253ý
254þ
255ÿ

نمایه (Index)

نمایهٔ انتهای کتاب با همان ترتیب الفبایی و شماره‌صفحه‌های منبع منتقل شده است. نام Functionها، Methodها، Propertyها، Objectها و Keywordهای VBA به‌صورت اصلی نگه داشته شده‌اند و توضیح‌های توصیفی تا حد ممکن به فارسی برگردانده شده‌اند.

– operator, 73
* operator, 72
^ operator, 74
+operator, 72–73
\ operator, 73
/ operator, 73
A
Abs function, 49
ACCDE files, 283–284
Access object models
فراخوانی Methodها, 180–184
Collectionها, 181–184
سلسله‌مراتب Objectها, 190–191
دست‌کاری Propertyهای خواندنی/نوشتنی, 178–179
Methodها, 176–178
مرور کلی, 175–176
Propertyها, 176–178
همچنین ببینید: Object Browser
ActiveControl, 201
ActiveX Data Objectها. See ADO
AddNew method, 208
ADO, 248–251
AllowAdditions property, 202
AllowDeletions property, 202
AllowEdits property, 202
AllowFilters property, 202
And operator, 75–76
animation, 273–275
API calls
defined, 253–254
گرفتن فضای Disk, 254–256
پخش صدای Multimedia, 263
خواندن/نوشتن INI File,
256–257
خواندن فعالیت Keyboard, 258–262
Append query, 159–161
همچنین ببینید: SQL Queryها
Application object, 176, 193
CurrentDb object, 194
CurrentProject object, 194
DAvg method, 194–195
DbEngine DAO object, 195–196
DCount method, 195
DFirst method, 196
DLast method, 196–197
DLookup method, 197
DMax method, 197
DMin method, 197
DoCmd object, 197
DSum method, 197–198
DVar/DVarP Methodها, 198
Formها collection, 198
Printer property, 199
Printers collection, 199
Quit method, 199
References collection, 199
Reportها collection, 199–200
Screen object, 200
SysCmd object, 200
Version, 201
arguments
argument data types, 33
optional arguments, 33
passing by value, 33–34
arithmetic Operatorها, 72–74
arrays
defining متغیرها as, 16
dynamic, 24
multidimensional, 23
مرور کلی, 22–23
Asc function, 50
ASCII character codes, 359–363
Audit Trailها
غنی‌سازی, 292
مرور کلی, 290
استفاده از events to create, 290–292
Userهای مجاز, 281–282
همچنین ببینید: Login IDها
B
Beep method, 213–214
BeginTrans statement, 189
BOF property, 208
break mode, 82
breakpoints, 84
bugs
avoiding, 90
همچنین ببینید: debugging
buttons
ایجاد code for custom buttons,
136–138
در Formها, 108–109
option buttons, 110
ByRef keyword, 33–34
ByVal keyword, 33–34
C
Call Stack dialog, 82–84
Call statement, 30
Caption property, 202
CDbl function, 52
Chartها, 231–236
Drill Down روی, 325–327
exporting as picture files, 237
دست‌کاری رنگ Chart, 321–323
کار با the Series Collection object,
236–237
check boxes, در Formها, 109
Chr function, 50–51
and arrays, 22
CInt function, 51
class modules
ایجاد a collection, 268–270
ایجاد a Data Service Layer, 266
ایجاد an object, 267–268
درج, 266
مرور کلی, 265–266
استفاده از the PNames collection, 270–271
استفاده از the PNames collection as a multitier
application, 272
CLng function, 51
Close method, 208, 214
CloseDatabase method, 214
code windows, 7–8
Collectionها, 181–184
ایجاد, 268–270
color, in Chartها, 321–323
Color dialog, 126–128
Combo Box controls, 101
Command button control, 108–109
Commit statement, 188–189
CommitTrans statement, 189
comparison Operatorها, 74
compile Errorها, 81–82
concatenating Stringها, 46
concatenation operator, 75
conditional Operatorها, 38
conditional statements, 36–38
multiple conditional statements, 38–39
Select case statements, 39–40
constants, 25
for message boxes, 67, 68, 69
توابع تبدیل, 51–52
CreateObject method, 221
CreateQueryDef method, 205
CreateReport method, 234
CreateReportControl, 234
CreateTableDef method, 205–206
CStr function, 51
CurrentDb object, 175, 176, 194, 205
CreateQueryDef method, 205
CreateTableDef method, 205–206
Execute method, 206
Name property, 206
OpenRecordset method, 206
QueryDefs collection, 207
TableDefs collection, 207
CurrentProject object, 194
Custom UI Editor, 132–136
cycling through Collectionها, 182
D
DAO Objectها, DbEngine, 195–196
Data Service Layer, 266
data source names. See DSNs
data types
argument data types, 33
مقادیر Date/Time ذخیره‌شده در variants, 19
مقدار Empty, 19
مقدار Null, 19–20
انواع عددی, 20–21
مرور کلی, 18, 20
انواع String, 21–22
variants, 18–19
همچنین ببینید: انواع تعریف‌شده توسط User
Databaseها, 239–240
linking to other Access Databaseها, 240
locking, 284–287
همچنین ببینید: ADO; Linked Table
Manager; ODBC
توابع تاریخ و زمان, 56–62
Date function, 57
DateAdd function, 57–58, 301–303
استفاده از to pause your code, 303
DateDiff function, 58
DatePart function, 58–59
DateSerial function, 59
Date/Time formats, 55
Date/Time values, 303
DateValue function, 60
DAvg method, 194–195
Day function, 60
DbEngine DAO object, 195–196
DCount method, 195
debug mode, 82–83
debugging
avoiding bugs, 90
breakpoints, 84
Call Stack dialog, 85–86
Debug window, 86–88
modes, 82–84
problem events, 88–89
running selected parts of code, 84–86
types of Errorها, 81–82
استفاده از message boxes, 89–90
استفاده از Stop statements, 82–84
همچنین ببینید: error handling
decisions, 36–38
Declare statement, 254
Delete method, 208
Delete query, 157–158
همچنین ببینید: SQL Queryها
حذف code, 11
design time mode, 82
DFirst method, 196
dialogs
Color dialog, 126–128
Open File dialog, 124–125
مرور کلی, 123
Print dialog, 128
Save File As dialog, 126
Dim statements
and Access object models, 183
and متغیرهای Local, 15–16
and static متغیرها, 17
and متغیرها, 14
Dirty property, 202
DLast method, 196–197
DLookup method, 197
DMax method, 197
DMin method, 197
Do Until loops, 42
DoCmd object, 197, 213
Beep method, 213–214
Close method, 214
CloseDatabase method, 214
Hourglass method, 214
Maximize method, 214–215
OpenForm method, 215
OpenQuery method, 215–216
OpenReport method, 216
OpenTable method, 216
PrintOut method, 216–217
Quit method, 217
RunCommand method, 217
SetWarnings method, 217–218
TransferSpreadsheet method, 218
TransferText method, 218–219
Drill Down روی Chartها, 325–327
DSNs, 241–243
استفاده از within Access, 243–245
DSum method, 197–198
DVar/DVarP Methodها, 198
dynamic arrays, 24
همچنین ببینید: arrays
E
Edit method, 209
End..If statements, 37
EOF property, 209
error handling, 91–93
On Error Resume Next statement, 94
generating your own Errorها, 94–95
Resume statement, 93–94
همچنین ببینید: debugging; Errorها
Error statement, 95
Errorها
compile Errorها, 81–82
generating your own, 94–95
logic Errorها, 82
runtime Errorها, 82
Type Mismatch Errorها, 73
همچنین ببینید: debugging
events
Activate, 112, 121
After/Before Delete Confirm, 112
After/Before Insert, 112–113
After/Before Update, 113
Click, 113, 121
Close, 113, 121
Current, 113, 121
روی Formها, 111–112
Load, 113, 121
and modules, 11
Open, 113, 121
Print, 121
روی Reportها, 120–121
Timer, 114, 122
استفاده از to create Audit Trailها, 290–292
Excel
اجازه به User برای طراحی Reportهای Excel,
333–335
انتقال Numberهای منفرد به Excel,
332–333
استفاده از a recordset to create a spreadsheet,
329–330
استفاده از an existing spreadsheet as a template,
330–331
Excel Object Library, افزودن Reference به, 329
Execute method, 206
ExecuteMso method, 140
Exit statements, 43
همچنین ببینید: looping
Declaration صریح, 14–15
Explosion property, 236
F
Field Objectها, 176
fields
حذف, 314
editing field Propertyها, 315
همچنین ببینید: Tableها
Fields collection, 209
file size limit, 343–344
File Transfer Protocol. See FTP
Filter property, 203
FindFirst method, 209
FindLast method, 210
FindNext method, 210
FindPrevious method, 210
For Each loops, 41–42
format characters, 56
Format function, 52–56
Formها
animation, 273–275
buttons, 108–109
check boxes, 109
ایجاد a simple form, 98–100
datasheet view, 104–106
images, 109
list boxes, 109
Interactive کردن Controlها, 349–353
making the form look professional, 106–107
option buttons, 110
مرور کلی, 97
relational fields, 100–102
subFormها, 102–104
Tab Control, 110
استفاده از a custom ribbon, 107
استفاده از events, 111–114
استفاده از VBA, 111
Formها collection, 198
formulas, استفاده از در Reportها, 117–119
For..Next loops, 40–41
FTP
مرور کلی, 337
Semaphore Fileها, 340–341
استفاده از VBA code to transfer files, 338–340
Functionها
commonly used, 49–51
توابع تبدیل, 51–52
توابع تاریخ و زمان, 56–62
public or private, 32
vs. Subroutineها, 28–29
استفاده از custom Functionها within SQL Queryها,
163–164
writing a simple function, 30–32
همچنین ببینید: individual Functionها
G
GetEnabledMso method, 140
GetImageMso method, 140
GetLabelMso method, 140
GetPressedMso method, 140
GetScreentipMso method, 140
GetSupertipMso method, 140
GetUserName function, 290
GetVisibleMso method, 140
متغیرهای Global, 15, 17
همچنین ببینید: متغیرها
got focus event, 89
H
HasDataLabels property, 236
“Hello World” code, 9–11
Hour function, 60
Hourglass method, 214
Hwnd property, 203
I
icons, for message boxes, 66–67
If..Then..Else statements, 36
images
در Formها, 109
on Ribbonها, 138
Declaration ضمنی, 14
indexes, ایجاد, 315–316
instant watch mode, 82–84
Instr function, 48–49
InstrRev function, 49
Int function, 49–50
interactive controls, 349–353
Is operator, 79
IsDate function, 19
IsEmpty function, 19
IsNull function, 20
IsNumeric function, 19
K
key combinations, 259–262
key down event, 88
keys
special keys not normally displayed, 65
همچنین ببینید: SendKeys command
L
Text Fileهای بزرگ, 307–311
LCase, 47–48
Left function, 47
Len function, 49
Like operator, 79–80
Linked Table Manager, 245–246
list boxes, در Formها, 109
متغیرهای Local, 15–16
همچنین ببینید: متغیرها
قفل‌کردن Databaseها, 284–287
قفل‌کردن Projectها, 283
logic Errorها, 82
logical Operatorها, 75–79
Login IDها, 279–280
همچنین ببینید: Userهای مجاز
looping
Do Until loops, 42
For Each loops, 41–42
early exit of loops, 43
For..Next loops, 40–41
مرور کلی, 40
While..Wend loops, 42–43
lost focus event, 89
M
macro applications, 5
Macro Editor, 3–4
macros, vs. modules, 3–4
Make Table query, 158–159
همچنین ببینید: SQL Queryها
Maximize method, 214–215
Me object, 201
ActiveControl, 201
AllowAdditions property, 202
AllowDeletions property, 202
AllowEdits property, 202
AllowFilters property, 202
Caption property, 202
Dirty property, 202
Filter property, 203
Hwnd property, 203
Picture property, 203
Printer property, 203
RecordSource property, 203
Refresh method, 203
Repaint method, 203–204
Requery method, 204
RibbonName property, 204
ScrollBars property, 204
SetFocus method, 204
Undo method, 204–205
Visible property, 205
menu structures, ایجاد with the ribbon,
345–348
message boxes, 66–69
در Debugging, 89–90
همچنین ببینید: MsgBox statements
Methodها, 176–178
calling, 180–184
Microsoft Graph 12.0 Object Library, 232
referencing, 231
Microsoft Office
driving Access from Office programs,
226–228
استفاده از Access to interact with other Office
programs, 221–224
Microsoft Outlook, driving, 224–226
Mid function, 46–47
Minute function, 61
Mod operator, 74
متغیرهای سطح Module, 16
modules
and events, 11
vs. macros, 3–4
مرور کلی, 27–28
همچنین ببینید: class modules
Month function, 61
mouse down event, 88
MoveFirst method, 211
MoveLast method, 211
MoveNext method, 155, 211
MovePrevious method, 211
MsgBox statements, 9–11
همچنین ببینید: message boxes
multidimensional arrays, 23
همچنین ببینید: arrays
MyCode, 7–8
N
Name property, 206
NoMatch property, 211
Not operator, 76
Now function, 56
مقدار Null, 19–20
numeric data types, 20–21
همچنین ببینید: data types
O
oAApp object, 227
Object Browser, 184–186
Object Library, افزودن Reference به, 221–222
object models
CurrentDb object, 205–207
سلسله‌مراتب Objectها, 190–191
همچنین ببینید: Access object models;
Object Browser
Objectها
Application object, 193–201
ایجاد, 267–268
ایجاد in memory, 189–190
Me object, 201–205
Recordset object, 207–211
Objectها inventories, ایجاد, 317–319
ODBC, 239–240
links and DSNs, 240–243
Office programs
driving Access from, 226–228
استفاده از Access to interact with, 221–224
On Error Resume Next statement, 94
Open File dialog, 124–125
OpenForm method, 111, 215
OpenQuery method, 215–216
OpenRecordset method, 206
OpenReport method, 216
OpenTable method, 216
Operatorها
arithmetic, 72–74
comparison, 74
concatenation, 75
conditional, 38
logical, 75–79
miscellaneous, 79–80
order of precedence, 71
مرور کلی, 71–72
option buttons, 110
Optional keyword, 33
Or operator, 76–77
order of precedence, 71
oRSet object, 228
P
pass-through Queryها, 246–248
همچنین ببینید: SQL Queryها
paاستفاده از code, 303
Picture property, 203
predefined Date and Time formats, 54
predefined formats, 53
Print dialog, 128
Printer property, 199, 203
Printers collection, 199
PrintOut method, 216–217
Private keyword, 32
procedure stepping, 85
Project Explorer, 6–8
Project trees, 6
Propertyها, 176–178
دست‌کاری Propertyهای خواندنی/نوشتنی,
178–179
Public keyword, 32
Q
Queryها
ایجاد a new query, 293–294
حذف an existing query, 294, 298–299
جست‌وجو و جایگزینی در Queryها, 299–300
searching for a specific string within all
Queryها, 297–299
به‌روزرسانی SQL Query, 294–295
همچنین ببینید: SQL Queryها
Query Design window, 150–154
QueryDefs collection, 207
Quit method, 199, 217
R
RecordCount property, 211
Recordset object, 186–188, 207
AddNew method, 208
BOF property, 208
Close method, 208
Delete method, 208
Edit method, 209
EOF property, 209
Fields collection, 209
FindFirst method, 209
FindLast method, 210
FindNext method, 210
FindPrevious method, 210
MoveFirst method, 211
MoveLast method, 211
MoveNext statement, 211
MovePrevious method, 211
NoMatch property, 211
RecordCount property, 211
Requery method, 211
Update method, 211
RecordSource property, 203
ReDim statements
and arrays, 22, 23
and متغیرهای Local, 15–16
References collection, 199
Refresh method, 203
relational fields, 100–102
ReleaseFocus method, 140
Repaint method, 203–204
Report Wizard, 114–116
Reportها
ایجاد a simple report, 114–116
keeping the report tidy, 116–117
مرور کلی, 114
استفاده از a custom ribbon, 119–120
استفاده از formulas, 117–119
استفاده از VBA, 120
Reportها collection, 199–200
Requery method, 204, 211
reserved words, 26
Resume statement, 93–94
ReturnUserName function, 290
RibbonName property, 204
Ribbonها
ایجاد a ribbon customization, 130–132
ایجاد code for custom buttons, 136–138
ایجاد menu structures with the ribbon,
345–348
editing استفاده از the Custom UI Editor,
132–136
further customization, 141–147
images, 138
مرور کلی, 129–130
استفاده از a custom ribbon on a form, 107
استفاده از a custom ribbon on a report, 119–120
استفاده از VBA code, 138–140
Right function, 47
RunCommand method, 217
running code, 9–10
runtime Errorها, 82
runtime mode, 82
S
Save File As dialog, 126
saving code, 12
Screen object, 200
ScrollBars property, 204
Second function, 61
Security
قفل‌کردن Databaseها, 284–287
قفل‌کردن Projectها, 283
تنظیم سطوح Security کاربر, 355–357
استفاده از an ACCDE file to protect your
application, 283–284
Select case statements, 39–40
همچنین ببینید: conditional statements
Select query, 154–156
همچنین ببینید: SQL Queryها
Semaphore Fileها, 340–341
SendKeys command, 62–66
Series Collection object, 236–237
SetFocus method, 204
SetWarnings method, 217–218
shadowing, 17
single stepping, 85
SQL Queryها
Append query, 159–161
Delete query, 157–158
Make Table query, 158–159
مرور کلی, 149
pass-through Queryها, 246–248
Select query, 154–156
Union query, 156–157
Update query, 161–163
updating, 294–295
استفاده از custom Functionها within,
163–164
استفاده از the Query Design window,
150–154
همچنین ببینید: Queryها
Sqr function, 50
Static keyword, 17
Static statements, and متغیرهای Local, 15–16
statistics, 305–306
stepping through code, 84–86
Stop statements, 84
strict متغیرها, 17
string data types, 21–22
همچنین ببینید: data types
Stringها
changing the appearance of, 47–48
concatenation, 46
مرور کلی, 45
searching, 48–49
splitting Stringها, 46–47
subFormها, 102–104
همچنین ببینید: Formها
Subroutineها
vs. Functionها, 28–29
public or private, 32
writing a simple subroutine, 29–30
SysCmd object, 200
T
Tab Control, 110
table macros
ایجاد, 165–171
مرور کلی, 165
Table Macro window, 167
TableDef Objectها, 176, 189–190
TableDefs collection, 207
Tableها
communicating with, 186–190
ایجاد a simple table, 313–314
ایجاد indexes, 315–316
حذف, 298–299, 314
پایش Statistics, 305–306
همچنین ببینید: fields
temp, 17
TempVal, 14, 15
text files, large, 307–311
Time function, 57
transactions, 188–189
TransferSpreadsheet method, 180–181, 218
TransferText method, 218–219
Type keyword, 24–25
Type Mismatch Errorها, 73
U
UCase, 47–48
Undo method, 204–205
Union query, 156–157
همچنین ببینید: SQL Queryها
Update method, 211
Update query, 161–163
همچنین ببینید: SQL Queryها
شناسایی نام User, 289–290
همچنین ببینید: Userهای مجاز
سطوح Security کاربر, 355–357
user-defined formats, 54
انواع تعریف‌شده توسط User
همچنین ببینید: data types
V
Val function, 52
متغیرها
Declaration صریح, 14–15
متغیرهای Global, 15, 17
Declaration ضمنی, 14
متغیرهای Local, 15–16
متغیرهای سطح Module, 16
تداخل نام, 17
مرور کلی, 13–14
Scope و Lifetime, 15
shadowing, 17
strict متغیرها, 17
انواع تعریف‌شده توسط User, 24–25
همچنین ببینید: constants; data types
variants, 18–19
مقادیر Date/Time ذخیره‌شده در, 19
مقدار Empty, 19
مقدار Null, 19–20
VarType, 18
VBA
به‌عنوان زبان Object-oriented, 7
استفاده از in Ribbonها, 138–140
استفاده از روی Formها, 111
استفاده از روی Reportها, 120
VBE. See Visual Basic Editor
Version, 201
Visible property, 205
Visual Basic Editor, 4–6
W
WAV files, 263
Weekday function, 62
While..Wend loops, 42–43
X
Xor operator, 78–79
Y
Year function, 61

امتیاز کاربران به این مقاله

☆☆☆☆☆

0 نفر امتیاز داده اند. میانگین: 0.0 از 5

 

0 نظر

نظر محترم شما در مورد مقاله های وب سایت برنامه نویسی و پایگاه داده

نظرات محترم شما در خدمات رسانی بهتر ما را یاری می نمایند. لطفا اگر مایل بودید یک نظر ما را مهمان فرمائید. آدرس ایمیل و وب سایت شما نمایش داده نخواهد شد.

0 / 500