المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : مشكل حفظ الاكسيل في الاتوبلاي


تواتي كريم
25-05-2014, 07:18 PM
السلام عليكم ورحمة الله وبركاته
لدي مشكل وهو :
عند فتح ملف الاكسيل من داخل الاتوبلاي و التعديل عليه و حفظه ثم الخروج من التجميعية ثم العودة اليها نجد ان التعديل لم يحفظ على الملف
اين يكمن المشكل ؟

ثامر أبو بلقيس
25-05-2014, 08:12 PM
السلام عليكم ورحمة الله وبركاته
في الاوتوبلاي عند تصدير المشروع لو كان الصيغة التي اخترناها WEB/Email executable
يصبح الملف ملف واحد تنفيذي " ذو حجم لا يمكن تغيره " وبالتالي اذ قمنا بالكتابة في الايكسل لن يتم الحفظ
لأن الحجم مغلق إن صح التعبير الا في حالة اذا كانت القراءة تتم من استدعاء لملف مزروع في الجهاز
--- سيكون شبه حل لو نختار حفظ المشروع بصيغة hard drive folder
هنا يمكن المشروع يكون مفتوح لاستقبال محتويات أو بيانات لداخل مجلداته
وللحديث عن الايكسل
1 - نزود التجميعية بفتح ملف الايكسل في عنصر الويب --- و الاكواد متوفرة الان ----
أعيد كتابتها لتزرع عند دخول التجميعية :
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Word.Document.8","BrowserFlags","2147483684",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Word.RTF.8","BrowserFlags","2147483684",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Word.Document.12","BrowserFlags","2147483684",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Word.DocumentMacroEnabled.12","BrowserFlags","2147483684",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Excel.Sheet.8","BrowserFlags","2147486208",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Excel.Sheet.12","BrowserFlags","2147486208",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Excel.SheetMacroEnabled.12","BrowserFlags","2147486208",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\Excel.SheetBinaryMacroEnabled.1 2","BrowserFlags","2147486208",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\PowerPoint.Show.8","BrowserFlags","2147483808",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\PowerPoint.Show.12","BrowserFlags","2147483808",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\PowerPoint.ShowMacroEnabled.12","BrowserFlags","2147483808",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\PowerPoint.SlideShow.8","BrowserFlags","2147483808",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\PowerPoint.SlideShow.12","BrowserFlags","2147483808",REG_DWORD);
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Classes\\PowerPoint.SlideShowMacroEnable d.12","BrowserFlags","2147483808",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\Shell\\AttachmentExe cute\\{0002DF01-0000-0000-C000-000000000046}","PowerPoint.Show.12","hex(0)",REG_BINARY);
Registry.SetValue(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\Shell\\AttachmentExe cute\\{0002DF01-0000-0000-C000-000000000046}","Excel.Sheet.12","hex(0)",REG_BINARY);
Registry.SetValue(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\Shell\\AttachmentExe cute\\{0002DF01-0000-0000-C000-000000000046}","Word.Document.12","hex(0)",REG_BINARY);
Registry.SetValue(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\Shell\\AttachmentExe cute\\{0002DF01-0000-0000-C000-000000000046}","Excel.Sheet.8","hex(0)",REG_BINARY);
Registry.SetValue(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\Shell\\AttachmentExe cute\\{0002DF01-0000-0000-C000-000000000046}","Word.Document.8","hex(0)",REG_BINARY);
Registry.SetValue(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows\\Shell\\AttachmentExe cute\\{0002DF01-0000-0000-C000-000000000046}","PowerPoint.Show.8","hex(0)",REG_BINARY);

و للتراجع عما سبق وجب زرع هذه القيمة عند الخروج من التجميعية في حدث مناسب :
Registry.DeleteKey(HKEY_CURRENT_USER, "Software\\Microsoft\\Windows\\Shell\\AttachmentExe cute\\{0002DF01-0000-0000-C000-000000000046}");
2 - نزود التجميعية بخفض مستوى الامان للايكسل عند دخولها
بالنسبة للاصدار 2003
--abou_belkiss... Security EXCEL2003
Registry.SetValue(HKEY_LOCAL_MACHINE,"SOFTWARE\\Microsoft\\Office\\11.0\\Excel\\Security","Level","1",REG_DWORD);
بالنسبة للاصدار 2010 :
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security","DataConnectionWarnings","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security","AccessVBOM","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security","VBAWarnings","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security","","",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location0","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location0","Path","C:\\Program Files\\Microsoft Office\\Office12\\XLSTART\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location0","Description","3",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location1","Path","%APPDATA%\\Microsoft\\Excel\\XLSTART",REG_EXPAND_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location1","Description","4",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location2","Path","%APPDATA%\\Microsoft\\Templates",REG_EXPAND_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location2","Description","5",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location3","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location3","Path","C:\\Program Files\\Microsoft Office\\Templates\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location3","Description","6",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location4","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location4","Path","C:\\Program Files\\Microsoft Office\\Office12\\STARTUP\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location4","Description","7",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location5","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location5","Path","C:\\Program Files\\Microsoft Office\\Office12\\Library\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\14.0\\Excel\\Security \\Trusted Locations\\Location5","Description","12",REG_SZ);
بالنسبة للاصدار 2007 :
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security","DataConnectionWarnings","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security","AccessVBOM","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security","VBAWarnings","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security","","",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location0","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location0","Path","C:\\Program Files\\Microsoft Office\\Office12\\XLSTART\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location0","Description","3",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location1","Path","%APPDATA%\\Microsoft\\Excel\\XLSTART",REG_EXPAND_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location1","Description","4",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location2","Path","%APPDATA%\\Microsoft\\Templates",REG_EXPAND_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location2","Description","5",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location3","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location3","Path","C:\\Program Files\\Microsoft Office\\Templates\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location3","Description","6",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location4","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location4","Path","C:\\Program Files\\Microsoft Office\\Office12\\STARTUP\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location4","Description","7",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location5","AllowSubFolders","1",REG_DWORD);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location5","Path","C:\\Program Files\\Microsoft Office\\Office12\\Library\\",REG_SZ);
Registry.SetValue(HKEY_CURRENT_USER,"SOFTWARE\\Microsoft\\Office\\12.0\\Excel\\Security \\Trusted Locations\\Location5","Description","12",REG_SZ);


طبعا بعد ما تضاف لهم ما تعلق بــالاصدار 2013 توضع أكواد خفظ مستوى الامان مع بعض عند دخول التجميعية
لتتعامل مع كل الاصدارات
و تتراجع بعكس القيم من 1 إلى 0 عند خروج التجميعية في حدث مناسب
3- نجعل صفحة الايكسل في حد ذاتها تحفظ تلقائيا البيانات بمجرد إغلاقها وذلك بالدخول للتعليمات البرمجية
للايكسل اضغط على ThisWorkbook ازرع الكود التالي :
Private Sub Workbook_BeforeClose(Cancel As Boolean)
ThisWorkbook.Save
End Sub
4- صدر المشروع كما اتفقنا بصيغة فولدر
5 - اجعل البرنامج مسؤولا
هذا ما دار في ذهني ريثما يفيدك الزملاء أكثر :abc_138:
لم أبخل بشيء أخي كريم موفق

تواتي كريم
26-05-2014, 12:51 AM
السلام عليكم ورحمة الله وبركاته
في الاوتوبلاي عند تصدير المشروع لو كان الصيغة التي اخترناها web/email executable
يصبح الملف ملف واحد تنفيذي " ذو حجم لا يمكن تغيره " وبالتالي اذ قمنا بالكتابة في الايكسل لن يتم الحفظ
لأن الحجم مغلق إن صح التعبير الا في حالة اذا كانت القراءة تتم من استدعاء لملف مزروع في الجهاز
--- سيكون شبه حل لو نختار حفظ المشروع بصيغة hard drive folder
هنا يمكن المشروع يكون مفتوح لاستقبال محتويات أو بيانات لداخل مجلداته
وللحديث عن الايكسل
1 - نزود التجميعية بفتح ملف الايكسل في عنصر الويب --- و الاكواد متوفرة الان ----
أعيد كتابتها لتزرع عند دخول التجميعية :
registry.setvalue(hkey_local_machine,"software\\classes\\word.document.8","browserflags","2147483684",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\word.rtf.8","browserflags","2147483684",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\word.document.12","browserflags","2147483684",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\word.documentmacroenabled.12","browserflags","2147483684",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\excel.sheet.8","browserflags","2147486208",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\excel.sheet.12","browserflags","2147486208",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\excel.sheetmacroenabled.12","browserflags","2147486208",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\excel.sheetbinarymacroenabled.1 2","browserflags","2147486208",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\powerpoint.show.8","browserflags","2147483808",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\powerpoint.show.12","browserflags","2147483808",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\powerpoint.showmacroenabled.12","browserflags","2147483808",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\powerpoint.slideshow.8","browserflags","2147483808",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\powerpoint.slideshow.12","browserflags","2147483808",reg_dword);
registry.setvalue(hkey_local_machine,"software\\classes\\powerpoint.slideshowmacroenable d.12","browserflags","2147483808",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\windows\\shell\\attachmentexe cute\\{0002df01-0000-0000-c000-000000000046}","powerpoint.show.12","hex(0)",reg_binary);
registry.setvalue(hkey_current_user,"software\\microsoft\\windows\\shell\\attachmentexe cute\\{0002df01-0000-0000-c000-000000000046}","excel.sheet.12","hex(0)",reg_binary);
registry.setvalue(hkey_current_user,"software\\microsoft\\windows\\shell\\attachmentexe cute\\{0002df01-0000-0000-c000-000000000046}","word.document.12","hex(0)",reg_binary);
registry.setvalue(hkey_current_user,"software\\microsoft\\windows\\shell\\attachmentexe cute\\{0002df01-0000-0000-c000-000000000046}","excel.sheet.8","hex(0)",reg_binary);
registry.setvalue(hkey_current_user,"software\\microsoft\\windows\\shell\\attachmentexe cute\\{0002df01-0000-0000-c000-000000000046}","word.document.8","hex(0)",reg_binary);
registry.setvalue(hkey_current_user,"software\\microsoft\\windows\\shell\\attachmentexe cute\\{0002df01-0000-0000-c000-000000000046}","powerpoint.show.8","hex(0)",reg_binary);

و للتراجع عما سبق وجب زرع هذه القيمة عند الخروج من التجميعية في حدث مناسب :
registry.deletekey(hkey_current_user, "software\\microsoft\\windows\\shell\\attachmentexe cute\\{0002df01-0000-0000-c000-000000000046}");
2 - نزود التجميعية بخفض مستوى الامان للايكسل عند دخولها
بالنسبة للاصدار 2003
--abou_belkiss... Security excel2003
registry.setvalue(hkey_local_machine,"software\\microsoft\\office\\11.0\\excel\\security","level","1",reg_dword);
بالنسبة للاصدار 2010 :
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security","dataconnectionwarnings","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security","accessvbom","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security","vbawarnings","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security","","",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location0","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location0","path","c:\\program files\\microsoft office\\office12\\xlstart\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location0","description","3",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location1","path","%appdata%\\microsoft\\excel\\xlstart",reg_expand_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location1","description","4",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location2","path","%appdata%\\microsoft\\templates",reg_expand_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location2","description","5",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location3","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location3","path","c:\\program files\\microsoft office\\templates\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location3","description","6",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location4","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location4","path","c:\\program files\\microsoft office\\office12\\startup\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location4","description","7",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location5","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location5","path","c:\\program files\\microsoft office\\office12\\library\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\14.0\\excel\\security \\trusted locations\\location5","description","12",reg_sz);
بالنسبة للاصدار 2007 :
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security","dataconnectionwarnings","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security","accessvbom","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security","vbawarnings","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security","","",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location0","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location0","path","c:\\program files\\microsoft office\\office12\\xlstart\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location0","description","3",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location1","path","%appdata%\\microsoft\\excel\\xlstart",reg_expand_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location1","description","4",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location2","path","%appdata%\\microsoft\\templates",reg_expand_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location2","description","5",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location3","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location3","path","c:\\program files\\microsoft office\\templates\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location3","description","6",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location4","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location4","path","c:\\program files\\microsoft office\\office12\\startup\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location4","description","7",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location5","allowsubfolders","1",reg_dword);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location5","path","c:\\program files\\microsoft office\\office12\\library\\",reg_sz);
registry.setvalue(hkey_current_user,"software\\microsoft\\office\\12.0\\excel\\security \\trusted locations\\location5","description","12",reg_sz);


طبعا بعد ما تضاف لهم ما تعلق بــالاصدار 2013 توضع أكواد خفظ مستوى الامان مع بعض عند دخول التجميعية
لتتعامل مع كل الاصدارات
و تتراجع بعكس القيم من 1 إلى 0 عند خروج التجميعية في حدث مناسب
3- نجعل صفحة الايكسل في حد ذاتها تحفظ تلقائيا البيانات بمجرد إغلاقها وذلك بالدخول للتعليمات البرمجية
للايكسل اضغط على thisworkbook ازرع الكود التالي :
private sub workbook_beforeclose(cancel as boolean)
thisworkbook.save
end sub
4- صدر المشروع كما اتفقنا بصيغة فولدر
5 - اجعل البرنامج مسؤولا
هذا ما دار في ذهني ريثما يفيدك الزملاء أكثر :abc_138:
لم أبخل بشيء أخي كريم موفق

شكرا اخي ابو بلقيس على سرعة الاستجابة و الافادة و دمت ذخرا لنا و منك ان شاء الله نتعلم