Jump to content
Xtreme .Net Talk

EricDotNet

Members
  • Posts

    22
  • Joined

  • Last visited

EricDotNet's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Any Idea? Thank!
  2. How to set the column width in datagrid?
  3. As I know, For Char(10) - fix length when u put "Hi" in database, the physical stored in database is "Hi________". (8 spaces in here) It use 10 bytes. For varchar(10) - variable length when u put "Hi" in database, the physical stored in database is "Hi" with end char. It use 2 + 1 bytes.
  4. display checkbox in datagrid. I find that there are 3 status: checked - check box with click icon unchecked - blank in check box unknown - click icon but color in gray..... How can I set the check box only 2 status, checked and unchecked?
  5. No Error prompt... I can't update the changed data into database.
  6. Hi, all I confused that datagrid cannot update to db. I create a dataset and fill in the datagrid component. Private Sub frmCountry1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load dim sSQL as string dim da as new dataAdapter() dim ds as new dataSet() sSQL = "SELECT * FROM COUNTRY" da = New SqlDataAdapter(sSQL, sConnString) da.TableMappings.Add("Table", "TMP") da.Fill(ds) datagrid1.DataSource = ds.Tables("TMP") End Sub When I modify the records in datagrid, I can't update to database... How can I do it? I have try this.... :confused: no effect .... :o ds.Tables("TMP").AcceptChanges() da.Update(ds)
  7. Open frmA Coding : Dim childForm As New frmMain childForm.MdiParent = Me childForm.Show() Open frmB Coding : Dim childForm As New frmMain childForm.MdiParent = [u]Me.parent[/u] childForm.Show() Since I open the frmB at frmA button, the system prompt error msg: An unhandled exception of type 'System.InvalidCastException' occurred in CeicSystem.exe Additional information: Specified cast is not valid. I debug the program, the error is happened at : childForm.MdiParent = Me.parent :confused:
  8. Dear all Since I have a MDI Container Form (frmMain), It contain a menu item (Open frmA) frmA is a MDI Child form, It have a button (Open frmB which is also a MDI Child form under frmMain) The problems is that When I open frmB from frmA button, frmB does not under frmMain How can I open frmB as a MDI Form under frmMain?
  9. I can inheritance MDI form la, But there are other problems: I don't want to see a child MDI form is displayed twice. (i.e. I don't have two instances showing) In parent MDI form, a button click event: Dim childForm As frmRefTable childForm = childForm.getInstance() childForm.MdiParent = Me childForm.Show() childForm.BringToFront() In Child MDI form, Public Shared frmChildForm As frmRefTable Public Shared Function getInstance() As frmRefTable If frmChildForm Is Nothing Then frmChildForm = New frmRefTable End If Return frmChildForm End Function It seem to be work, but when i close the child form and open child form again, Error display: An unhandled exception of type 'System.ObjectDisposedException' occurred in system.windows.forms.dll Additional information: Cannot access a disposed object named "frmRefTable".
  10. I try a Window Form can inheritance, but MDI Form cannot. Anyone can help me? Thank!
  11. PlausiblyDamp, just simple send email function i.e. type something & add attachment & send to someone... :rolleyes: Is it easy?
  12. :D I find the solution la, N share to all Dim ProcID As Integer ' Start the Calculator application, and store the process id. ProcID = Shell("CALC.EXE", AppWinStyle.NormalFocus) ' Activate the Calculator application. AppActivate(ProcID) SendKeys.SendWait("9") SendKeys.SendWait("*") SendKeys.SendWait("8") SendKeys.SendWait("+") SendKeys.SendWait("7") SendKeys.SendWait("*") SendKeys.SendWait("6") SendKeys.SendWait("+") SendKeys.SendWait("5") SendKeys.SendWait("*") SendKeys.SendWait("4") SendKeys.SendWait("+") SendKeys.SendWait("3") SendKeys.SendWait("*") SendKeys.SendWait("2") SendKeys.SendWait("-") SendKeys.SendWait("123456789") SendKeys.SendWait("=")
  13. I find that System.Windows.Forms provide a class "SendKeys" May be It can send keystrokes to application... I now try to use FindWindow & SetForegroundWindow to force the focus to other applications... and try to sendkeys to other applications.
  14. How to programming E-mail function?
×
×
  • Create New...