|
This you can check in the when you are bindind the datagrid again after the deletion. Check for the condition and if true reduce the page to previous one.
Best Regards,
Apurva Kaushal
|
|
|
|
|
hey there,
use the following code after deleting ....this will solve your problem
dt is the datatable for binding grid (datasource actually)
Dim currentindex = DATAGRID.CurrentPageIndex
If dt.Rows.Count > 0 Then
If DATAGRID.CurrentPageIndex > 0 Then
If dt.Rows.Count / currentindex = DATAGRID.PageSize Then
DATAGRID.CurrentPageIndex = currentindex - 1
End If
DATAGRID.Visible = True
DATAGRID.DataSource = dt
DATAGRID.DataBind()
Else
DATAGRID.Visible = True
DATAGRID.DataSource = dt
DATAGRID.DataBind()
End If
Else
lblError.Visible = True
lblError.Font.Bold = True
lblError.Text = "No records exists"
DATAGRID.Visible = False
End If
|
|
|
|
|
hi use this code
Datagrid1.currentpageindex=0
rggards
saravanan

|
|
|
|
|
Hello All,
Help me for one code.
I'm using web form pages in conjuction with master pages. I'm facing some problem.
Let me know first, whenever I'm using webform & looks results in IE browser it shows form id
as 'aspnetForm'. can I change it.
Regards
Balasaheb
-- modified at 23:50 Wednesday 22nd November, 2006
-- modified at 23:51 Wednesday 22nd November, 2006
Balasaheb
Software Developer
Platform: Asp.net,vb.net
Database: SQL Server 2000
|
|
|
|
|
Good Morning,
I'm developing web application in c#.NET.
I have two tables on a webpage out of which I have print button on one table and i want to take print out of that table only .
using window.print() of javascript i got print of
complete page but i have to take print out of only that table that have print button on it.
So please tell some way to achieve this functionality.
Thank you.
yog
hui gfgh kgdgrt njjn hjgkn
|
|
|
|
|
Hi
Use CSS to format your page differently when printing
By including a section similar to below (in the page Head section or css file) for printing/print preview and wrapping the section you do not want to print in a DIV with a corresponding ID
<style type="text/css">
@media print{
html {height:auto;}
body {height:auto;width:100%;}
div#content {display: none;}
}
</style>
<DIV ID="content"> Hidden BLAH </DIV>
when the user Prints, does Print Preview or you initiate Print from Javascript, this CSS formatting will be used.

|
|
|
|
|
I am trying to understand how YouTube and Google convert the videos into Flash videos.
If I were to create a similiar website (using .Net), how would I convert the uploaded videos into Flash video?
Also, How can I make sure that the system is resilient and robust in uploading large files. What should I remember when designing such applications.
I will be using FileUpload web control in my application.
Thanks
|
|
|
|
|
Here is the solution
http://www.all4dotnet.com/[^]
Try Media Manager Pro, it can convert almost all videos one format to another in .net.
Moreover, it can grab thumbnails from videos or post watermark on videos in .net.
--------------------
Warm Regards
--------------------
Rashid Javed Ansari
Web Developer
Silicon World
New Delhi
|
|
|
|
|
Sounds difficult, but anybody knows some free hosting providers in order to deploy over a real enviroment?
keep Learning and you never will be out of date...
|
|
|
|
|
I'm not familiar with them, but a quick search came up with this:
Free web hosting with ASP.NET 2.0, SQL Server express and MS Access
www.aspspider.com
|
|
|
|
|
|
Hi..
Could any one explain to me what are site maps?
Could any one lead me to an example?
How can I design a sitemap for general users(not only for google,Yahoo and MSN crawlers)?
I am too late but i will never give up
|
|
|
|
|
|
Essentially a site map is an XML file that contains details of the pages in your website.
If you are using ASP.net 2.0 or Dreamweaver 8 both these utilities offer site map utilities.
"a fool will not learn from a wise man, but a wise man will learn from a fool"
"It is hard to fail, but it is worse never to have tried to succeed." - Theodore Roosevelt
"Success is going from failure to failure without losing your enthusiasm." - Winston Churchill
My Website || My Blog
|
|
|
|
|
Aloha,
What do you do if your ASP.NET app. is hosted somewhere where you don't have access to the eventlog?
I have uploaded my stuff, but now I get this error message:
------------
Server Application Unavailable
The web application you are attempting to access on this web server is currently unavailable. Please hit the "Refresh" button in your web browser to retry your request.
Administrator Note: An error message detailing the cause of this specific request failure can be found in the application event log of the web server. Please review this log entry to discover what caused this error to occur.
------------
I know that I can probably ask the support department to fetch the information for me, but I'm looking for a more permanent solution so I don't have to ask support again and again.
Is it for example possible to redirect the error messages to the screen or to a file?
Thank you,
|
|
|
|
|
|
You can edit your web.config file to show errors, place some code in the OnError handler in the global.aspx, use the Enterprise Library. The options are many.
only two letters away from being an asset
|
|
|
|
|
Tried both of these options, but none of them worked.
But it turned out that there was a logical explanation. My host had forgotten to enable ASP.NET 2.0 for my domain. So now my code works and I guess the options you and the other guy mentioned also work.
Thank you for your replies, Mads
|
|
|
|
|
Event log is great but there is a even better solution than event log. try http://www.app-messenger.com . Unlike event log you can create email subscription for certain messages based on message tags. They can also push you the events as they occur in real-time. you can invite multiple people and have certain message go to certain people again based on the message tag. check them out.
|
|
|
|
|
i hav created a menus using flah menu creator but i dono how to insrt it in ma asp.net page....the file has n extension .fmb
regards bia ali
|
|
|
|
|
wut exakly iz ur problm? u plas tha flah menu as n mbeded resrc.
|
|
|
|
|
first the fmb extension its for your flash project or the exported flash file?,
So, its the second option, You must to copy the flash file inside the site root and write these onto html code page.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="120" height="60">
<param name="quality" value="high" />
<embed src="xxxxxx/yyyyy" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" />
change the embed src to relative address file..
keep Learning and you never will be out of date...
|
|
|
|
|
i m doing exactly this but its i m using asp.net 2.0 and it dsnt accept the tag <embed /> it dsnt display it
|
|
|
|
|
Ok, Biaali try these lines
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="120" height="60">
<param name="movie" value="flash/mail.swf" />
<param name="quality" value="high" />
<embed src="flash/mail.swf" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="120" height="60" />
Remember change the two flash/mail.swf urls by your relative url
And the Width and height properties.
You must to insert this Javascript in order to download the flash player, (if the user dont have installed)
This the code
keep Learning and you NEVER WILL BE out of date...
|
|
|
|
|
Check these lines from code Behind page
Imports ShockwaveFlashObjects
Imports AxShockwaveFlashObjects
Imports System.IO
Public Class Form1
Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim flash As New AxShockwaveFlash
Dim percorso As String
percorso = Path.Combine(Directory.GetCurrentDirectory, "logo_tre_hp.swf")
Dim startupSize = New System.Drawing.Size(1024, 768)
Dim startupsize2 = New System.Drawing.Size(640, 480)
'Start
flash.BeginInit()
flash.Location = New Point(50, 80)
flash.Name = "Testina"
flash.TabIndex = 0
Controls.Add(flash)
flash.Size = startupsize2
flash.EndInit()
flash.LoadMovie(0, percorso)
flash.Play()
FormBorderStyle = 1
ClientSize = startupSize
End Sub
End Class
I hope work for you
keep Learning and you never will be out of date...
|
|
|
|