Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
B

babamara

@babamara
About
Posts
14
Topics
6
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Arrays
    B babamara

    I use this function void CPropertyTabControl::ActivateTabDialogs() { int nSel = GetCurSel(); if(dlgArray[nSel]->m_hWnd) dlgArray[nSel]->ShowWindow(SW_HIDE); CRect l_rectClient; CRect l_rectWnd; GetClientRect(l_rectClient); AdjustRect(FALSE,l_rectClient); GetWindowRect(l_rectWnd); GetParent()->ScreenToClient(l_rectWnd); l_rectClient.OffsetRect(l_rectWnd.left,l_rectWnd.top); for(int nCount=0; nCount < m_nPageCount; nCount++) { dlgArray[nCount]->SetWindowPos(&wndTop+21, l_rectClient.left, l_rectClient.top, l_rectClient.Width(), l_rectClient.Height(), SWP_HIDEWINDOW); } dlgArray[nSel]->SetWindowPos(&wndTop+21, l_rectClient.left, l_rectClient.top, l_rectClient.Width(), l_rectClient.Height(), SWP_SHOWWINDOW); dlgArray[nSel]->ShowWindow(SW_SHOW); }

    C / C++ / MFC data-structures

  • Arrays
    B babamara

    Thank you. I change GetParent with this and this solves the probelm. Now I am going to check why the dialog are not shown in my Tab Control.

    C / C++ / MFC data-structures

  • Arrays
    B babamara

    First Thank you all for replays. I'm still stack. So I will give you additional information . Please excuse my English I still learning. First I create the Array in my header file with template, like this: CArray<CDialog *, CDialog *> dlgArray; Then in my .cpp file I add some data: dlgArray.Add(new CDlgSettings()); And I want to use this data by this way: m_nPageCount = 1; for(int nCount=0; nCount < m_nPageCount; nCount++) dlgArray.GetAt(nCount)->Create(m_DialogPages[nCount],GetParent()); My idea is to use the above code to insert dialog into Tab Control. The project is compiling without error, but when i try to open the dialog which contains the Tab Control I receive the folowing error. Asseration Failed! MyProgram: File afxwin2.inl, Line 262

    modified on Sunday, January 06, 2008 3:12:48 AM

    C / C++ / MFC data-structures

  • Arrays
    B babamara

    Hello Gurus I've stack in my try to convert this: CDialog *m_Dialog[2]; Into this: CArray<CDialog *, CDialog *> dlgArray; I just want to be more flexible.But when I use it by this way: for(int nCount=0; nCount < m_nPageCount; nCount++) dlgArray.GetAt(nCount)->Create(m_DialogPages[nCount],GetParent()); I receive an exeption. I think that my mistake is in the template, but I can't solve it. Thanks.

    C / C++ / MFC data-structures

  • help with javascript
    B babamara

    I want to take pictures from a database i have tables for albums and images i retrived them with ViewImage.aspx?img= or by album with Privew.aspx?album= i think i have to put this links somewhere in my javascript i think i need to make some modifications but i don't know how. I use this project like template so everithing is preaty same. If you can tell me good article or sample code i will be very thankful or just tell me how to correct this code.

    Web Development help java javascript asp-net database

  • help with javascript
    B babamara

    Hi all, I've a little problem. I try to make slideshow. I have a sample writen in java and here is where i stuck. I don't know anything about java, but I must convert my code to use pictures from database, now it takes pictures from directory.I take the sample code from here http://www.codeproject.com/aspnet/CatalogViewPhotoGallery.asp[^]. Please help me. 10x.

    Web Development help java javascript asp-net database

  • image uploading
    B babamara

    try something like this Stream imgStream = UploadFile.PostedFile.InputStream; int imgLen = UploadFile.PostedFile.ContentLength; string imgContentType = UploadFile.PostedFile.ContentType; string imgName = txtImgName.Value; byte[] imgBinaryData = new byte[imgLen]; int n = imgStream.Read(imgBinaryData,0,imgLen); //thumb MemoryStream stream = new MemoryStream(); System.Drawing.Image thumb = System.Drawing.Image.FromStream(imgStream); System.Drawing.Image thumbnail = thumb.GetThumbnailImage(50, 50, new System.Drawing.Image.GetThumbnailImageAbort(ThumbnailCallback), IntPtr.Zero); thumbnail.Save(stream, System.Drawing.Imaging.ImageFormat.Jpeg); byte[] thumbBinaryData = new byte[stream.Length]; stream.Position = 0; int m = stream.Read(thumbBinaryData, 0, (int)stream.Length); // SaveToDB(imgName, imgBinaryData, imgContentType, thumbBinaryData); Good luck :) -- modified at 8:12 Sunday 16th April, 2006

    C# tutorial question

  • TreeView
    B babamara

    Hi i've try to write a tree using webcontrols, but i don't know the equivalent of TreeNode.Tag which i use in windows forms . Please help. 10x.:confused:

    C# winforms data-structures help

  • Form to Web Service
    B babamara

    Is there some convertor or good article which can help me.

    C# graphics docker data-structures help

  • Form to Web Service
    B babamara

    Hi, all. I want to convert this form to a web service but my knowladge is not enough. Please help. using System; using System.Drawing; using System.Collections; using System.ComponentModel; using System.Windows.Forms; using System.Data; using System.Data.SqlClient; namespace AlbumViewer { /// /// Summary description for Form1. /// public class MainForm : System.Windows.Forms.Form { private System.Windows.Forms.PictureBox pictureBox; private System.Windows.Forms.MainMenu mainMenu; private System.Windows.Forms.MenuItem menuItem3; private System.Windows.Forms.TreeView treeAlbum; private System.Windows.Forms.MenuItem mnuFile; private System.Windows.Forms.MenuItem mnuOpen; private System.Windows.Forms.MenuItem mnuExit; private System.Windows.Forms.MenuItem mnuOptions; private System.Windows.Forms.MenuItem mnuSlideShow; private System.Data.SqlClient.SqlConnection sqlConn; private System.Windows.Forms.OpenFileDialog FileOpenDlg; private System.Windows.Forms.MenuItem mnuAddPhoto; private System.Windows.Forms.MenuItem mnuRenameAlbum; private System.Windows.Forms.MenuItem mnuDeleteAlbum; private System.Windows.Forms.ContextMenu mnuPhotoPopup; private System.Windows.Forms.MenuItem mnuRenamePhoto; private System.Windows.Forms.MenuItem mnuDeletePhoto; private System.Windows.Forms.ContextMenu mnuAlbumPopup; private System.Windows.Forms.MenuItem mnuNewAlbum; private System.Windows.Forms.TextBox txtDesc; private System.Windows.Forms.Button btnUpdate; private System.Windows.Forms.Label lblDesc; private System.Windows.Forms.MenuItem mnuEditDesc; private System.Windows.Forms.MenuItem mnuAlbumEdit; private System.Windows.Forms.MenuItem mnuPhotoEdit; private System.Windows.Forms.ContextMenu mnuImage; private System.Windows.Forms.MenuItem menuItem1; private System.Windows.Forms.MenuItem menuItem2; /// /// Required designer variable. /// private System.ComponentModel.Container components = null; /// /// The main entry point for the application. /// [STAThread] static void Main() { Application.Run(new MainForm()); } public MainForm() { // // Required for Windows Form Designer support // InitializeComponent(); // Initaliaze the tree control LoadTree(); } /// /// Clean up any resources being used. /// protected override void Dispose( bool dispo

    C# graphics docker data-structures help

  • C# mysql problem
    B babamara

    hi all i want to save images to database. I use this code private int SaveToDB(string imgName, byte[] imgbin, string imgcontenttype) { //use the web.config to store the connection string MySqlConnection connection = new MySqlConnection(ConfigurationSettings.AppSettings["DSN"]); MySqlCommand command = new MySqlCommand( "INSERT INTO Image (img_name,img_data,img_contenttype) VALUES ( @img_name, @img_data,@img_contenttype )", connection ); MySqlParameter param0 = new MySqlParameter( "@img_name", MySqlDbType.VarChar,50 ); param0.Value = imgName; command.Parameters.Add( param0 ); MySqlParameter param1 = new MySqlParameter( "@img_data", MySqlDbType.LongBlob ); param1.Value = imgbin; command.Parameters.Add( param1 ); MySqlParameter param2 = new MySqlParameter( "@img_contenttype", MySqlDbType.VarChar,50 ); param2.Value = imgcontenttype; command.Parameters.Add( param2 ); connection.Open(); int numRowsAffected = command.ExecuteNonQuery(); connection.Close(); return numRowsAffected; } I have no errors it tells me that the image is save but when i go to my database there is only new row with no data. Where i am wrong P.S. I use MySql connector -- modified at 13:09 Friday 17th March, 2006

    C# csharp database mysql help

  • Setting Texbox(Password mode) viewstate property true?????
    B babamara

    Try to use cookies. That works for me.

    ASP.NET tutorial question

  • Asp .net problem
    B babamara

    I've done all of this. 10x anyway.

    ASP.NET help csharp mysql visual-studio sysadmin

  • Asp .net problem
    B babamara

    Dear colleagues I am a legacy developer came newly to the .Net platform. I have problems when I try to start my ASP .NET site i take a very huge error that tells me that i can not debug because the application is not found on this server. I use c# with vs2005 on windows xp + sp2 i try almost everything i found in Google but nothing happen. If you can not help me with that please tell me how to make the starter kit for VS to work with MYSQl so i can use it for my purpose because it is the only thing that works for me. Thanks for the help.

    ASP.NET help csharp mysql visual-studio sysadmin
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups