|
The API Documentation is no help. It assumes you will use POSTMAN to access the ADP API.
I need to run daily with a C# program to pull data.
Has anyone been able to build a C# program to integrate using the ADP API?
If so, can you sure some insights?
I've successfully integrated C# with PointClickCare's API and NetHealth's API, one using XML objects and the other using JSON objects.
|
|
|
|
|
If you use Postman 10.10.6 or later, it has built-in support for generating a C# snippet to replicate the Postman request. You can generate code that uses RestSharp, or code that uses the raw HttpClient.
Open a working request in Postman, and click on the </> icon on the right-hand side.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Richard Deeming wrote: it has built-in support for generating a C# snippet
Well that is interesting information. I would not have even thought to look for that.
|
|
|
|
|
trying to convert dataMember from int to Color
color1.DataBindings.Add("BackColor",NavBill.DataSource,"Color1" );
Control : color1 is panel
Binding dataMember : "Color1" is columns(int,null)
How can convert dataMemer value from (int) to (Color) before assignment to property?
|
|
|
|
|
Yes you just need to use a Format event handler on the Binding object
For example
private void AddBinding() {
Binding b = color1.DataBindings.Add("BackColor", NavBill.DataSource, "Color1", true);
b.Format += PanelBackColorBinding_Format;
}
private void PanelBackColorBinding_Format(Object sender, ConvertEventArgs e) {
if (e.DesiredType == typeof(Color)) {
Int32 number = (Int32)e.Value;
Color col = GetColor(number);
e.Value = col;
}
}
Make sure that a default color is assigned to e.Value if there is any chance that the column will have missing or non convertable values.
|
|
|
|
|
Hey Everyone:
I've never done something like this before - announcing the relase of my first NuGet package. (I've had a couple of others but they were really niche.) This is an extension to the MarkDig markdown parser in .NET 6, and I used a tutorial article from here to make it happen! Thanks @cyotek for the big help!
The source code - along with my hopefully coherent documentation - is available at:
GitHub - crazycga/Evergrowth.AspForMarkDigExtension: This is the source repository for the Asp-For MarkDig Extension.[^]
The NuGet package is called "Evergrowth.AspForMarkDigExtension".
What it does:
I had a situation where a client of mine wanted to use markdown to prepare some forms for clients. Semi-static stuff. I found that when I was parsing the markdown in the controller, it wasn't getting parsed properly to make use of the 'asp-for="<model name="">"' function to build input fields. I tilted at that windmill for a time, then decided it would be a good way to grow a little as a developer and get input on my stuff... So here we are.
Thanks everyone here who - over the years - has helped me immeasurably become better at this!
-J
|
|
|
|
|
Don't post this here - forums can move pretty rapidly, and once this scrolls off the first page it gets less likely that anyone will ever see it. Plus, it's kinda rude for a "technical forum" to be plugging your work, even a free to use nuget package.
Instead, have you considered posting the Github as a Project here? Provided your documentation is indeed coherent it should be pretty easy to do: Your GitHub Project on CodeProject[^] and that is more likely to be found.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Sorry didn't mean to be rude. Was trying to thank someone for their help and inspiration. And didn't want to have a huge long lasting thing so figured posting in a forum would be good, so that it was ephemeral. For some reason I can't seem to delete to post. If you can, please do so.
|
|
|
|
|
If you want to thank someone, reply to a comment they made, or post at the bottom of the article. That way they should notice it*
Why would you want your work to be ephemeral, if you are sharing it anyway?
You can't delete your post because it has a reply - that would "orphan" the response(s) and lose the meaning of the thread (obvious if you think about it). Yes I can delete the whole thread (all Protectors can) but it's not necessary it's only "slightly rude" not "you b*****d" rude! I wouldn't worry about it, but if you still want that, just say the word.
* Some people run with emails disabled, or deliberately use a dummy email so "@" messages may not get through at all.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Since the license makes it free you can post in the Free Tools forum.
|
|
|
|
|
I want to parse multiple html table using htmlagility pack. i want to iterate in all TD and extract values.
please have a look at this url https:
the above url has many tabular data whose html tables i have to parse.
here i am pasting a small snippet of html table. please check how data is stored in this table.
<pre><table style="border-collapse:collapse;display:inline-table;margin-bottom:5pt;vertical-align:text-bottom;width:99.853%"> <tbody> <tr> <td style="width:1.0%"></td> <td style="width:71.960%"></td> <td style="width:0.1%"></td> <td style="width:0.1%"></td> <td style="width:0.532%"></td> <td style="width:0.1%"></td> <td style="width:1.0%"></td> <td style="width:11.637%"></td> <td style="width:0.1%"></td> <td style="width:0.1%"></td> <td style="width:0.532%"></td> <td style="width:0.1%"></td> <td style="width:1.0%"></td> <td style="width:11.639%"></td> <td style="width:0.1%"></td> </tr> <tr style="height:12pt"> <td colspan="3" style="padding:2px 1pt;text-align:left;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:1pt;font-weight:700;line-height:100%"> </span></td> <td colspan="3" style="padding:0 1pt"></td> <td colspan="3" rowspan="2" style="padding:2px 1pt;text-align:center;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:8pt;font-weight:700;line-height:100%">June 30,<br>2023</span></td> <td colspan="3" style="padding:0 1pt"></td> <td colspan="3" rowspan="2" style="padding:2px 1pt;text-align:center;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:8pt;font-weight:700;line-height:100%">December 31,<br>2022</span></td> </tr> <tr style="height:12pt"> <td colspan="3" style="padding:2px 1pt;text-align:left;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:8pt;font-weight:700;line-height:100%">(In thousands, except share data)</span></td> <td colspan="3" style="padding:0 1pt"></td> <td colspan="3" style="padding:0 1pt"></td> </tr> <tr> <td colspan="3" style="background-color:#cceeff;border-top:1pt solid #000000;padding:2px 1pt;text-align:left;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:10pt;font-weight:700;line-height:100%">Assets</span></td> <td colspan="3" style="background-color:#cceeff;padding:0 1pt"></td> <td colspan="3" style="background-color:#cceeff;border-top:1pt solid #000000;padding:2px 1pt;text-align:right;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:1pt;font-weight:700;line-height:100%"> </span></td> <td colspan="3" style="background-color:#cceeff;padding:0 1pt"></td> <td colspan="3" style="background-color:#cceeff;border-top:1pt solid #000000;padding:2px 1pt;text-align:right;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:1pt;font-weight:400;line-height:100%"> </span></td> </tr> <tr> <td colspan="3" style="background-color:#ffffff;padding:2px 1pt;text-align:left;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:10pt;font-weight:400;line-height:100%">Cash and due from banks</span></td> <td colspan="3" style="background-color:#ffffff;padding:0 1pt"></td> <td style="background-color:#ffffff;padding:2px 0 2px 1pt;text-align:left;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:10pt;font-weight:400;line-height:100%">$</span></td> <td style="background-color:#ffffff;padding:2px 0;text-align:right;vertical-align:bottom"> <span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:10pt;font-weight:400;line-height:100%"> <ix:nonfraction unitref="usd" contextref="c-3" decimals="-3" name="us-gaap:CashAndDueFromBanks" format="ixt:num-dot-decimal" scale="3" id="f-32">120,285</ix:nonfraction> </span> </td> <td style="background-color:#ffffff;padding:2px 1pt 2px 0;text-align:right;vertical-align:bottom"></td> <td colspan="3" style="background-color:#ffffff;padding:0 1pt"></td> <td style="background-color:#ffffff;padding:2px 0 2px 1pt;text-align:left;vertical-align:bottom"><span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:10pt;font-weight:400;line-height:100%">$</span></td> <td style="background-color:#ffffff;padding:2px 0;text-align:right;vertical-align:bottom"> <span style="color:#000000;font-family:'Times New Roman',sans-serif;font-size:10pt;font-weight:400;line-height:100%"> <ix:nonfraction unitref="usd" contextref="c-4" decimals="-3" name="us-gaap:CashAndDueFromBanks" format="ixt:num-dot-decimal" scale="3" id="f-33">145,342</ix:nonfraction> </span> </td> <td style="background-color:#ffffff;padding:2px 1pt 2px 0;text-align:right;vertical-align:bottom"></td> </tr> </tbody> </table>
Some time TD has direct data and some time TD has SPAN which has data. some time SPAN has custom tag which has data <ix:nonfraction
for a long time i am trying to loop through all TD's of all table and extract data only but getting no success.
here is my code which is trying to iterate and get data but code is not working.
<pre>var table1 = htmlDoc.DocumentNode.SelectNodes("//table");
var tbody = table1.ChildNodes["tbody"];
var lst = new List<Table1>();
foreach (var row in tbody.ChildNodes.Where(r => r.Name == "tr"))
{
var tbl1 = new Table1();
var columnsArray = row.ChildNodes.Where(c => c.Name == "td").ToArray();
for (int i = 0; i < columnsArray.Length; i++)
{
if (i == 0)
tbl1.Course = columnsArray[i].InnerText.Trim();
if (i == 1)
tbl1.Count = columnsArray[i].InnerText.Trim();
if (i == 2)
tbl1.Correct = columnsArray[i].InnerText.Trim();
}
lst.Add(tbl1);
}
Please some one guide me with a sample code which can extract data from html table TR,TD
please please need your support and help to extract data from html tables. thanks
|
|
|
|
|
Quote: but code is not working. Unfortunately that does not provide us with any useful information as to what happens when you run your code. Please edit your question, and add complete details of what is not working.
|
|
|
|
|
The name looked familiar, so I searched messages for it.
If it's the same person, and his question here fits the pattern in the days before, he's an old Assistive Nosferatu we terminated six years ago.
Just a heads up.
|
|
|
|
|
Thanks Dave. Let's see how this pans out.
|
|
|
|
|
What are you trying to say
pans out ??
|
|
|
|
|
I was replying to Dave Kreskowiak.
|
|
|
|
|
Why Dave said this ->
The name looked familiar, so I searched messages for it. what he is talking about?
|
|
|
|
|
It's a private conversation.
|
|
|
|
|
if private conversation then why you guys post text in my thread?
why do not create a new thread and gossip there?
|
|
|
|
|
Because you have a history here. One that got you booted before.
|
|
|
|
|
I wondered about that. I thought I'd seen the name. I was sure that Buffy had done her thing with Mr Pointy.
|
|
|
|
|
Tridip Bhattacharjee from Unknown wrote: code is not working.
Explain how it is not working.
Also explain what you did to determine exactly where it is failing.
|
|
|
|
|
Now it is working. i made some mistake in code. Thanks
|
|
|
|
|
getting too slow when connect c# desktop application with mysql cloud database
|
|
|
|
|
I am thinking you're going to need a lot more information than that.
"the debugger doesn't tell me anything because this code compiles just fine" - random QA comment
"Facebook is where you tell lies to your friends. Twitter is where you tell the truth to strangers." - chriselst
"I don't drink any more... then again, I don't drink any less." - Mike Mullikins uncle
|
|
|
|