קובץ מסוג aspx.cs

yossikz

New member
קובץ מסוג aspx.cs

בסביבת הסטודיו 2003 בדף חדש שפתחתי משום מה אני לא מקבל את הקובץ בסיומת aspx.cs מה השתבש ואיך מתקנים את התקלה
 

adam222

New member
האם יש לך שרת IIS

אם לא, אתה צריך להתקין ואז לעדכן את הסטודיו אם יש לך, אתה צריך להריץ קובץ מתוך ה-Framework aspnet_regiis -i
 

yuval k

New member
למה אתה מתכוון ב"משום מה אני לא

מקבל את הקובץ בסיומת aspx.cs"?
 

yossikz

New member
מקובץ קודם

תהליך מסויים שבצעתי לפי הכתובת http://www.c-sharpcorner.com//Database/GDWalkThroughACNov132001.asp בשלב Setting the DataSource property alone will not bind dvProd to DataGrid1. We have to add some code to do the binding. We have to fill the DataSet and bind the DataGrid at runtime. Since these two steps usually comes together, putting them in a BindGrid() method is a good idea. Add the following code in WebForm1.aspx.cs as shown. נתנה את הקובץ עם הסיומת aspx.cs והיום לא קבלתי את הקובץ השני
 

yossikz

New member
בבדיקה נוספת מתברר

בספריה אני רואה שהקבצים קיימים (WebForm1.aspx.cs WebForm1.aspx). אבל הם אינם מוצגים בחלון של solution explorer איך מציגים אותם בחלון של solution explorer ?
 

yuval k

New member
ה-code behind לא מוצג בצורה נפרדת

ב-Solution Explorer, אתה יכול לעבור אליו דרך תפריט View (גם כתוב שם קיצור הדרך מהמקלדת - אצלי זה F7).
 

yossikz

New member
גם אני חשבתי כך

גם אני חשבתי כך אבל המציאות היא שונה זה לא מוצג ב Solution Explorer
 

gilad g

New member
יש כפתור ב-Solution Explorer

שקוראים לו "Show all files". אחרי שאתה לוחץ עליו, ליד ה-ASPX שלך אמור להיות פלוס כזה... תלחץ על הפלוס ותראה את ה-aspx.cs
 

yossikz

New member
למה השגיאה

לא ברורה לי השגיאה לגבי הרשאה. לגבי פתיחת הקובץ איך אני בודק שמישהו אחר לא מחזיק בקובץ ? להלןתיאור השגיאה
Server Error in '/WebTest2' Application. --------------------------------------------------------------------- ‏‏למנגנון מסד הנתונים Jet של Microsoft אין אפשרות לפתוח את הקובץ 'C:\Inetpub\wwwroot\fpdb\Northwind.mdb'. הקובץ פתוח כבר באופן בלעדי על-ידי משתמש אחר, או שדרושה לך הרשאה כדי להציג את נתוני הקובץ. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Data.OleDb.OleDbException: ‏‏למנגנון מסד הנתונים Jet של Microsoft אין אפשרות לפתוח את הקובץ 'C:\Inetpub\wwwroot\fpdb\Northwind.mdb'. הקובץ פתוח כבר באופן בלעדי על-ידי משתמש אחר, או שדרושה לך הרשאה כדי להציג את נתוני הקובץ. Source Error: Line 26: public void BindGrid() Line 27: { Line 28: cmdProd.Fill(dsProd1, "Products"); Line 29: DataGrid1.DataBind(); Line 30: } Source File: c:\inetpub\wwwroot\webtest2\webform1.aspx.cs Line: 28
 
למעלה