|
I have a form with a Gridview, MultiView and Menu control on one aspx page.
Sequence of events:
User selects Gridview record A, multiview displays tab 1 and 2
Tab 1 displays record A data
Tab 2 displays record A data
Gridview record B is selected, multiview displays tab 1 and 2
Tab 1 displays record B data
Tab 2 displays record "A" data (this is the problem)
Each tab is a formview populated via seperate SqlDataSources
Does anyone know why the previous record is being displayed?
Does anyone know how I can trace what is "really" being sent to second SqlDataSource?
My debug watch shows the correct record id but second datasource is not returning the correct record info.
|
|
|
|
|
Hi:
My Problem is:
i'm using microsoft word object library 11.0 in my web site, when I’m debugging the application works fine, my question is, why when i call the site from another machine ,the document doesn’t work, it doesn't throw any exception .
I have mentioned my code below:
object missing = System.Reflection.Missing.Value;
try
{
object fileName = "d://testword.docx";
object readOnly = false;
object isVisible = false;
ApplicationClass oWordApp = new ApplicationClass();
Document oWordDoc = oWordApp.Documents.Open(ref fileName,
ref missing, ref readOnly,ref missing, ref missing, ref missing,
ref missing, ref missing, ref missing, ref missing,ref missing,
ref isVisible, ref missing, ref missing, ref missing);
oWordDoc.Activate();
txtContent.Text = oWordDoc.Content.Text;
}
catch (Exception ex)
{
throw ex;
}
Please kindly give me suggestion to solve this issue.
Thanks & Regards:
Suresh.S
suresh
|
|
|
|
|
How can I prevent users from accessing web pages by typing the url of these pages in the address bar of the browser?
I tried checking for the "REFERER" server variable and if it's null, then redirect the user to the home page..but this actually prevents pop up pages from being displayed for the user when he clicks on a link to access another page.
Is there any other way to achieve this?
|
|
|
|
|
One way is to use authentication, but that forces the user to login. A user that is not authenticated will be automatically redirected to the login page.
Good or bad? Your choice.
Another way is to have an "entry page" for the users and use server.transfer instead of "response.redirect" when you refer them to the next page. That way they won't find out what the other pages are.
|
|
|
|
|
Well, I won't be able to do the first suggestion.
But, could you explain in more details the second solution. What do you mean "entry page"??
I know the server.transfer method, but I'm not quite sure how to use it in this second solution?
thanks in advance
|
|
|
|
|
With "entry page" I mean a page with choices for the user, or links to other pages, or the home page you would have referred the user to.
If this page is called "Index.aspx" and the user clicks on the link "Results" which refers to "Results.aspx",
the user would still see "Index.aspx" in the address bar if you use server.transfer instead of response.redirect.
And therefore the users will not know that "Results.aspx" exists.
|
|
|
|
|
I see, thanks. But what if he somehow knew that Results.aspx exists, how can I prevent him from accessing it by typing the url in the address bar?
|
|
|
|
|
Well, you could check the value of request.path or request.filepath.
|
|
|
|
|
Is there anything else I could do..checking for every requested path is going to be hard, since I have lots of pages in my project!!
Please, is there any other suggestion?
|
|
|
|
|
How about putting a check for Request.CurrentExecutionFilePath = Request.FilePath in a masterpage, that's one place!
|
|
|
|
|
And then what?
It's going to be the same as the typed url he enters and he'll still have access to the page.
|
|
|
|
|
If the user has typed the url himself it should be the same.
If you have used used server.transfer it should not be the same.
|
|
|
|
|
hi,
Im trying to use AjaxControlToolkit CascadingDropDown but Im always getting Method error 500
can anyone help PLEEEEEAASSEEE?
this is the html section:
<asp:dropdownlist id="ddlStation" runat="server" xmlns:asp="#unknown">
<cc1:cascadingdropdown id="CascadingDropDown1" runat="server" targetcontrolid="ddlStation" prompttext="Please select Station" xmlns:cc1="#unknown">
ServiceMethod="GetOnlyStations" ServicePath=service.asmx Category="category">
and this is the Web service
[WebMethod]
public AjaxControlToolkit.CascadingDropDownNameValue[] GetOnlyStations(string knownCategoryValues, string category)
{
List<ajaxcontroltoolkit.cascadingdropdownnamevalue> values =
new List<ajaxcontroltoolkit.cascadingdropdownnamevalue>();
return values.ToArray();
}
modified on Tuesday, November 4, 2008 3:01 AM
|
|
|
|
|
How to alter the connection string in web.config programmatically?
Thanks in Advance.
|
|
|
|
|
You can programatically open the configuration with using the System.configuration namespace:
Configuration myConfig = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
Then you can access the connection strings collection at:
myConfig.ConnectionStrings.ConnectionStrings
You can modify the collection however you want, and when done call .Save() on the configuration object.
Errors are like Mini Skirts, shorter they get, more revealing they become.
|
|
|
|
|
hi
i have a manually binded GridView with sorting and editing enabled.
my problem is with editing columns after sorting them, as the newEditIndex property in the GridView RowEditing event is a reflection of the data from the db and not the dataview that have been set on the gridview Sorting event, the outcome is that when pressing the edit button on a row after sorting, a different row in getting in to edit mode.
if any one know the solution please in light me...:}
tnx
j
|
|
|
|
|
In the sorting event you could set the editindex = -1 and then let the edit button do it's thing.
Use the OnRowEditing even and some similar code in that function possibly?
GridView grdView = sender as GridView;
grdView.EditIndex = e.NewEditIndex;
//Rebind grid here...
Revolutionary: Disk drives go round and round.
|
|
|
|
|
i think that as long you are not in edit mode the editIndex will always will be -1?
I've solved it by saving the sorting definitions (the expression and direction) in a Session object and retrieved the data with an "ORDER BY" clause giving it these parameters...
thanks
j
|
|
|
|
|
Yes, sorry. I misread the question.
Glad you got it worked out!
Revolutionary: Disk drives go round and round.
|
|
|
|
|
Hi,
I am trying to call a .Net class from flex by using third party tool
webORB , i installed weborb,i created a project having reference to
this webORB virtual directory created automatically , i gone through
all the security issues and devlopement and deployment process, but
when i run my application it is works fine.
But when i Exports Release Build, i get error:
faultCode:Client.Error.MessageSend faultString:'Send failed'
faultDetail:'Channel.Security.Error error Error #2048: Security
sandbox violation: http://localhost/test12/testweborb.swf cannot load
data from https://localhost/test12/weborb.aspx. url: 'https://
localhost/test12/weborb.aspx''
giving error like this.
I copied crossdomain.xml to root url , but still i am getting this error .
this is my crossdomain.xml file :
<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "
http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
<site-control permitted-cross-domain-policies="by-content-type" />
<allow-access-from domain="localhost" to-ports="*" secure="false" />
<allow-access-from domain="*" to-ports="*" secure="false"/>
</cross-domain-policy>
i use RemoteObject API and weborb.dll to get/put data from client-server and i have included some file *.swc (Flex Library Project)
Please see: http://www.gis.net.vn
Please can anybody help me.
Thanks,
|
|
|
|
|
Hi,
Can anyone please provide solution for this one..The error is as follows..
Unable to start debugging on the web server. The server does not support debugging of ASP.NET or ATL Server applications. Click help for more information on how to enable debugging.
you may also want to refer to the ASP.NET and ATL Server debugging topic in the online documentation.
|
|
|
|
|
Hi all,
I am working in authentication process of my project. I want to know whether their is any concept or arch. or technology is available, that in msn messenger or in yahoo messenger having security feature- if the two user know a password and id. but one can only use the id at a time, if other one try to logging in means it will automatically show that user already logged.
Is any technology/concept is available now?
Thanks in advance
with regards,
Senthil.S
A Software Engineer
|
|
|
|
|
I have also also handled the same type of situation.I used SQL server for it.When a user logged in by a ID,I make a entry in DB,whenever any user try to log in ,it first check whether there is any entry to corresponding ID in DB,if yes,then showing the message the user is already logged in.
Cheers!!
Brij
|
|
|
|
|
If session mode is inproc then session values stored in server. I need to see the physical path of the session stored in server for some security resons.
smile
|
|
|
|
|
Sankar Komma wrote: I need to see the physical path of the session stored in server for some security resons
No you don't.
Besides, AFAIK it is stored in memory.
|
|
|
|