Přidat otázku mezi oblíbenéZasílat nové odpovědi e-mailem C# ASP.NET Class - problém s funkčností třídy

Classes you add will not have any connection to the HttpContext, i.e they will not have access to things like Request, Response, Session and Server.
If the method is called when a request is in progress, you will be able to access Server using

HttpContext.Current.Server


A better approach though is that you add the target folder as a method argument and create the path from that. That way, the class will be usable in non-web contexts as well.
public void CreateFile(string[] PR,string targetfolder)
http://forums.asp.net/t/1140104.aspx/1

Reakce na odpověď

1 Zadajte svou přezdívku:
2 Napište svou odpověď:
3 Pokud chcete dostat ban, zadejte libovolný text:

Zpět do poradny