|
if (this.Request.QueryString["lang"] == "nl") DoRedirect();
Help people,so poeple can help you.
|
|
|
|
|
Hi Ali! Thank you for your response! Again, not being a programmer, and I'm not too intelligent, but would I put this in a javascript tag in the head of my page? If not, where would I put this code you offered? Thanks again!
Jason Weber
http://on.fb.me/JasonPWeber
|
|
|
|
|
add it to Page.Init handler (wait a minute, are you a VB guy ?)
use this
if Me.Request.QueryString("lang") = "nl" Then DoRedirect()
Help people,so poeple can help you.
|
|
|
|
|
Ali, I'm not a programmer at all, but my company is small and I cannot afford to hire one. So I just researched a lot on the internet and made this site in VB. I have a C# to VB converter. So I will look for the Page Init command. It's probably in my BasePage.vb file. I'm learning, though, and it's generous people like you who are helping me do this! Thanks again!
Jason Weber
http://on.fb.me/JasonPWeber
|
|
|
|
|
Ali, where would I put the code you suggested:
if Me.Request.QueryString("lang") = "nl" Then DoRedirect()
??
Jason Weber
http://on.fb.me/JasonPWeber
|
|
|
|
|
in the code behind file select in the first combo box 'Page events' and the other 'Init' then you can add my code inside the resulting function.
if you failed to do this please give me your code so i can fix it.(sennd it to ali.alomairi@hotmail.com)
Help people,so poeple can help you.
|
|
|
|
|
Hello Ali. Did you get my message? I sent it to your e-mail ....
Jason Weber
http://on.fb.me/JasonPWeber
|
|
|
|
|
yes, and i am working on it.
Help people,so poeple can help you.
|
|
|
|
|
Thank you so much, one again, for your kindness, Ali. Please take your time; without people like you, I would have never gotten this done. Almost all of my code is taken from Developing an ASP.NET page with MasterPage and Localization[^] right here in Code Project. I cannot thank you enough, and if there is ever anything I can do for you, please let me know!
Jason Weber
http://on.fb.me/JasonPWeber
|
|
|
|
|
hey guys,
I'm developing an ASP web application and i need to run it on another computer. computers are connected to the same LAN.
How can I do that?
|
|
|
|
|
ASP.NET web application are run within IIS which servers requests for resources from that web application to clients. You make a request in your web browser for the page, just like you did when posting this question. You didn't need to have Code Project installed on your machine.
No comment
|
|
|
|
|
I configured IIS 7 but still it can't run my application on a remote computer.
|
|
|
|
|
Need a lot more details. It is pretty simple. Setup a new site in IIS, then from the other computer open IE and browser to http://[servername]/[sitename]. Sounds like you might need training on IIS.
|
|
|
|
|
That's the issue, I try that path but the distant computer take time to respond then displays a timeout error, so I think it works but there is just that issue with reponse time.
|
|
|
|
|
What is the exact error? Is it a SQL timeout or an http timeout?
|
|
|
|
|
Right click on site in IIS and click "Browse", if the site's default page opens up, configuration is OK and problem might be with network. And if some problem with site configuration is there, it will show you proper error details.
|
|
|
|
|
You can use IP Address or Computer name of that computer to achieve the same.
First of all deploy your application to your computer's IIS.
Then if required, then disable your firewall.
now you can access the web application from LAN computers using the URL given below:
http://[ComputerName OR IP]/[WebAppName]
I hope, this will help you out.
|
|
|
|
|
Hi... I am creating search function in my web. I create a dropdownlist, textbox and button. This is my code:
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="true"
OnSelectedIndexChanged="DropDownList1_SelectedIndexChanged">
<asp:ListItem></asp:ListItem>
<asp:ListItem Value="Pelanggan Rumah"></asp:ListItem>
<asp:ListItem Value="Kios Air"></asp:ListItem>
</asp:DropDownList>
<asp:TextBox ID="CariText" runat="server" Width="100px" Height="23px" CssClass="text_boxt_search"></asp:TextBox>
<asp:Button ID="Find" runat="server" Text="Search" Width="61px" CssClass="style105" Height="25px" />
<asp:SqlDataSource ID="SqlDataSourceCustomer" runat="server"
ConnectionString="<%$ ConnectionStrings:ATBGISMAPDBConnectionString %>"
SelectCommand="SELECT * FROM [DBCUSTOMER] WHERE ([CUST_NAME] LIKE '%' + @CUST_NAME + '%')">
<SelectParameters>
<asp:ControlParameter ControlID="CariText" Name="CUST_NAME" PropertyName="Text" Type="String" />
</SelectParameters>
</asp:SqlDataSource>
<asp:SqlDataSource ID="SqlDataSourceKiosk" runat="server"
ConnectionString="<%$ ConnectionStrings:ATBGISMAPDBConnectionString %>"
SelectCommand="SELECT * FROM [KIOSK] WHERE ([Cust_Name] LIKE '%' + @Cust_Name + '%')">
<SelectParameters>
<asp:ControlParameter ControlID="CariText" Name="Cust_Name" PropertyName="Text" Type="String" />
</SelectParameters>
</asp:SqlDataSource>
And this in the controller:
Public Sub DropDownList1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles DropDownList1.SelectedIndexChanged
Dim strConnect As String = Nothing
strConnect = Session("Data Source=192.168.1.88;Initial Catalog=ATBGISMAPDB;Persist Security Info=True;User ID=gis;Password=Pa5word@tb")
Dim a As String = "SqlDataSourceCustomer"
Dim b As String = "SqlDataSourceTank"
Dim c As String = "SqlDataSourceKiosk"
Dim d As String = "Pipa"
If DropDownList1.SelectedItem.Value = a Then
Query = "SELECT * FROM DBCUSTOMER where a = '" & LabelDDL.Text & "'"
ElseIf DropDownList1.SelectedItem.Value = c Then
Query = "SELECT * FROM KIOSK where c = '" & LabelDDL.Text & "'"
End If
End Sub
But the script not can yet working i mean. Do Anyone can help me?
|
|
|
|
|
Maybe you'd like to tell us what, specific, part of this not can yet working.
No comment
|
|
|
|
|
You have to databind() again. It looks like you are just changing some variable named Query. But then what? Do you databind()?
|
|
|
|
|
Rad Dock has Property Of Drag and Drop on Rad dock zone i Want to stop Movement of it
|
|
|
|
|
Contact the author.
"If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." Red Adair.
nils illegitimus carborundum
me, me, me
|
|
|
|
|
Hi,
I have a gridview bound to the database(columns - price, units,total) . I have a option to edit the row. On change of the value while editing I need to do some calculation based on the the value entered and update another textbox/label in the same row ( as well as sum of all the total price in footer row ie. Grand total) without doing any postback. I'm new to javascript. Can anyone help me to achieve this.
Thanks in advance.
|
|
|
|
|
|
I don't think you can do that in JavaScript or Jquery without making a trip back to the server.
If the server binds data from a database and creates a gridview object with the bound data, and then sends it to the browser, the server will expect the same data to return back on postback. If the data changes on the client side, the server will throw an exception saying that the gridview has been tampered with, and you will get the error page. This is a built-in security measure to prevent hacking.
You would have to send the gridview without the data, but with empty cells, and make an Javascript AJAX call to populate the cells, Javascript to edit the cells, and Javascript to write back the cell data, and then just destroy the page when done.
You can use an update panel to make a small async postback to the server for just the gridview, and calculate on the server side. All will be well then.
Edit:
I may be wrong, try out the post above first, but I know for sure on objects like the listbox will do that. Textbox is exempt from validation on the server side, because it's expected to change.
|
|
|
|