topic stringlengths 1 63 | text stringlengths 1 577k ⌀ |
|---|---|
CLASS modification | Nice Calendar.... |
CLASS modification | [quote="Marc Venken":2ggmd239]Nice Calendar....[/quote:2ggmd239]
Download Complete:
[url:2ggmd239]https://mega.nz/file/cIcwEBaZ#E3PhxjP_GekUMwgN2rOYWN0c00bogblM4WLymsU4fJ8[/url:2ggmd239]
Regards, saludos. |
CLASS modification | Dear Otto,
> Do I make a copy of tcalenda.prg and include it in my App
Usually this is the best way |
CLASS modification | [quote="karinha":2xk3snxb][quote="Marc Venken":2xk3snxb]Nice Calendar....[/quote:2xk3snxb]
Download Complete:
[url:2xk3snxb]https://mega.nz/file/cIcwEBaZ#E3PhxjP_GekUMwgN2rOYWN0c00bogblM4WLymsU4fJ8[/url:2xk3snxb]
Regards, saludos.[/quote:2xk3snxb]
Thank you !! |
CLASS modification | I Wish calendar as datepick where the finale user can select year, mourh etc .
Why i mudt change my oldest applications onlyvehen i must recompilre It for modifications?
It Is not right |
CLASS modification | hi Silvio,
[quote="Silvio.Falconi":f628q0hi]I Wish calendar as datepick where the finale user can select year, mourh etc .
Why i mudt change my oldest applications onlyvehen i must recompilre It for modifications?
It Is not right[/quote:f628q0hi]
Calendar is "SysMonthCal32"
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/create-a-month-calendar-control">https://learn.microsoft.com/en-us/windo ... ar-control</a><!-- m -->
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/month-calendar-control-reference">https://learn.microsoft.com/en-us/windo ... -reference</a><!-- m -->
Datepicker is "SysDateTimePick32"
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/create-a-date-and-time-picker-control">https://learn.microsoft.com/en-us/windo ... er-control</a><!-- m -->
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/date-and-time-picker-control-reference">https://learn.microsoft.com/en-us/windo ... -reference</a><!-- m -->
Difference : Datepicker can show only 1 Month
but you can change Month / Year in "Header"
you can use Calendar as "Date Picker" when set dDate1 = dDate2
but while it have "Start-Date" and "End-Date" you need LbDown / LbUp and not DblClick which will "destroy marker"
[img:f628q0hi]https://i.postimg.cc/Hn5D2fHv/Calendar-Xmas.jpg[/img:f628q0hi]
when include last Modification, which you have found out, both work now
DblClick -> Array(dDate1,dDate2) where dDate1 = dDate2
Ctrl+ (End) click -> mark "Start" to "End" where dDate1 <>,dDate2 |
CLASS modification | Dear Jimmy,
> when include last Modification, which you have found out, both work now
What modification is it ? thanks! |
CLASS modification | [quote="Jimmy":25h5j9vh]hi Silvio,
[quote="Silvio.Falconi":25h5j9vh]I Wish calendar as datepick where the finale user can select year, mourh etc .
Why i mudt change my oldest applications onlyvehen i must recompilre It for modifications?
It Is not right[/quote:25h5j9vh]
Calendar is "SysMonthCal32"
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/create-a-month-calendar-control">https://learn.microsoft.com/en-us/windo ... ar-control</a><!-- m -->
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/month-calendar-control-reference">https://learn.microsoft.com/en-us/windo ... -reference</a><!-- m -->
Datepicker is "SysDateTimePick32"
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/create-a-date-and-time-picker-control">https://learn.microsoft.com/en-us/windo ... er-control</a><!-- m -->
<!-- m --><a class="postlink" href="https://learn.microsoft.com/en-us/windows/win32/controls/date-and-time-picker-control-reference">https://learn.microsoft.com/en-us/windo ... -reference</a><!-- m -->
Difference : Datepicker can show only 1 Month
but you can change Month / Year in "Header"
you can use Calendar as "Date Picker" when set dDate1 = dDate2
but while it have "Start-Date" and "End-Date" you need LbDown / LbUp and not DblClick which will "destroy marker"
[img:25h5j9vh]https://i.postimg.cc/Hn5D2fHv/Calendar-Xmas.jpg[/img:25h5j9vh]
when include last Modification, which you have found out, both work now
DblClick -> Array(dDate1,dDate2) where dDate1 = dDate2
Ctrl+ (End) click -> mark "Start" to "End" where dDate1 <>,dDate2[/quote:25h5j9vh]
[b:25h5j9vh]Sorry, I still don't understand, I'll be slow on the uptake.[/b:25h5j9vh]
[b:25h5j9vh]Read carefully what I write to you[/b:25h5j9vh]
I have an old application that I've been using for many years at school where I have a get (action) control that opens a calendar (Tcalendar class) in a dialog (popup) and the user selects the date.
Now it happened that I had to modify some procedures of that program and I went to recompile and that get while loading the calendar (Tcalendar) doesn't make doubleclick work so it's unusable.
I have to read bullshit or meaningless sentences on the forum, I don't want to use other procedures, I want a calendar like Tcalendar .
I know well the differences between SysDateTimePick32 and SysMonthCal32. with Tcalendar you could select the months and years in a perpetual way and the same thing does datepick unless you have admitted a range of dates
[b:25h5j9vh]I want this[/b:25h5j9vh] ( opened on a dialog popup and the user can select the date)
[img:25h5j9vh]https://i.postimg.cc/fW20RhV6/2.png[/img:25h5j9vh]
[img:25h5j9vh]https://i.postimg.cc/50G1Dptk/3.png[/img:25h5j9vh]
[img:25h5j9vh]https://i.postimg.cc/vmZ4sqQQ/4.png[/img:25h5j9vh]
[b:25h5j9vh]I don't ask for the moon!!![/b:25h5j9vh]
I just ask you to restore my old software, I don't understand why I have to change everything, because the selection of the date is in almost all the program procedures.
[b:25h5j9vh]Tcaledar Modifications [/b:25h5j9vh]
the latest modifications on the Tcaledar class suggested by Cristobal work, ie the user can select a date through the doubleclick system.
But the Tcalendar doesn't work ie the end user can't view the months and years
logically the IsOverDay() function is wrong as I can't find this function determines that the mouse is on the prompt of the days or in other areas.
if you hover the mouse over the name of the month or over the year it is not highlighted !!!
while if you click on the black arrows you can change the month before and after
so it's the Isoverday function that determines where the mouse is positioned
so you have to change this function to isoverday
[code=fw:25h5j9vh]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> ISOVERDAY <span style="color: #000000;">)</span><br /><span style="color: #000000;">{</span><br /> #ifndef _WIN64<br /> HWND hwndMC = <span style="color: #000000;">(</span> HWND <span style="color: #000000;">)</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> #else<br /> HWND hwndMC = <span style="color: #000000;">(</span> HWND <span style="color: #000000;">)</span> hb_parnll<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> #endif<br /> PMCHITTESTINFO pMCHitTest = <span style="color: #000000;">(</span> PMCHITTESTINFO <span style="color: #000000;">)</span> hb_xgrab<span style="color: #000000;">(</span> sizeof <span style="color: #000000;">(</span> MCHITTESTINFO <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> ;<br /> BOOL lOver;<br /> <br /> memset<span style="color: #000000;">(</span> pMCHitTest, <span style="color: #000000;">0</span>, sizeof<span style="color: #000000;">(</span> MCHITTESTINFO <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /> <br /> pMCHitTest->cbSize = sizeof<span style="color: #000000;">(</span> MCHITTESTINFO <span style="color: #000000;">)</span>;<br /> pMCHitTest->pt.y = hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span>;<br /> pMCHitTest->pt.x = hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span>;<br /> <br /> lOver = <span style="color: #000000;">(</span> MonthCal_HitTest<span style="color: #000000;">(</span> hwndMC, pMCHitTest <span style="color: #000000;">)</span> == MCHT_CALENDARDATE <span style="color: #000000;">)</span>;<br /> <br /> hb_xfree<span style="color: #000000;">(</span> pMCHitTest <span style="color: #000000;">)</span>;<br /> <br /> hb_retl<span style="color: #000000;">(</span> lOver <span style="color: #000000;">)</span>;<br /><span style="color: #000000;">}</span></div>[/code:25h5j9vh]
This function determines whether a given point (x, y) on a month calendar control is over a specific day or not. |
CLASS modification | Silvio, As you are one of the young people here in our group, technology and especially your users will soon force you into the web.
Best regards,
Otto |
CLASS modification | [quote="Otto":1nj3bk27]Silvio, As you are one of the young people here in our group, technology and especially your users will soon force you into the web.
Best regards,
Otto[/quote:1nj3bk27]
Otto,
I'm not the youngest of your group, I use fivewin from version 14.4 (1992) [b:1nj3bk27]maybe you are the youngest[/b:1nj3bk27] in fact I don't remember you in the famous outlook newsgroups!!!!
My users will never go on the web with my applications and I have already explained to you several times why
I see no need to create web applications when windows applications and especially basic procedures are not correct
You who make Web applications, can you do everything in Windows system?
I don't think so... there are many things that still don't work properly or you don't care
and I'm not young I'm 57 years of age and in 5 years I'm retiring as a teacher and I don't think I'll make applications in windows but I'll take care of gardening, grandchildren until the last day of my old age |
CLASS modification | Hello Silvio,
[i:24vj4enw]"I'm not the youngest of your group. I've been using fivewin since version 14.4 (1992). Maybe you are the youngest; in fact, I don't remember seeing you in the famous Outlook newsgroups!"[/i:24vj4enw]
This was not Outlook but Compuserve!
[i:24vj4enw]"My users will never access the web with my applications, and I have already explained to you several times why."[/i:24vj4enw]
How do they access windows from their smartphones?
[i:24vj4enw]"I see no need to create web applications when Windows applications, especially basic procedures, are not correct."[/i:24vj4enw]
I mean, you can use webview2 from Fivewin. It's great!
[i:24vj4enw]"You, who make web applications, can you do everything in the Windows system? I don't think so... There are still many things that don't work properly or that you don't care about."[/i:24vj4enw]
I can do it all and more. Ask me something you think can't be done.
[i:24vj4enw]
"And I'm not young; I'm 57 years old. In 5 years, I'll be retiring as a teacher, and I don't think I'll be making applications in Windows anymore. Instead, I'll take care of gardening and my grandchildren until the last day of my old age."[/i:24vj4enw]
I don't believe that. You are such a passionate, creative, and innovative programmer that I am convinced you'll never stop.
Best regards,
Otto |
CLASS modification | [quote="Otto":2ngv4fvk]Hello Silvio,
[i:2ngv4fvk]"I'm not the youngest of your group. I've been using fivewin since version 14.4 (1992). Maybe you are the youngest; in fact, I don't remember seeing you in the famous Outlook newsgroups!"[/i:2ngv4fvk]
This was not Outlook but Compuserve!
[i:2ngv4fvk]"My users will never access the web with my applications, and I have already explained to you several times why."[/i:2ngv4fvk]
How do they access windows from their smartphones?
[i:2ngv4fvk]"I see no need to create web applications when Windows applications, especially basic procedures, are not correct."[/i:2ngv4fvk]
I mean, you can use webview2 from Fivewin. It's great!
[i:2ngv4fvk]"You, who make web applications, can you do everything in the Windows system? I don't think so... There are still many things that don't work properly or that you don't care about."[/i:2ngv4fvk]
I can do it all and more. Ask me something you think can't be done.
[i:2ngv4fvk]
"And I'm not young; I'm 57 years old. In 5 years, I'll be retiring as a teacher, and I don't think I'll be making applications in Windows anymore. Instead, I'll take care of gardening and my grandchildren until the last day of my old age."[/i:2ngv4fvk]
I don't believe that. You are such a passionate, creative, and innovative programmer that I am convinced you'll never stop.
Best regards,
Otto[/quote:2ngv4fvk]
[b:2ngv4fvk]>This was not Outlook but Compuserve![/b:2ngv4fvk]
Sorry I used Outlook express to show fivetech newsgroup and not Had Compuserve!!!!
[b:2ngv4fvk]>How do they access windows from their smartphones?[/b:2ngv4fvk]
why should they make no sense what you say
[b:2ngv4fvk]>I mean, you can use webview2 from Fivewin. It's great![/b:2ngv4fvk]
I don't doubt it, but think about it, can you do everything on windows? Are you sure there is something you wanted and you couldn't do because no one helped you and you were left with the remorse that if you had had those particular procedures now you would have had many more clients than you do today?
[b:2ngv4fvk]>I can do it all and more. Ask me something you think can't be done.[/b:2ngv4fvk]
1) tcalendar Problem
2) dasboard system ( see the forum my messages)
3) xbrowse <-> tree same xbrowse ( width search system all data )
4) insert in the search of the xbrowse that created Nageswarao (@ 10, 550 COMBOBOX oBrw:oSortCbx VAR oBrw:cSortOrder)
the possibility of inserting the options "entries that begin with" and "entries that contain"
and therefore have both possibilities, i.e. for example the search for a city and at the same time the entries starting with ...
5) insert in the same xbrowse the possibility of grouping the records, for example in a product archive grouping by category in the xbrowse or for date of add
[b:2ngv4fvk]these are just the last few things i cant do and i am trying to do in windows[/b:2ngv4fvk]
[b:2ngv4fvk]>I don't believe that. You are such a passionate, creative, and innovative programmer that I am convinced you'll never stop.[/b:2ngv4fvk]
maybe once, lately I'm tired, after my mother's death I lost faith in myself and in others, but how is it possible that I have to waste time with an old software from my school in which I had modified some things, I went to recompile and now the tcalendar doesn't work as before I haven't touched anything in the tcalendar . and it's not the first time that when I recompile I have problems because there's always something wrong |
CLASS modification | Silvio, Compuserv was there long before Outlook.
Regards,
Otto
[quote:3pudg1ay]
Compuserve existed before Outlook. Compuserve, founded in 1969, was one of the earliest commercial online services that provided email, forums, and other communication features. It was a popular platform for accessing online communities and exchanging messages. Microsoft Outlook, on the other hand, is an email client that was introduced in 1997 as part of the Microsoft Office suite. [/quote:3pudg1ay] |
CLASS modification | for tcalendar now I resolved with datepick styles but not refresh the button
[img:xtibfncu]https://i.postimg.cc/3xG0q9Yd/gg.png[/img:xtibfncu] |
CLASS modification | Silvio,
I will turn 77 soon. I love being outdoors, working in my garden, spending time with my 15 grandchildren, attending theater productions, going to Disneyland regularly, and so much more. I also travel.
With age comes wisdom, and that is why I still program and support clients. I have a great balance of time, but everyone I know who does not rigorously exercise their mind as they age, declines in health, and loses happiness. It is very important to continue to challenge your brain, and the logical thought involved in programming is an outstanding way to accomplish this task.
Retirement sounds great until boredom sets in. Too many of my peers are rapidly declining, or passing away, because they didn't stay active physically and mentally.
That is why so many people who retired have gone back to work, even if part time. Idle time is just not healthy.
Tim |
CLASS modification | Otto,
Over a year ago you "strongly encouraged" me to re-build my program for the internet. A year later, and you have 3 people working on this, you have made some nice advances. That is great for YOU ... but for some of us, it's not the focus for our business or clients. Here are a few observations:
[list=]
My clients hire me, and the service I provide. They are not interested in the internet
Most of my clients do not have internet connections strong enough to handle their workload.
My clients who do use internet services complain they never work right, constantly break down, and they can't ever reach support people
I have yet to see an internet program that provides anywhere near the complexity of what my package currently offers
With all the hacking issues, and data theft, my clients don't want to expose their business to net servers
For the small business, like myself, having to provide support to an internet server takes way too much time.
So many companies providing hosted servers last for a short time, and when they shut down, we would have to relocate everything to another server. Not worth it.
[/list]
This is just some of the reasons I have for not converting to a web based platform. I have not lost a single client because of this. Perhaps that is because my clients value the personalized service, and very fast timing, I provide. Also, my clients all run their businesses, and none of them will do it from their phone, ever. Convenient services like text messaging, text to pay, etc. can all be provided from their local computers and clients can respond from their devices. But no one is going to write up a complex, multi-page work order, with perhaps 20 or 30 parts, from their phone. If they want to work on a computer remotely, via the internet, no problem. They do that regularly with what we have setup.
You have every right to be proud of what you are doing, but to be very honest, for many, the web based platforms are not the great option.
I will give one classic example: EMAIL
Many providers now want us to use a web based mail program. For me, that is totally inefficient . I use outlook to monitor 6 different email accounts, all in one place. Emails come in, I see a quick notification, and I can respond right away, or when it is convenient. I keep everything in folders on my computer, and since they are all exchange accounts, they are live on all of my devices. The alternative ? I would have to open 6 different browser tabs, one for each webmail page, and keep them open, along with any other web based programs, throughout the day. I would then have to look at each one separately to view the traffic. HOW INEFFICIENT !!! Outlook puts all of those inboxes into one on my email client, which is fast, informative, and effective.
I've gone on long enough. Not everything belongs on the web. One of my clients summed it up perfectly. He had the opportunity to compare a web based management program to my system. In his words, it was far more expensive, yet couldn't begin to do the things that my software provides. And it was supposed to be the best alternative out there for our industry. He, and others who are solicited all the time, have no interest in making any changes ... |
CLASS modification | [quote="Silvio.Falconi":2el4k0c7]for tcalendar now I resolved with datepick styles but not refresh the button
[img:2el4k0c7]https://i.postimg.cc/3xG0q9Yd/gg.png[/img:2el4k0c7][/quote:2el4k0c7]
when you "close" Datepicker than Notify Event DTN_CLOSEUP is send
[code=fw:2el4k0c7]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">METHOD</span> Notify<span style="color: #000000;">(</span>...<span style="color: #000000;">)</span><br /> ...<br /> <span style="color: #00C800;">case</span> nCode == DTN_CLOSEUP<br /> ::<span style="color: #000000;">lClosed</span> = .T.</div>[/code:2el4k0c7]
Datepicker have VALID where can can place a ACTION into ::bValid Codeblock
[code=fw:2el4k0c7]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #00C800;">if</span> bValid != <span style="color: #00C800;">nil</span><br /> ::<span style="color: #000000;">bValid</span> = <span style="color: #000000;">{</span> || <span style="color: #00C800;">If</span><span style="color: #000000;">(</span> ::<span style="color: #000000;">lClosed</span>, Eval<span style="color: #000000;">(</span> bValid, <span style="color: #00C800;">Self</span> <span style="color: #000000;">)</span>, .F. <span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /> <span style="color: #00C800;">endif</span></div>[/code:2el4k0c7] |
CLASS modification | Hello Tim,
While web-based solutions have become popular and offer certain advantages, there are valid reasons why some businesses may choose to stick with traditional software or systems.
You mentioned several points:
Client Focus, Internet Connection, Complexity of Software, Security and Data Protection, Support and Reliability
While these reasons are understandable, it's worth mentioning that web-based platforms continue to evolve and address many of these concerns. For example, advancements in internet infrastructure, enhanced security measures, and reliable customer support are some areas where improvements have been made.
It's worth keeping an open mind - please see your post to Silvio, which I support 100%.
Thank you for sharing your experiences and insights. If you and your clients are satisfied with the current setup, and it continues to serve you well, it's perfectly valid to maintain the status quo.
However, keep in mind that the transition of one's own software to a web application is not a task that can be completed in a few days - like flipping a switch.
Just as fossil fuel-powered vehicles are gradually being replaced by electric cars, traditional desktop applications are also being phased out in favor of web-based solutions. The advancements in technology and the need for more sustainable and efficient options are driving this transition in both industries.
Best regards,
Otto |
CLASS modification | [quote="Jimmy":q5jpakrb][quote="Silvio.Falconi":q5jpakrb]for tcalendar now I resolved with datepick styles but not refresh the button
[img:q5jpakrb]https://i.postimg.cc/3xG0q9Yd/gg.png[/img:q5jpakrb][/quote:q5jpakrb]
when you "close" Datepicker than Notify Event DTN_CLOSEUP is send
[code=fw:q5jpakrb]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">METHOD</span> Notify<span style="color: #000000;">(</span>...<span style="color: #000000;">)</span><br /> ...<br /> <span style="color: #00C800;">case</span> nCode == DTN_CLOSEUP<br /> ::<span style="color: #000000;">lClosed</span> = .T.</div>[/code:q5jpakrb]
Datepicker have VALID where can can place a ACTION into ::bValid Codeblock
[code=fw:q5jpakrb]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #00C800;">if</span> bValid != <span style="color: #00C800;">nil</span><br /> ::<span style="color: #000000;">bValid</span> = <span style="color: #000000;">{</span> || <span style="color: #00C800;">If</span><span style="color: #000000;">(</span> ::<span style="color: #000000;">lClosed</span>, Eval<span style="color: #000000;">(</span> bValid, <span style="color: #00C800;">Self</span> <span style="color: #000000;">)</span>, .F. <span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /> <span style="color: #00C800;">endif</span></div>[/code:q5jpakrb][/quote:q5jpakrb]
How ?
[code=fw:q5jpakrb]<div class="fw" id="{CB}" style="font-family: monospace;"><br />@ nRow, <span style="color: #000000;">70</span> DTPICKER aGet<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> ddatacambio <span style="color: #0000ff;">OF</span> oDlgSub <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">198</span>, <span style="color: #000000;">25</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"ddd dd mmm yyyy"</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> oBtnGetExchange:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE<br /><br /> @ nRow, <span style="color: #000000;">70</span> <span style="color: #0000ff;">GET</span> aGet<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> nCambio <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">200</span>,<span style="color: #000000;">24</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlgSub <span style="color: #0000ff;">RIGHT</span><br /><br /> @ nRow<span style="color: #000000;">-0.2</span>, <span style="color: #000000;">320</span> <span style="color: #0000ff;">BTNBMP</span> oBtnGetExchange ;<br /> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Aggiorna on line"</span> <span style="color: #0000ff;">OF</span> oDlgSub;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">120</span>, <span style="color: #000000;">24</span> <span style="color: #0000ff;">PIXEL</span> FLAT GDIPLUS ;<br /> BITMAP <span style="color: #ff0000;">"BTN_INTERNET"</span> <span style="color: #0000ff;">LEFT</span> NOROUND ;<br /> <span style="color: #0000ff;">ACTION</span> ...<br /><br /> </div>[/code:q5jpakrb] |
CLASS modification | [quote="Silvio.Falconi":1uf74wft]
How ?
[code=fw:1uf74wft]<div class="fw" id="{CB}" style="font-family: monospace;"><br />@ nRow, <span style="color: #000000;">70</span> DTPICKER aGet<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> ddatacambio <span style="color: #0000ff;">OF</span> oDlgSub <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">198</span>, <span style="color: #000000;">25</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"ddd dd mmm yyyy"</span> ;<br /> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> oBtnGetExchange:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE<br /><br /> @ nRow, <span style="color: #000000;">70</span> <span style="color: #0000ff;">GET</span> aGet<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> nCambio <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">200</span>,<span style="color: #000000;">24</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlgSub <span style="color: #0000ff;">RIGHT</span><br /><br /> @ nRow<span style="color: #000000;">-0.2</span>, <span style="color: #000000;">320</span> <span style="color: #0000ff;">BTNBMP</span> oBtnGetExchange ;<br /> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Aggiorna on line"</span> <span style="color: #0000ff;">OF</span> oDlgSub;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">120</span>, <span style="color: #000000;">24</span> <span style="color: #0000ff;">PIXEL</span> FLAT GDIPLUS ;<br /> BITMAP <span style="color: #ff0000;">"BTN_INTERNET"</span> <span style="color: #0000ff;">LEFT</span> NOROUND ;<br /> <span style="color: #0000ff;">ACTION</span> ...<br /><br /> </div>[/code:1uf74wft][/quote:1uf74wft]
use VALID instead of ON CHANGE |
CLASS modification | Args:
[ 1] = U
Stack Calls
===========
Called from: .\source\classes\CONTROL.PRG => TDATEPICK:LVALID( 983 )
Called from: .\source\classes\CONTROL.PRG => TDATEPICK:FWLOSTFOCUS( 1233 )
Called from: .\source\classes\CONTROL.PRG => TDATEPICK:HANDLEEVENT( 1830 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3560 )
@ nRow, 70 DTPICKER aGet[1] VAR ddatacambio OF oDlgSub SIZE 198, 25 PIXEL ;
FONT oFont UPDATE PICTURE "ddd dd mmm yyyy" ;
VALID oBtnGetExchange:refresh() STYLE DTS_SHOWNONE |
CLASS modification | hi Silvio,
[code=fw:2gvj6unh]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #0000ff;">VALID</span> oBtnGetExchange:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE</div>[/code:2gvj6unh]
you must RETURN a Logic Value for VALID
try this
[code=fw:2gvj6unh]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span>oBtnGetExchange:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, .T.<span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE</div>[/code:2gvj6unh]
or this Way
[code=fw:2gvj6unh]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span> DoSwitch<span style="color: #000000;">(</span> oBtnGetExchange <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE<br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> DoSwitch<span style="color: #000000;">(</span> oBtnGetExchange <span style="color: #000000;">)</span><br /> oBtnGetExchange:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">RETURN</span> .T.</div>[/code:2gvj6unh] |
CLASS modification | [quote="Jimmy":1dg7kxfd]hi Silvio,
[code=fw:1dg7kxfd]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #0000ff;">VALID</span> oBtnGetExchange:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE</div>[/code:1dg7kxfd]
you must RETURN a Logic Value for VALID
try this
[code=fw:1dg7kxfd]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span>oBtnGetExchange:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, .T.<span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE</div>[/code:1dg7kxfd]
or this Way
[code=fw:1dg7kxfd]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span> DoSwitch<span style="color: #000000;">(</span> oBtnGetExchange <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE<br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> DoSwitch<span style="color: #000000;">(</span> oBtnGetExchange <span style="color: #000000;">)</span><br /> oBtnGetExchange:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">RETURN</span> .T.</div>[/code:1dg7kxfd][/quote:1dg7kxfd]
nothing happens, it doesn't make an error, and it doesn't refresh the btnbmp control anyway.
if I press the checkbox of the datepick control or select a different date nothing happens it does not refresh the bnbmp control
the btnbmp control is only refreshed if the user hovers over the get |
CLASS modification | hi Silvio,
i know that CODE work, but what do you want to do when "refresh" BTNBMP <!-- s:?: --><img src="{SMILIES_PATH}/icon_question.gif" alt=":?:" title="Question" /><!-- s:?: -->
i also saw
[code=fw:7dwgjt5l]<div class="fw" id="{CB}" style="font-family: monospace;">@ nRow, <span style="color: #000000;">70</span> DTPICKER<br />@ nRow, <span style="color: #000000;">70</span> <span style="color: #0000ff;">GET</span></div>[/code:7dwgjt5l]
so both are on same Place ... what do you want to do <!-- s:?: --><img src="{SMILIES_PATH}/icon_question.gif" alt=":?:" title="Question" /><!-- s:?: --> |
CLASS modification | [img:24mvdajj]https://i.postimg.cc/3xG0q9Yd/gg.png[/img:24mvdajj]
I press on datepick must refresh the btnbmp
If the user clicks on the datepick control it does not refresh the btnbmp control, however now the user has to move the mouse over the get control to refresh the btnbmp control.
It is the management of the EUR/USD currency exchange the btnbmp control accesses an online service and extracts the monetary quotation, to do this it needs to have a date and a type of currency that's why I needed the empty date. |
CLASS modification | hi Silvio,
[quote="Silvio.Falconi":3ty7w1hh]I press on datepick must refresh the btnbmp[/quote:3ty7w1hh]
i do "see" that BTMBMP "seems disable" <!-- s:?: --><img src="{SMILIES_PATH}/icon_question.gif" alt=":?:" title="Question" /><!-- s:?: -->
when "refresh" it does only "re-paint" but not "enable" it or EVAL() ACTION of BTNBMP
---
i have ask why DTPICKER and GET have "same" Position @ nRow, 70
as you need a String, not Date, you can use DTOC()
to "validate" if a String "is" a Date use CTOD() |
CLASS modification | [b:336yh87a]>i have ask why DTPICKER and GET have "same" Position @ nRow, 70[/b:336yh87a]
[b:336yh87a]because DATEPICK and GET ARE NOT N THE SAME POSITION[/b:336yh87a]
Must I publish all my source code here ?
[code=fw:336yh87a]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #00C800;">local</span> nRow:= <span style="color: #000000;">0</span>,nCol:= <span style="color: #000000;">10</span><br /> <span style="color: #00C800;">local</span> nInterlinea := <span style="color: #000000;">30</span><br /><br /> ddatacambio := oBrw:<span style="color: #000000;">aArraydata</span><span style="color: #000000;">[</span>nRecord<span style="color: #000000;">]</span><span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span><br /> cGiorno := oBrw:<span style="color: #000000;">aArraydata</span><span style="color: #000000;">[</span>nRecord<span style="color: #000000;">]</span><span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span><br /> ncambio := oBrw:<span style="color: #000000;">aArraydata</span><span style="color: #000000;">[</span>nRecord<span style="color: #000000;">]</span><span style="color: #000000;">[</span><span style="color: #000000;">3</span><span style="color: #000000;">]</span><br /><br /><br /> nRow+=<span style="color: #000000;">8</span><br /> @ nRow, <span style="color: #000000;">10</span> <span style="color: #0000ff;">SAY</span> oSay<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Data "</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>,<span style="color: #000000;">25</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlgSub TRANSPARENT <span style="color: #0000ff;">FONT</span> oFont<br /> nRow-=<span style="color: #000000;">2</span><br /> @ nRow, <span style="color: #000000;">70</span> DTPICKER aGet<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> ddatacambio <span style="color: #0000ff;">OF</span> oDlgSub <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">198</span>, <span style="color: #000000;">25</span> <span style="color: #0000ff;">PIXEL</span> ;<br /> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"ddd dd mmm yyyy"</span> ;<br /> <span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span> DoSwitch<span style="color: #000000;">(</span> oBtnGetExchange <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #0000ff;">STYLE</span> DTS_SHOWNONE<br /> nRow+=nInterlinea<br /> @ nRow,<span style="color: #000000;">10</span> <span style="color: #0000ff;">SAY</span> oSay<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Cambio"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>,<span style="color: #000000;">25</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlgSub TRANSPARENT <span style="color: #0000ff;">FONT</span> oFont<br /> nRow-=<span style="color: #000000;">2</span><br /> @ nRow, <span style="color: #000000;">70</span> <span style="color: #0000ff;">GET</span> aGet<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> nCambio <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">200</span>,<span style="color: #000000;">24</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlgSub <span style="color: #0000ff;">RIGHT</span><br /> @ nRow<span style="color: #000000;">-0.2</span>, <span style="color: #000000;">320</span> <span style="color: #0000ff;">BTNBMP</span> oBtnGetExchange ;<br /> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Aggiorna on line"</span> <span style="color: #0000ff;">OF</span> oDlgSub;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">120</span>, <span style="color: #000000;">24</span> <span style="color: #0000ff;">PIXEL</span> FLAT GDIPLUS ;<br /> BITMAP <span style="color: #ff0000;">"BTN_INTERNET"</span> <span style="color: #0000ff;">LEFT</span> NOROUND ;<br /> <span style="color: #0000ff;">ACTION</span> .....<br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br /><br /> <span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> DoSwitch<span style="color: #000000;">(</span> oBtnGetExchange <span style="color: #000000;">)</span><br /> oBtnGetExchange:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">RETURN</span> .T.</div>[/code:336yh87a]
>i do "see" that BTMBMP "seems disable" <!-- s:?: --><img src="{SMILIES_PATH}/icon_question.gif" alt=":?:" title="Question" /><!-- s:?: -->
>when "refresh" it does only "re-paint" but not "enable" it or EVAL() ACTION of BTNBMP
yes the btnbmp must be disabled, only when there is a valid data the btnbmp must be enable, on init the ddatacambio is ctod('') |
CLASS modification | hi Silvio,
[quote="Silvio.Falconi":nt3fej6s]yes the btnbmp must be disabled, only when there is a valid data the btnbmp must be enable, on init the ddatacambio is ctod('')[/quote:nt3fej6s]
i do not "see" CODE which "enable" or "disable" BTNBMP
as i say "Refresh" does only "paint" Control but did not "modify" it
[code=fw:nt3fej6s]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #0000ff;">VALID</span> <span style="color: #000000;">(</span> DoSwitch<span style="color: #000000;">(</span> ddatacambio, oBtnGetExchange<span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> DoSwitch<span style="color: #000000;">(</span> ddatacambio, oBtnGetExchange <span style="color: #000000;">)</span><br /><span style="color: #00C800;">LOCAL</span> dDate := ddatacambio:<span style="color: #000000;">GetDate</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /><span style="color: #00C800;">LOCAL</span> cDate := DTOC<span style="color: #000000;">(</span>dDate<span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">IF</span> EMPTY<span style="color: #000000;">(</span>cDate<span style="color: #000000;">)</span><br /> oBtnGetExchange:<span style="color: #000000;">Disable</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">ELSE</span><br /> oBtnGetExchange:<span style="color: #000000;">enable</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">ENDIF</span><br /> oBtnGetExchange:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">RETURN</span> .T.</div>[/code:nt3fej6s] |
CLASS modification | [b:1qa7op63]Error[/b:1qa7op63]
[img:1qa7op63]https://i.postimg.cc/FzRZgz7S/f.gif[/img:1qa7op63]
[code=fw:1qa7op63]<div class="fw" id="{CB}" style="font-family: monospace;">Application<br />===========<br /> Path and <span style="color: #0000ff;">name</span>: <span style="color: #000000;">C</span>:\Work\Prg\valute\Pvalute.Exe <span style="color: #000000;">(</span><span style="color: #000000;">32</span> bits<span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">Size</span>: <span style="color: #000000;">4</span>,<span style="color: #000000;">631</span>,<span style="color: #000000;">040</span> bytes<br /> Compiler version: <span style="color: #000000;">Harbour</span> <span style="color: #000000;">3.2</span>.0dev <span style="color: #000000;">(</span>r2104281802<span style="color: #000000;">)</span><br /> FiveWin version: <span style="color: #000000;">FWH</span> <span style="color: #000000;">22.03</span><br /> C compiler version: <span style="color: #000000;">Borland</span> C++ <span style="color: #000000;">5.8</span><span style="color: #000000;">.2</span> <span style="color: #000000;">(</span><span style="color: #000000;">32</span>-bit<span style="color: #000000;">)</span><br /> Windows version: <span style="color: #000000;">6.2</span>, Build <span style="color: #000000;">9200</span> <br /><br /> Time <span style="color: #0000ff;">from</span> start: <span style="color: #000000;">0</span> hours <span style="color: #000000;">0</span> mins <span style="color: #000000;">15</span> secs <br /> Error occurred <span style="color: #00C800;">at</span>: <span style="color: #000000;">05</span><span style="color: #000000;">-06</span><span style="color: #000000;">-2023</span>, <span style="color: #000000;">09</span>:<span style="color: #000000;">06</span>:<span style="color: #000000;">37</span><br /> Error description: <span style="color: #000000;">Error</span> BASE/<span style="color: #000000;">1004</span> Metodo non disponibile: <span style="color: #000000;">GETDATE</span><br /> Args:<br /> <span style="color: #000000;">[</span> <span style="color: #000000;">1</span><span style="color: #000000;">]</span> = D <span style="color: #000000;">05</span><span style="color: #000000;">-06</span><span style="color: #000000;">-2023</span><br /><br />Stack Calls<br />===========<br /> Called <span style="color: #0000ff;">from</span>: => GETDATE<span style="color: #000000;">(</span> <span style="color: #000000;">0</span> <span style="color: #000000;">)</span><br /> Called <span style="color: #0000ff;">from</span>: <span style="color: #000000;">source</span>\Pvalute.prg => DOSWITCH<span style="color: #000000;">(</span> <span style="color: #000000;">1134</span> <span style="color: #000000;">)</span><br /> Called <span style="color: #0000ff;">from</span>: <span style="color: #000000;">source</span>\Pvalute.prg => <span style="color: #000000;">(</span>b<span style="color: #000000;">)</span>EDIT_STORICO<span style="color: #000000;">(</span> <span style="color: #000000;">1085</span> <span style="color: #000000;">)</span><br /> Called <span style="color: #0000ff;">from</span>: .\source\classes\TDTPICKE.PRG => <span style="color: #000000;">(</span>b<span style="color: #000000;">)</span>TDATEPICK_NEW<span style="color: #000000;">(</span> <span style="color: #000000;">168</span> <span style="color: #000000;">)</span></div>[/code:1qa7op63] |
CLASSE DSAY.PRG CON COMANDO TRANSPARENT | Buenas...
Hola Foro. Necesito di una DSAY.PRG y DSAY.CH modificada para el uso del comando TRANSPARENT.
És posible??
<!-- e --><a href="mailto:kmt_karinha@pop.com.br">kmt_karinha@pop.com.br</a><!-- e -->
Gracias, Saludos a todos. |
CLASSE DSAY.PRG CON COMANDO TRANSPARENT | João,
[code:20jxgzwe]
METHOD Paint() CLASS TDSay
local n
local nColorShadow, nColorLight
::GetDC()
if ::lActive
if ::lView
if ::lTransparent .and. ! Empty( ::oBrush:hBitmap )
SetBrushOrgEx( ::hDC, nBmpWidth( ::oBrush:hBitmap ) - ::nLeft, nBmpHeight( ::oBrush:hBitmap ) - ::nTop )
FillRect( ::hDC, GetClientRect( ::hWnd ), ::oBrush:hBrush )
endif
for n := 1 to len( ::aCaption )
...
[/code:20jxgzwe]
Also this fix is required in control.prg:
[code:20jxgzwe]
METHOD Initiate( hDlg ) CLASS TControl
...
if ::lTransparent
::SetBrush( ::oWnd:oBrush )
else
::SetBrush( TBrush():New( "NULL" ) )
endif
return nil
[/code:20jxgzwe] |
CLASSE DSAY.PRG CON COMANDO TRANSPARENT | Antonio,
thanks a lot !!! <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: -->
Saludos,
Félix |
CLASSE DSAY.PRG CON COMANDO TRANSPARENT | Antonio, No Funciono... Ke hice errado??
Aplicacao:
===========
Caminho(Path): C:\PDVXB\BALCAOW.EXE (32 bits)
Tamanho: 3,496,960 bytes
Hora Inicial: 0 hours 0 mins 1 secs
Ocorrencia de Erro: 21/02/06, 11:43:58
Descricao do Erro: Error BASE/1004 Message not found: TDSAY:LTRANSPARENT
Chamada da Pilha:
=================
Chamada De: TDSAY:ERROR(179)
Chamada De: (b)HBOBJECT:HBOBJECT(105)
Chamada De: TDSAY:MSGNOTFOUND(0)
Chamada De: TDSAY:LTRANSPARENT(167)
Chamada De: TCONTROL:INITIATE(378)
Chamada De: (b)TDSAY:TDSAY(68)
Chamada De: TDSAY:INITIATE(0)
Chamada De: __OBJSENDMSG(0)
Chamada De: OSEND(224)
Chamada De: ASEND(175)
Chamada De: TDIALOG:INITIATE(638)
Chamada De: TDIALOG:HANDLEEVENT(855)
Chamada De: DIALOGBOXINDIRECT(0)
Chamada De: TDIALOG:ACTIVATE(264)
Chamada De: SENHA2(335)
Chamada De: SENHA(137)
Chamada De: MAIN(295) |
CLASSE DSAY.PRG CON COMANDO TRANSPARENT | //-> CLASSE DSAY.PRG
METHOD Paint() CLASS TDSay
local n
local nColorShadow, nColorLight
::GetDC()
if ::lActive
if ::lView
//-> Modificado Por Antonio Linares, em 20/02/2006 Para TRANSPARENT
if ::lTransparent .and. ! Empty( ::oBrush:hBitmap )
SetBrushOrgEx( ::hDC, nBmpWidth( ::oBrush:hBitmap ) - ::nLeft, nBmpHeight( ::oBrush:hBitmap ) - ::nTop )
FillRect( ::hDC, GetClientRect( ::hWnd ), ::oBrush:hBrush )
endif
for n := 1 to len( ::aCaption )
WSay( ::hWnd, ::hDC, ::nDTop + ( n - 1 ) * ::nTxtHeight, ::nDLeft, ::aCaption[ n ], ::nClrText,,;
If( ::oFont != nil, ::oFont:hFont, 0 ), .T., .T., ::nAlign )
next
if ::lScroll .and. ::lWrap
if ::lHorizontal
for n := 1 to len( ::aCaption )
WSay( ::hWnd, ::hDC, ::nDTop + ( n - 1 ) * ::nTxtHeight, ::nDLeft + ::nLong, ::aCaption[ n ], ::nClrText,,;
If( ::oFont != nil, ::oFont:hFont, 0 ), .T., .T., ::nAlign )
next
else
for n := 1 to len( ::aCaption )
WSay( ::hWnd, ::hDC, ::nDTop + ( n - 1 ) * ::nTxtHeight + ::nLong, ::nDLeft, ::aCaption[ n ], ::nClrText,,;
If( ::oFont != nil, ::oFont:hFont, 0 ), .T., .T., ::nAlign )
next
endif
endif
else
InvalidateRect( ::hWnd, ::aRect, .t. )
endif
else
nColorShadow := GetSysColor( COLOR_BTNSHADOW )
nColorLight := GetSysColor( COLOR_BTNHIGHLIGHT )
for n := 1 to len( ::aCaption )
WSay( ::hWnd, ::hDC, ::nDTop + ( n - 1 ) * ::nTxtHeight + 1, ::nDLeft + 1, ::aCaption[ n ], nColorLight,,;
If( ::oFont != nil, ::oFont:hFont, 0 ), .T., .T., ::nAlign )
WSay( ::hWnd, ::hDC, ::nDTop + ( n - 1 ) * ::nTxtHeight, ::nDLeft, ::aCaption[ n ], nColorShadow,,;
If( ::oFont != nil, ::oFont:hFont, 0 ), .T., .T., ::nAlign )
next
endif
// 3D
if ::lShaded
WndInset( ::hWnd, ::hDC ) // SHADED, SHADOW
endif
if ::lRaised
WndRaised( ::hWnd, ::hDC ) // RAISED
endif
if ::lBox
WndBoxIn( ::hDC, 0, 0, ::nBottom-::nTop, ::nRight-::nLeft )
WndBoxRaised( ::hDC, 1, 1, ::nBottom-::nTop-1, ::nRight-::nLeft-1 )
endif
::ReleaseDC()
return nil |
CLASSE DSAY.PRG CON COMANDO TRANSPARENT | CLASSE CONTROL.PRG
METHOD Initiate( hDlg ) CLASS TControl
DEFAULT ::lActive := .t., ::lDrag := .f., ::lCaptured := .f.,;
::lFocused := .f., ::lCancel := .f.
if( ( ::hWnd := GetDlgItem( hDlg, ::nId ) ) != 0 )
If( ::lActive, ::Enable(), ::Disable() )
::Link()
if ::oFont != nil
::SetFont( ::oFont )
else
::GetFont()
endif
else
#define NOVALID_CONTROLID 1
Eval( ErrorBlock(), _FWGenError( NOVALID_CONTROLID, "No: " + ;
Str( ::nId, 6 ) ) )
endif
//->Modificado Por Antonio Linares, em 20/02/2006 Para TRANSPARENT em DSAY.PRG
if ::lTransparent
::SetBrush( ::oWnd:oBrush )
else
::SetBrush( TBrush():New( "NULL" ) )
endif
return nil |
CLASSE RADIO | É possível colocar na Horizontal os BT de Rádio isto é:@ 1, 0 RADIO btradio ; ITEMS "&One", "&Two", "T&hree" SIZE 80, 15; ON CHANGE MsgBeep() OF oWndResulta isto:- One- Two- ThreeMas eu queria assim: - One - Two - ThreeSerá que é possível?Obrigado |
CLASSE RADIO | Sergio,test.prg[code:2l01i45l]
#include "FWCE.ch"
function Main()
local oDlg, oRad, nValue := 1
DEFINE DIALOG oDlg SIZE 230, 100
@ 0.2, 2 RADIO oRad VAR nValue ITEMS "One" OF oDlg SIZE 25, 20
@ 0.2, 6 RADIOITEM "Two" RADIOMENU oRad OF oDlg SIZE 25, 20
@ 0.2, 10 RADIOITEM "Three" RADIOMENU oRad OF oDlg SIZE 25, 20
@ 1.7, 7 BUTTON "Value" OF oDlg ACTION MsgInfo( nValue )
ACTIVATE DIALOG oDlg CENTERED
return nil
[/code:2l01i45l][url=http://imageshack.us:2l01i45l][img:2l01i45l]http://img295.imageshack.us/img295/2760/radiosbp6.jpg[/img:2l01i45l][/url:2l01i45l] |
CLASSE RADIO | Obrigado LinaresE Como faço para mudificar o tipo e tamanho de Letra? |
CLAUSE @ FOLDER ...BOTTOM | @ 0, 0 FOLDER oFld PROMPTS "General", "Nivel", "Note","Other" ;
SIZE 240,290 PIXEL BOTTOM
NOT RUN ? |
CLAUSE @ FOLDER ...BOTTOM | Hello Silvio,
try it this way:
oFld := TFolder():New( 0, 0, {"Generale", "Dettagli", "Note"}, {},,,,, .F., .F., 240, 95,, .F.,, .T. )
Best regards,
Otto |
CLAUSE IN ERROR WHEN GET FOLDER NE / FOLDEEX | hello everyone, I have the following situation in tfolder and tfolderex:
use the when clause to enable or disable gets the folder / folderex.
operate normally without the folder when I change the variable value to false lBrowse.
gets where they should be enabled and not enabled, refresh setoption already did before and do not refresh enables gets.
with normal folder when Fando FiveWin change the variable value to enable gets if I click on the second tab and then return to the first shows there apeans more so. tfolderex now not working right.
Daniel or if someone there can help me thank you, 'cause do not want to get get: enable, so I created the variable lBrowse to be more practical and organized the code.
sorry my bad inglish, i used google translator, rsrsrsrs.
#DEFINE AbaCadastro oFldEmpresa:aDialogs[01]
local lBrowse:=.T.
REDEFINE COMBOBOX oEstado VAR oDbfEmpresa:UF ITEMS aEstados ID 117 OF AbaCadastro;
WHEN !lBrowse UPDATE; |
CLAUSE IN ERROR WHEN GET FOLDER NE / FOLDEEX | Don't know if I understood your problem but try using
[code=fw:2h34qpqe]<div class="fw" id="{CB}" style="font-family: monospace;">oFldEmpresa:<span style="color: #000000;">aDialogs</span><span style="color: #000000;">[</span><span style="color: #000000;">01</span><span style="color: #000000;">]</span>:<span style="color: #000000;">AEvalWhen</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span></div>[/code:2h34qpqe]
EMG |
CLIENTE/SERVIDOR | Antonio, como se puede trabajar con clipper+fivewin como Cliente/Servidor.
Saludos |
CLIENTE/SERVIDOR | [quote="jbrita":3vn8xiud]Antonio, como se puede trabajar con clipper+fivewin como Cliente/Servidor.
Saludos[/quote:3vn8xiud]
Claro que si, para DBFs con Advantage Database Server:
Mirate este ejemplo:
<!-- m --><a class="postlink" href="http://www.google.d2g.com/ads/demos/aiswin32.zip">http://www.google.d2g.com/ads/demos/aiswin32.zip</a><!-- m -->
Y con SQL via ADO
Mas info:
<!-- m --><a class="postlink" href="http://www.google.com/ads.htm">http://www.google.com/ads.htm</a><!-- m --> |
CLIENTE/SERVIDOR | Gracias por responder Rene pero se ve Lento no habra una manera mas rapido.
Saludos |
CLIENTE/SERVIDOR | Depende de la parte del mundo donde estes.
Los datos estan en nuestro servidor en Cd. de Mexico. Conectado por ADS de 2 mbps.
Nuestros clientes que usan esta tecnologica usualmente estan conectados por ADSL de 512 kbps y dentro del mismo pais tenemos una estupenda velocidad de respuesta, como si estuvieras en la red local. |
CLIENTE/SERVIDOR | eagle 1 de manuel exposito es buenasa
no he probado condor pero deber se tambien buena
Saludos |
CLIP2HARB | ¿Es obligatorio utilizar CLIP2HARB para crear funciones C para xHarbour?
Resulta que tengo alguna utilidad en C a 16 bit que quiero pasar a 32 bits pero tras pasar el CLIP2HARB y compilar con BCC32 me dice que HB_FUNC está repetida y no compila. ¿que tengo que hacer, una funcion por fichero? o hay otra solucion. Con una sola funcion por fichero compila, pero me advierte de que el parámetro que paso a la funcion HB_FUNC ( nombre de la antigua funcion 16 bits) no se está utilizando.
Por ultimo. Tras hacer el OBJ. Como lo utilizo con VERCE, ¿Metiendolo donde los demas OBJ (no me funciona)?¿Creando una LIB primero?¿o hay otra solucion?
Gracias de antemano
Un saludo |
CLIP2HARB | > ¿Es obligatorio utilizar CLIP2HARB para crear funciones C para xHarbour?
No es obligatorio. FWH lo usa para asi poder usar los mismos ficheros C desde 16 (con Clipper) ó 32 bits (con Harbour). |
CLIP2HARB | ¿Entonces compilando los de 16 bit con BCC32 sin modificarlos me servirían para Harbour? |
CLIP2HARB | Por cierto, que hago con el OBJ desde Verce. ¿O monto una LIB? ¿Que es mejor?
Muchas Gracias |
CLIP2HARB | Si usas los ficheros de cabecera correctos, puedes usarlos perfectamente con Harbour.
Nosotros no usamos Verce. Usamos y recomendamos UEStudio |
CLIP2HARB | Vale. Gracias.
Buscare el UEStudio y lo probaré |
CLIPPER/FIVEWIN COMUNICACION SERIAL COMM | Estoy desarrollando una aplicacion en Clipper/Fivewin que usa un lector de huella digital, necesito comunicarme con el decodificador por un puerto comm RS232, enviar y recibir comandos (nibbles), me podrian decir si existen las instrucciones necesarias para esto o que me recomienden un software de comunicacion.
Se los voy agradecer mucho. <!-- s:roll: --><img src="{SMILIES_PATH}/icon_rolleyes.gif" alt=":roll:" title="Rolling Eyes" /><!-- s:roll: --> |
CLIPPER/FIVEWIN COMUNICACION SERIAL COMM | Hugo,
Puedes revisar ejemplos en samples\phone.prg ó uno más complejo en samples\comm\* |
CLase Timprime/Utilprn Da error | Saludos al Forum
CLase Timprime/Utilprn Da error, [b:3cdyv5kh]Error (6) Enhanced metafile Error description[/b:3cdyv5kh]
Cuando el reporte es de una pagina funciiona bien , el problema es cuando es ma de una pagina. |
CLase Timprime/Utilprn Da error | Si no eres más especifico , poco o nada podemos hacer.
La uso sin problemas, con cientos de paginas.
Quizás sea problema de permisos o similar. Fijate que te da un error DOS 6, 06 Invalid handle. Quizás no pudo abrir el fichero.
Seguramente, falla en la rutina de la impresion de pagina 1 de XXX.
Indica a TImprime que no te ponga la numeración. |
CLase Timprime/Utilprn Da error | Gracias compañero por su respuesta que version usas de fwh,
hasta la version fwh 11.09 funciona perfecto, cuando emigro a la fwh 11.11 genera este problema, no se si alguien pueda hacer la prueba con esta clase.
Compile los ejemplos que bienen con la clase, y pasa lo mismo. |
CLase Timprime/Utilprn Da error | Pues entonces el culpable es de FWh 11.11 <!-- s;-) --><img src="{SMILIES_PATH}/icon_wink.gif" alt=";-)" title="Wink" /><!-- s;-) -->
No tengo esa versión, tendrías que ver las diferencias en fivewin. |
CLase Timprime/Utilprn Da error | [quote="thefull":30p99rl2]Pues entonces el culpable es de FWh 11.11 <!-- s;-) --><img src="{SMILIES_PATH}/icon_wink.gif" alt=";-)" title="Wink" /><!-- s;-) -->
No tengo esa versión, tendrías que ver las diferencias en fivewin.[/quote:30p99rl2]
Cual es tu email |
CLase Timprime/Utilprn Da error | Tienes que mirar diferencias en la clase TPRINTER, seguramente se tocó alguna cosa.
Yo suo la FWH/FWHX 10.8 07/Sep/2010
Lo acabo de poner en la firma. |
CLase Timprime/Utilprn Da error | ESO PASA CUANDO FALTA UN ENDPAGE |
CLase Timprime/Utilprn Da error com Fwh1309 | Path and name: D:\LJ2000\LJ-Frente.exe (32 bits)
Size: 4,390,912 bytes
Compiler version: xHarbour 1.2.3 Intl. (SimpLex) (Build 20130422)
FiveWin Version: FWHX 13.08
Windows version: 6.1, Build 7601 Service Pack 1
Time from start: 0 hours 0 mins 46 secs
Error occurred at: 03/12/2013, 16:30:13
Error description: Error BASE/1004 Class: 'NIL' has no exported method: BOXMSG
Args:
[ 1] = U
[ 2] = U
[ 3] = U
[ 4] = U
[ 5] = U
[ 6] = U
[ 7] = O TPEN
[ 8] = L .T.
[ 9] = N 18
[ 10] = N 18
[ 11] = A { ... }
[ 12] = N 0.60
[ 13] = N 0
[ 14] = U
[ 15] = U
[ 16] = U
[ 17] = N 0.25
[ 18] = N 2
[ 19] = L .T.
[ 20] = N 0.1
[ 21] = U
[ 22] = O TPEN
[ 23] = L .T.
[ 24] = U
[ 25] = L .F.
Stack Calls
===========
Called from: => BOXMSG( 0 )
Called from: ImpCupom.prg => TIMPCUPOMWIN:CABECALHO( 1087 )
Called from: ImpCupom.prg => TIMPCUPOMWIN:NEW( 1054 )
Called from: ImpCupom.prg => (b)EMITEPEDIDOVENDA( 156 )
Called from: btnbmp.prg => TBTNBMP:CLICK( 492 )
Called from: btnbmp.prg => TBTNBMP:LBUTTONUP( 689 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1723 )
Called from: btnbmp.prg => TBTNBMP:HANDLEEVENT( 1447 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3236 )
Called from: => DIALOGBOX( 0 )
Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 274 )
Called from: ImpCupom.prg => EMITEPEDIDOVENDA( 188 )
Called from: Checkout.Prg => GRAVAORCAMENTO( 8349 )
Called from: Checkout.Prg => BTNFECHA( 8050 )
Called from: Checkout.Prg => TECLAPRESS( 1943 )
Called from: Checkout.Prg => (b)CHECKOUT( 1254 )
Called from: .\source\classes\WINDOW.PRG => TWINDOW:KEYDOWN( 2652 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:KEYDOWN( 1047 )
Called from: .\source\classes\XBROWSE.PRG => TXBROWSE:KEYDOWN( 2362 )
Called from: => TWINDOW:HANDLEEVENT( 0 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1733 )
Called from: .\source\classes\XBROWSE.PRG => TXBROWSE:HANDLEEVENT( 12140 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3236 )
Called from: => WINRUN( 0 )
Called from: .\source\classes\WINDOW.PRG => TWINDOW:ACTIVATE( 1003 )
Called from: Checkout.Prg => LOJAFRENTE( 781 ) |
CLase Timprime/Utilprn Da error com Fwh1309 | Estoy usando la clase timprime de Rafa con fwh1309 y xharbour123 está dando error, parece que no puede inicializar los objetos que se encuentran dentro de la clase, hasta el lanzamiento de fwh1201 xharbour121 y funcionaban normalmente. |
CLase Todometer de Ramón Avendaño | Hola a tod@s,
Alguien tine la clase Odometer de Ramón Avendaño para 32b.
Gracias de antemano |
CLase Todometer de Ramón Avendaño | Hola yo se de la paginita del señor Avendaño <!-- m --><a class="postlink" href="http://personales.mundivia.es/rar/">http://personales.mundivia.es/rar/</a><!-- m -->
pero no sepo si funcione lo que ahí esta
Saluditos <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: --> |
CLase Todometer de Ramón Avendaño | Gracias AIDA,
Ya conozco la página, todo lo que ahí esta funciona a la perfección en FW para Clipper, pero en concreto la clase Odometer no funciona en FWH ya que hace uso de unas rutinas en C que habría que portar de 16 a 32 bits.
Espero que algún compañero del foro la tenga portada o alguien con conocimientos en C lo pueda hacer.
Gracias por tu interés.
Saluditos <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: --> |
CLase Todometer de Ramón Avendaño | Aqui esta el codiguito en "C" a ver si alguien del foro que sepa mucho del "C" nos ayuda
Gracias <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: -->
[code=fw:226jc9s3]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <WinTen.h><br /><span style="color: #00D7D7;">#include</span> <Windows.h><br /><span style="color: #00D7D7;">#include</span> <ShellApi.h><br /><span style="color: #00D7D7;">#include</span> <ClipApi.h><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br />CLIPPER DRAWDIGIT<span style="color: #000000;">(</span> PARAMS <span style="color: #000000;">)</span> <span style="color: #B900B9;">// hDC, nTop, nLeft, nBottom, nRight, cDigit, nPos, </span><br /> <span style="color: #B900B9;">// hFont, nClrPane, nClrText </span><br /><span style="color: #000000;">{</span><br /> <br /> HDC hDC = <span style="color: #000000;">(</span> HDC <span style="color: #000000;">)</span> _parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> long wRow; <br /> long wCol;<br /><br /> RECT rct;<br /> <br /> LPSTR szChar = _parc<span style="color: #000000;">(</span> <span style="color: #000000;">6</span> <span style="color: #000000;">)</span>;<br /> LPSTR szChar_ = <span style="color: #ff0000;">"0"</span>;<br /> <br /> int nPos = _parnl<span style="color: #000000;">(</span> <span style="color: #000000;">7</span> <span style="color: #000000;">)</span>;<br /> <br /> COLORREF nClrBack = _parnl<span style="color: #000000;">(</span> <span style="color: #000000;">9</span> <span style="color: #000000;">)</span>;<br /> COLORREF nClrFore = _parnl<span style="color: #000000;">(</span> <span style="color: #000000;">10</span> <span style="color: #000000;">)</span>;<br /><br /> HFONT hFont = <span style="color: #000000;">(</span> HFONT <span style="color: #000000;">)</span> _parnl<span style="color: #000000;">(</span> <span style="color: #000000;">8</span> <span style="color: #000000;">)</span>;<br /> HFONT hOldFont;<br /><br /> TEXTMETRIC tm;<br /><br /> DWORD dwCWidth;<br /><br /> int nHeight;<br /><br /> <span style="color: #00C800;">if</span><span style="color: #000000;">(</span> hFont <span style="color: #000000;">)</span><br /> hOldFont = SelectObject<span style="color: #000000;">(</span> hDC, hFont <span style="color: #000000;">)</span>;<br /><br /> GetTextMetrics<span style="color: #000000;">(</span> hDC, &tm <span style="color: #000000;">)</span>;<br /><br /> szChar_<span style="color: #000000;">[</span> <span style="color: #000000;">0</span> <span style="color: #000000;">]</span> = szChar<span style="color: #000000;">[</span> <span style="color: #000000;">0</span> <span style="color: #000000;">]</span> + <span style="color: #000000;">1</span>;<br /> <span style="color: #00C800;">if</span> <span style="color: #000000;">(</span> szChar_<span style="color: #000000;">[</span> <span style="color: #000000;">0</span> <span style="color: #000000;">]</span> == <span style="color: #ff0000;">':'</span> <span style="color: #000000;">)</span> szChar_<span style="color: #000000;">[</span> <span style="color: #000000;">0</span> <span style="color: #000000;">]</span> = <span style="color: #ff0000;">'0'</span>;<br /><br /> rct.top = _parni<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span>;<br /> rct.<span style="color: #0000ff;">left</span> = _parni<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span>;<br /> rct.bottom = _parni<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span>;<br /> rct.<span style="color: #0000ff;">right</span> = _parni<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>;<br /><br /> dwCWidth = <span style="color: #0000ff;">MAX</span><span style="color: #000000;">(</span> GetTextExtent<span style="color: #000000;">(</span> hDC, szChar, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>, tm.tmAveCharWidth <span style="color: #000000;">)</span>;<br /><br /> wCol = <span style="color: #000000;">(</span> rct.<span style="color: #0000ff;">right</span> + rct.<span style="color: #0000ff;">left</span> - dwCWidth + <span style="color: #000000;">1</span> <span style="color: #000000;">)</span> / <span style="color: #000000;">2</span>;<br /> wRow = rct.top - <span style="color: #000000;">1</span>;<br /><br /> <span style="color: #00C800;">if</span> <span style="color: #000000;">(</span> nPos > <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> nHeight = rct.top - rct.bottom;<br /> <span style="color: #00C800;">else</span> nHeight = rct.bottom - rct.top;<br /><br /> SetTextColor<span style="color: #000000;">(</span> hDC, nClrFore <span style="color: #000000;">)</span>;<br /> SetBkColor<span style="color: #000000;">(</span> hDC, nClrBack <span style="color: #000000;">)</span>;<br /><br /> ExtTextOut<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span>, <span style="color: #000000;">1</span>, ETO_OPAQUE, &rct, <span style="color: #ff0000;">""</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span>;<br /> ExtTextOut<span style="color: #000000;">(</span> hDC, wCol, wRow + nPos, ETO_CLIPPED, &rct, szChar, <span style="color: #000000;">1</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span>;<br /> ExtTextOut<span style="color: #000000;">(</span> hDC, wCol, wRow + nPos + nHeight, ETO_CLIPPED, &rct, szChar_, <span style="color: #000000;">1</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span>;<br /> <span style="color: #B900B9;">// DrawText( hDC, szChar, 1, &rct, (DT_CENTER || DT_VCENTER) );</span><br /><br /> <span style="color: #00C800;">if</span><span style="color: #000000;">(</span> hFont <span style="color: #000000;">)</span><br /> SelectObject<span style="color: #000000;">(</span> hDC, hOldFont <span style="color: #000000;">)</span>;<br /><br /> _ret<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br /><br /><span style="color: #000000;">}</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br />CLIPPER DIGITSBOX<span style="color: #000000;">(</span> PARAMS <span style="color: #000000;">)</span> <span style="color: #B900B9;">// hWnd, nDigits, nHeight, nWidth, l3D</span><br /><span style="color: #000000;">{</span><br /><br /> int i;<br /><br /> HWND hWnd = <span style="color: #000000;">(</span> HWND <span style="color: #000000;">)</span> _parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /><br /> WORD wDigits = _parni<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span>;<br /><br /> WORD wHeight = _parni<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span>;<br /> WORD wWidth = _parni<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span>;<br /><br /> WORD wCol = <span style="color: #000000;">1</span>;<br /> WORD wLong = wDigits * wWidth + <span style="color: #000000;">1</span>;<br /><br /> HPEN hPBlack = CreatePen<span style="color: #000000;">(</span> PS_SOLID, <span style="color: #000000;">1</span>, RGB<span style="color: #000000;">(</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /><br /> BOOL b3DLook = _parl<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>;<br /><br /> HPEN hPUpLeft;<br /> HPEN hPBotRit;<br /><br /> HDC hDC = GetDC<span style="color: #000000;">(</span> hWnd <span style="color: #000000;">)</span>;<br /><br /> HPEN hOldPen = SelectObject<span style="color: #000000;">(</span> hDC, hPBlack <span style="color: #000000;">)</span>;<br /><br /> MoveTo<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, wLong, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, wLong, wHeight <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span>, wHeight <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">1</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /><br /> <span style="color: #00C800;">for</span> <span style="color: #000000;">(</span> i = <span style="color: #000000;">1</span>; i < wDigits ; i++ <span style="color: #000000;">)</span><br /> <span style="color: #000000;">{</span><br /> wCol += wWidth;<br /><br /> MoveTo<span style="color: #000000;">(</span> hDC, wCol, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, wCol, wHeight <span style="color: #000000;">)</span>;<br /><br /> <span style="color: #000000;">}</span><br /><br /> <span style="color: #00C800;">if</span> <span style="color: #000000;">(</span> b3DLook <span style="color: #000000;">)</span><br /> <span style="color: #000000;">{</span><br /> hPUpLeft = CreatePen<span style="color: #000000;">(</span> PS_SOLID, <span style="color: #000000;">1</span>, GetSysColor<span style="color: #000000;">(</span> COLOR_BTNSHADOW <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /> hPBotRit = CreatePen<span style="color: #000000;">(</span> PS_SOLID, <span style="color: #000000;">1</span>, GetSysColor<span style="color: #000000;">(</span> COLOR_BTNHIGHLIGHT <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /><br /> SelectObject<span style="color: #000000;">(</span> hDC, hPUpLeft <span style="color: #000000;">)</span>;<br /> MoveTo<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">0</span>, wHeight + <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, wLong + <span style="color: #000000;">1</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">)</span>;<br /><br /> SelectObject<span style="color: #000000;">(</span> hDC, hPBotRit <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, wLong + <span style="color: #000000;">1</span>, wHeight + <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /> LineTo<span style="color: #000000;">(</span> hDC, <span style="color: #000000;">0</span>, wHeight + <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>;<br /><br /> DeleteObject<span style="color: #000000;">(</span> hPUpLeft <span style="color: #000000;">)</span>;<br /> DeleteObject<span style="color: #000000;">(</span> hPBotRit <span style="color: #000000;">)</span>;<br /> <span style="color: #000000;">}</span><br /><br /> SelectObject<span style="color: #000000;">(</span> hDC, hOldPen <span style="color: #000000;">)</span>;<br /><br /> DeleteObject<span style="color: #000000;">(</span> hPBlack <span style="color: #000000;">)</span>;<br /><br /> ReleaseDC<span style="color: #000000;">(</span> hWnd, hDC <span style="color: #000000;">)</span>;<br /><br /> _ret<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br /><br /><span style="color: #000000;">}</span><br /> </div>[/code:226jc9s3] |
CLase Todometer de Ramón Avendaño | Saludos
les dejo la adaptacion a la version actual que esta usando fivewin, le añadi la tecnica de doble buffer, las adaptaciones en el codigo C y el cambio de un par de funciones
incluye librerias y obj, para harbour/xharbor, make/bat para generarlas, ejecutable ejemplo
[url:2lrjj6gf]http://www.sitasoft.net/fivewin/samples/odom.rar[/url:2lrjj6gf] |
CLase Todometer de Ramón Avendaño | !!Muchas gracias Daniel !! <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> |
CLase Todometer de Ramón Avendaño | Que lindo <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
Muchas gracias Daniel <!-- s:mrgreen: --><img src="{SMILIES_PATH}/icon_mrgreen.gif" alt=":mrgreen:" title="Mr. Green" /><!-- s:mrgreen: -->
Saluditos <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: --> |
CMIMEENC (pdf-file to mime) | Use
cResult := Hb_base64Encode(Hb_MemoRead('C:\Users\Marc\Documents\Factuur 20210005.pdf')) |
CMIMEENC (pdf-file to mime) | Hi,
A want to add a PDF-file into a xml-file with mime (base64) encoded.
How can I add this?
If I use
[code=fw:3lmxmxor]<div class="fw" id="{CB}" style="font-family: monospace;">CMIMEENC<span style="color: #000000;">(</span><span style="color: #ff0000;">'C:<span style="color: #000000;">\U</span>sers<span style="color: #000000;">\M</span>arc<span style="color: #000000;">\D</span>ocuments<span style="color: #000000;">\F</span>actuur 20210005.pdf'</span><span style="color: #000000;">)</span></div>[/code:3lmxmxor]
then the text 'C:\Users\Marc\Documents\Factuur 20210005.pdf' is converted.
Can I use memoread()? Does this also read the special characters of PDF-file? |
CMIMEENC CMIMEDEC. Donde encontrar estas dos funciones? | A que libreria pertenecen las funciones "cmimeenc" y "cmimedec"?. Estoy trabajando (bajo 16 bits) en una aplicación para el envio de mensajes empleando TSMTP y me hacen falta estas dos funciones.Gracias,Julio VivasCaracas - Venezuela |
CMIMEENC CMIMEDEC. Donde encontrar estas dos funciones? | Julio,Son funciones que proporciona FiveWin. Aqui tienes el código fuente:[code:1i702j9b]
//&& HEADER FILE --------------------------------------------------------------
// File Name: mime64.c
// Description: Mime Based Encoding/Decoding.
// Author: Jim Gale
// Date created: 8/28/97 Date updated: þ5/1/98
// Copyright: 1998 by Gale-Force. All Rights Reserved.
// Email: jg5@gale-force.com
//-----------------------------------------------------------------------------
#include <WinTen.h>
#include <Windows.h>
#include <ClipApi.h>
static char cMime[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
unsigned int at(char c1, char *c2);
CLIPPER CMIMEDEC( PARAMS )
{
int x, nIn, nLen, nOut;
unsigned short int n2, n3, n1, n4;
char far *cIn, *cOut;
cIn = _parc(1);
nIn = _parclen(1);
nLen = ((nIn+3)*3/4)+1;
cOut = ( char * ) _xgrab(nLen);
nOut = -1;
for(x=0;x<nIn;x+=4)
{
n1 = at((char) cIn[x] ,cMime);
n2 = at((char) cIn[x+1],cMime);
if ( (n3 = at((char) cIn[x+2],cMime))==64 ) {
cOut[++nOut] = (( ( n1 << 2) & 252 ) | ((n2 >> 4) & 3) );
break;
}
if ( (n4 = at((char) cIn[x+3],cMime))==64 ) {
cOut[++nOut] = (( ( n1 << 2) & 252 ) | ((n2 >> 4) & 3) );
cOut[++nOut] = (( ( n2 << 4) & 240 ) | ( (n3 >> 2) & 15) );
break;
}
cOut[++nOut] = (( ( n1 << 2) & 252 ) | ((n2 >> 4) & 3) );
cOut[++nOut] = (( ( n2 << 4) & 240 ) | ( (n3 >> 2) & 15) );
cOut[++nOut] = (( ( n3 << 6) & 192 ) | ( n4 & 63) );
}
_retclen( cOut, nOut+1 );
_xfree( cOut );
}
unsigned int at(char c1, char *c2)
{
int x=-1,nLen;
nLen = 65; //sizeof(c2);
while(++x<nLen)
{
if( (char) c1 == (char) c2[x] )
return x;
}
return 0;
}
CLIPPER CMIMEENC( PARAMS )
{
int x, nIn, nLen, nOut;
unsigned short int n2, n3, n1, n4, nA1, nA2, nA3;
char far *cIn, *cOut;
cIn = _parc(1);
nIn = _parclen(1);
nLen = ((nIn+2)*4/3)+1;
cOut = ( char * ) _xgrab(nLen);
nOut = -1;
for(x=0;x<nIn;x+=3)
{
switch ( nIn-x )
{
case 1 :
nA1 = ((char) (cIn[x ]));
n1 = ( ( nA1 >> 2) & 63 );
n2 = ( ( nA1 << 4) & 48 );
cOut[++nOut] = (char) cMime[n1];
cOut[++nOut] = (char) cMime[n2];
cOut[++nOut] = '=';
cOut[++nOut] = '=';
break;
case 2 :
nA1 = ((char) (cIn[x ]));
nA2 = ((char) (cIn[x+1]));
n1 = ( ( nA1 >> 2) & 63 );
n2 = ( ( ( nA1 << 4) & 48 ) | ( ( nA2 & 240 ) >> 4 ) );
n3 = ( ( ( nA2 << 4) & 240 ) >> 2 );
cOut[++nOut] = (char) cMime[n1];
cOut[++nOut] = (char) cMime[n2];
cOut[++nOut] = (char) cMime[n3];
cOut[++nOut] = '=';
break;
default:
nA1 = ((char) (cIn[x ]));
nA2 = ((char) (cIn[x+1]));
nA3 = ((char) (cIn[x+2]));
n1 = ( ( nA1 >> 2) & 63 );
n2 = ( ( ( nA1 << 4) & 48 ) | ( ( nA2 & 240 ) >> 4 ) );
n3 = ( ( ( ( nA2 << 4) & 240 ) >> 2 ) | ( ( nA3 >> 6 ) & 3 ) );
n4 = ( nA3 & 63 );
cOut[++nOut] = (char) cMime[n1];
cOut[++nOut] = (char) cMime[n2];
cOut[++nOut] = (char) cMime[n3];
cOut[++nOut] = (char) cMime[n4];
}
}
cOut[nOut+1] = 0;
_retclen( cOut, nOut+1 );
_xfree( cOut );
}
[/code:1i702j9b] |
CMIMEENC CMIMEDEC. Donde encontrar estas dos funciones? | Diciembre 08, 2008Muchas gracias Antonio, supuse que serian funciones del mismo FIVEWIN, pero la version que tengo no las contiene, no se si es porque el fivewin que utilizo es muy antiguo o porque en algun momento perdí las fuentes de "mime64.c".Nuevamente gracias y perdona las molestias.Julio VivasCaracas - Venezuela |
COBOL humour | <!-- m --><a class="postlink" href="http://archive.midrange.com/midrange-l/199705/msg00513.html">http://archive.midrange.com/midrange-l/ ... 00513.html</a><!-- m -->
---
There was once a COBOL programmer in the mid to late 1990s. For the
sake of this story, we'll call him Jack. After years of being taken
for granted and treated as a technological dinosaur by all the UNIX
programmers and Client/Server programmers and website developers, Jack
was finally getting some respect. He'd become a private consultant
specializing in Year 2000 conversions. He was working short-term
assignments for prestige companies, traveling all over the world on
different assignments. He was working 70 and 80 and even 90 hour
weeks, but it was worth it.
Several years of this relentless, mind-numbing work had taken its toll
on Jack. He had problems sleeping and began having anxiety dreams
about the Year 2000. It had reached a point where even the thought of
the year 2000 made him nearly violent. He must have suffered some sort
of breakdown, because all he could think about was how he could avoid
the year 2000 and all that came with it.
Jack decided to contact a company that specialized in cryogenics. He
made a deal to have himself frozen until March 15th, 2000. This was a
very expensive process and totally automated. He was thrilled. The
next thing he would know is he'd wake up in the year 2000; after the
New Year celebrations and computer debacles; after the leap day.
Nothing else to worry about except getting on with his life.
He was put into his cryogenic receptacle, the technicians set the
revive date, he was given injections to slow his heartbeat to a bare
minimum, and that was that.
The next thing that Jack saw was an enormous and very modern room
filled with excited people. They were all shouting "I can't believe
it!" and "It's a miracle" and "He's alive!". There were cameras
(unlike any he'd ever seen) and equipment that looked like it came out
of a science fiction movie.
Someone who was obviously a spokesperson for the group stepped
forward. Jack couldn't contain his enthusiasm. "It is over?" he asked.
"Is 2000 already here? Are all the millennial parties and promotions
and crises all over and done with?"
The spokesman explained that there had been a problem with the
programming of the timer on Jack's cryogenic receptacle, it hadn't
been year 2000 compliant. It was actually eight thousand years later,
not the year 2000. But the spokesman told Jack that he shouldn't get
excited; someone important wanted to speak to him.
Suddenly a wall-sized projection screen displayed the image of a man
that looked very much like Bill Gates. This man was Prime Minister of
Earth. He told Jack not to be upset. That this was a wonderful time to
be alive. That there was world peace and no more starvation. That the
space program had been reinstated and there were colonies on the moon
and on Mars. That technology had advanced to such a degree that
everyone had virtual reality interfaces which allowed them to contact
anyone else on the planet, or to watch any entertainment, or to hear
any music recorded anywhere.
"That sounds terrific," said Jack. "But I'm curious. Why is everybody
so interested in me?"
"Well," said the Prime Minister. "The year 10000 is just around the
corner, and it says in your files that you know COBOL."
---
Cheers, ROman |
CODE BAR ( por si alguien le sirve ) | Amigos con este código de barra, hecho en FWH,
imprimimos código de barra con BARLIB.
[code=fw:b9qkv41n]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">METHOD</span> BuildCode<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> ScCodebar<br /> <span style="color: #00C800;">local</span> oPrn<br /> <span style="color: #00C800;">local</span> nAncho := <span style="color: #000000;">6</span> <span style="color: #B900B9;">//medidas en cm</span><br /> <span style="color: #00C800;">local</span> nLargo := <span style="color: #000000;">3</span> <span style="color: #B900B9;">//medidas en cm</span><br /> <br /> PrnSetSize<span style="color: #000000;">(</span>nAncho*<span style="color: #000000;">100</span>, nLargo*<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <span style="color: #B900B9;">//tamaño de la etiqueta</span><br /><br /> <span style="color: #00C800;">PRINT</span> oPrn <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"SysCtrl CodeBar"</span> PREVIEW<br /><br /> <span style="color: #0000ff;">define</span> <span style="color: #0000ff;">font</span> oFont <span style="color: #0000ff;">name</span> <span style="color: #ff0000;">"New Roman"</span> <span style="color: #0000ff;">size</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-08</span> <span style="color: #0000ff;">of</span> oPrn<br /><br /> oPrn:<span style="color: #000000;">lPrvModal</span> := .t.<br /><br /> oPrn:<span style="color: #000000;">SetPortrait</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> ::<span style="color: #000000;">nRowStep</span> := oPrn:<span style="color: #000000;">nVertRes</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> / nLargo<br /> ::<span style="color: #000000;">nColStep</span> := oPrn:<span style="color: #000000;">nHorzRes</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> / nAncho<br /><br /> <span style="color: #00C800;">if</span> ! oPrn:<span style="color: #000000;">setup</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> <span style="color: #00C800;">endif</span><br /><br /><br /> <span style="color: #00C800;">for</span> i := <span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> nCuantos<br /> <span style="color: #0000ff;">PAGE</span><br /> nRow := <span style="color: #000000;">1</span><br /> nCol := .<span style="color: #000000;">5</span><br /><br /><br /> oPrn:<span style="color: #0000ff;">Say</span><span style="color: #000000;">(</span>nRow, ::<span style="color: #000000;">nColStep</span> * nCol,cstr2<span style="color: #000000;">(</span>cCode_bar<span style="color: #000000;">)</span>, oFont <span style="color: #000000;">)</span><br /><br /> nRow += ::<span style="color: #000000;">nRowStep*</span>.<span style="color: #000000;">5</span><br /><br /> @ nRow , ::<span style="color: #000000;">nColStep*nCol</span> code128 cstr2<span style="color: #000000;">(</span>cCode_bar<span style="color: #000000;">)</span> <span style="color: #0000ff;">of</span> oPrn <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">1</span><br /><br /> nRow += ::<span style="color: #000000;">nRowStep</span><br /><br /> oPrn:<span style="color: #0000ff;">Say</span><span style="color: #000000;">(</span> nRow, ::<span style="color: #000000;">nColStep</span> * nCol, cstr2<span style="color: #000000;">(</span>cNombre<span style="color: #000000;">)</span>, oFont <span style="color: #000000;">)</span><br /><br /><br /> <span style="color: #0000ff;">ENDPAGE</span><br /> <span style="color: #00C800;">next</span><br /> <span style="color: #0000ff;">ENDPRINT</span><br /> <br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /> </div>[/code:b9qkv41n]
[img:b9qkv41n]http://i64.tinypic.com/14e6h03.jpg[/img:b9qkv41n]
Por si a alguien le interesa ahi esta,
estas etiquetas se imprimen en una impresora ZEBRA,
saludos.. |
CODE BAR ( por si alguien le sirve ) | César, és posible hacer un DEMO simples en formato *.zip con las librerias que usastes y poner en un link? Gracias, saludos. |
CODE BAR ( por si alguien le sirve ) | Hola con mucho gusto, en un momento hago un test y lo subo aquí.
saludos.. |
CODE BAR ( por si alguien le sirve ) | karinha, amigo
servido aquí tienes,
saludos.
<!-- m --><a class="postlink" href="https://app.box.com/s/y6cfnku4stb9r0y2rgwf7rnc14djccxj">https://app.box.com/s/y6cfnku4stb9r0y2rgwf7rnc14djccxj</a><!-- m --> |
CODE BAR ( por si alguien le sirve ) | Muchas gracias Friend!! Excelente! |
CODE BAR ( por si alguien le sirve ) | César, mejoras:
[code=fw:1k5ke6uw]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivewin.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">'barcode.ch'</span> <span style="color: #B900B9;">// C:\FWH\INCLUDE</span><br /><br /><span style="color: #00D7D7;">#DEFINE</span> C_SIMPLE CHR<span style="color: #000000;">(</span> <span style="color: #000000;">39</span> <span style="color: #000000;">)</span><br /><span style="color: #00D7D7;">#DEFINE</span> c_simple CHR<span style="color: #000000;">(</span> <span style="color: #000000;">39</span> <span style="color: #000000;">)</span><br /><br />* +++++++++++++++++++++++++++++++++++++++++++++++++++++++ *<br />* *<br />* SysCtrl CodeBar + BARLIB DE Cayetano Gomez *<br />* *<br />* Sistema para imprimir codigos de barra *<br />* *<br />* fecha <span style="color: #000000;">26</span> de febrero <span style="color: #000000;">2016</span> *<br />* Autor: <span style="color: #000000;">Cesar</span> Cortes Cruz *<br />* CopyRight <span style="color: #000000;">(</span>c<span style="color: #000000;">)</span> SysCtrl Software <span style="color: #000000;">2003</span><span style="color: #000000;">-2016</span> *<br />* +++++++++++++++++++++++++++++++++++++++++++++++++++++++ *<br /><br /><span style="color: #B900B9;">/* Nota: <br /> esta aplicacion fue desarrollada para imprimir etiquetas de codigos de barra en impresora ZEBRA<br /> importante que la impresora este calibrada por el programa ( ZebraDesigner )<br /> toda duda o mejoras es bienvenido.<br />*/</span><br /><br /><span style="color: #00C800;">static</span> oCode, oWnd<br /><span style="color: #00C800;">static</span> cCode_bar<br /><span style="color: #00C800;">static</span> cNombre<br /><span style="color: #00C800;">static</span> nCuantos<br /><br />REQUEST HB_LANG_PT<br />REQUEST HB_CODEPAGE_PT850<br /><br /><span style="color: #00C800;">function</span> Principal<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">PRIVATE</span> <span style="color: #00C800;">SELF</span><br /><br /> SET DATE BRITISH<br /> SET EPOCH <span style="color: #0000ff;">TO</span> <span style="color: #000000;">1950</span><br /> SET CENTURY <span style="color: #0000ff;">ON</span><br /> SET SOFTSEEK OFF<br /> SET WRAP <span style="color: #0000ff;">ON</span><br /> SETCANCEL<span style="color: #000000;">(</span> .F. <span style="color: #000000;">)</span><br /> SET CONFIRM OFF<br /> SET DELETED <span style="color: #0000ff;">ON</span><br /> SET ESCAPE OFF<br /> SET EXACT <span style="color: #0000ff;">ON</span><br /> SET EXCLUSIVE OFF<br /> SET MULTIPLE OFF<br /><br /> HB_LANGSELECT<span style="color: #000000;">(</span> <span style="color: #ff0000;">'PT'</span> <span style="color: #000000;">)</span> <span style="color: #B900B9;">// Default language is now Portuguese</span><br /> HB_SETCODEPAGE<span style="color: #000000;">(</span> <span style="color: #ff0000;">"PT850"</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">IF</span> IsExeRunning<span style="color: #000000;">(</span> cFileName<span style="color: #000000;">(</span> HB_ARGV<span style="color: #000000;">(</span> <span style="color: #000000;">0</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> QUIT<br /> <span style="color: #00C800;">ENDIF</span><br /><br /> WITH OBJECT ScCodebar<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> :<span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> END OBJECT<br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">CLASS</span> ScCodebar<br /><br /> <span style="color: #00C800;">data</span> oCon AS OBJECT<br /><br /> * ---------------------------------- *<br /> * variables usadas en tprinter *<br /> * ---------------------------------- *<br /> <span style="color: #00C800;">data</span> nRowStep, nColStep<br /><br /> <span style="color: #00C800;">Method</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oCon <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">METHOD</span> MakeWin<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">METHOD</span> MakeDlg<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">METHOD</span> BuildCode<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">ENDCLASS</span><br /><br /><span style="color: #00C800;">METHOD</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> ScCodebar<br /><br /> ::<span style="color: #000000;">MakeWin</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">METHOD</span> MakeWin<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> ScCodebar<br /><br /> <span style="color: #00C800;">local</span> oMenu<br /> <span style="color: #00C800;">local</span> oSelf := <span style="color: #00C800;">Self</span><br /><br /> <span style="color: #0000ff;">menu</span> oMenu <span style="color: #000000;">2007</span><br /><br /> <span style="color: #0000ff;">menuitem</span> <span style="color: #ff0000;">"MENU: SysCtrl CodeBar + ( BARLIB ) "</span><br /><br /> <span style="color: #0000ff;">menu</span><br /><br /> <span style="color: #0000ff;">menuitem</span> <span style="color: #ff0000;">"Codigo STD Ean13"</span> <span style="color: #0000ff;">action</span><span style="color: #000000;">(</span> oSelf:<span style="color: #000000;">MakeDlg</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">SEPARATOR</span><br /> <span style="color: #0000ff;">menuitem</span> <span style="color: #ff0000;">"Salida del Sistema"</span> <span style="color: #0000ff;">action</span><span style="color: #000000;">(</span> Encerra<span style="color: #000000;">(</span> oWnd <span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">endmenu</span><br /><br /> <span style="color: #0000ff;">endmenu</span><br /><br /> <span style="color: #0000ff;">define</span> <span style="color: #0000ff;">window</span> oWnd <span style="color: #0000ff;">menu</span> oMenu <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"SysCtrl CodeBar + Barlib of Cayetano Gomez"</span><br /><br /> <span style="color: #0000ff;">activate</span> <span style="color: #0000ff;">window</span> oWnd<br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">METHOD</span> MakeDlg<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> ScCodebar<br /><br /> <span style="color: #00C800;">local</span> oGet := array<span style="color: #000000;">(</span> <span style="color: #000000;">10</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">local</span> oBtn := array<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">local</span> oBrush<br /> <span style="color: #00C800;">local</span> oBox<br /> <span style="color: #00C800;">local</span> nRow := <span style="color: #000000;">10</span><br /><br /> cCode_bar := <span style="color: #ff0000;">"A1A1A1A1A1A1"</span><br /> cNombre := <span style="color: #ff0000;">"NOMBRE DEL PRODUCTO"</span><br /> nCuantos := <span style="color: #000000;">10</span> <span style="color: #B900B9;">//cuantas etiquetas</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BRUSH</span> oBrush <span style="color: #0000ff;">color</span> nrgb<span style="color: #000000;">(</span><span style="color: #000000;">255</span>,<span style="color: #000000;">255</span>,<span style="color: #000000;">255</span> <span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oBox <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">600</span>, <span style="color: #000000;">250</span> <span style="color: #0000ff;">FONT</span> WndMain<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">oFont</span> TRANSPARENT <span style="color: #0000ff;">BRUSH</span> oBrush<br /><br /> oBox:<span style="color: #000000;">lhelpicon</span> := .F.<br /><br /> oBox:<span style="color: #000000;">lTransparent</span> := .t.<br /> oBox:<span style="color: #000000;">cTitle</span> := <span style="color: #ff0000;">"Impresion de etiquedas para productos ..."</span><br /><br /> @ nRow, <span style="color: #000000;">10</span> <span style="color: #0000ff;">SAY</span> <span style="color: #ff0000;">"Clave de producto: "</span> <span style="color: #0000ff;">OF</span> oBox <span style="color: #0000ff;">pixel</span><br /> @ nRow, <span style="color: #000000;">70</span> <span style="color: #0000ff;">GET</span> oGet<span style="color: #000000;">[</span> <span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> cCode_bar <span style="color: #0000ff;">of</span> oBox <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>, <span style="color: #000000;">10</span> ;<br /> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@!k"</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">UPDATE</span><br /><br /> nRow += <span style="color: #000000;">15</span><br /><br /> @ nRow, <span style="color: #000000;">10</span> <span style="color: #0000ff;">SAY</span> <span style="color: #ff0000;">"Nombre: "</span> <span style="color: #0000ff;">OF</span> oBox <span style="color: #0000ff;">pixel</span><br /> @ nRow, <span style="color: #000000;">70</span> <span style="color: #0000ff;">GET</span> oGet<span style="color: #000000;">[</span> <span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> cNombre <span style="color: #0000ff;">of</span> oBox <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">230</span>, <span style="color: #000000;">10</span> ;<br /> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@!k"</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">UPDATE</span><br /> <br /> nRow += <span style="color: #000000;">15</span><br /><br /> @ nRow, <span style="color: #000000;">10</span> <span style="color: #0000ff;">SAY</span> <span style="color: #ff0000;">"Cuantas etiquetas : ? "</span> <span style="color: #0000ff;">OF</span> oBox <span style="color: #0000ff;">pixel</span><br /> @ nRow, <span style="color: #000000;">70</span> <span style="color: #0000ff;">GET</span> oGet<span style="color: #000000;">[</span> <span style="color: #000000;">3</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">VAR</span> nCuantos <span style="color: #0000ff;">of</span> oBox <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">30</span>, <span style="color: #000000;">10</span> ;<br /> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"999999"</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">UPDATE</span><br /><br /> @ <span style="color: #000000;">5.3</span>, <span style="color: #000000;">6</span> <span style="color: #0000ff;">BUTTON</span> oBtn<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"&Aceptar"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">48</span>, <span style="color: #000000;">24</span> <span style="color: #0000ff;">OF</span> oBox ;<br /> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">(</span> ::<span style="color: #000000;">BuildCode</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span>, oGet<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><br /> @ <span style="color: #000000;">5.3</span>, <span style="color: #000000;">18</span> <span style="color: #0000ff;">BUTTON</span> oBtn<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"&Regresar"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">48</span>, <span style="color: #000000;">24</span> <span style="color: #0000ff;">OF</span> oBox <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">(</span> oBox:<span style="color: #000000;">end</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> CANCEL<br /><br /> <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oBox <span style="color: #0000ff;">CENTERED</span><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /><br /><span style="color: #00C800;">METHOD</span> BuildCode<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">CLASS</span> ScCodebar<br /><br /> <span style="color: #00C800;">local</span> oPrn<br /> <span style="color: #00C800;">local</span> nAncho := <span style="color: #000000;">6</span> <span style="color: #B900B9;">//medidas en cm</span><br /> <span style="color: #00C800;">local</span> nLargo := <span style="color: #000000;">3</span> <span style="color: #B900B9;">//medidas en cm</span><br /> <span style="color: #00C800;">local</span> oFont<br /> <span style="color: #00C800;">local</span> nRow, nCol<br /><br /> PrnSetSize<span style="color: #000000;">(</span>nAncho*<span style="color: #000000;">100</span>, nLargo*<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <span style="color: #B900B9;">//tamaño de la etiqueta</span><br /><br /> <span style="color: #00C800;">PRINT</span> oPrn <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"SysCtrl CodeBar"</span> PREVIEW<br /><br /> <span style="color: #0000ff;">define</span> <span style="color: #0000ff;">font</span> oFont <span style="color: #0000ff;">name</span> <span style="color: #ff0000;">"New Roman"</span> <span style="color: #0000ff;">size</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-08</span> <span style="color: #0000ff;">of</span> oPrn<br /><br /> oPrn:<span style="color: #000000;">lPrvModal</span> := .t.<br /><br /> oPrn:<span style="color: #000000;">SetPortrait</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> ::<span style="color: #000000;">nRowStep</span> := oPrn:<span style="color: #000000;">nVertRes</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> / nLargo<br /> ::<span style="color: #000000;">nColStep</span> := oPrn:<span style="color: #000000;">nHorzRes</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> / nAncho<br /><br /> <span style="color: #00C800;">if</span> ! oPrn:<span style="color: #000000;">setup</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /> <span style="color: #00C800;">endif</span><br /><br /><br /> <span style="color: #00C800;">for</span> i := <span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> nCuantos<br /> <span style="color: #0000ff;">PAGE</span><br /> nRow := <span style="color: #000000;">1</span><br /> nCol := .<span style="color: #000000;">5</span><br /><br /> oPrn:<span style="color: #0000ff;">Say</span><span style="color: #000000;">(</span>nRow, ::<span style="color: #000000;">nColStep</span> * nCol,cstr2<span style="color: #000000;">(</span>cCode_bar<span style="color: #000000;">)</span>, oFont <span style="color: #000000;">)</span><br /><br /> nRow += ::<span style="color: #000000;">nRowStep*</span>.<span style="color: #000000;">5</span><br /><br /> @ nRow , ::<span style="color: #000000;">nColStep*nCol</span> code128 cstr2<span style="color: #000000;">(</span>cCode_bar<span style="color: #000000;">)</span> <span style="color: #0000ff;">of</span> oPrn <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">1</span><br /><br /> nRow += ::<span style="color: #000000;">nRowStep</span><br /><br /> oPrn:<span style="color: #0000ff;">Say</span><span style="color: #000000;">(</span> nRow, ::<span style="color: #000000;">nColStep</span> * nCol, cstr2<span style="color: #000000;">(</span>cNombre<span style="color: #000000;">)</span>, oFont <span style="color: #000000;">)</span><br /><br /><br /> <span style="color: #0000ff;">ENDPAGE</span><br /><br /> <span style="color: #00C800;">next</span><br /><br /> <span style="color: #0000ff;">ENDPRINT</span><br /> <br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br /><br /><span style="color: #00C800;">FUNCTION</span> cStr2<span style="color: #000000;">(</span> nNum <span style="color: #000000;">)</span><br /><span style="color: #00C800;">RETURN</span> AllTrim<span style="color: #000000;">(</span> CStr<span style="color: #000000;">(</span> nNum <span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /><br /><br /><span style="color: #00C800;">FUNCTION</span> ENCERRA<span style="color: #000000;">(</span> oWnd <span style="color: #000000;">)</span><br /><br /> oWnd:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> FreeResources<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> SysRefresh<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #0000ff;">RELEASE</span> All<br /><br /> Hb_GCAll<span style="color: #000000;">(</span> .T. <span style="color: #000000;">)</span><br /><br /> CLEAR MEMORY<br /><br /> PostQuitMessage<span style="color: #000000;">(</span> <span style="color: #000000;">0</span> <span style="color: #000000;">)</span><br /><br /> __QUIT<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /><br /><span style="color: #B900B9;">// FIN</span><br /> </div>[/code:1k5ke6uw]
Muchas gracias, saludos. |
CODE BAR ( por si alguien le sirve ) | Bien amigo, gracias,
saludos.. |
CODE BAR ( por si alguien le sirve ) | Muchas gracias, Cesar. Voy a probarlo.
Saludos. |
CODE BAR ( por si alguien le sirve ) | ok. Francisco,
saludos.
Cesar. |
CODE BAR ( por si alguien le sirve ) | [quote="sysctrl2":2pbvsj4e]ok. Francisco,
saludos.
Cesar.[/quote:2pbvsj4e]
Gracias Cesar Cortez.
Saludos |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | Code complete:
[code:1g8ttpip]
// FiveWin OLE support demo
// Using Microsoft MAPI Control
// By Rochinha - Brazil
#include "FiveWin.ch"
#define SESSION_SIGNON 1
#define MESSAGE_COMPOSE 6
#define ATTACHTYPE_DATA 0
#define RECIPTYPE_TO 1
#define RECIPTYPE_CC 2
#define MESSAGE_RESOLVENAME 13
#define MESSAGE_SEND 3
#define SESSION_SIGNOFF 2
function Main()
local oWnd
DEFINE WINDOW oWnd TITLE "FiveWin OLE Support"
MapiSession1 := TOleAuto():New( "MSMAPI.MAPISession.1" )
MapiMessages1 := TOleAuto():New( "MSMAPI.MAPImessages.1" )
//MapiSession1:aboutbox()
//Open up a MAPI session
MapiSession1:Action := SESSION_SIGNON
//Point the MAPI messages control to the open MAPI session:
MapiMessages1:SessionID := 1
MapiMessages1:Action := MESSAGE_COMPOSE //Start a new message
// Set the subject of the message:
MapiMessages1:MsgSubject := "This is the subject."
// Set the message content
MapiMessages1:MsgNoteText:= "This is the mail message."
// The following four lines of code add an attachment to the message,
// and set the character position within the MsgNoteText where the
// attachment icon will appear. A value of 0 means the attachment will
// replace the first character in the MsgNoteText. You must have at
// least one character in the MsgNoteText to be able to attach a file.
MapiMessages1:AttachmentPosition := 0
// Set the type of attachment
MapiMessages1:AttachmentType := ATTACHTYPE_DATA
// Set the icon title of attachment:
MapiMessages1:AttachmentName := "System Configuration File"
// Set the path and file name of the attachment:
MapiMessages1:AttachmentPathName := "C:\CONFIG.SYS"
// Set the recipients
MapiMessages1:RecipIndex := 0 // First recipient
MapiMessages1:RecipType := RECIPTYPE_TO // Recipient in TO line
MapiMessages1:RecipDisplayName := "EddieSpaghetti" // e-mail name
MapiMessages1:RecipIndex := 1 // add a second recipient
MapiMessages1:RecipType := RECIPTYPE_TO // Recipient in TO line
MapiMessages1:RecipDisplayName := "TanyaLasagna" // e-mail name
MapiMessages1:RecipIndex := 2 // Add a third recipient
MapiMessages1:RecipType := RECIPTYPE_CC // Recipient in CC line
MapiMessages1:RecipDisplayName := "BlairAngelHair" // e-mail name
MapiMessages1:RecipIndex := 3 // Add a fourth recipient
MapiMessages1:RecipType := RECIPTYPE_CC // Recipient on CC Line
MapiMessages1:RecipDisplayName := "JoanieCannelloni" // e-mail name"
// MESSAGE_RESOLVENAME checks to ensure the recipient is valid and puts
// the recipient address in MapiMessages1:RecipAddress
// If the E-Mail name is not valid, a trappable error will occur.
MapiMessages1:Action := MESSAGE_RESOLVENAME
// Send the message:
MapiMessages1:Action := MESSAGE_SEND
// Close MAPI mail session:
MapiSession1:Action := SESSION_SIGNOFF
ACTIVATE WINDOW oWnd
return nil
[/code:1g8ttpip]
Download de .OCX
<!-- m --><a class="postlink" href="http://home.wxs.nl/~hafoh000/MSMAPI32.zip">http://home.wxs.nl/~hafoh000/MSMAPI32.zip</a><!-- m --> |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | Hello Rochinha,
Thanks for your help and file.
I will get new skill for it.
But I got this error message
Error description: Error TOleAuto/-1 Unknown error: TOLEAUTO:NEW
Regards,
Richard |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | Hola
Gracias por el código, lo que pasa es que, aunque me compila perfectamente, cuando ejecuto la aplicación me da el siguiente error:
Error description: Error TOleAuto/-1 Unknown error: TOLEAUTO:NEW
Que puede ser?
Saludos
Jose Luis |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | Excuse me friends,
Download the .OCX on link below and register in your system first:
<!-- m --><a class="postlink" href="http://home.wxs.nl/~hafoh000/MSMAPI32.zip">http://home.wxs.nl/~hafoh000/MSMAPI32.zip</a><!-- m -->
COPY MSMAPI32.OCX C:\WINDOWS\SYSTEM32
CD WINDOWS\SYSTEM32
REGSVR32.EXE MSMAPI32.OCX
I'm use a tradicional Harbour, not xHarbour.
Change the TAutoOLE() to CreateOLEObject()
MapiSession1 := CreateOLEObject( "MSMAPI.MAPISession.1" )
MapiMessages1 := CreateOLEObject( "MSMAPI.MAPImessages.1" )
And set properties and methods to:
Properties:
OLESetProperty(MapiSession1,"property",value)
OLEGetProperty(MapiSession1,"property")
Methods:
OLEInvoke(MapiSession1,"method") |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | Here is the Send/Receiving code:
[code:2k9xmdes]
// FiveWin OLE support demo - Using Microsoft MAPI Control
#include "FiveWin.ch"
#define SESSION_SIGNON 1
#define MESSAGE_COMPOSE 6
#define ATTACHTYPE_DATA 0
#define RECIPTYPE_TO 1
#define RECIPTYPE_CC 2
#define MESSAGE_RESOLVENAME 13
#define MESSAGE_SEND 3
#define SESSION_SIGNOFF 2
function Main()
local oWnd, aMessages := {}
SET DATE BRIT
//
// FiveWin OLE Support - Sending
//
MapiSession1 := TOleAuto():New( "MSMAPI.MAPISession.1" )
MapiMessages1 := TOleAuto():New( "MSMAPI.MAPImessages.1" )
//MapiSession1:aboutbox()
//Open up a MAPI session
MapiSession1:Action := SESSION_SIGNON
//Point the MAPI messages control to the open MAPI session:
MapiMessages1:SessionID := MAPISession1:SessionID
MapiMessages1:Action := MESSAGE_COMPOSE //Start a new message
// Set the subject of the message:
MapiMessages1:MsgSubject := "This is the subject."
// Set the message content
MapiMessages1:MsgNoteText:= "This is the mail message."
// The following four lines of code add an attachment to the message,
// and set the character position within the MsgNoteText where the
// attachment icon will appear. A value of 0 means the attachment will
// replace the first character in the MsgNoteText. You must have at
// least one character in the MsgNoteText to be able to attach a file.
MapiMessages1:AttachmentPosition := 0
// Set the type of attachment
MapiMessages1:AttachmentType := ATTACHTYPE_DATA
// Set the icon title of attachment
MapiMessages1:AttachmentName := "System Configuration File"
// Set the path and file name of the attachment
MapiMessages1:AttachmentPathName := "C:\CONFIG.SYS"
// Set the TO recipients
aTORecipients := { "softclever@itelefonica.com.br", ;
"irochinha@itelefonica.com.br", ;
"fivolution@hotmail.com", ;
"softclever@ig.com.br" }
aCCRecipients := { RECIPTYPE_TO, RECIPTYPE_CC, RECIPTYPE_CC, RECIPTYPE_CC }
for i = 1 to len(aTORecipients)
MapiMessages1:RecipIndex := i // Recipient count
MapiMessages1:RecipType := aCCRecipients[i] // Recipient in TO line
MapiMessages1:RecipDisplayName := aTORecipients[i] // e-mail name
MapiMessages1:MsgReceiptRequested := .t.
next
// MESSAGE_RESOLVENAME checks to ensure the recipient is valid and puts
// the recipient address in MapiMessages1:RecipAddress
// If the E-Mail name is not valid, a trappable error will occur.
MapiMessages1:Action := MESSAGE_RESOLVENAME
// Send the message
MapiMessages1:Action := MESSAGE_SEND
// Close MAPI mail session
MapiSession1:Action := SESSION_SIGNOFF
MapiSession1:End()
MapiMessages1:End()
//
// FiveWin OLE Support - Receiving
//
MapiSession1 := TOleAuto():New( "MSMAPI.MAPISession.1" )
MapiMessages1 := TOleAuto():New( "MSMAPI.MAPImessages.1" )
MAPISession1:DownLoadMail := .t.
MAPISession1:SignOn()
MAPIMessages1:SessionID := MAPISession1:SessionID
MAPIMessages1:Fetch()
nMsgHoje := 0
nMsgLida := 0
If MAPIMessages1:MsgCount > 0
For i = 0 To MAPIMessages1:MsgCount - 1
MAPIMessages1:MsgIndex := i
if MDtoD( MAPIMessages1:MsgDateReceived ) = date()
nMsgHoje := nMsgHoje + 1
endif
if MAPIMessages1:MsgRead
nMsgLida := nMsgLida + 1
endif
AADD( aMessages, { "From: " + MAPIMessages1:MsgOrigDisplayName, ;
"Subject: " + MAPIMessages1:MsgSubject } )
Next
End If
MAPISession1:SignOff()
MapiSession1:End()
MapiMessages1:End()
? "Menssages: "+str(len( aMessages )), "Today: "+str(nMsgHoje), "Reads: "+str(nMsgLida)
return nil
Function MDtoD( cData )
cData := substr( cData, 1, 10 )
return ctod( substr(cData,9,2)+"/"+substr(cData,6,2)+"/"+substr(cData,1,4) )
[/code:2k9xmdes] |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | Hola Rochinha
Yo utilizo xharbour+verce, y siempre que quiero utilizar Toleauto:New, me da error, y es que no se si tengo que enlazar con alguna libreria o qué.
Como has indicado, he sustituido
[code:3lgb2miu] MapiSession1 := TOleAuto():New( "MSMAPI.MAPISession.1" )
MapiMessages1 := TOleAuto():New( "MSMAPI.MAPImessages.1" )
[/code:3lgb2miu]
por
[code:3lgb2miu]MapiSession1 := CreateOLEObject( "MSMAPI.MAPISession.1" )
MapiMessages1 := CreateOLEObject( "MSMAPI.MAPImessages.1" )
[/code:3lgb2miu]
y ahora me sale en tiempo de ejecución el siguiente error:
" Error description: Error BASE/1005 Class: 'NUMERIC' has no property: ACTION"
Este error hace referencia a ésta línea:
" MapiSession1:Action := SESSION_SIGNON "
Me das algún consejo?
Saludos
Jose Luis |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | eu recebi o mesmo erro que o Jose Luiz
Ari |
CODE SAMPLE: Here is Microsoft MAPI support with OCX | ¿Hay alguien aquí trató de leer un servidor POP3 para descubrir nuevos correos no leídos en un servidor POP3.
También estoy recibiendo el mismo error.
Si puedo comprobar el ValType de
[code=fw:gs77l42v]<div class="fw" id="{CB}" style="font-family: monospace;">MapiSession1: = CreateOleObject <span style="color: #000000;">(</span> <span style="color: #ff0000;">"MSMAPI.MAPISession.1"</span><span style="color: #000000;">)</span></div>[/code:gs77l42v]
Se trata de "N" (numérico)
Me estoy haciendo el mismo error que José Luis y Ari
¿Hay algo malo?. ¿Alguien trató este
Saludos
Anser |
CODE128 BARCODE | I have to print CODE128 barcode with fivewin .I also have to be able to use it in word , excel .The string i have to print look like : =B01420806123400(It is for a medical use)How to ?Thanks |
CODE128 BARCODE | [quote="Jack":2nykh9bg]I have to print CODE128 barcode with fivewin .
I also have to be able to use it in word , excel .
The string i have to print look like : =B01420806123400
(It is for a medical use)
How to ?
Thanks[/quote:2nykh9bg]There are ttf fonts code128, with them you can simply print with tprint of fwh and with all windows applications with codebars.The only problem is that you will have to install this font in all pc´s that will print codebars. |
CODE128 BARCODE | Thanks for this answer .Where can i find this font .Do you have also a sample of code .Thanks |
CODE128 BARCODE | Hello Jack,there are mostly commercial-versions of this font.Here is a free one from my website :<!-- m --><a class="postlink" href="http://www.pflegeplus.com/fw_downloads/code128.ttf">http://www.pflegeplus.com/fw_downloads/code128.ttf</a><!-- m -->RegardsUwe <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: --> |
CODE128 BARCODE | What about the code :PRINT oprint NAME "Test Font128"DEFINE FONT oFont NAME "CODE128" SIZE 0,-20 of OprintoPrint:CmSay(ol,0.5,ww,oFont) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.