Click here to Skip to main content
15,908,776 members
Home / Discussions / C#
   

C#

 
GeneralRe: Control to display web pages in my winforms app? Pin
matthias s.23-Jun-04 6:22
matthias s.23-Jun-04 6:22 
GeneralRe: Control to display web pages in my winforms app? Pin
LongRange.Shooter23-Jun-04 8:48
LongRange.Shooter23-Jun-04 8:48 
QuestionSmart client template solution ??? Pin
gicio23-Jun-04 0:40
gicio23-Jun-04 0:40 
AnswerRe: Smart client template solution ??? Pin
LongRange.Shooter23-Jun-04 4:12
LongRange.Shooter23-Jun-04 4:12 
GeneralFile Path's question Pin
jzb23-Jun-04 0:32
jzb23-Jun-04 0:32 
GeneralRe: File Path's question Pin
Dave Kreskowiak23-Jun-04 4:26
mveDave Kreskowiak23-Jun-04 4:26 
GeneralRe: File Path's question Pin
Heath Stewart23-Jun-04 5:04
protectorHeath Stewart23-Jun-04 5:04 
GeneralRe: File Path's question Pin
Heath Stewart23-Jun-04 5:12
protectorHeath Stewart23-Jun-04 5:12 
I can't really make sense of your question either, but let me try...

You're saying that the UserControl you've embedded in a web page uses http://localhost to access a file on the server? IF so, ALL content in a browser window that users see - including embedded .NET, ActiveX, and Java controls - run all on the client machine. So http://localhost refers to their machine, which requires that a web server be running. While "localhost" resolves to the 127.0.0.1 IP address that all machines define as themselves (the loopback address), putting http:// requires that they have an HTTP daemon (like IIS or Apache) running on the default HTTP port, which is port 80. Fat chance that all your clients have that.

So, remember that your embedded user control runs client-side. The only access back to the server is the same as any user would have to make: you need to use the fully-qualified URL of the server. Any file paths you use must also be local to their machine.

Above all, you must grant your user control permissions by getting the users to install a code group on their machines. If they don't, your options are none to limited so program accordingly. In .NET 1.0, controls in the Internet zone were not allowed to execute at all. In .NET 1.1 (partly thanks to yours truly), controls in the Internet zone are granted some permissions, but not many. The only file system access is through isolated storage (System.IO.IsolatedStorage). So you have to add a code group (do not change the Internet_Zone group!) that grants your assembly/assemblies the necessary permissions based on host or strong name identity evidence (other types of evidence are not collected by IEExec.exe, the managed host for Internet Explorer).

Read my old article, User Controls for Windows and the Web[^], for more details.

 

Microsoft MVP, Visual C#
My Articles
GeneralMenu and FormBorderStyle = None Pin
23-Jun-04 0:32
suss23-Jun-04 0:32 
QuestionCan we define constructor with arguments in web service. Pin
agarwalv23-Jun-04 0:23
agarwalv23-Jun-04 0:23 
AnswerRe: Can we define constructor with arguments in web service. Pin
Heath Stewart23-Jun-04 4:47
protectorHeath Stewart23-Jun-04 4:47 
GeneralRe: Can we define constructor with arguments in web service. Pin
Anonymous24-Jun-04 18:54
Anonymous24-Jun-04 18:54 
GeneralTrouble getting designer for a component Pin
Simon_uk23-Jun-04 0:17
Simon_uk23-Jun-04 0:17 
GeneralRe: Trouble getting designer for a component Pin
Heath Stewart23-Jun-04 4:36
protectorHeath Stewart23-Jun-04 4:36 
GeneralRe: Trouble getting designer for a component Pin
Simon_uk23-Jun-04 5:33
Simon_uk23-Jun-04 5:33 
Generald Pin
Anonymous22-Jun-04 23:52
Anonymous22-Jun-04 23:52 
GeneralRe: d Pin
eggie523-Jun-04 9:58
eggie523-Jun-04 9:58 
GeneralDiscussion forum Pin
Member 94217022-Jun-04 23:51
Member 94217022-Jun-04 23:51 
GeneralRe: Discussion forum Pin
Colin Angus Mackay23-Jun-04 0:31
Colin Angus Mackay23-Jun-04 0:31 
GeneralIEndPoint Object Pin
dabuskol22-Jun-04 23:49
dabuskol22-Jun-04 23:49 
GeneralRe: IEndPoint Object Pin
Colin Angus Mackay23-Jun-04 0:33
Colin Angus Mackay23-Jun-04 0:33 
GeneralRe: IEndPoint Object Pin
dabuskol23-Jun-04 0:59
dabuskol23-Jun-04 0:59 
GeneralRe: IEndPoint Object Pin
Colin Angus Mackay23-Jun-04 1:19
Colin Angus Mackay23-Jun-04 1:19 
GeneralRe: IEndPoint Object Pin
dabuskol23-Jun-04 1:26
dabuskol23-Jun-04 1:26 
GeneralRe: IEndPoint Object Pin
Heath Stewart23-Jun-04 4:24
protectorHeath Stewart23-Jun-04 4:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.