Click here to Skip to main content
15,895,656 members
Home / Discussions / C#
   

C#

 
QuestionConvert number from exponential form to decimal form ( dot notation ) Pin
Abhiroop0925-May-14 22:41
Abhiroop0925-May-14 22:41 
AnswerRe: Convert number from exponential form to decimal form ( dot notation ) Pin
Mycroft Holmes25-May-14 22:54
professionalMycroft Holmes25-May-14 22:54 
Questioni am changing size of imge with dimension given by textbox. Pin
megha_p25-May-14 22:14
megha_p25-May-14 22:14 
Questionc# Pin
Member 1070273525-May-14 19:19
Member 1070273525-May-14 19:19 
AnswerRe: c# Pin
Kornfeld Eliyahu Peter25-May-14 20:38
professionalKornfeld Eliyahu Peter25-May-14 20:38 
AnswerRe: c# Pin
Richard MacCutchan25-May-14 21:50
mveRichard MacCutchan25-May-14 21:50 
Questionmicrosoft word interop - inserting file into a word document. Pin
Member 1065956825-May-14 15:48
Member 1065956825-May-14 15:48 
QuestionTimer and scrollbar position of update panel Pin
Tracy Chong25-May-14 0:16
Tracy Chong25-May-14 0:16 
SQL
Hello, I need some help.

Currently, I have a gridview that will update with the timer and also a button when clicked, will update the gridview.

So now, I am currently facing a problem regarding when scrolling the updatepanel/gridview, I would like it to remain at scrollbar position. But when I click on the button, I will like the updatepanel/gridview to return to bottom (already have the javascript).

Thanks in advance!



C#
<div id="scrollChat" style="overflow: auto; width: 80%; height: 250px; margin-left: auto;
        margin-right: auto;">
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
        <asp:Timer ID="timer" runat="server" OnTick="timer_Tick" Interval="2000">
        </asp:Timer>
        <asp:UpdatePanel ID="upChat" runat="server" UpdateMode="Conditional">
            <Triggers>
                <asp:AsyncPostBackTrigger ControlID="timer" EventName="Tick" />
            </Triggers>
            <ContentTemplate>
                <asp:GridView ID="gvChat" runat="server" Style="width: 100%;" Font-Names="Verdana"
                    AutoGenerateColumns="True" ShowHeader="False" GridLines="None">
                    <RowStyle Height="25" />
                </asp:GridView>
            </ContentTemplate>
        </asp:UpdatePanel>
        <div id="chat" style="height: 1px;">
        </div>
    </div>
    <div style="width: 100%; height: 100px; text-align: center; margin-bottom: 30px;">
        <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
            <ContentTemplate>
                <asp:TextBox ID="tbMsg" Rows="3" Height="60px" Width="80%" TextMode="multiline" runat="server"
                    Style="margin-bottom: 15px;" Font-Names="Verdana" placeholder="Type your message here..."></asp:TextBox>
                <br />
                <asp:Button ID="btnSend" class="btn btn-primary btn-lg" runat="server" Text="Send"
                    OnClick="btnSend_Click" Width="200px" Font-Bold="true" Font-Names="Verdana" OnClientClick="btnSend_Click" />
            </ContentTemplate>
        </asp:UpdatePanel>
    </div>
     
    <br />
    <br />

    <script type="text/javascript">
        Sys.Application.add_load(function () {
            var t = document.getElementById('scrollChat');
            t.scrollTop = t.scrollHeight;
        });
	</script>

AnswerRe: Timer and scrollbar position of update panel Pin
OriginalGriff25-May-14 0:31
mveOriginalGriff25-May-14 0:31 
Questionhow to gradient TextBox in word document by c#? Pin
Member 1078639324-May-14 23:56
Member 1078639324-May-14 23:56 
AnswerRe: how to gradient TextBox in word document by c#? Pin
Richard MacCutchan25-May-14 0:56
mveRichard MacCutchan25-May-14 0:56 
QuestionIssues with Microsoft.Deployment.WindowsInstaller Namespace Pin
Mohan Subramani24-May-14 8:15
Mohan Subramani24-May-14 8:15 
AnswerRe: Issues with Microsoft.Deployment.WindowsInstaller Namespace Pin
Richard Andrew x6424-May-14 9:09
professionalRichard Andrew x6424-May-14 9:09 
Questionimage scaling Pin
megha_p24-May-14 1:42
megha_p24-May-14 1:42 
AnswerRe: image scaling Pin
Richard MacCutchan24-May-14 3:37
mveRichard MacCutchan24-May-14 3:37 
Questionimage processing program using c# Pin
Member 1083976523-May-14 6:08
Member 1083976523-May-14 6:08 
AnswerRe: image processing program using c# Pin
OriginalGriff23-May-14 6:13
mveOriginalGriff23-May-14 6:13 
AnswerRe: image processing program using c# Pin
Richard MacCutchan23-May-14 6:18
mveRichard MacCutchan23-May-14 6:18 
QuestionRe: image processing program using c# Pin
Kenneth Haugland24-May-14 2:58
mvaKenneth Haugland24-May-14 2:58 
JokeRe: image processing program using c# Pin
Brien Dev26-May-14 11:28
Brien Dev26-May-14 11:28 
QuestionOut of interest, how many of you have used SecureString for passwords? Pin
Rob Philpott23-May-14 4:24
Rob Philpott23-May-14 4:24 
AnswerRe: Out of interest, how many of you have used SecureString for passwords? Pin
Eddy Vluggen23-May-14 5:13
professionalEddy Vluggen23-May-14 5:13 
AnswerRe: Out of interest, how many of you have used SecureString for passwords? Pin
Gilbert Consellado24-May-14 0:20
professionalGilbert Consellado24-May-14 0:20 
GeneralRe: Out of interest, how many of you have used SecureString for passwords? Pin
harold aptroot24-May-14 2:05
harold aptroot24-May-14 2:05 
GeneralRe: Out of interest, how many of you have used SecureString for passwords? Pin
Gilbert Consellado24-May-14 2:23
professionalGilbert Consellado24-May-14 2:23 

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.