Jump to content
Xtreme .Net Talk

Joe Mamma

Avatar/Signature
  • Posts

    1093
  • Joined

  • Last visited

Everything posted by Joe Mamma

  1. oops. . . I forgot, you cant right-clcik "view source" on a modal window. . . here's the code for 'default.htm' <html> <script> function editValues() { var invals = new Object(); invals.value1 = document.all.value1.innerHTML; invals.value2 = document.all.value2.innerHTML; var vals = window.showModalDialog("./editVals.htm", invals, " dialogHeight: 200px; dialogWidth:300px; dialogTop: px; dialogLeft: px; " + "center: Yes; edge: Raised; help: Yes; resizable: No; status: No; scroll:no;"); if (vals != null) { document.all.value1.innerHTML = vals.value1; document.all.value2.innerHTML = vals.value2; } } </script> <body> <span ID="value1">foo</SPAN> <br> <span ID="value2">foo</SPAN> <br> <button onclick='editValues();'>Edit</button> </BODY> </HTML> here's the code for 'editvals.htm': <html> <script> function returnVals(cancel) { if (cancel) return null; var outvals = new Object(); outvals.value1 = document.all.value1.value; outvals.value2 = document.all.value2.value; window.returnValue = outvals; window.close(); } function loadArgs() { document.all.value1.value = window.dialogArguments.value1; document.all.value2.value = window.dialogArguments.value2; } </script> <body onload='loadArgs();'> <table> <TR><TD>Value 1:</TD><TD> <input ID="value1" type="text" /></TD></TR> <TR><TD>Value 2:</TD><TD> <input ID="value2" type="text" /></TD></TR> </table> <br> <button ID="ok" onclick='returnVals(false);'>Ok</button> <button ID="cancel" onclick='returnVals(true);'>Cancel</button> </body> </html>
  2. Oh, how I love when people say 'That's inpossible!' http://www.obj-tec.com/XtremeDotNet/ModalFormResponse/
  3. search for saving images to a database, its no different.
  4. You were supposed to refrain from talking about spreadsheets. ;) The above is a proposed solution for accomplishing a task. . . In general, you are saying: 1. The user points the application to a datafile in the local filesystem 2. The application manipulates the datafile. 3. The manipulated datafile is presented back to user in edit mode. To build on aj - While it is entirely possible to do the above, isn't this a violation of the HTTP protocol? I wouldn't do it in an html based app. I mean, are you going to write client side jscript to manipulate the datafile? or are you planing on pushing the entire datafile to the server to do the processing and return it back??? I am not saying that you shouldn't develop an html/http app, just that if html/http is an architectural requirement you might want to consider a different approach. Although, IMHO, html/http should never be a requirement! Are you developing this for a third party, or is this for in house purposes? I would like to know more about what you want to do. Tell me what you are trying to bake, not how you want to bake it. To build on bri - Spreadsheet/Client-Side/Display are physical, not functional requirements. Using the bake analogy, the functional requirements would be: Invoking bake(temp, time, concoction) heats concoction for time mins at temp degrees A physical requirement is that baking will be done in a convection oven. Physical and functional requirements are, for the most part, independent.
  5. I am thinking you should reassess your design. Just for fun, with out mentioning 'web pages' and 'spreadsheets' and 'control,' describe what you want to accomplish.
  6. I think you are making this a little harder than it has to be. . . aspx code: <%@ Page language="c#" Codebehind="TestWaiting.aspx.cs" AutoEventWireup="false" Inherits="TestWait.TestWaiting" %> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" > <HTML> <HEAD> <title>TestWaiting</title> <meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR"> <meta content="C#" name="CODE_LANGUAGE"> <meta content="JavaScript" name="vs_defaultClientScript"> <meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema"> </HEAD> <body onload="document.all.messageDiv.style.visibility='hidden';"> <form id="Form1" onsubmit="document.all.paramsDiv.style.visibility='hidden';document.all.messageDiv.style.visibility='visible'; return true;" method="post" runat="server"> <DIV style="WIDTH: 152px; HEIGHT: 168px" ms_positioning="FlowLayout"> <DIV ms_positioning="FlowLayout"><asp:panel id="paramsDiv" runat="server"> <asp:Label id="Label2" runat="server" Width="88px">Enter a value:</asp:Label> <asp:TextBox id="TextBox1" runat="server"></asp:TextBox> <asp:Button id="Button1" runat="server" Text="submit"></asp:Button> </asp:panel><asp:panel id="resultsDiv" runat="server" Visible="False"> <asp:Label id="Label3" runat="server">Label</asp:Label> </asp:panel></DIV> <span style="LEFT: 0px; POSITION: absolute; TOP: 0px"><DIV id="messageDiv" ms_positioning="FlowLayout"> <asp:Label id="Label1" runat="server">Please wait while your request is processed...</asp:Label></DIV> </span> </DIV> </form> </body> </HTML> code behind: using System; using System.Collections; using System.ComponentModel; using System.Data; using System.Drawing; using System.Web; using System.Web.SessionState; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.HtmlControls; namespace TestWait { /// <summary> /// Summary description for TestWaiting. /// </summary> public class TestWaiting : System.Web.UI.Page { protected System.Web.UI.WebControls.Panel paramsDiv; protected System.Web.UI.WebControls.Label Label1; protected System.Web.UI.WebControls.Label Label2; protected System.Web.UI.WebControls.TextBox TextBox1; protected System.Web.UI.WebControls.Button Button1; protected System.Web.UI.WebControls.Panel resultsDiv; protected System.Web.UI.WebControls.Label Label3; private void Page_Load(object sender, System.EventArgs e) { if (this.IsPostBack) { System.Threading.Thread.Sleep(1000); paramsDiv.Visible = false; resultsDiv.Visible = true; Label3.Text = "You entered: " + TextBox1.Text; } } #region Web Form Designer generated code override protected void OnInit(EventArgs e) { // // CODEGEN: This call is required by the ASP.NET Web Form Designer. // InitializeComponent(); base.OnInit(e); } /// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { this.Load += new System.EventHandler(this.Page_Load); } #endregion } } TestWaiting.zip
  7. what db are you using???? A real database like SQL Server/Oracle/Firebird/Sybase/DB2??? use databased triggers and the database's native mail utility.
  8. Forget everything you were told about using grids in the xtremevbtalk forums. . . it was wrong. Terribly wrong!!!! Even for VBsux. Remember, in general, your controls are not be used to contain data. They present data, hence the term "presentation.' Controls format, generate events and automatically load data into and out of the underlying data structures (datasets for example) to which they are bound. The underlying data structure should know how to 'talk' to the datastore (such as via a dataadapter.)
  9. Where are my cookies???
  10. Damn. . . I Love math. . . I hate arithmetic. . . . check: given that ∫ Ax^n = A ((x^n+1)/(n+1)) + C and ∫ ( f(x) + g(x) ) = ∫ f(x) + ∫ g(x) therefore ∫ (12x+8)(3x^2+4x) = ∫ (36 x^3 +24x^2 +48x^2 + 32x) = ∫ 36 x^3 + ∫ 72x^2 + ∫ 32x = 36 (x^4)/4 + 72(x^3) / 3 + 32 (x^2) / 2 = 9 x^4 + 24x^3 + 16 x^2 = (x^2) ( 9x^2 + 24x + 16) = (x^2) ( 9x^2 + 24x + 16) + C = (x^2) (3x +4) ^2 +C =========================== ∫ (12x+8)(3x^2+4x) = (x^2) (3x +4) ^2 +C Now - thats my final answer!!!!
  11. I believe it is: [ (x^2) (9x^2+22x+16) ]+C
  12. Wow. . . 'Free' means 20 bux a year. I didn't know that! :rolleyes:
  13. So my OEM Norton A/V 2004 subscription just expired and they want US$35 to renew. As I contemplate giving them my money, it occurred to me - If I owned an Anti-Virus software company, how would utilize my developer workforce? 1% developing antivirus software - 99% developing virii ????? At any rate, it really pisses me off having to spend money on anti-virus software. Is there a consensus on the best for the price???
  14. By the way . . . cyclonebri are you still around? did that work for you?
  15. I am not sure if this will help. But a little over a year ago cyclonebri needed to script interaction with a website to gather metrics. I wrote a testbed for him here that utilized System.Net, specifically the HttpWebRequest and HttpWebResponse classes. Take a look at the class posted in the last response.
  16. Oledb doesnt support named parameters in the command text - you can name them as you set them. try this: [indent]Dim daStudy As New OleDbDataAdapter("SELECT * FROM tblStudy WHERE StudyID = ?", conSmallGrp) Dim dsStudy As New DataSet Me.ShowStudy(ddlStudy.SelectedItem.Value) [/indent] Private Sub ShowStudy(ByVal StudyID As Integer) [indent]daStudy.SelectCommand.Parameters.Add("StudyID", StudyID) daStudy.Fill(dsStudy, "tblStudy") txtStudyID = dsStudy.Tables("tblStudy").Rows(0).Item("StudyID") txtCategory = dsStudy.Tables("tblStudy").Rows(0).Item("CategoryID") txtBookTitle = dsStudy.Tables("tblStudy").Rows(0).Item("Book") txtAuthor = dsStudy.Tables("tblStudy").Rows(0).Item("Author") txtISBN = dsStudy.Tables("tblStudy").Rows(0).Item("Isbn") txtSummary = dsStudy.Tables("tblStudy").Rows(0).Item("Summary") [/indent] End Sub
  17. :mad: Do you have MSDN help installed??? search "Read Text From A File"
  18. I was thinking you could do something like this: [indent]Dim proc As New Process proc.StartInfo.CreateNoWindow = True proc.Start("xcopy", sourceDir & " " & destDir & " /S /E /I") While Not proc.HasExited End While MessageBox.Show("Done") [/indent] It copies the files but creates a window. . . and this line: "While Not proc.HasExited" immediately throws eexception "No process is associated with this object." maybe someone has an idea???
  19. http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_vbcode/html/vbtskcodeexamplereadingexceldataintodataset.asp
  20. http://www.obj-tec.com/toolbar.jpg lotsa info in help
  21. Drop an image list on a form. . . put the image in the image list. . . set the transparentcolor of the imagelist to olive. . . color the button to what ever color you want the background to be. . . set the ImageList prop of the button to the image list set the ImageIndex prop of the button to the index of the image in the Image list. . . boom goes the dynamite!
  22. oh yeah. . . put them in an image list and set transparentcolor to olive.
  23. here are some that came in Delphi: http://www.obj-tec.com/VCRFSFOR.BMP http://www.obj-tec.com/VCRPAUSE.BMP http://www.obj-tec.com/VCRPLAY.BMP http://www.obj-tec.com/VCRRECRD.BMP http://www.obj-tec.com/VCRREWND.BMP the background is System.Drawing.Color.Olive -- (r:128 g:128 b:0)
×
×
  • Create New...