|
Hi all,
Does SiteMapNode property 'Roles' must provide for each Node those contain childNode ?
Because of if I do not add 'Roles' at SiteMapNode and set securityTrimmingEnabled="true" at webconfig.
Some SiteMapNodes those have childNode are not showing in menu.
Is there any way to show menu without provide 'Roles' to each SiteMapNode and just show menu as Admin user have defined Access rule for particular Role?
My purpose is when admin user create new Role and Access rule I don't want to manually add that new Role in sitemap file.
Thanks to all
|
|
|
|
|
while Redirect the page, Page_Load is not calling after hosting the application to IIS. when using the visual studio is calling ... i made like these..
Base class which has inherit Page
public partial class BasePage: Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
}
Our page Inherit BasePage
public partial class MainPage : BasePage
{
protected void Page_Load(object sender, EventArgs e)
{
}
}
Now calling from Another page
Response.Redirect(MainPage.aspx)
The Mainpage calss Page_Load is calling whilw running Visualstudio app. But after hosting to the IIS The Page_Load is not called
Please help me
Thanks
|
|
|
|
|
Something needs to trigger for this redirect to take place. Maybe you can have a javascript that this code inside page_load? Hope this makes sense.
|
|
|
|
|
Hello all,
I am trying to get the file path which I choose to upload. I mean the value of the textbox of the file upload control. With this code:
fUploadcheckpayment.PostedFile.FileName I just only get the file name not the path. I tried
Server.MapPath(fUploadcheckpayment.FileName) and that didnt work either. I get a path of my project. Any ideas how i can do this?
To be more clear what I am trying to do:
When the user uploads a file I rename the file and save it to a folder. After saving it to the folder I want to delete uploaded file from its original source. Such as the user upload the file from its desktop. I save the file to a folder udner C://Folder name. I want to delete the file from the desktop.
modified on Tuesday, April 26, 2011 5:59 PM
|
|
|
|
|
As you are talking about uploading files, I am guessing that this is an asp.net project. If it is you cannot access the users desktop from the brower. It is a security risk. The browser will allow you to read files to upload only. The only way you could achieve this is using flash or a browser plugin that is not constrained but the browsers security sandbox.
Hope this helps.
|
|
|
|
|
Yes it is a ASP.net project. Seems like securty issues preventing me to do this I will search what you have offered thanks for the suggestion though
|
|
|
|
|
|
I tried this but it reads only the file name not the full path
|
|
|
|
|
I think it's not possible since this is a standard security precaution.
Ignorance of the ability brings disability.
|
|
|
|
|
Well seems like it, all my research lead me to the same way.
|
|
|
|
|
VS2010, .NET 3.5 & 4
Not sure if it's an asp.net problem or visual studio itself, but...
URL: /favicon.ico
User: me
Exception Type: System.Web.HttpException
Message: File does not exist.
Stack Trace: at System.Web.StaticFileHandler.GetFileInfo(String virtualPathWithPathInfo, String physicalPath, HttpResponse response)
at System.Web.StaticFileHandler.ProcessRequestInternal(HttpContext context)
at System.Web.DefaultHttpHandler.BeginProcessRequest(HttpContext context, AsyncCallback callback, Object state)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
It can't find the favicon.ico file.
For good reason: it does not exist.
It doesn't exist for a good reason, too: I didn't reference one anywhere in my code, so didn't feel the need to create one.
So why do I keep getting this error? Annoying, since unhandled exceptions get emailed to me.
|
|
|
|
|
Browsers automatically ask for a favicon.ico when they load your page, there is nothing that you can do to stop this.
If it is the error that is bothering you there are only two options. Create a blank favicon.ico file or add a hack to prevent the error when it is a favicon.ico request.
this is a link to the yahoo advice on fav icons.
http://developer.yahoo.com/performance/rules.html#favicon[^]
Just thought, if you are using System.Routing you can add an Ignore route that stops the asp.net handler from trying to work with the favicon file. The should stop the request going though you asp.net pipeline and triggering and unhandled execption alert
|
|
|
|
|
busbyam wrote: Browsers automatically ask for a favicon.ico when they load your page
Ah. I thought that was only IE5.
Thanks
|
|
|
|
|
Hi,
what is the process for moving files over servers.
i have used System.IO class File.Move.
when i am trying to move files i am getting error as (Access to the path is denied).
|
|
|
|
|
The error is a clue: run as an account that has permission to move to the target directory (and permission to delete from the current one, for that matter.)
|
|
|
|
|
have a read of this ASP.NET Impersonate user example[^]
As barmey as a sack of badgers
Dude, if I knew what I was doing in life, I'd be rich, retired, dating a supermodel and laughing at the rest of you from the sidelines.
|
|
|
|
|
hi simon,
i have used this impersonation, but we can only have one impersonated user
in our web.config file.
my problem is i have to move the files through almost five servers, at this point i am getting
the error.
|
|
|
|
|
Can you use the same username password combination for all 5 servers? As all they need to the relevant file access rights
As barmey as a sack of badgers
Dude, if I knew what I was doing in life, I'd be rich, retired, dating a supermodel and laughing at the rest of you from the sidelines.
|
|
|
|
|
Need some advice.
I have been tasked with updating the companies on-line quote system. The main requirement is that now users can enter more than one property and its contents for an insurance quote. Now this can generate potentially quite a bit of data.
Now I'm not sure if I should temporary save the data to the database for each page or look at such things as session objects / view state etc. I have looked at the following article ASP.NET State Management[^].
But for each type of temporary storage (if that is the right terminology for it!) cookies, view state, query string and hidden fields, it states these are for small amounts of information that you need to pass between pages.
Which or what would be the best technique for gathering potentially alot of data from pages? or should I update the database with data from each page?
Thanks
Simon
As barmey as a sack of badgers
Dude, if I knew what I was doing in life, I'd be rich, retired, dating a supermodel and laughing at the rest of you from the sidelines.
|
|
|
|
|
One school of thought would be to "reserve" a quote number at the beginning of the process and use that as reference as you work through the quoting process.
For example: (my system is also a quoting system, requesting price quotes)
(This description is waaay over simplified, but you should get the idea ...)
1) salesman initiates a price quote with basic information: Who and which product. (Save quote and generate an ID).
2) Request can then develop based on additional information being collected, input from other departments etc.
3) Use a status field to determine the "state" of the quote: 100 - initial, 200 - customer service, 300 Mgmt approval, 400 - Approved.
I also use the staus of the quote to fields to read-only so that once someone has approved a section, no one else can change it.
At any point in the process you can save the work you are doing and complete it later.
Seems to work for me.
Good luck.
|
|
|
|
|
Thank you David that has given me a good starting point
As barmey as a sack of badgers
Dude, if I knew what I was doing in life, I'd be rich, retired, dating a supermodel and laughing at the rest of you from the sidelines.
|
|
|
|
|
I got my company to buy the DXperience ASP.NET package and it has made a world of difference in being able to develop really rich browser based applications for our Intranet.
Check out this video show what is going to be soon released. Absolutely amazing. There support forum is really top-notch.
http://tv.devexpress.com/#Asp2011vol1FeaturesSoFar;;3[^]
Good luck with your project.
BTW: I have no financial or other connection to DevExpress, I'm just a very happy customer.
david
|
|
|
|
|
Dear all,
Please help, how to create custom Access Rule page for admin user, that provide assign particular page to particular Role.
Any sample link please?
|
|
|
|
|
The Microsoft has provided variety of tutors on this.
Please check this page[^] for same.
♫ 99 little bugs in the code,
99 bugs in the code
We fix a bug, compile it again
101 little bugs in the code ♫
|
|
|
|
|