|
not sure what your exact difficulty is but it seems like you need help with the internet transmission end of the app----try finding on MSDN site the section entitled "Internet Programming With WinINet", it's a good place to start....if you are using MFC you can get alot of free functionality with the MFC wrappers for the wininet stuff....
good luck
1. The Lord loves a workin' man.
2. See a doctor and get rid of it.
3. Don't trust whitey.
|
|
|
|
|
int CFlowChartView::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
if (CScrollView::OnCreate(lpCreateStruct) == -1)
return -1;
SetScrollSizes(MM_TEXT, CSize(1000, 1000));
ScrollToPosition(CPoint(500, 500));
return 0;
} This is my OnCreate handler in a CScrollView. First I set the scroll size, and I want the scrolls to start off in the middle. But for some reason nothing happens when I call ScrollToPosition. Does anyone know why this happens, and a possible solution...
Thanks for your time!
With time we live, with money we spend!
Joel Holdsworth
|
|
|
|
|
you need to put the scrollto code in OnInitialUpdate to see some results, you will need to then add code to the OnUpdate as well to scroll....also this code will not position the scrollbars in the middle of the scroll track---this code scroll the logical document point (500,500) to the upper lefthand corner of the client window-----the thumbtrack pos will be dependent on the window size( window state == normalized, maximized, etc and that relation to the scroll pos) , sorry, it's not as simple as falling out of your chair!!!
1. The Lord loves a workin' man.
2. See a doctor and get rid of it.
3. Don't trust whitey.
|
|
|
|
|
Can anyone tell me where the Address Book is stored? Is it stored as a file? Or in the registry? Is it stored just on a per user basis? Or is it stored on a per user per OE-identity basis?
Nish
Author of the romantic comedy
Summer Love and Some more Cricket [New Win]
|
|
|
|
|
|
Search for *.wab files. For NT it should be stored in -
C:\Documents and Settings\USER_NAME\Application Data\Microsoft\Address Book as a .wab file.
HTH,
- Manish
|
|
|
|
|
|
For some reason I cant add member variables to items in dialogs, either via the context menu or CTRL and double clicking. If I add say a radio button to the About Dialog it works there, but CTRL + double clicking on a control in a user defined form just brings up the add class dialog.
Any help appreciated
|
|
|
|
|
I want to convert modal dialog to modeless dialog box.Can I? the dialog box is already created and I want this conversion at run time.
VIKS
|
|
|
|
|
|
hi,
Here the issue is not like this I don't have code for dialog box and I am converting it to modal or modeless dialog box.I am in different process. I have dialog window handle of some other application of different process. and I want this conversion.
VIKS
|
|
|
|
|
vikrams wrote:
I have dialog window handle of some other application of different process. and I want this conversion.
Not possible! The modality of a window is not a window style. It's simulated via code. For example, the CDialog::DoModal will disable the parent window till the dialog is dismissed! That's how it gives us a modal feel!
Nish
Author of the romantic comedy
Summer Love and Some more Cricket [New Win]
|
|
|
|
|
thanx nish,
I got the idea. Actually I want some trigger event in order to trap the modal dialog box creation. SO whenever the modal dialog box created the parent window style is changed to WS_DISABLED
|
|
|
|
|
Hello!
I'm writing an activex control and I wondered how I could return a pointer to a class object back to a JavaScript Variable. I know that sounds really weird but I'll give you an example:
Here's the java script:
--------------------------------------------------------------------------------
1: var testbox;
2: var variable = document.testcontrol; // this points to the active control <object idclass="blahblahblah" id="testcontrol">
4: testbox = variable.CreateMsgBox();
5: testbox.SetText("Hello Universe"); // im sick of "Hello World" lol <img src="images/smilies/smile.gif" border="0" alt="">
--------------------------------------------------------------------------------
Let me explain the above code. When the variable named "variable" calls the IDispatch method CreateMsgBox(), on line 4, I want it to return a pointer from the newly created class back to the variable "testbox". Then on line 5 I can access the class methods through the "testbox".
Heres the pusedo code of the c++ code when one calls the CreateBox() function above.
--------------------------------------------------------------------------------
CCreateBox CreateBox()
{
1: CCreateBox newBox; // CCreateBox is the MsgBox class
2: return newBox;
}
--------------------------------------------------------------------------------
I hope anyone can understand this, and if anyone can help I’d greatly appreciate it!!!!!!!!!!!!!
Thank You,
Caleb
|
|
|
|
|
Not a chance in hell. Your COM component runs in a different process, and could even run on a different machine. How is the system going to marshall a class pointer for you ? Both client and server need to know about the class, in fact, you're basically talking about another COM component.
Christian
I am completely intolerant of stupidity. Stupidity is, of course, anything that doesn't conform to my way of thinking. - Jamie Hale - 29/05/2002
Half the reason people switch away from VB is to find out what actually goes on.. and then like me they find out that they weren't quite as good as they thought - they've been nannied. - Alex, 13 June 2002
|
|
|
|
|
Dim Rs1 As New ADODB.Recordset
Rs1 is a pointer to the Recordset interface of the ADODB object. I believe this is what you are asking for.
If the control is already embedded in the document using an
|
|
|
|
|
I have a CTreeCtrl and CTabCtrl that has a property sheet with a few property pages attached to it. The tree initially is selected. If you press the Tab key the focus moves the the TabCtrl. If you press Tab again the focus should go back to the tree but it doesn't. I was thinking of watching for when the Tab key is pressed then setting the focus to the tree but I'd think there is an easier way.
-Raffi Yet another example of my bad programming skills.
|
|
|
|
|
i'm wondering how can i set the text of the cell in the datagrid control(microsoft datagrid control, version 6.0(oledb))in my dialog project? i don't have any database source, i just wanna show some text in those grids.
anybody knows? thanks
|
|
|
|
|
If you don't have any datasource it is better to use other grids like flex grid or grids in CP.
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
How do I code it so that when a button is press the data on the ComboBox randomize? Please help this newbie programmer.
|
|
|
|
|
Let's say the button is called IDC_BUTTON1
So i guess by now u should know how to do a event for IDC_BUTTON1? Hook on the msg BN_CLICKED.
So let's say you have assigned the combobox to a variable called m_comboBox. This can be done thru class wizard.
You would get
void ClassName::OnButton1
{
m_comboBox.AddString("....");// Your random data
}
Hope this helps.
|
|
|
|
|
I'm sorry, perhaps I didn't explained in detail what I want to achieved. Say my combobox have 5 data entries (properties -> data)
data1
data2
data3
data4
data5
When you press the button, it pick one of those entries and make it the display entry.
|
|
|
|
|
Generate a random number between 0 and CComboBox::GetCount() - 1
Now use CComboBox::GetLBText() on this random number.
Is that what you wanted? Now each time you get a random entry from the combo box
Nish
Author of the romantic comedy
Summer Love and Some more Cricket [New Win]
|
|
|
|
|
To generate random numbers, use the srand(time(NULL)) to seed the generator.
Then use rand() to get a random number between 0 and MAX_INT (4 billion or so).
To scale this massive range down to that of your listbox, use this formula:
rand() % listbox.ItemCount (or whatever the property is)
That will generate a number between zero and listbox.ItemCount - 1.
You +/- and constant value if you need to shift the lower limit or use rand() % (listbox.ItemCount + x) to shift the upper limit.
|
|
|
|
|
This will be my last time asking, please try to help me this last time.
rand() % listbox.ItemCount
I understand that, but say I have a combobox name IDC_COMBO1, how do I tell its name to use inside my codes?
|
|
|
|