|
You probably mean this and perhaps this too.
Here's a list of software license/product key articles.
|
|
|
|
|
Thanks A Lot to all of you.
Regards
Yogesh
|
|
|
|
|
Hi all,
I have made a report style list control. In that list control i have made two columns.
What i want to do is when column 2 value changes to certain number then column 1 value should change into hyperlink.
how can i do this.
Thanks in advance
|
|
|
|
|
What event causes column 2 to change? You need to monitor or capture that, and make the changes to column 1 at the appropriate time. Without knowing more about your code it is difficult to be more specific.
|
|
|
|
|
both columns have been initialized with some values
when initial value of column 2 increases then column one value should become hyperlink.
Thanks.
|
|
|
|
|
|
for static controls: here
|
|
|
|
|
|
and the question is?
0100000101101110011001000111001011101001
|
|
|
|
|
#include "stdafx.h"
#include <stdio.h>
int main()
{
/*int i, c, cp;
for(cp=c=getchar(), i = 0; c != EOF; c = getchar() ) {
if ( c == cp ) {
i++;
} else {
printf("%d%c", i, cp);
i = 1;
}
cp = c;
}
printf("%d%c", i, cp);*/
/*
int i, c, j;
while( scanf("%d%c", &i, &c) == 2 ) 1
{
for(j=0; j < i; j++)
{
printf("%c", c);
}
}
}
Failure is Success If we learn from it!!
|
|
|
|
|
hi,
how to convert LANGID to wstring?
Zo.Naderi-Iran
|
|
|
|
|
Hi,
MSDN is your friend and you will be a much better software engineer if you learn to use it. The LCIDToLocaleName function[^] is available for Vista+ operating systems. The DownlevelLCIDToLocaleName function[^] is available for XP and below but unfortunately users will need to install the National Language Support (NLS) package.
You can avoid all of this by using the code I gave you here[^] which works on all operating systems >= WinXP. I've never tested it on Win2k.
Best Wishes,
-David Delaune
[Updated incorrect MSDN links]
modified 12-Oct-11 6:22am.
|
|
|
|
|
Hi there, I have an edit box control in a dialog and a button which opens another dialog... I need to learn how can I use main dialog's aditbox text in opened one's editbox (Data transfer)... Please I need urgent help...
|
|
|
|
|
|
Howdy, you'll need the HWND of each dialog and the INT identifier of each control, or you'll need the HWND of each edit control.I'll assume the first.
HWND editSrc, editDst;
char *szBuffer;
int stringLength;
editSrc = GetDlgItem(dlg1, IDC_EDITBOX1);
editDst = GetDlgItem(dlg2, IDC_EDITBOX2);
stringLength = GetWindowTextLength(editSrc);
szBuffer = new char[stringLength+1];
ZeroMemory(szBuffer, stringLength+1);
GetWindowText(editSrc, szBuffer, stringLength);
SetWindowText(editDst, szBuffer);
delete szBuffer;
|
|
|
|
|
See my response for simpler functions.
|
|
|
|
|
:facepalm:
Of course!
Cheers Richard.
|
|
|
|
|
Keep a public CString member variable in Child dialog class, set the member variable before calling the DoModal() or Create function of child dialog. Call SetWindowText of edit control in InitDialog.
for. eg
If CMainDlg is your Main dialog class and CChildDialog be the child.
in header of CChildDialog you declare a public member variable to hold the string
class CChildDialog : public CDialog
{
public :
CString m_strText;
}
and in your button click function of CMainDlg do this
void CMainDlg::OnClick_Button()
{
CChildDialog oChildDlg;
oChildDlg.m_strText = strText; oChildDlg.DoModal();
}
Set the variable value in CChildDialog's OnInitDialog as
CChildDialog::OnInitDialog()
{
SetDlgItemText(ID_OF_YOUR_EDIT, m_strText);
}
You can also set the text by modifying your constructor of CChildDialog, such as
CChildDialog::CChildDialog(CString strText)
|
|
|
|
|
From class wizard, maindialog's member variables I added a member variable to the editbox which gets the editbox's value and then as you said, I equalize each variables but than it returns nothing from main dialog ???
|
|
|
|
|
|
I did it as Mahdu replied and by your hint... like
void mainform::OnBnClickedButton2()
{
GetDlgItemText(IDC_EDIT1,newform.strtext);
}
BOOL newform::OnInitDialog()
{
SetDlgItemText(IDC_EDIT1, strtext);
}
THANKS TO YOU ALL FOR REPLIES PEOPLE!!! YOU ARE GREAT... )
|
|
|
|
|
How about something like:
CMainDlg::OnButtonClick()
{
CString strText;
m_edit.GetWindowText(strText);
CSecondDlg dlg;
dlg.setData(strText);
dlg.DoModal();
}
CSecondDlg::setData( LPCTSTR lpszText )
{
m_strText = lpszText;
}
CSecondDlg:OnInitDialog()
{
m_edit.SetWindowText(m_strText);
} I'm a big fan of weak coupling, so tying these two dialogs together like this would not be my first choice. I would opt for a "data transfer" or "liaison" class instead. This is a one-instance class where you would put all of your shared data.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Show me a community that obeys the Ten Commandments and I'll show you a less crowded prison system." - Anonymous
|
|
|
|
|
Thanks for your reply David... I would like to criticise your post if I was more skilled... But seems to me for now... Maybe not, in the future?? Just joking, thanks again...
|
|
|
|
|
By the way, you can just explain this :
CFileDialog *pOpenDlg=new CFileDialog(FALSE,".txt",NULL,OFN_OVERWRITEPROMPT,"Text Files (*.txt)|*.txt|All Files(*.*)|*.*||");
if you want some more charity from our heavenly father?? PLEASE!
|
|
|
|
|
Try and put this code in a button click and see what happens. then you will understand why is this code required.
Every new day is another chance to change your life.
|
|
|
|