Click here to Skip to main content
15,881,811 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Can we access session cookies from C++/VC++ code? [modified] Pin
sarat16-Sep-09 6:54
sarat16-Sep-09 6:54 
QuestionRe: Can we access session cookies from C++/VC++ code? Pin
David Crow16-Sep-09 6:59
David Crow16-Sep-09 6:59 
AnswerRe: Can we access session cookies from C++/VC++ code? Pin
sarat16-Sep-09 8:16
sarat16-Sep-09 8:16 
GeneralRe: Can we access session cookies from C++/VC++ code? Pin
David Crow16-Sep-09 8:19
David Crow16-Sep-09 8:19 
GeneralRe: Can we access session cookies from C++/VC++ code? Pin
sarat22-Sep-09 23:52
sarat22-Sep-09 23:52 
GeneralRe: Can we access session cookies from C++/VC++ code? Pin
David Crow23-Sep-09 2:53
David Crow23-Sep-09 2:53 
GeneralRe: Can we access session cookies from C++/VC++ code? Pin
sarat23-Sep-09 20:43
sarat23-Sep-09 20:43 
QuestionODBC- too long text trnasmition problem Pin
Rafix11114-Sep-09 2:57
Rafix11114-Sep-09 2:57 
My class which cooperates with MS Acces base looks like below:
In doted place I removed code as a not relevant for case:
Problem is that field mTekst in Acces is set as Memo type. And I wish
to place long report texts in.
My class can't transfer longer text then 255 chars otherwise it shows
an error. Temporarily I deal with it by cutting part of chars.
(Look in function LeftF()) . But a program is not functionally then.
What can I do to deal with problem? Help

1. IMPLEMENT_DYNAMIC(mRec, CRecordset)
2.
3. mRec::mRec(CDatabase* pdb): CRecordset(pdb)
4. {
5. //{{AFX_FIELD_INIT(mRec)
6. // ......
7. m_Temat = _T(""); //
8. // ........
9. //}}AFX_FIELD_INIT
10. m_nDefaultType = snapshot;
11. }
12.
13.
14. CString mRec::GetDefaultConnect()
15. {
16. return _T("ODBC;DSN=mbasa"); // mbasa it is my base in MS
17. Acces
18. }
19.
20. CString mRec::GetDefaultSQL()
21. {
22. return _T("[mHeapTb]"); // mHeapTB it is my table in in
23. my base
24. }
25.
26. void mRec::DoFieldExchange(CFieldExchange* pFX)
27. {
28. //{{AFX_FIELD_MAP(mRec)
29. pFX->SetFieldType(CFieldExchange::outputColumn);
30. ..........
31. RFX_Text(pFX, _T("[mTekst]"), m_mTekst); //mTekst it is
32. field in Table
33. ...........
34. //}}AFX_FIELD_MAP
35. }
36.
37. // Here are my functions
38.
39. CString mRec::GetmTekst(int i)
40. {
41. InterriroF(i);
42.
43. return m_mTekst;
44. }
45. //.................................
46.
47. void mRec::InterriroF(int i)
48. {
49. if(Open(AFX_DB_USE_DEFAULT_TYPE,"SELECT * FROM mHeapTb",readOnly))
50. {
51. try
52. {
53. SetAbsPos (i);
54. }
55. catch(CDBException * e)
56. {
57. LeftF();
58. e->Delete();
59.
60.}
61. Close() ;
62. }
63. }
64.
65. //................
66.
67.
68. void mRec::SetTekst(CString mTxt,int i)
69. {
70. if(Open(AFX_DB_USE_DEFAULT_TYPE,"SELECT * FROM mHeapTb",none))
71. {
72. SetAbsPos(i);
73. Edit();
74. if(mTxt.GetLength()>255)
75. mTxt=mTxt.Left(255);
76. mTxt=mTxt;
77. Update();
78. Close();
79. }
80. }
81. //........................
82.
83.
84. void mRec::SetAbsPos(int i)
85. {
86. try
87. {
88. SetAbsolutePosition (i);
89. }
90. catch(CDBException * e)
91. {
92. LeftF();
93. e->Delete();
94. }
95. }
96.
97. void mRec::LeftF()
98. {
99. if (m_mTekst.GetLength()>255)
100. m_mTekst= m_mTekst.Left(255);
101.
102. }
AnswerRe: ODBC- too long text trnasmition problem Pin
David Crow14-Sep-09 4:26
David Crow14-Sep-09 4:26 
GeneralRe: ODBC- too long text trnasmition problem Pin
Rafix11114-Sep-09 7:23
Rafix11114-Sep-09 7:23 
GeneralRe: ODBC- too long text trnasmition problem Pin
David Crow14-Sep-09 7:30
David Crow14-Sep-09 7:30 
GeneralRe: ODBC- too long text trnasmition problem Pin
Rafix11114-Sep-09 9:35
Rafix11114-Sep-09 9:35 
QuestionSet property of folder? Pin
Arrin14-Sep-09 1:58
Arrin14-Sep-09 1:58 
AnswerRe: Set property of folder? Pin
Iain Clarke, Warrior Programmer14-Sep-09 2:23
Iain Clarke, Warrior Programmer14-Sep-09 2:23 
GeneralRe: Set property of folder? Pin
Arrin14-Sep-09 3:00
Arrin14-Sep-09 3:00 
GeneralRe: Set property of folder? Pin
Iain Clarke, Warrior Programmer14-Sep-09 3:20
Iain Clarke, Warrior Programmer14-Sep-09 3:20 
Questionvsnprintf() Pin
shriniwas198514-Sep-09 1:52
shriniwas198514-Sep-09 1:52 
AnswerRe: vsnprintf() Pin
David Crow14-Sep-09 3:35
David Crow14-Sep-09 3:35 
GeneralRe: vsnprintf() Pin
shriniwas198514-Sep-09 4:40
shriniwas198514-Sep-09 4:40 
GeneralRe: vsnprintf() Pin
norish14-Sep-09 7:32
norish14-Sep-09 7:32 
AnswerRe: vsnprintf() Pin
Joe Woodbury14-Sep-09 8:08
professionalJoe Woodbury14-Sep-09 8:08 
AnswerRe: vsnprintf() Pin
Member 419459314-Sep-09 9:07
Member 419459314-Sep-09 9:07 
QuestionI have to insert value into table at runtime ? Pin
jadhavjitendrar14-Sep-09 0:26
jadhavjitendrar14-Sep-09 0:26 
AnswerRe: I have to insert value into table at runtime ? Pin
«_Superman_»14-Sep-09 0:44
professional«_Superman_»14-Sep-09 0:44 
GeneralRe: I have to insert value into table at runtime ? Pin
jadhavjitendrar14-Sep-09 0:48
jadhavjitendrar14-Sep-09 0:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.